diff --git a/.buildinfo b/.buildinfo new file mode 100644 index 00000000..356587de --- /dev/null +++ b/.buildinfo @@ -0,0 +1,4 @@ +# Sphinx build info version 1 +# This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done. +config: 6c7c1262a1580286ec92e39d17c05019 +tags: 645f666f9bcd5a90fca523b33c5a78b7 diff --git a/.doctrees/api_reference.doctree b/.doctrees/api_reference.doctree new file mode 100644 index 00000000..67497655 Binary files /dev/null and b/.doctrees/api_reference.doctree differ diff --git a/.doctrees/calling_the_notecard_api.doctree b/.doctrees/calling_the_notecard_api.doctree new file mode 100644 index 00000000..48c4531a Binary files /dev/null and b/.doctrees/calling_the_notecard_api.doctree differ diff --git a/.doctrees/environment.pickle b/.doctrees/environment.pickle new file mode 100644 index 00000000..0feede96 Binary files /dev/null and b/.doctrees/environment.pickle differ diff --git a/.doctrees/getting_started.doctree b/.doctrees/getting_started.doctree new file mode 100644 index 00000000..21e1ecbf Binary files /dev/null and b/.doctrees/getting_started.doctree differ diff --git a/.doctrees/index.doctree b/.doctrees/index.doctree new file mode 100644 index 00000000..5563b0d5 Binary files /dev/null and b/.doctrees/index.doctree differ diff --git a/.doctrees/library_initialization.doctree b/.doctrees/library_initialization.doctree new file mode 100644 index 00000000..c39cb7f4 Binary files /dev/null and b/.doctrees/library_initialization.doctree differ diff --git a/.doctrees/ports.doctree b/.doctrees/ports.doctree new file mode 100644 index 00000000..9cc1983a Binary files /dev/null and b/.doctrees/ports.doctree differ diff --git a/.nojekyll b/.nojekyll new file mode 100644 index 00000000..e69de29b diff --git a/CMakeFiles/CMakeDirectoryInformation.cmake b/CMakeFiles/CMakeDirectoryInformation.cmake new file mode 100644 index 00000000..296016b3 --- /dev/null +++ b/CMakeFiles/CMakeDirectoryInformation.cmake @@ -0,0 +1,16 @@ +# CMAKE generated file: DO NOT EDIT! +# Generated by "Unix Makefiles" Generator, CMake Version 3.29 + +# Relative path conversion top directories. +set(CMAKE_RELATIVE_PATH_TOP_SOURCE "/home/runner/work/note-c/note-c") +set(CMAKE_RELATIVE_PATH_TOP_BINARY "/home/runner/work/note-c/note-c/build") + +# Force unix paths in dependencies. +set(CMAKE_FORCE_UNIX_PATHS 1) + + +# The C and CXX include file regular expressions for this directory. +set(CMAKE_C_INCLUDE_REGEX_SCAN "^.*$") +set(CMAKE_C_INCLUDE_REGEX_COMPLAIN "^$") +set(CMAKE_CXX_INCLUDE_REGEX_SCAN ${CMAKE_C_INCLUDE_REGEX_SCAN}) +set(CMAKE_CXX_INCLUDE_REGEX_COMPLAIN ${CMAKE_C_INCLUDE_REGEX_COMPLAIN}) diff --git a/CMakeFiles/docs.dir/DependInfo.cmake b/CMakeFiles/docs.dir/DependInfo.cmake new file mode 100644 index 00000000..29b95a51 --- /dev/null +++ b/CMakeFiles/docs.dir/DependInfo.cmake @@ -0,0 +1,22 @@ + +# Consider dependencies only in project. +set(CMAKE_DEPENDS_IN_PROJECT_ONLY OFF) + +# The set of languages for which implicit dependencies are needed: +set(CMAKE_DEPENDS_LANGUAGES + ) + +# The set of dependency files which are needed: +set(CMAKE_DEPENDS_DEPENDENCY_FILES + ) + +# Targets to which this target links which contain Fortran sources. +set(CMAKE_Fortran_TARGET_LINKED_INFO_FILES + ) + +# Targets to which this target links which contain Fortran sources. +set(CMAKE_Fortran_TARGET_FORWARD_LINKED_INFO_FILES + ) + +# Fortran module output directory. +set(CMAKE_Fortran_TARGET_MODULE_DIR "") diff --git a/CMakeFiles/docs.dir/build.make b/CMakeFiles/docs.dir/build.make new file mode 100644 index 00000000..e9878d62 --- /dev/null +++ b/CMakeFiles/docs.dir/build.make @@ -0,0 +1,88 @@ +# CMAKE generated file: DO NOT EDIT! +# Generated by "Unix Makefiles" Generator, CMake Version 3.29 + +# Delete rule output on recipe failure. +.DELETE_ON_ERROR: + +#============================================================================= +# Special targets provided by cmake. + +# Disable implicit rules so canonical targets will work. +.SUFFIXES: + +# Disable VCS-based implicit rules. +% : %,v + +# Disable VCS-based implicit rules. +% : RCS/% + +# Disable VCS-based implicit rules. +% : RCS/%,v + +# Disable VCS-based implicit rules. +% : SCCS/s.% + +# Disable VCS-based implicit rules. +% : s.% + +.SUFFIXES: .hpux_make_needs_suffix_list + +# Command-line flag to silence nested $(MAKE). +$(VERBOSE)MAKESILENT = -s + +#Suppress display of executed commands. +$(VERBOSE).SILENT: + +# A target that is always out of date. +cmake_force: +.PHONY : cmake_force + +#============================================================================= +# Set environment variables for the build. + +# The shell in which to execute make rules. +SHELL = /bin/sh + +# The CMake executable. +CMAKE_COMMAND = /usr/local/bin/cmake + +# The command to remove a file. +RM = /usr/local/bin/cmake -E rm -f + +# Escaping for special characters. +EQUALS = = + +# The top-level source directory on which CMake was run. +CMAKE_SOURCE_DIR = /home/runner/work/note-c/note-c + +# The top-level build directory on which CMake was run. +CMAKE_BINARY_DIR = /home/runner/work/note-c/note-c/build + +# Utility rule file for docs. + +# Include any custom commands dependencies for this target. +include docs/CMakeFiles/docs.dir/compiler_depend.make + +# Include the progress variables for this target. +include docs/CMakeFiles/docs.dir/progress.make + +docs/CMakeFiles/docs: + @$(CMAKE_COMMAND) -E cmake_echo_color "--switch=$(COLOR)" --blue --bold --progress-dir=/home/runner/work/note-c/note-c/build/CMakeFiles --progress-num=$(CMAKE_PROGRESS_1) "Running Sphinx HTML build..." + cd /home/runner/work/note-c/note-c/build/docs && /usr/local/bin/cmake -E env /opt/hostedtoolcache/Python/3.12.4/x64/bin/sphinx-build -b html -c /home/runner/work/note-c/note-c/docs -w /home/runner/work/note-c/note-c/build/docs/build.log -j auto -W --keep-going -T /home/runner/work/note-c/note-c/docs /home/runner/work/note-c/note-c/build/docs + +docs: docs/CMakeFiles/docs +docs: docs/CMakeFiles/docs.dir/build.make +.PHONY : docs + +# Rule to build all files generated by this target. +docs/CMakeFiles/docs.dir/build: docs +.PHONY : docs/CMakeFiles/docs.dir/build + +docs/CMakeFiles/docs.dir/clean: + cd /home/runner/work/note-c/note-c/build/docs && $(CMAKE_COMMAND) -P CMakeFiles/docs.dir/cmake_clean.cmake +.PHONY : docs/CMakeFiles/docs.dir/clean + +docs/CMakeFiles/docs.dir/depend: + cd /home/runner/work/note-c/note-c/build && $(CMAKE_COMMAND) -E cmake_depends "Unix Makefiles" /home/runner/work/note-c/note-c /home/runner/work/note-c/note-c/docs /home/runner/work/note-c/note-c/build /home/runner/work/note-c/note-c/build/docs /home/runner/work/note-c/note-c/build/docs/CMakeFiles/docs.dir/DependInfo.cmake "--color=$(COLOR)" +.PHONY : docs/CMakeFiles/docs.dir/depend + diff --git a/CMakeFiles/docs.dir/cmake_clean.cmake b/CMakeFiles/docs.dir/cmake_clean.cmake new file mode 100644 index 00000000..ae753a31 --- /dev/null +++ b/CMakeFiles/docs.dir/cmake_clean.cmake @@ -0,0 +1,8 @@ +file(REMOVE_RECURSE + "CMakeFiles/docs" +) + +# Per-language clean rules from dependency scanning. +foreach(lang ) + include(CMakeFiles/docs.dir/cmake_clean_${lang}.cmake OPTIONAL) +endforeach() diff --git a/CMakeFiles/docs.dir/compiler_depend.make b/CMakeFiles/docs.dir/compiler_depend.make new file mode 100644 index 00000000..8aa0ceec --- /dev/null +++ b/CMakeFiles/docs.dir/compiler_depend.make @@ -0,0 +1,2 @@ +# Empty custom commands generated dependencies file for docs. +# This may be replaced when dependencies are built. diff --git a/CMakeFiles/docs.dir/compiler_depend.ts b/CMakeFiles/docs.dir/compiler_depend.ts new file mode 100644 index 00000000..62f75408 --- /dev/null +++ b/CMakeFiles/docs.dir/compiler_depend.ts @@ -0,0 +1,2 @@ +# CMAKE generated file: DO NOT EDIT! +# Timestamp file for custom commands dependencies management for docs. diff --git a/CMakeFiles/docs.dir/progress.make b/CMakeFiles/docs.dir/progress.make new file mode 100644 index 00000000..781c7de2 --- /dev/null +++ b/CMakeFiles/docs.dir/progress.make @@ -0,0 +1,2 @@ +CMAKE_PROGRESS_1 = 1 + diff --git a/CMakeFiles/progress.marks b/CMakeFiles/progress.marks new file mode 100644 index 00000000..573541ac --- /dev/null +++ b/CMakeFiles/progress.marks @@ -0,0 +1 @@ +0 diff --git a/Makefile b/Makefile new file mode 100644 index 00000000..4412fb3d --- /dev/null +++ b/Makefile @@ -0,0 +1,155 @@ +# CMAKE generated file: DO NOT EDIT! +# Generated by "Unix Makefiles" Generator, CMake Version 3.29 + +# Default target executed when no arguments are given to make. +default_target: all +.PHONY : default_target + +# Allow only one "make -f Makefile2" at a time, but pass parallelism. +.NOTPARALLEL: + +#============================================================================= +# Special targets provided by cmake. + +# Disable implicit rules so canonical targets will work. +.SUFFIXES: + +# Disable VCS-based implicit rules. +% : %,v + +# Disable VCS-based implicit rules. +% : RCS/% + +# Disable VCS-based implicit rules. +% : RCS/%,v + +# Disable VCS-based implicit rules. +% : SCCS/s.% + +# Disable VCS-based implicit rules. +% : s.% + +.SUFFIXES: .hpux_make_needs_suffix_list + +# Command-line flag to silence nested $(MAKE). +$(VERBOSE)MAKESILENT = -s + +#Suppress display of executed commands. +$(VERBOSE).SILENT: + +# A target that is always out of date. +cmake_force: +.PHONY : cmake_force + +#============================================================================= +# Set environment variables for the build. + +# The shell in which to execute make rules. +SHELL = /bin/sh + +# The CMake executable. +CMAKE_COMMAND = /usr/local/bin/cmake + +# The command to remove a file. +RM = /usr/local/bin/cmake -E rm -f + +# Escaping for special characters. +EQUALS = = + +# The top-level source directory on which CMake was run. +CMAKE_SOURCE_DIR = /home/runner/work/note-c/note-c + +# The top-level build directory on which CMake was run. +CMAKE_BINARY_DIR = /home/runner/work/note-c/note-c/build + +#============================================================================= +# Targets provided globally by CMake. + +# Special rule for the target edit_cache +edit_cache: + @$(CMAKE_COMMAND) -E cmake_echo_color "--switch=$(COLOR)" --cyan "Running CMake cache editor..." + /usr/local/bin/ccmake -S$(CMAKE_SOURCE_DIR) -B$(CMAKE_BINARY_DIR) +.PHONY : edit_cache + +# Special rule for the target edit_cache +edit_cache/fast: edit_cache +.PHONY : edit_cache/fast + +# Special rule for the target rebuild_cache +rebuild_cache: + @$(CMAKE_COMMAND) -E cmake_echo_color "--switch=$(COLOR)" --cyan "Running CMake to regenerate build system..." + /usr/local/bin/cmake --regenerate-during-build -S$(CMAKE_SOURCE_DIR) -B$(CMAKE_BINARY_DIR) +.PHONY : rebuild_cache + +# Special rule for the target rebuild_cache +rebuild_cache/fast: rebuild_cache +.PHONY : rebuild_cache/fast + +# The main all target +all: cmake_check_build_system + cd /home/runner/work/note-c/note-c/build && $(CMAKE_COMMAND) -E cmake_progress_start /home/runner/work/note-c/note-c/build/CMakeFiles /home/runner/work/note-c/note-c/build/docs//CMakeFiles/progress.marks + cd /home/runner/work/note-c/note-c/build && $(MAKE) $(MAKESILENT) -f CMakeFiles/Makefile2 docs/all + $(CMAKE_COMMAND) -E cmake_progress_start /home/runner/work/note-c/note-c/build/CMakeFiles 0 +.PHONY : all + +# The main clean target +clean: + cd /home/runner/work/note-c/note-c/build && $(MAKE) $(MAKESILENT) -f CMakeFiles/Makefile2 docs/clean +.PHONY : clean + +# The main clean target +clean/fast: clean +.PHONY : clean/fast + +# Prepare targets for installation. +preinstall: all + cd /home/runner/work/note-c/note-c/build && $(MAKE) $(MAKESILENT) -f CMakeFiles/Makefile2 docs/preinstall +.PHONY : preinstall + +# Prepare targets for installation. +preinstall/fast: + cd /home/runner/work/note-c/note-c/build && $(MAKE) $(MAKESILENT) -f CMakeFiles/Makefile2 docs/preinstall +.PHONY : preinstall/fast + +# clear depends +depend: + cd /home/runner/work/note-c/note-c/build && $(CMAKE_COMMAND) -S$(CMAKE_SOURCE_DIR) -B$(CMAKE_BINARY_DIR) --check-build-system CMakeFiles/Makefile.cmake 1 +.PHONY : depend + +# Convenience name for target. +docs/CMakeFiles/docs.dir/rule: + cd /home/runner/work/note-c/note-c/build && $(MAKE) $(MAKESILENT) -f CMakeFiles/Makefile2 docs/CMakeFiles/docs.dir/rule +.PHONY : docs/CMakeFiles/docs.dir/rule + +# Convenience name for target. +docs: docs/CMakeFiles/docs.dir/rule +.PHONY : docs + +# fast build rule for target. +docs/fast: + cd /home/runner/work/note-c/note-c/build && $(MAKE) $(MAKESILENT) -f docs/CMakeFiles/docs.dir/build.make docs/CMakeFiles/docs.dir/build +.PHONY : docs/fast + +# Help Target +help: + @echo "The following are some of the valid targets for this Makefile:" + @echo "... all (the default if no target is provided)" + @echo "... clean" + @echo "... depend" + @echo "... edit_cache" + @echo "... rebuild_cache" + @echo "... docs" +.PHONY : help + + + +#============================================================================= +# Special targets to cleanup operation of make. + +# Special rule to run CMake to check the build system integrity. +# No rule that depends on this can have commands that come from listfiles +# because they might be regenerated. +cmake_check_build_system: + cd /home/runner/work/note-c/note-c/build && $(CMAKE_COMMAND) -S$(CMAKE_SOURCE_DIR) -B$(CMAKE_BINARY_DIR) --check-build-system CMakeFiles/Makefile.cmake 0 +.PHONY : cmake_check_build_system + diff --git a/_sources/api_reference.rst.txt b/_sources/api_reference.rst.txt new file mode 100644 index 00000000..ec96f136 --- /dev/null +++ b/_sources/api_reference.rst.txt @@ -0,0 +1,188 @@ +************* +API Reference +************* + +.. contents:: Table of Contents + :depth: 2 + +These pages cover the core functions and types that make up the note-c API. + +Dynamic Memory and Timing Hooks +=============================== + +Functions +--------- + +.. doxygenfunction:: NoteSetFn + +Types +----- + +.. doxygentypedef:: mallocFn + +.. doxygentypedef:: freeFn + +.. doxygentypedef:: delayMsFn + +.. doxygentypedef:: getMsFn + + +I/O Hooks +========= + +Serial Hooks +------------ + +Functions +^^^^^^^^^ + +.. doxygenfunction:: NoteSetFnSerial + +Types +^^^^^ + +.. doxygentypedef:: serialResetFn + +.. doxygentypedef:: serialTransmitFn + +.. doxygentypedef:: serialAvailableFn + +.. doxygentypedef:: serialReceiveFn + +I2C +--- + +Functions +^^^^^^^^^ + +.. doxygenfunction:: NoteSetFnI2C + +Types +^^^^^ + +.. doxygentypedef:: i2cResetFn + +.. doxygentypedef:: i2cTransmitFn + +.. doxygentypedef:: i2cReceiveFn + +Macros +^^^^^^ + +.. doxygendefine:: NOTE_I2C_ADDR_DEFAULT + +.. doxygendefine:: NOTE_I2C_MAX_DEFAULT + +Mutex Hooks +=========== + +Notecard Mutex +-------------- + +Functions +^^^^^^^^^ + +.. doxygenfunction:: NoteSetFnNoteMutex + +Types +^^^^^ + +.. doxygentypedef:: mutexFn + +I2C Mutex +--------- + +Functions +^^^^^^^^^ + +.. doxygenfunction:: NoteSetFnI2CMutex + +Types +^^^^^ + +See :c:type:`mutexFn`. + +Notecard API Calls +================== + +Functions +--------- + +.. doxygenfunction:: NoteNewRequest + +.. doxygenfunction:: NoteRequestResponse + +.. doxygenfunction:: NoteRequestResponseWithRetry + +.. doxygenfunction:: NoteRequest + +.. doxygenfunction:: NoteRequestWithRetry + +.. doxygendefine:: NoteResponseError + +.. doxygendefine:: NoteDeleteResponse + +.. doxygenfunction:: NoteRequestResponseJSON + +JSON Manipulation +================= + +Functions +--------- + +.. doxygenfunction:: JAddBinaryToObject + +.. doxygenfunction:: JAddBoolToObject + +.. doxygenfunction:: JAddNumberToObject + +.. doxygenfunction:: JAddStringToObject + +.. doxygenfunction:: JAddObjectToObject + +.. doxygenfunction:: JAddArrayToObject + +.. doxygenfunction:: JCreateObject + +.. doxygenfunction:: JDelete + +.. doxygenfunction:: JFree + +.. doxygenfunction:: JGetArray + +.. doxygenfunction:: JGetBinaryFromObject + +.. doxygenfunction:: JGetBool + +.. doxygenfunction:: JGetInt + +.. doxygenfunction:: JGetNumber + +.. doxygenfunction:: JGetObject + +.. doxygenfunction:: JGetString + +.. doxygenfunction:: JIsPresent + +.. doxygenfunction:: JMalloc + +.. doxygenfunction:: JParse + +.. doxygenfunction:: JPrintUnformatted + + +Types +----- + +.. doxygenstruct:: J + +.. doxygentypedef:: JNUMBER + +.. doxygentypedef:: JINTEGER + +.. doxygentypedef:: JUINTEGER + +Macros +------ + +.. doxygendefine:: N_CJSON_NESTING_LIMIT diff --git a/_sources/calling_the_notecard_api.rst.txt b/_sources/calling_the_notecard_api.rst.txt new file mode 100644 index 00000000..4c37db4d --- /dev/null +++ b/_sources/calling_the_notecard_api.rst.txt @@ -0,0 +1,81 @@ +************************ +Calling the Notecard API +************************ + +The `Notecard API `_ is JSON-based. note-c uses a modified version of the `cJSON library `_ for working with JSON. The core JSON struct used in note-c is ``J``. You should treat this type as opaque; you will only ever need to work with ``J *`` when using note-c. + +To make a Notecard API call, first create a JSON request: + +.. code-block:: c + + J *req = NoteNewRequest("note.add"); + +When ``req`` is serialized to a string, it looks like this: + +.. code-block:: json + + {"req": "note.add"} + +To add fields to the request, there are a number of ``JAdd*`` functions: + +* :c:func:`JAddBoolToObject` +* :c:func:`JAddNumberToObject` +* :c:func:`JAddStringToObject` +* :c:func:`JAddObjectToObject` +* :c:func:`JAddArrayToObject` + +For example, to add the field ``"file": "data.qo"`` to ``req``, use :c:func:`JAddStringToObject`: + +.. code-block:: c + + JAddStringToObject(req, "file", "data.qo") + +Now, when ``req`` is serialized, it will have the ``"file"`` field: + +.. code-block:: json + + {"req": "note.add", "file": "data.qo"} + +Once the request has been prepared, send it to the Notecard with :c:func:`NoteRequestResponse`: + +.. code-block:: c + + J *rsp = NoteRequestResponse(req); + +``rsp`` holds the JSON response from the Notecard. Use :c:func:`NoteResponseError` to check the response for errors: + +.. code-block:: c + + if (rsp == NULL || NoteResponseError(rsp)) { + // handle error + } + +``NoteRequestResponse`` will take care of freeing the passed in request object, but you must free the response with :c:func:`NoteDeleteResponse`: + +.. code-block:: c + + NoteDeleteResponse(rsp); + +The function :c:func:`NoteRequest` is useful when you don't care about the details of the Notecard's response, just whether the API call was successful or not. It returns true if the API call was successful and false if there was an error sending the request or if there was an error in the response (i.e. it calls :c:func:`NoteResponseError` internally): + +.. code-block:: c + + if (NoteRequest(req)) { + // success + } + else { + // handle error + } + +:c:func:`NoteRequest` frees the request object for you. + +.. note:: + To use plain C-strings as the JSON interface into note-c, rather than ``J *``, check out :c:func:`NoteRequestResponseJSON` + +Examples +======== + +For examples of real applications calling the Notecard API with note-c, check out some of the `Zephyr `_-based `Blues App Accelerators `_: + +* `Valve Monitor and Control `_ +* `Temperature and Humidity Monitor `_ diff --git a/_sources/getting_started.rst.txt b/_sources/getting_started.rst.txt new file mode 100644 index 00000000..dcfa0048 --- /dev/null +++ b/_sources/getting_started.rst.txt @@ -0,0 +1,20 @@ +Getting Started +=============== + +Notecard Background +------------------- + +Before using note-c, it's essential to understand the fundamentals of communicating with a Notecard. Read the `Notecard Overview `_ on the Blues developer site to familiarize yourself with the communications protocol. The protocol is JSON-based and supports `serial and I2C connections `_. + +Getting the Source Code +----------------------- + +To use note-c in your project, you can `download or clone the git repository from GitHub `_. The library is composed of all the .c and .h files prefixed with "n\_" in the root directory of the repository. Simply add the .c files alongside your other source files and make sure the .h files are on an include path visible to your compiler. + +Using the Library +----------------- + +The pages below cover how to use note-c in your project. + +* :doc:`library_initialization` +* :doc:`calling_the_notecard_api` diff --git a/_sources/index.rst.txt b/_sources/index.rst.txt new file mode 100644 index 00000000..0912ee7a --- /dev/null +++ b/_sources/index.rst.txt @@ -0,0 +1,18 @@ +.. note-c documentation master file, created by + sphinx-quickstart on Fri Oct 27 12:49:18 2023. + You can adapt this file completely to your liking, but it should at least + contain the root `toctree` directive. + +note-c +====== + +note-c is the official C library for communicating with a `Blues Notecard `_. The source code is open source and `available on GitHub `_ under the MIT license. + +.. toctree:: + :maxdepth: 1 + + getting_started + library_initialization + calling_the_notecard_api + ports + api_reference diff --git a/_sources/library_initialization.rst.txt b/_sources/library_initialization.rst.txt new file mode 100644 index 00000000..9b84c366 --- /dev/null +++ b/_sources/library_initialization.rst.txt @@ -0,0 +1,343 @@ +********************** +Library Initialization +********************** + +.. contents:: Table of Contents + :depth: 2 + +In order to send and receive data to and from the Notecard, note-c requires several hooks (i.e. callbacks) to be set. The implementations of the hooks are platform-specific and hence cannot be provided by note-c itself. + +Blues develops several open source ports of these hooks for different platforms to accelerate getting started with note-c. The level of abstraction of these ports varies. For example, `note-stm32l4 `_ implements these hooks for the STM32L4 series of MCUs using the STM32L4 HAL, while `note-arduino `_ is a more generic port that allows you to use note-c with essentially any Arduino-compatible board. + +For a comprehensive listing of note-c ports, go to :doc:`ports`. + +For an example and detailed breakdown of implementing the hooks for a specific platform, go to :ref:`library_initialization:Example: note-c Hooks for STM32L4`. + +Dynamic Memory and Timing Hooks +=============================== + +A port must set the dynamic memory and timing hooks using :c:func:`NoteSetFn` for: + +* Allocating memory +* Freeing memory +* Millisecond delay +* Millisecond counter + +I/O Hooks +========= + +note-c maintains one active Notecard I/O interface (serial or I2C) at a time. Calling :c:func:`NoteSetFnSerial` sets the active interface to serial, and calling :c:func:`NoteSetFnI2C` sets the active interface to I2C. + +Serial +------ + +:c:func:`NoteSetFnSerial` sets the serial hooks for: + +* Resetting the serial peripheral +* Transmitting bytes +* Checking if there's a byte available to receive +* Receiving a single byte + +I2C +--- + +:c:func:`NoteSetFnI2C` sets the I2C hooks for: + +* Resetting the I2C peripheral +* Transmitting bytes +* Receiving bytes + +:c:func:`NoteSetFnI2C` also requires two additional parameters: the I2C address of the Notecard and the maximum number of bytes to send to the Notecard in a single I2C chunk. To use the defaults for these two values, use the macros :c:macro:`NOTE_I2C_ADDR_DEFAULT` and :c:macro:`NOTE_I2C_MAX_DEFAULT`, respectively. + +The I2C hooks are slightly more complex than the serial hooks. The transmit and receive hooks must implement the Notecard's serial-over-I2C protocol: + + *Unlike many fixed-length and register-based I2C protocols, the Notecard defines a variable-length, serial-over-I2C protocol that allows developers to handle JSON requests and responses in a similar manner as a direct serial connection.* + +Familiarize yourself with the protocol using `this guide `_ from the Blues developer site. :ref:`library_initialization:Example: note-c Hooks for STM32L4` provides a detailed breakdown of implementing the protocol for STM32L4. While this example uses the STM32L4 HAL, the overall approach is generalizable to other platforms. + +Mutex Hooks +=========== + +Notecard Mutex +-------------- + +A port must set the Notecard mutex hooks using :c:func:`NoteSetFnNoteMutex` if it intends to support multiple concurrent tasks that communicate with the Notecard. Specifically, the port must set lock and unlock hooks. Internally, note-c will call the lock hook before every transaction with the Notecard begins, and it will call the unlock hook after every transaction ends. This ensures that one task doesn't interrupt another task in the middle of a transaction. + +The simplest implementation of these hooks relies on a flag indicating if access to the Notecard is locked by some other task. The lock hook sleeps/yields until the flag indicates the Notecard is unlocked and then acquires the lock itself: + +.. code-block:: c + + void lockNotecard(void) + { + while (notecardLocked) { + NoteDelayMs(10); // sleep 10 ms between checks + } + + notecardLocked = true; + } + +The unlock hook simply clears the flag: + +.. code-block:: c + + void unlockNotecard(void) + { + notecardLocked = false; + } + +I2C Mutex +--------- + +A port must set the I2C mutex hooks using :c:func:`NoteSetFnI2CMutex` if it intends to support multiple concurrent tasks that drive the same I2C bus that the Notecard is on. Specifically, the port must set lock and unlock hooks. The simple lock-unlock implementation described previously in :ref:`library_initialization:Notecard Mutex` can be used for these hooks, too. Internally, note-c will call the lock hook before every I2C transaction with the Notecard begins, and it will call the unlock hook after every I2C transaction ends. The other tasks using I2C must be amended to do the same. + +Example: note-c Hooks for STM32L4 +================================= + +`note-stm32l4 `_ is the note-c port for the STM32L4 series of MCUs. This section walks through how the various note-c hooks are implemented for this platform. Notecard and I2C mutex hooks are not covered. + +Dynamic Memory and Timing Hooks +------------------------------- + +This line in `Src/main.c `_ sets the dynamic memory and timing hooks: + +.. code-block:: c + + NoteSetFn(malloc, free, delay, millis); + +``malloc`` +^^^^^^^^^^ + +The memory allocation hook is set to ``malloc`` from libc. + +``free`` +^^^^^^^^ + +The memory freeing hook is set to ``free`` from libc. + +``delay`` +^^^^^^^^^ + +.. code-block:: c + + void delay(uint32_t ms) { + HAL_Delay(ms); + } + +``delay`` calls into the STM32 HAL to delay for the specified number of milliseconds. + +``millis`` +^^^^^^^^^^ + +.. code-block:: c + + long unsigned int millis() { + return (long unsigned int) HAL_GetTick(); + } + +``millis`` uses the HAL to get the value of a continuously running millisecond counter. + +I/O Hooks +--------- + +The code below from `Src/main.c `_ determines which I/O interface gets used, depending on the value of the ``NOTECARD_USE_I2C`` macro. + +.. code-block:: c + + #if NOTECARD_USE_I2C + NoteSetFnI2C(NOTE_I2C_ADDR_DEFAULT, NOTE_I2C_MAX_DEFAULT, noteI2CReset, noteI2CTransmit, noteI2CReceive); + #else + NoteSetFnSerial(noteSerialReset, noteSerialTransmit, noteSerialAvailable, noteSerialReceive); + #endif + +``noteSerialReset`` +^^^^^^^^^^^^^^^^^^^ + +.. code-block:: c + + bool noteSerialReset() { + MX_USART1_UART_DeInit(); + MX_USART1_UART_Init(); + + return true; + } + +The serial reset hook reinitializes the serial peripheral connected to the Notecard. + +``noteSerialTransmit`` +^^^^^^^^^^^^^^^^^^^^^^ + +.. code-block:: c + + void noteSerialTransmit(uint8_t *text, size_t len, bool flush) { + HAL_UART_Transmit(&huart1, text, len, 5000); + } + +The serial transmit hook uses the HAL to write the data in the buffer to the serial peripheral connected to the Notecard. + +``noteSerialAvailable`` +^^^^^^^^^^^^^^^^^^^^^^^ + +.. code-block:: c + + bool noteSerialAvailable() { + return (serialFillIndex != serialDrainIndex); + } + +For receiving serial data from the Notecard, note-stm32l4 uses a circular buffer. In the receive interrupt handler for the UART peripheral, this buffer gets populated with the received data. ``serialFillIndex`` is the write index into that buffer, and ``serialDrainIndex`` is the read index. If the two indices are equal, there's nothing new to read. If they aren't equal, there is something to read. + +``noteSerialReceive`` +^^^^^^^^^^^^^^^^^^^^^ + +.. code-block:: c + + char noteSerialReceive() { + char data; + while (!noteSerialAvailable()) ; + if (serialDrainIndex < sizeof(serialBuffer)) + data = serialBuffer[serialDrainIndex++]; + else { + data = serialBuffer[0]; + serialDrainIndex = 1; + } + return data; + } + +The serial receive hook returns the byte from the circular receive buffer at the read index, handling the case where the index wraps around to 0. + +``noteI2CReset`` +^^^^^^^^^^^^^^^^ + +.. code-block:: c + + bool noteI2CReset(uint16_t DevAddress) { + MX_I2C1_DeInit(); + MX_I2C1_Init(); + + return true; + } + +The I2C reset hook reinitializes the I2C peripheral used to communicate with the Notecard. + +``noteI2CTransmit`` +^^^^^^^^^^^^^^^^^^^ + +.. code-block:: c + + const char *noteI2CTransmit(uint16_t DevAddress, uint8_t* pBuffer, uint16_t Size) { + char *errstr = NULL; + int writelen = sizeof(uint8_t) + Size; + uint8_t *writebuf = malloc(writelen); + if (writebuf == NULL) { + errstr = "i2c: insufficient memory (write)"; + } else { + writebuf[0] = Size; + memcpy(&writebuf[1], pBuffer, Size); + HAL_StatusTypeDef err_code = HAL_I2C_Master_Transmit(&hi2c1, DevAddress<<1, writebuf, writelen, 250); + free(writebuf); + if (err_code != HAL_OK) { + errstr = "i2c: HAL_I2C_Master_Transmit error"; + } + } + return errstr; + } + +To frame the data to transmit to the Notecard using the serial-over-I2C protocol, the host first adds a byte indicating the number of bytes in the payload, which is ``Size``: + +.. code-block:: c + + writebuf[0] = Size; + +Then, it adds on the payload of ``Size`` bytes, which is pointed to by ``pBuffer``: + +.. code-block:: c + + memcpy(&writebuf[1], pBuffer, Size); + +Then the host calls the platform-specific method to send those bytes over I2C, which is ``HAL_I2C_Master_Transmit`` in this case. + +``noteI2CReceive`` +^^^^^^^^^^^^^^^^^^ + +.. code-block:: c + + const char *noteI2CReceive(uint16_t DevAddress, uint8_t* pBuffer, uint16_t Size, uint32_t *available) { + const char *errstr = NULL; + HAL_StatusTypeDef err_code; + + // Retry transmit errors several times, because it's harmless to do so + for (int i=0; i<3; i++) { + uint8_t hdr[2]; + hdr[0] = (uint8_t) 0; + hdr[1] = (uint8_t) Size; + HAL_StatusTypeDef err_code = HAL_I2C_Master_Transmit(&hi2c1, DevAddress<<1, hdr, sizeof(hdr), 250); + if (err_code == HAL_OK) { + errstr = NULL; + break; + } + errstr = "i2c: HAL_I2C_Master_Transmit error"; + } + + // Only receive if we successfully began transmission + if (errstr == NULL) { + + int readlen = Size + (sizeof(uint8_t)*2); + uint8_t *readbuf = malloc(readlen); + if (readbuf == NULL) { + errstr = "i2c: insufficient memory (read)"; + } else { + err_code = HAL_I2C_Master_Receive(&hi2c1, DevAddress<<1, readbuf, readlen, 10); + if (err_code != HAL_OK) { + errstr = "i2c: HAL_I2C_Master_Receive error"; + } else { + uint8_t availbyte = readbuf[0]; + uint8_t goodbyte = readbuf[1]; + if (goodbyte != Size) { + errstr = "i2c: incorrect amount of data"; + } else { + *available = availbyte; + memcpy(pBuffer, &readbuf[2], Size); + } + } + free(readbuf); + } + } + + // Done + return errstr; + + } + +Setting aside the retry logic at the start and the error checking, the above code is simpler than it initially appears. To initiate a read with the Notecard, the serial-over-I2C protocol specifies that the host first send a 2-byte packet: a 0 followed by a byte indicating the max amount of data the host is prepared to receive. That's ``Size`` in this case, which is the available space in the receive buffer ``pBuffer``. + +.. code-block:: c + + hdr[0] = (uint8_t) 0; + hdr[1] = (uint8_t) Size; + +Then, the host calls the platform-specific method to send those bytes over I2C. + +Now, to read the data from the Notecard, the host calls the platform-specific method for an I2C read (``HAL_I2C_Master_Receive``). The packet it receives from the Notecard has a 2-byte header. The first byte indicates the number of bytes still available to read from the Notecard after this packet: + +.. code-block:: c + + uint8_t availbyte = readbuf[0]; + +The second byte is the number of bytes in the current packet: + +.. code-block:: c + + uint8_t goodbyte = readbuf[1]; + +The rest of the packet is the payload: + +.. code-block:: c + + memcpy(pBuffer, &readbuf[2], Size); + +Note that the number of bytes still available is returned to the caller via the ``available`` parameter: + +.. code-block:: c + + *available = availbyte; + +This lets note-c know if it should call this hook again to keep reading. diff --git a/_sources/ports.rst.txt b/_sources/ports.rst.txt new file mode 100644 index 00000000..296ba7ba --- /dev/null +++ b/_sources/ports.rst.txt @@ -0,0 +1,28 @@ +Ports +===== + +This is a listing of all the open source note-c ports developed by Blues. + +.. list-table:: + :header-rows: 1 + + * - Name + - Description + * - `note-arduino `_ + - Arduino library wrapper. + * - `note-zephyr `_ + - Port for the Zephyr RTOS. + * - `note-mbed `_ + - Port for the Mbed RTOS. + * - `note-stm32g0 `_ + - Port for STM32G0. + * - `note-stm32f1 `_ + - Port for STM32F1. + * - `note-stm32l0 `_ + - Port for STM32L0. + * - `note-stm32l4 `_ + - Port for STM32L4. + * - `note-msp430 `_ + - Port for TI MSP430. + * - `note-nrf52 `_ + - Port for nRF52. diff --git a/_static/_sphinx_javascript_frameworks_compat.js b/_static/_sphinx_javascript_frameworks_compat.js new file mode 100644 index 00000000..81415803 --- /dev/null +++ b/_static/_sphinx_javascript_frameworks_compat.js @@ -0,0 +1,123 @@ +/* Compatability shim for jQuery and underscores.js. + * + * Copyright Sphinx contributors + * Released under the two clause BSD licence + */ + +/** + * small helper function to urldecode strings + * + * See https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/decodeURIComponent#Decoding_query_parameters_from_a_URL + */ +jQuery.urldecode = function(x) { + if (!x) { + return x + } + return decodeURIComponent(x.replace(/\+/g, ' ')); +}; + +/** + * small helper function to urlencode strings + */ +jQuery.urlencode = encodeURIComponent; + +/** + * This function returns the parsed url parameters of the + * current request. Multiple values per key are supported, + * it will always return arrays of strings for the value parts. + */ +jQuery.getQueryParameters = function(s) { + if (typeof s === 'undefined') + s = document.location.search; + var parts = s.substr(s.indexOf('?') + 1).split('&'); + var result = {}; + for (var i = 0; i < parts.length; i++) { + var tmp = parts[i].split('=', 2); + var key = jQuery.urldecode(tmp[0]); + var value = jQuery.urldecode(tmp[1]); + if (key in result) + result[key].push(value); + else + result[key] = [value]; + } + return result; +}; + +/** + * highlight a given string on a jquery object by wrapping it in + * span elements with the given class name. + */ +jQuery.fn.highlightText = function(text, className) { + function highlight(node, addItems) { + if (node.nodeType === 3) { + var val = node.nodeValue; + var pos = val.toLowerCase().indexOf(text); + if (pos >= 0 && + !jQuery(node.parentNode).hasClass(className) && + !jQuery(node.parentNode).hasClass("nohighlight")) { + var span; + var isInSVG = jQuery(node).closest("body, svg, foreignObject").is("svg"); + if (isInSVG) { + span = document.createElementNS("http://www.w3.org/2000/svg", "tspan"); + } else { + span = document.createElement("span"); + span.className = className; + } + span.appendChild(document.createTextNode(val.substr(pos, text.length))); + node.parentNode.insertBefore(span, node.parentNode.insertBefore( + document.createTextNode(val.substr(pos + text.length)), + node.nextSibling)); + node.nodeValue = val.substr(0, pos); + if (isInSVG) { + var rect = document.createElementNS("http://www.w3.org/2000/svg", "rect"); + var bbox = node.parentElement.getBBox(); + rect.x.baseVal.value = bbox.x; + rect.y.baseVal.value = bbox.y; + rect.width.baseVal.value = bbox.width; + rect.height.baseVal.value = bbox.height; + rect.setAttribute('class', className); + addItems.push({ + "parent": node.parentNode, + "target": rect}); + } + } + } + else if (!jQuery(node).is("button, select, textarea")) { + jQuery.each(node.childNodes, function() { + highlight(this, addItems); + }); + } + } + var addItems = []; + var result = this.each(function() { + highlight(this, addItems); + }); + for (var i = 0; i < addItems.length; ++i) { + jQuery(addItems[i].parent).before(addItems[i].target); + } + return result; +}; + +/* + * backward compatibility for jQuery.browser + * This will be supported until firefox bug is fixed. + */ +if (!jQuery.browser) { + jQuery.uaMatch = function(ua) { + ua = ua.toLowerCase(); + + var match = /(chrome)[ \/]([\w.]+)/.exec(ua) || + /(webkit)[ \/]([\w.]+)/.exec(ua) || + /(opera)(?:.*version|)[ \/]([\w.]+)/.exec(ua) || + /(msie) ([\w.]+)/.exec(ua) || + ua.indexOf("compatible") < 0 && /(mozilla)(?:.*? rv:([\w.]+)|)/.exec(ua) || + []; + + return { + browser: match[ 1 ] || "", + version: match[ 2 ] || "0" + }; + }; + jQuery.browser = {}; + jQuery.browser[jQuery.uaMatch(navigator.userAgent).browser] = true; +} diff --git a/_static/basic.css b/_static/basic.css new file mode 100644 index 00000000..f316efcb --- /dev/null +++ b/_static/basic.css @@ -0,0 +1,925 @@ +/* + * basic.css + * ~~~~~~~~~ + * + * Sphinx stylesheet -- basic theme. + * + * :copyright: Copyright 2007-2024 by the Sphinx team, see AUTHORS. + * :license: BSD, see LICENSE for details. + * + */ + +/* -- main layout ----------------------------------------------------------- */ + +div.clearer { + clear: both; +} + +div.section::after { + display: block; + content: ''; + clear: left; +} + +/* -- relbar ---------------------------------------------------------------- */ + +div.related { + width: 100%; + font-size: 90%; +} + +div.related h3 { + display: none; +} + +div.related ul { + margin: 0; + padding: 0 0 0 10px; + list-style: none; +} + +div.related li { + display: inline; +} + +div.related li.right { + float: right; + margin-right: 5px; +} + +/* -- sidebar --------------------------------------------------------------- */ + +div.sphinxsidebarwrapper { + padding: 10px 5px 0 10px; +} + +div.sphinxsidebar { + float: left; + width: 230px; + margin-left: -100%; + font-size: 90%; + word-wrap: break-word; + overflow-wrap : break-word; +} + +div.sphinxsidebar ul { + list-style: none; +} + +div.sphinxsidebar ul ul, +div.sphinxsidebar ul.want-points { + margin-left: 20px; + list-style: square; +} + +div.sphinxsidebar ul ul { + margin-top: 0; + margin-bottom: 0; +} + +div.sphinxsidebar form { + margin-top: 10px; +} + +div.sphinxsidebar input { + border: 1px solid #98dbcc; + font-family: sans-serif; + font-size: 1em; +} + +div.sphinxsidebar #searchbox form.search { + overflow: hidden; +} + +div.sphinxsidebar #searchbox input[type="text"] { + float: left; + width: 80%; + padding: 0.25em; + box-sizing: border-box; +} + +div.sphinxsidebar #searchbox input[type="submit"] { + float: left; + width: 20%; + border-left: none; + padding: 0.25em; + box-sizing: border-box; +} + + +img { + border: 0; + max-width: 100%; +} + +/* -- search page ----------------------------------------------------------- */ + +ul.search { + margin: 10px 0 0 20px; + padding: 0; +} + +ul.search li { + padding: 5px 0 5px 20px; + background-image: url(file.png); + background-repeat: no-repeat; + background-position: 0 7px; +} + +ul.search li a { + font-weight: bold; +} + +ul.search li p.context { + color: #888; + margin: 2px 0 0 30px; + text-align: left; +} + +ul.keywordmatches li.goodmatch a { + font-weight: bold; +} + +/* -- index page ------------------------------------------------------------ */ + +table.contentstable { + width: 90%; + margin-left: auto; + margin-right: auto; +} + +table.contentstable p.biglink { + line-height: 150%; +} + +a.biglink { + font-size: 1.3em; +} + +span.linkdescr { + font-style: italic; + padding-top: 5px; + font-size: 90%; +} + +/* -- general index --------------------------------------------------------- */ + +table.indextable { + width: 100%; +} + +table.indextable td { + text-align: left; + vertical-align: top; +} + +table.indextable ul { + margin-top: 0; + margin-bottom: 0; + list-style-type: none; +} + +table.indextable > tbody > tr > td > ul { + padding-left: 0em; +} + +table.indextable tr.pcap { + height: 10px; +} + +table.indextable tr.cap { + margin-top: 10px; + background-color: #f2f2f2; +} + +img.toggler { + margin-right: 3px; + margin-top: 3px; + cursor: pointer; +} + +div.modindex-jumpbox { + border-top: 1px solid #ddd; + border-bottom: 1px solid #ddd; + margin: 1em 0 1em 0; + padding: 0.4em; +} + +div.genindex-jumpbox { + border-top: 1px solid #ddd; + border-bottom: 1px solid #ddd; + margin: 1em 0 1em 0; + padding: 0.4em; +} + +/* -- domain module index --------------------------------------------------- */ + +table.modindextable td { + padding: 2px; + border-collapse: collapse; +} + +/* -- general body styles --------------------------------------------------- */ + +div.body { + min-width: 360px; + max-width: 800px; +} + +div.body p, div.body dd, div.body li, div.body blockquote { + -moz-hyphens: auto; + -ms-hyphens: auto; + -webkit-hyphens: auto; + hyphens: auto; +} + +a.headerlink { + visibility: hidden; +} + +a:visited { + color: #551A8B; +} + +h1:hover > a.headerlink, +h2:hover > a.headerlink, +h3:hover > a.headerlink, +h4:hover > a.headerlink, +h5:hover > a.headerlink, +h6:hover > a.headerlink, +dt:hover > a.headerlink, +caption:hover > a.headerlink, +p.caption:hover > a.headerlink, +div.code-block-caption:hover > a.headerlink { + visibility: visible; +} + +div.body p.caption { + text-align: inherit; +} + +div.body td { + text-align: left; +} + +.first { + margin-top: 0 !important; +} + +p.rubric { + margin-top: 30px; + font-weight: bold; +} + +img.align-left, figure.align-left, .figure.align-left, object.align-left { + clear: left; + float: left; + margin-right: 1em; +} + +img.align-right, figure.align-right, .figure.align-right, object.align-right { + clear: right; + float: right; + margin-left: 1em; +} + +img.align-center, figure.align-center, .figure.align-center, object.align-center { + display: block; + margin-left: auto; + margin-right: auto; +} + +img.align-default, figure.align-default, .figure.align-default { + display: block; + margin-left: auto; + margin-right: auto; +} + +.align-left { + text-align: left; +} + +.align-center { + text-align: center; +} + +.align-default { + text-align: center; +} + +.align-right { + text-align: right; +} + +/* -- sidebars -------------------------------------------------------------- */ + +div.sidebar, +aside.sidebar { + margin: 0 0 0.5em 1em; + border: 1px solid #ddb; + padding: 7px; + background-color: #ffe; + width: 40%; + float: right; + clear: right; + overflow-x: auto; +} + +p.sidebar-title { + font-weight: bold; +} + +nav.contents, +aside.topic, +div.admonition, div.topic, blockquote { + clear: left; +} + +/* -- topics ---------------------------------------------------------------- */ + +nav.contents, +aside.topic, +div.topic { + border: 1px solid #ccc; + padding: 7px; + margin: 10px 0 10px 0; +} + +p.topic-title { + font-size: 1.1em; + font-weight: bold; + margin-top: 10px; +} + +/* -- admonitions ----------------------------------------------------------- */ + +div.admonition { + margin-top: 10px; + margin-bottom: 10px; + padding: 7px; +} + +div.admonition dt { + font-weight: bold; +} + +p.admonition-title { + margin: 0px 10px 5px 0px; + font-weight: bold; +} + +div.body p.centered { + text-align: center; + margin-top: 25px; +} + +/* -- content of sidebars/topics/admonitions -------------------------------- */ + +div.sidebar > :last-child, +aside.sidebar > :last-child, +nav.contents > :last-child, +aside.topic > :last-child, +div.topic > :last-child, +div.admonition > :last-child { + margin-bottom: 0; +} + +div.sidebar::after, +aside.sidebar::after, +nav.contents::after, +aside.topic::after, +div.topic::after, +div.admonition::after, +blockquote::after { + display: block; + content: ''; + clear: both; +} + +/* -- tables ---------------------------------------------------------------- */ + +table.docutils { + margin-top: 10px; + margin-bottom: 10px; + border: 0; + border-collapse: collapse; +} + +table.align-center { + margin-left: auto; + margin-right: auto; +} + +table.align-default { + margin-left: auto; + margin-right: auto; +} + +table caption span.caption-number { + font-style: italic; +} + +table caption span.caption-text { +} + +table.docutils td, table.docutils th { + padding: 1px 8px 1px 5px; + border-top: 0; + border-left: 0; + border-right: 0; + border-bottom: 1px solid #aaa; +} + +th { + text-align: left; + padding-right: 5px; +} + +table.citation { + border-left: solid 1px gray; + margin-left: 1px; +} + +table.citation td { + border-bottom: none; +} + +th > :first-child, +td > :first-child { + margin-top: 0px; +} + +th > :last-child, +td > :last-child { + margin-bottom: 0px; +} + +/* -- figures --------------------------------------------------------------- */ + +div.figure, figure { + margin: 0.5em; + padding: 0.5em; +} + +div.figure p.caption, figcaption { + padding: 0.3em; +} + +div.figure p.caption span.caption-number, +figcaption span.caption-number { + font-style: italic; +} + +div.figure p.caption span.caption-text, +figcaption span.caption-text { +} + +/* -- field list styles ----------------------------------------------------- */ + +table.field-list td, table.field-list th { + border: 0 !important; +} + +.field-list ul { + margin: 0; + padding-left: 1em; +} + +.field-list p { + margin: 0; +} + +.field-name { + -moz-hyphens: manual; + -ms-hyphens: manual; + -webkit-hyphens: manual; + hyphens: manual; +} + +/* -- hlist styles ---------------------------------------------------------- */ + +table.hlist { + margin: 1em 0; +} + +table.hlist td { + vertical-align: top; +} + +/* -- object description styles --------------------------------------------- */ + +.sig { + font-family: 'Consolas', 'Menlo', 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', monospace; +} + +.sig-name, code.descname { + background-color: transparent; + font-weight: bold; +} + +.sig-name { + font-size: 1.1em; +} + +code.descname { + font-size: 1.2em; +} + +.sig-prename, code.descclassname { + background-color: transparent; +} + +.optional { + font-size: 1.3em; +} + +.sig-paren { + font-size: larger; +} + +.sig-param.n { + font-style: italic; +} + +/* C++ specific styling */ + +.sig-inline.c-texpr, +.sig-inline.cpp-texpr { + font-family: unset; +} + +.sig.c .k, .sig.c .kt, +.sig.cpp .k, .sig.cpp .kt { + color: #0033B3; +} + +.sig.c .m, +.sig.cpp .m { + color: #1750EB; +} + +.sig.c .s, .sig.c .sc, +.sig.cpp .s, .sig.cpp .sc { + color: #067D17; +} + + +/* -- other body styles ----------------------------------------------------- */ + +ol.arabic { + list-style: decimal; +} + +ol.loweralpha { + list-style: lower-alpha; +} + +ol.upperalpha { + list-style: upper-alpha; +} + +ol.lowerroman { + list-style: lower-roman; +} + +ol.upperroman { + list-style: upper-roman; +} + +:not(li) > ol > li:first-child > :first-child, +:not(li) > ul > li:first-child > :first-child { + margin-top: 0px; +} + +:not(li) > ol > li:last-child > :last-child, +:not(li) > ul > li:last-child > :last-child { + margin-bottom: 0px; +} + +ol.simple ol p, +ol.simple ul p, +ul.simple ol p, +ul.simple ul p { + margin-top: 0; +} + +ol.simple > li:not(:first-child) > p, +ul.simple > li:not(:first-child) > p { + margin-top: 0; +} + +ol.simple p, +ul.simple p { + margin-bottom: 0; +} + +aside.footnote > span, +div.citation > span { + float: left; +} +aside.footnote > span:last-of-type, +div.citation > span:last-of-type { + padding-right: 0.5em; +} +aside.footnote > p { + margin-left: 2em; +} +div.citation > p { + margin-left: 4em; +} +aside.footnote > p:last-of-type, +div.citation > p:last-of-type { + margin-bottom: 0em; +} +aside.footnote > p:last-of-type:after, +div.citation > p:last-of-type:after { + content: ""; + clear: both; +} + +dl.field-list { + display: grid; + grid-template-columns: fit-content(30%) auto; +} + +dl.field-list > dt { + font-weight: bold; + word-break: break-word; + padding-left: 0.5em; + padding-right: 5px; +} + +dl.field-list > dd { + padding-left: 0.5em; + margin-top: 0em; + margin-left: 0em; + margin-bottom: 0em; +} + +dl { + margin-bottom: 15px; +} + +dd > :first-child { + margin-top: 0px; +} + +dd ul, dd table { + margin-bottom: 10px; +} + +dd { + margin-top: 3px; + margin-bottom: 10px; + margin-left: 30px; +} + +.sig dd { + margin-top: 0px; + margin-bottom: 0px; +} + +.sig dl { + margin-top: 0px; + margin-bottom: 0px; +} + +dl > dd:last-child, +dl > dd:last-child > :last-child { + margin-bottom: 0; +} + +dt:target, span.highlighted { + background-color: #fbe54e; +} + +rect.highlighted { + fill: #fbe54e; +} + +dl.glossary dt { + font-weight: bold; + font-size: 1.1em; +} + +.versionmodified { + font-style: italic; +} + +.system-message { + background-color: #fda; + padding: 5px; + border: 3px solid red; +} + +.footnote:target { + background-color: #ffa; +} + +.line-block { + display: block; + margin-top: 1em; + margin-bottom: 1em; +} + +.line-block .line-block { + margin-top: 0; + margin-bottom: 0; + margin-left: 1.5em; +} + +.guilabel, .menuselection { + font-family: sans-serif; +} + +.accelerator { + text-decoration: underline; +} + +.classifier { + font-style: oblique; +} + +.classifier:before { + font-style: normal; + margin: 0 0.5em; + content: ":"; + display: inline-block; +} + +abbr, acronym { + border-bottom: dotted 1px; + cursor: help; +} + +.translated { + background-color: rgba(207, 255, 207, 0.2) +} + +.untranslated { + background-color: rgba(255, 207, 207, 0.2) +} + +/* -- code displays --------------------------------------------------------- */ + +pre { + overflow: auto; + overflow-y: hidden; /* fixes display issues on Chrome browsers */ +} + +pre, div[class*="highlight-"] { + clear: both; +} + +span.pre { + -moz-hyphens: none; + -ms-hyphens: none; + -webkit-hyphens: none; + hyphens: none; + white-space: nowrap; +} + +div[class*="highlight-"] { + margin: 1em 0; +} + +td.linenos pre { + border: 0; + background-color: transparent; + color: #aaa; +} + +table.highlighttable { + display: block; +} + +table.highlighttable tbody { + display: block; +} + +table.highlighttable tr { + display: flex; +} + +table.highlighttable td { + margin: 0; + padding: 0; +} + +table.highlighttable td.linenos { + padding-right: 0.5em; +} + +table.highlighttable td.code { + flex: 1; + overflow: hidden; +} + +.highlight .hll { + display: block; +} + +div.highlight pre, +table.highlighttable pre { + margin: 0; +} + +div.code-block-caption + div { + margin-top: 0; +} + +div.code-block-caption { + margin-top: 1em; + padding: 2px 5px; + font-size: small; +} + +div.code-block-caption code { + background-color: transparent; +} + +table.highlighttable td.linenos, +span.linenos, +div.highlight span.gp { /* gp: Generic.Prompt */ + user-select: none; + -webkit-user-select: text; /* Safari fallback only */ + -webkit-user-select: none; /* Chrome/Safari */ + -moz-user-select: none; /* Firefox */ + -ms-user-select: none; /* IE10+ */ +} + +div.code-block-caption span.caption-number { + padding: 0.1em 0.3em; + font-style: italic; +} + +div.code-block-caption span.caption-text { +} + +div.literal-block-wrapper { + margin: 1em 0; +} + +code.xref, a code { + background-color: transparent; + font-weight: bold; +} + +h1 code, h2 code, h3 code, h4 code, h5 code, h6 code { + background-color: transparent; +} + +.viewcode-link { + float: right; +} + +.viewcode-back { + float: right; + font-family: sans-serif; +} + +div.viewcode-block:target { + margin: -1px -10px; + padding: 0 10px; +} + +/* -- math display ---------------------------------------------------------- */ + +img.math { + vertical-align: middle; +} + +div.body div.math p { + text-align: center; +} + +span.eqno { + float: right; +} + +span.eqno a.headerlink { + position: absolute; + z-index: 1; +} + +div.math:hover a.headerlink { + visibility: visible; +} + +/* -- printout stylesheet --------------------------------------------------- */ + +@media print { + div.document, + div.documentwrapper, + div.bodywrapper { + margin: 0 !important; + width: 100%; + } + + div.sphinxsidebar, + div.related, + div.footer, + #top-link { + display: none; + } +} \ No newline at end of file diff --git a/_static/blues_logo_no_text.png b/_static/blues_logo_no_text.png new file mode 100644 index 00000000..1598330d Binary files /dev/null and b/_static/blues_logo_no_text.png differ diff --git a/_static/css/badge_only.css b/_static/css/badge_only.css new file mode 100644 index 00000000..c718cee4 --- /dev/null +++ b/_static/css/badge_only.css @@ -0,0 +1 @@ +.clearfix{*zoom:1}.clearfix:after,.clearfix:before{display:table;content:""}.clearfix:after{clear:both}@font-face{font-family:FontAwesome;font-style:normal;font-weight:400;src:url(fonts/fontawesome-webfont.eot?674f50d287a8c48dc19ba404d20fe713?#iefix) format("embedded-opentype"),url(fonts/fontawesome-webfont.woff2?af7ae505a9eed503f8b8e6982036873e) format("woff2"),url(fonts/fontawesome-webfont.woff?fee66e712a8a08eef5805a46892932ad) format("woff"),url(fonts/fontawesome-webfont.ttf?b06871f281fee6b241d60582ae9369b9) format("truetype"),url(fonts/fontawesome-webfont.svg?912ec66d7572ff821749319396470bde#FontAwesome) format("svg")}.fa:before{font-family:FontAwesome;font-style:normal;font-weight:400;line-height:1}.fa:before,a .fa{text-decoration:inherit}.fa:before,a .fa,li .fa{display:inline-block}li .fa-large:before{width:1.875em}ul.fas{list-style-type:none;margin-left:2em;text-indent:-.8em}ul.fas li .fa{width:.8em}ul.fas li .fa-large:before{vertical-align:baseline}.fa-book:before,.icon-book:before{content:"\f02d"}.fa-caret-down:before,.icon-caret-down:before{content:"\f0d7"}.fa-caret-up:before,.icon-caret-up:before{content:"\f0d8"}.fa-caret-left:before,.icon-caret-left:before{content:"\f0d9"}.fa-caret-right:before,.icon-caret-right:before{content:"\f0da"}.rst-versions{position:fixed;bottom:0;left:0;width:300px;color:#fcfcfc;background:#1f1d1d;font-family:Lato,proxima-nova,Helvetica Neue,Arial,sans-serif;z-index:400}.rst-versions a{color:#2980b9;text-decoration:none}.rst-versions .rst-badge-small{display:none}.rst-versions .rst-current-version{padding:12px;background-color:#272525;display:block;text-align:right;font-size:90%;cursor:pointer;color:#27ae60}.rst-versions .rst-current-version:after{clear:both;content:"";display:block}.rst-versions .rst-current-version .fa{color:#fcfcfc}.rst-versions .rst-current-version .fa-book,.rst-versions .rst-current-version .icon-book{float:left}.rst-versions .rst-current-version.rst-out-of-date{background-color:#e74c3c;color:#fff}.rst-versions .rst-current-version.rst-active-old-version{background-color:#f1c40f;color:#000}.rst-versions.shift-up{height:auto;max-height:100%;overflow-y:scroll}.rst-versions.shift-up .rst-other-versions{display:block}.rst-versions .rst-other-versions{font-size:90%;padding:12px;color:grey;display:none}.rst-versions .rst-other-versions hr{display:block;height:1px;border:0;margin:20px 0;padding:0;border-top:1px solid #413d3d}.rst-versions .rst-other-versions dd{display:inline-block;margin:0}.rst-versions .rst-other-versions dd a{display:inline-block;padding:6px;color:#fcfcfc}.rst-versions.rst-badge{width:auto;bottom:20px;right:20px;left:auto;border:none;max-width:300px;max-height:90%}.rst-versions.rst-badge .fa-book,.rst-versions.rst-badge .icon-book{float:none;line-height:30px}.rst-versions.rst-badge.shift-up .rst-current-version{text-align:right}.rst-versions.rst-badge.shift-up .rst-current-version .fa-book,.rst-versions.rst-badge.shift-up .rst-current-version .icon-book{float:left}.rst-versions.rst-badge>.rst-current-version{width:auto;height:30px;line-height:30px;padding:0 6px;display:block;text-align:center}@media screen and (max-width:768px){.rst-versions{width:85%;display:none}.rst-versions.shift{display:block}} \ No newline at end of file diff --git a/_static/css/fonts/Roboto-Slab-Bold.woff b/_static/css/fonts/Roboto-Slab-Bold.woff new file mode 100644 index 00000000..6cb60000 Binary files /dev/null and b/_static/css/fonts/Roboto-Slab-Bold.woff differ diff --git a/_static/css/fonts/Roboto-Slab-Bold.woff2 b/_static/css/fonts/Roboto-Slab-Bold.woff2 new file mode 100644 index 00000000..7059e231 Binary files /dev/null and b/_static/css/fonts/Roboto-Slab-Bold.woff2 differ diff --git a/_static/css/fonts/Roboto-Slab-Regular.woff b/_static/css/fonts/Roboto-Slab-Regular.woff new file mode 100644 index 00000000..f815f63f Binary files /dev/null and b/_static/css/fonts/Roboto-Slab-Regular.woff differ diff --git a/_static/css/fonts/Roboto-Slab-Regular.woff2 b/_static/css/fonts/Roboto-Slab-Regular.woff2 new file mode 100644 index 00000000..f2c76e5b Binary files /dev/null and b/_static/css/fonts/Roboto-Slab-Regular.woff2 differ diff --git a/_static/css/fonts/fontawesome-webfont.eot b/_static/css/fonts/fontawesome-webfont.eot new file mode 100644 index 00000000..e9f60ca9 Binary files /dev/null and b/_static/css/fonts/fontawesome-webfont.eot differ diff --git a/_static/css/fonts/fontawesome-webfont.svg b/_static/css/fonts/fontawesome-webfont.svg new file mode 100644 index 00000000..855c845e --- /dev/null +++ b/_static/css/fonts/fontawesome-webfont.svg @@ -0,0 +1,2671 @@ + + + + +Created by FontForge 20120731 at Mon Oct 24 17:37:40 2016 + By ,,, +Copyright Dave Gandy 2016. All rights reserved. + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/_static/css/fonts/fontawesome-webfont.ttf b/_static/css/fonts/fontawesome-webfont.ttf new file mode 100644 index 00000000..35acda2f Binary files /dev/null and b/_static/css/fonts/fontawesome-webfont.ttf differ diff --git a/_static/css/fonts/fontawesome-webfont.woff b/_static/css/fonts/fontawesome-webfont.woff new file mode 100644 index 00000000..400014a4 Binary files /dev/null and b/_static/css/fonts/fontawesome-webfont.woff differ diff --git a/_static/css/fonts/fontawesome-webfont.woff2 b/_static/css/fonts/fontawesome-webfont.woff2 new file mode 100644 index 00000000..4d13fc60 Binary files /dev/null and b/_static/css/fonts/fontawesome-webfont.woff2 differ diff --git a/_static/css/fonts/lato-bold-italic.woff b/_static/css/fonts/lato-bold-italic.woff new file mode 100644 index 00000000..88ad05b9 Binary files /dev/null and b/_static/css/fonts/lato-bold-italic.woff differ diff --git a/_static/css/fonts/lato-bold-italic.woff2 b/_static/css/fonts/lato-bold-italic.woff2 new file mode 100644 index 00000000..c4e3d804 Binary files /dev/null and b/_static/css/fonts/lato-bold-italic.woff2 differ diff --git a/_static/css/fonts/lato-bold.woff b/_static/css/fonts/lato-bold.woff new file mode 100644 index 00000000..c6dff51f Binary files /dev/null and b/_static/css/fonts/lato-bold.woff differ diff --git a/_static/css/fonts/lato-bold.woff2 b/_static/css/fonts/lato-bold.woff2 new file mode 100644 index 00000000..bb195043 Binary files /dev/null and b/_static/css/fonts/lato-bold.woff2 differ diff --git a/_static/css/fonts/lato-normal-italic.woff b/_static/css/fonts/lato-normal-italic.woff new file mode 100644 index 00000000..76114bc0 Binary files /dev/null and b/_static/css/fonts/lato-normal-italic.woff differ diff --git a/_static/css/fonts/lato-normal-italic.woff2 b/_static/css/fonts/lato-normal-italic.woff2 new file mode 100644 index 00000000..3404f37e Binary files /dev/null and b/_static/css/fonts/lato-normal-italic.woff2 differ diff --git a/_static/css/fonts/lato-normal.woff b/_static/css/fonts/lato-normal.woff new file mode 100644 index 00000000..ae1307ff Binary files /dev/null and b/_static/css/fonts/lato-normal.woff differ diff --git a/_static/css/fonts/lato-normal.woff2 b/_static/css/fonts/lato-normal.woff2 new file mode 100644 index 00000000..3bf98433 Binary files /dev/null and b/_static/css/fonts/lato-normal.woff2 differ diff --git a/_static/css/theme.css b/_static/css/theme.css new file mode 100644 index 00000000..19a446a0 --- /dev/null +++ b/_static/css/theme.css @@ -0,0 +1,4 @@ +html{box-sizing:border-box}*,:after,:before{box-sizing:inherit}article,aside,details,figcaption,figure,footer,header,hgroup,nav,section{display:block}audio,canvas,video{display:inline-block;*display:inline;*zoom:1}[hidden],audio:not([controls]){display:none}*{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}html{font-size:100%;-webkit-text-size-adjust:100%;-ms-text-size-adjust:100%}body{margin:0}a:active,a:hover{outline:0}abbr[title]{border-bottom:1px dotted}b,strong{font-weight:700}blockquote{margin:0}dfn{font-style:italic}ins{background:#ff9;text-decoration:none}ins,mark{color:#000}mark{background:#ff0;font-style:italic;font-weight:700}.rst-content code,.rst-content tt,code,kbd,pre,samp{font-family:monospace,serif;_font-family:courier new,monospace;font-size:1em}pre{white-space:pre}q{quotes:none}q:after,q:before{content:"";content:none}small{font-size:85%}sub,sup{font-size:75%;line-height:0;position:relative;vertical-align:baseline}sup{top:-.5em}sub{bottom:-.25em}dl,ol,ul{margin:0;padding:0;list-style:none;list-style-image:none}li{list-style:none}dd{margin:0}img{border:0;-ms-interpolation-mode:bicubic;vertical-align:middle;max-width:100%}svg:not(:root){overflow:hidden}figure,form{margin:0}label{cursor:pointer}button,input,select,textarea{font-size:100%;margin:0;vertical-align:baseline;*vertical-align:middle}button,input{line-height:normal}button,input[type=button],input[type=reset],input[type=submit]{cursor:pointer;-webkit-appearance:button;*overflow:visible}button[disabled],input[disabled]{cursor:default}input[type=search]{-webkit-appearance:textfield;-moz-box-sizing:content-box;-webkit-box-sizing:content-box;box-sizing:content-box}textarea{resize:vertical}table{border-collapse:collapse;border-spacing:0}td{vertical-align:top}.chromeframe{margin:.2em 0;background:#ccc;color:#000;padding:.2em 0}.ir{display:block;border:0;text-indent:-999em;overflow:hidden;background-color:transparent;background-repeat:no-repeat;text-align:left;direction:ltr;*line-height:0}.ir br{display:none}.hidden{display:none!important;visibility:hidden}.visuallyhidden{border:0;clip:rect(0 0 0 0);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;width:1px}.visuallyhidden.focusable:active,.visuallyhidden.focusable:focus{clip:auto;height:auto;margin:0;overflow:visible;position:static;width:auto}.invisible{visibility:hidden}.relative{position:relative}big,small{font-size:100%}@media print{body,html,section{background:none!important}*{box-shadow:none!important;text-shadow:none!important;filter:none!important;-ms-filter:none!important}a,a:visited{text-decoration:underline}.ir a:after,a[href^="#"]:after,a[href^="javascript:"]:after{content:""}blockquote,pre{page-break-inside:avoid}thead{display:table-header-group}img,tr{page-break-inside:avoid}img{max-width:100%!important}@page{margin:.5cm}.rst-content .toctree-wrapper>p.caption,h2,h3,p{orphans:3;widows:3}.rst-content .toctree-wrapper>p.caption,h2,h3{page-break-after:avoid}}.btn,.fa:before,.icon:before,.rst-content .admonition,.rst-content .admonition-title:before,.rst-content .admonition-todo,.rst-content .attention,.rst-content .caution,.rst-content .code-block-caption .headerlink:before,.rst-content .danger,.rst-content .eqno .headerlink:before,.rst-content .error,.rst-content .hint,.rst-content .important,.rst-content .note,.rst-content .seealso,.rst-content .tip,.rst-content .warning,.rst-content code.download span:first-child:before,.rst-content dl dt .headerlink:before,.rst-content h1 .headerlink:before,.rst-content h2 .headerlink:before,.rst-content h3 .headerlink:before,.rst-content h4 .headerlink:before,.rst-content h5 .headerlink:before,.rst-content h6 .headerlink:before,.rst-content p.caption .headerlink:before,.rst-content p .headerlink:before,.rst-content table>caption .headerlink:before,.rst-content tt.download span:first-child:before,.wy-alert,.wy-dropdown .caret:before,.wy-inline-validate.wy-inline-validate-danger .wy-input-context:before,.wy-inline-validate.wy-inline-validate-info .wy-input-context:before,.wy-inline-validate.wy-inline-validate-success .wy-input-context:before,.wy-inline-validate.wy-inline-validate-warning .wy-input-context:before,.wy-menu-vertical li.current>a button.toctree-expand:before,.wy-menu-vertical li.on a button.toctree-expand:before,.wy-menu-vertical li button.toctree-expand:before,input[type=color],input[type=date],input[type=datetime-local],input[type=datetime],input[type=email],input[type=month],input[type=number],input[type=password],input[type=search],input[type=tel],input[type=text],input[type=time],input[type=url],input[type=week],select,textarea{-webkit-font-smoothing:antialiased}.clearfix{*zoom:1}.clearfix:after,.clearfix:before{display:table;content:""}.clearfix:after{clear:both}/*! + * Font Awesome 4.7.0 by @davegandy - http://fontawesome.io - @fontawesome + * License - http://fontawesome.io/license (Font: SIL OFL 1.1, CSS: MIT License) + */@font-face{font-family:FontAwesome;src:url(fonts/fontawesome-webfont.eot?674f50d287a8c48dc19ba404d20fe713);src:url(fonts/fontawesome-webfont.eot?674f50d287a8c48dc19ba404d20fe713?#iefix&v=4.7.0) format("embedded-opentype"),url(fonts/fontawesome-webfont.woff2?af7ae505a9eed503f8b8e6982036873e) format("woff2"),url(fonts/fontawesome-webfont.woff?fee66e712a8a08eef5805a46892932ad) format("woff"),url(fonts/fontawesome-webfont.ttf?b06871f281fee6b241d60582ae9369b9) format("truetype"),url(fonts/fontawesome-webfont.svg?912ec66d7572ff821749319396470bde#fontawesomeregular) format("svg");font-weight:400;font-style:normal}.fa,.icon,.rst-content .admonition-title,.rst-content .code-block-caption .headerlink,.rst-content .eqno .headerlink,.rst-content code.download span:first-child,.rst-content dl dt .headerlink,.rst-content h1 .headerlink,.rst-content h2 .headerlink,.rst-content h3 .headerlink,.rst-content h4 .headerlink,.rst-content h5 .headerlink,.rst-content h6 .headerlink,.rst-content p.caption .headerlink,.rst-content p .headerlink,.rst-content table>caption .headerlink,.rst-content tt.download span:first-child,.wy-menu-vertical li.current>a button.toctree-expand,.wy-menu-vertical li.on a button.toctree-expand,.wy-menu-vertical li button.toctree-expand{display:inline-block;font:normal normal normal 14px/1 FontAwesome;font-size:inherit;text-rendering:auto;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}.fa-lg{font-size:1.33333em;line-height:.75em;vertical-align:-15%}.fa-2x{font-size:2em}.fa-3x{font-size:3em}.fa-4x{font-size:4em}.fa-5x{font-size:5em}.fa-fw{width:1.28571em;text-align:center}.fa-ul{padding-left:0;margin-left:2.14286em;list-style-type:none}.fa-ul>li{position:relative}.fa-li{position:absolute;left:-2.14286em;width:2.14286em;top:.14286em;text-align:center}.fa-li.fa-lg{left:-1.85714em}.fa-border{padding:.2em .25em .15em;border:.08em solid #eee;border-radius:.1em}.fa-pull-left{float:left}.fa-pull-right{float:right}.fa-pull-left.icon,.fa.fa-pull-left,.rst-content .code-block-caption .fa-pull-left.headerlink,.rst-content .eqno .fa-pull-left.headerlink,.rst-content .fa-pull-left.admonition-title,.rst-content code.download span.fa-pull-left:first-child,.rst-content dl dt .fa-pull-left.headerlink,.rst-content h1 .fa-pull-left.headerlink,.rst-content h2 .fa-pull-left.headerlink,.rst-content h3 .fa-pull-left.headerlink,.rst-content h4 .fa-pull-left.headerlink,.rst-content h5 .fa-pull-left.headerlink,.rst-content h6 .fa-pull-left.headerlink,.rst-content p .fa-pull-left.headerlink,.rst-content table>caption .fa-pull-left.headerlink,.rst-content tt.download span.fa-pull-left:first-child,.wy-menu-vertical li.current>a button.fa-pull-left.toctree-expand,.wy-menu-vertical li.on a button.fa-pull-left.toctree-expand,.wy-menu-vertical li button.fa-pull-left.toctree-expand{margin-right:.3em}.fa-pull-right.icon,.fa.fa-pull-right,.rst-content .code-block-caption .fa-pull-right.headerlink,.rst-content .eqno .fa-pull-right.headerlink,.rst-content .fa-pull-right.admonition-title,.rst-content code.download span.fa-pull-right:first-child,.rst-content dl dt .fa-pull-right.headerlink,.rst-content h1 .fa-pull-right.headerlink,.rst-content h2 .fa-pull-right.headerlink,.rst-content h3 .fa-pull-right.headerlink,.rst-content h4 .fa-pull-right.headerlink,.rst-content h5 .fa-pull-right.headerlink,.rst-content h6 .fa-pull-right.headerlink,.rst-content p .fa-pull-right.headerlink,.rst-content table>caption .fa-pull-right.headerlink,.rst-content tt.download span.fa-pull-right:first-child,.wy-menu-vertical li.current>a button.fa-pull-right.toctree-expand,.wy-menu-vertical li.on a button.fa-pull-right.toctree-expand,.wy-menu-vertical li button.fa-pull-right.toctree-expand{margin-left:.3em}.pull-right{float:right}.pull-left{float:left}.fa.pull-left,.pull-left.icon,.rst-content .code-block-caption .pull-left.headerlink,.rst-content .eqno .pull-left.headerlink,.rst-content .pull-left.admonition-title,.rst-content code.download span.pull-left:first-child,.rst-content dl dt .pull-left.headerlink,.rst-content h1 .pull-left.headerlink,.rst-content h2 .pull-left.headerlink,.rst-content h3 .pull-left.headerlink,.rst-content h4 .pull-left.headerlink,.rst-content h5 .pull-left.headerlink,.rst-content h6 .pull-left.headerlink,.rst-content p .pull-left.headerlink,.rst-content table>caption .pull-left.headerlink,.rst-content tt.download span.pull-left:first-child,.wy-menu-vertical li.current>a button.pull-left.toctree-expand,.wy-menu-vertical li.on a button.pull-left.toctree-expand,.wy-menu-vertical li button.pull-left.toctree-expand{margin-right:.3em}.fa.pull-right,.pull-right.icon,.rst-content .code-block-caption .pull-right.headerlink,.rst-content .eqno .pull-right.headerlink,.rst-content .pull-right.admonition-title,.rst-content code.download span.pull-right:first-child,.rst-content dl dt .pull-right.headerlink,.rst-content h1 .pull-right.headerlink,.rst-content h2 .pull-right.headerlink,.rst-content h3 .pull-right.headerlink,.rst-content h4 .pull-right.headerlink,.rst-content h5 .pull-right.headerlink,.rst-content h6 .pull-right.headerlink,.rst-content p .pull-right.headerlink,.rst-content table>caption .pull-right.headerlink,.rst-content tt.download span.pull-right:first-child,.wy-menu-vertical li.current>a button.pull-right.toctree-expand,.wy-menu-vertical li.on a button.pull-right.toctree-expand,.wy-menu-vertical li button.pull-right.toctree-expand{margin-left:.3em}.fa-spin{-webkit-animation:fa-spin 2s linear infinite;animation:fa-spin 2s linear infinite}.fa-pulse{-webkit-animation:fa-spin 1s steps(8) infinite;animation:fa-spin 1s steps(8) infinite}@-webkit-keyframes fa-spin{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}to{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}@keyframes fa-spin{0%{-webkit-transform:rotate(0deg);transform:rotate(0deg)}to{-webkit-transform:rotate(359deg);transform:rotate(359deg)}}.fa-rotate-90{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=1)";-webkit-transform:rotate(90deg);-ms-transform:rotate(90deg);transform:rotate(90deg)}.fa-rotate-180{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=2)";-webkit-transform:rotate(180deg);-ms-transform:rotate(180deg);transform:rotate(180deg)}.fa-rotate-270{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=3)";-webkit-transform:rotate(270deg);-ms-transform:rotate(270deg);transform:rotate(270deg)}.fa-flip-horizontal{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=0, mirror=1)";-webkit-transform:scaleX(-1);-ms-transform:scaleX(-1);transform:scaleX(-1)}.fa-flip-vertical{-ms-filter:"progid:DXImageTransform.Microsoft.BasicImage(rotation=2, mirror=1)";-webkit-transform:scaleY(-1);-ms-transform:scaleY(-1);transform:scaleY(-1)}:root .fa-flip-horizontal,:root .fa-flip-vertical,:root .fa-rotate-90,:root .fa-rotate-180,:root .fa-rotate-270{filter:none}.fa-stack{position:relative;display:inline-block;width:2em;height:2em;line-height:2em;vertical-align:middle}.fa-stack-1x,.fa-stack-2x{position:absolute;left:0;width:100%;text-align:center}.fa-stack-1x{line-height:inherit}.fa-stack-2x{font-size:2em}.fa-inverse{color:#fff}.fa-glass:before{content:""}.fa-music:before{content:""}.fa-search:before,.icon-search:before{content:""}.fa-envelope-o:before{content:""}.fa-heart:before{content:""}.fa-star:before{content:""}.fa-star-o:before{content:""}.fa-user:before{content:""}.fa-film:before{content:""}.fa-th-large:before{content:""}.fa-th:before{content:""}.fa-th-list:before{content:""}.fa-check:before{content:""}.fa-close:before,.fa-remove:before,.fa-times:before{content:""}.fa-search-plus:before{content:""}.fa-search-minus:before{content:""}.fa-power-off:before{content:""}.fa-signal:before{content:""}.fa-cog:before,.fa-gear:before{content:""}.fa-trash-o:before{content:""}.fa-home:before,.icon-home:before{content:""}.fa-file-o:before{content:""}.fa-clock-o:before{content:""}.fa-road:before{content:""}.fa-download:before,.rst-content code.download span:first-child:before,.rst-content tt.download span:first-child:before{content:""}.fa-arrow-circle-o-down:before{content:""}.fa-arrow-circle-o-up:before{content:""}.fa-inbox:before{content:""}.fa-play-circle-o:before{content:""}.fa-repeat:before,.fa-rotate-right:before{content:""}.fa-refresh:before{content:""}.fa-list-alt:before{content:""}.fa-lock:before{content:""}.fa-flag:before{content:""}.fa-headphones:before{content:""}.fa-volume-off:before{content:""}.fa-volume-down:before{content:""}.fa-volume-up:before{content:""}.fa-qrcode:before{content:""}.fa-barcode:before{content:""}.fa-tag:before{content:""}.fa-tags:before{content:""}.fa-book:before,.icon-book:before{content:""}.fa-bookmark:before{content:""}.fa-print:before{content:""}.fa-camera:before{content:""}.fa-font:before{content:""}.fa-bold:before{content:""}.fa-italic:before{content:""}.fa-text-height:before{content:""}.fa-text-width:before{content:""}.fa-align-left:before{content:""}.fa-align-center:before{content:""}.fa-align-right:before{content:""}.fa-align-justify:before{content:""}.fa-list:before{content:""}.fa-dedent:before,.fa-outdent:before{content:""}.fa-indent:before{content:""}.fa-video-camera:before{content:""}.fa-image:before,.fa-photo:before,.fa-picture-o:before{content:""}.fa-pencil:before{content:""}.fa-map-marker:before{content:""}.fa-adjust:before{content:""}.fa-tint:before{content:""}.fa-edit:before,.fa-pencil-square-o:before{content:""}.fa-share-square-o:before{content:""}.fa-check-square-o:before{content:""}.fa-arrows:before{content:""}.fa-step-backward:before{content:""}.fa-fast-backward:before{content:""}.fa-backward:before{content:""}.fa-play:before{content:""}.fa-pause:before{content:""}.fa-stop:before{content:""}.fa-forward:before{content:""}.fa-fast-forward:before{content:""}.fa-step-forward:before{content:""}.fa-eject:before{content:""}.fa-chevron-left:before{content:""}.fa-chevron-right:before{content:""}.fa-plus-circle:before{content:""}.fa-minus-circle:before{content:""}.fa-times-circle:before,.wy-inline-validate.wy-inline-validate-danger .wy-input-context:before{content:""}.fa-check-circle:before,.wy-inline-validate.wy-inline-validate-success .wy-input-context:before{content:""}.fa-question-circle:before{content:""}.fa-info-circle:before{content:""}.fa-crosshairs:before{content:""}.fa-times-circle-o:before{content:""}.fa-check-circle-o:before{content:""}.fa-ban:before{content:""}.fa-arrow-left:before{content:""}.fa-arrow-right:before{content:""}.fa-arrow-up:before{content:""}.fa-arrow-down:before{content:""}.fa-mail-forward:before,.fa-share:before{content:""}.fa-expand:before{content:""}.fa-compress:before{content:""}.fa-plus:before{content:""}.fa-minus:before{content:""}.fa-asterisk:before{content:""}.fa-exclamation-circle:before,.rst-content .admonition-title:before,.wy-inline-validate.wy-inline-validate-info .wy-input-context:before,.wy-inline-validate.wy-inline-validate-warning .wy-input-context:before{content:""}.fa-gift:before{content:""}.fa-leaf:before{content:""}.fa-fire:before,.icon-fire:before{content:""}.fa-eye:before{content:""}.fa-eye-slash:before{content:""}.fa-exclamation-triangle:before,.fa-warning:before{content:""}.fa-plane:before{content:""}.fa-calendar:before{content:""}.fa-random:before{content:""}.fa-comment:before{content:""}.fa-magnet:before{content:""}.fa-chevron-up:before{content:""}.fa-chevron-down:before{content:""}.fa-retweet:before{content:""}.fa-shopping-cart:before{content:""}.fa-folder:before{content:""}.fa-folder-open:before{content:""}.fa-arrows-v:before{content:""}.fa-arrows-h:before{content:""}.fa-bar-chart-o:before,.fa-bar-chart:before{content:""}.fa-twitter-square:before{content:""}.fa-facebook-square:before{content:""}.fa-camera-retro:before{content:""}.fa-key:before{content:""}.fa-cogs:before,.fa-gears:before{content:""}.fa-comments:before{content:""}.fa-thumbs-o-up:before{content:""}.fa-thumbs-o-down:before{content:""}.fa-star-half:before{content:""}.fa-heart-o:before{content:""}.fa-sign-out:before{content:""}.fa-linkedin-square:before{content:""}.fa-thumb-tack:before{content:""}.fa-external-link:before{content:""}.fa-sign-in:before{content:""}.fa-trophy:before{content:""}.fa-github-square:before{content:""}.fa-upload:before{content:""}.fa-lemon-o:before{content:""}.fa-phone:before{content:""}.fa-square-o:before{content:""}.fa-bookmark-o:before{content:""}.fa-phone-square:before{content:""}.fa-twitter:before{content:""}.fa-facebook-f:before,.fa-facebook:before{content:""}.fa-github:before,.icon-github:before{content:""}.fa-unlock:before{content:""}.fa-credit-card:before{content:""}.fa-feed:before,.fa-rss:before{content:""}.fa-hdd-o:before{content:""}.fa-bullhorn:before{content:""}.fa-bell:before{content:""}.fa-certificate:before{content:""}.fa-hand-o-right:before{content:""}.fa-hand-o-left:before{content:""}.fa-hand-o-up:before{content:""}.fa-hand-o-down:before{content:""}.fa-arrow-circle-left:before,.icon-circle-arrow-left:before{content:""}.fa-arrow-circle-right:before,.icon-circle-arrow-right:before{content:""}.fa-arrow-circle-up:before{content:""}.fa-arrow-circle-down:before{content:""}.fa-globe:before{content:""}.fa-wrench:before{content:""}.fa-tasks:before{content:""}.fa-filter:before{content:""}.fa-briefcase:before{content:""}.fa-arrows-alt:before{content:""}.fa-group:before,.fa-users:before{content:""}.fa-chain:before,.fa-link:before,.icon-link:before{content:""}.fa-cloud:before{content:""}.fa-flask:before{content:""}.fa-cut:before,.fa-scissors:before{content:""}.fa-copy:before,.fa-files-o:before{content:""}.fa-paperclip:before{content:""}.fa-floppy-o:before,.fa-save:before{content:""}.fa-square:before{content:""}.fa-bars:before,.fa-navicon:before,.fa-reorder:before{content:""}.fa-list-ul:before{content:""}.fa-list-ol:before{content:""}.fa-strikethrough:before{content:""}.fa-underline:before{content:""}.fa-table:before{content:""}.fa-magic:before{content:""}.fa-truck:before{content:""}.fa-pinterest:before{content:""}.fa-pinterest-square:before{content:""}.fa-google-plus-square:before{content:""}.fa-google-plus:before{content:""}.fa-money:before{content:""}.fa-caret-down:before,.icon-caret-down:before,.wy-dropdown .caret:before{content:""}.fa-caret-up:before{content:""}.fa-caret-left:before{content:""}.fa-caret-right:before{content:""}.fa-columns:before{content:""}.fa-sort:before,.fa-unsorted:before{content:""}.fa-sort-desc:before,.fa-sort-down:before{content:""}.fa-sort-asc:before,.fa-sort-up:before{content:""}.fa-envelope:before{content:""}.fa-linkedin:before{content:""}.fa-rotate-left:before,.fa-undo:before{content:""}.fa-gavel:before,.fa-legal:before{content:""}.fa-dashboard:before,.fa-tachometer:before{content:""}.fa-comment-o:before{content:""}.fa-comments-o:before{content:""}.fa-bolt:before,.fa-flash:before{content:""}.fa-sitemap:before{content:""}.fa-umbrella:before{content:""}.fa-clipboard:before,.fa-paste:before{content:""}.fa-lightbulb-o:before{content:""}.fa-exchange:before{content:""}.fa-cloud-download:before{content:""}.fa-cloud-upload:before{content:""}.fa-user-md:before{content:""}.fa-stethoscope:before{content:""}.fa-suitcase:before{content:""}.fa-bell-o:before{content:""}.fa-coffee:before{content:""}.fa-cutlery:before{content:""}.fa-file-text-o:before{content:""}.fa-building-o:before{content:""}.fa-hospital-o:before{content:""}.fa-ambulance:before{content:""}.fa-medkit:before{content:""}.fa-fighter-jet:before{content:""}.fa-beer:before{content:""}.fa-h-square:before{content:""}.fa-plus-square:before{content:""}.fa-angle-double-left:before{content:""}.fa-angle-double-right:before{content:""}.fa-angle-double-up:before{content:""}.fa-angle-double-down:before{content:""}.fa-angle-left:before{content:""}.fa-angle-right:before{content:""}.fa-angle-up:before{content:""}.fa-angle-down:before{content:""}.fa-desktop:before{content:""}.fa-laptop:before{content:""}.fa-tablet:before{content:""}.fa-mobile-phone:before,.fa-mobile:before{content:""}.fa-circle-o:before{content:""}.fa-quote-left:before{content:""}.fa-quote-right:before{content:""}.fa-spinner:before{content:""}.fa-circle:before{content:""}.fa-mail-reply:before,.fa-reply:before{content:""}.fa-github-alt:before{content:""}.fa-folder-o:before{content:""}.fa-folder-open-o:before{content:""}.fa-smile-o:before{content:""}.fa-frown-o:before{content:""}.fa-meh-o:before{content:""}.fa-gamepad:before{content:""}.fa-keyboard-o:before{content:""}.fa-flag-o:before{content:""}.fa-flag-checkered:before{content:""}.fa-terminal:before{content:""}.fa-code:before{content:""}.fa-mail-reply-all:before,.fa-reply-all:before{content:""}.fa-star-half-empty:before,.fa-star-half-full:before,.fa-star-half-o:before{content:""}.fa-location-arrow:before{content:""}.fa-crop:before{content:""}.fa-code-fork:before{content:""}.fa-chain-broken:before,.fa-unlink:before{content:""}.fa-question:before{content:""}.fa-info:before{content:""}.fa-exclamation:before{content:""}.fa-superscript:before{content:""}.fa-subscript:before{content:""}.fa-eraser:before{content:""}.fa-puzzle-piece:before{content:""}.fa-microphone:before{content:""}.fa-microphone-slash:before{content:""}.fa-shield:before{content:""}.fa-calendar-o:before{content:""}.fa-fire-extinguisher:before{content:""}.fa-rocket:before{content:""}.fa-maxcdn:before{content:""}.fa-chevron-circle-left:before{content:""}.fa-chevron-circle-right:before{content:""}.fa-chevron-circle-up:before{content:""}.fa-chevron-circle-down:before{content:""}.fa-html5:before{content:""}.fa-css3:before{content:""}.fa-anchor:before{content:""}.fa-unlock-alt:before{content:""}.fa-bullseye:before{content:""}.fa-ellipsis-h:before{content:""}.fa-ellipsis-v:before{content:""}.fa-rss-square:before{content:""}.fa-play-circle:before{content:""}.fa-ticket:before{content:""}.fa-minus-square:before{content:""}.fa-minus-square-o:before,.wy-menu-vertical li.current>a button.toctree-expand:before,.wy-menu-vertical li.on a button.toctree-expand:before{content:""}.fa-level-up:before{content:""}.fa-level-down:before{content:""}.fa-check-square:before{content:""}.fa-pencil-square:before{content:""}.fa-external-link-square:before{content:""}.fa-share-square:before{content:""}.fa-compass:before{content:""}.fa-caret-square-o-down:before,.fa-toggle-down:before{content:""}.fa-caret-square-o-up:before,.fa-toggle-up:before{content:""}.fa-caret-square-o-right:before,.fa-toggle-right:before{content:""}.fa-eur:before,.fa-euro:before{content:""}.fa-gbp:before{content:""}.fa-dollar:before,.fa-usd:before{content:""}.fa-inr:before,.fa-rupee:before{content:""}.fa-cny:before,.fa-jpy:before,.fa-rmb:before,.fa-yen:before{content:""}.fa-rouble:before,.fa-rub:before,.fa-ruble:before{content:""}.fa-krw:before,.fa-won:before{content:""}.fa-bitcoin:before,.fa-btc:before{content:""}.fa-file:before{content:""}.fa-file-text:before{content:""}.fa-sort-alpha-asc:before{content:""}.fa-sort-alpha-desc:before{content:""}.fa-sort-amount-asc:before{content:""}.fa-sort-amount-desc:before{content:""}.fa-sort-numeric-asc:before{content:""}.fa-sort-numeric-desc:before{content:""}.fa-thumbs-up:before{content:""}.fa-thumbs-down:before{content:""}.fa-youtube-square:before{content:""}.fa-youtube:before{content:""}.fa-xing:before{content:""}.fa-xing-square:before{content:""}.fa-youtube-play:before{content:""}.fa-dropbox:before{content:""}.fa-stack-overflow:before{content:""}.fa-instagram:before{content:""}.fa-flickr:before{content:""}.fa-adn:before{content:""}.fa-bitbucket:before,.icon-bitbucket:before{content:""}.fa-bitbucket-square:before{content:""}.fa-tumblr:before{content:""}.fa-tumblr-square:before{content:""}.fa-long-arrow-down:before{content:""}.fa-long-arrow-up:before{content:""}.fa-long-arrow-left:before{content:""}.fa-long-arrow-right:before{content:""}.fa-apple:before{content:""}.fa-windows:before{content:""}.fa-android:before{content:""}.fa-linux:before{content:""}.fa-dribbble:before{content:""}.fa-skype:before{content:""}.fa-foursquare:before{content:""}.fa-trello:before{content:""}.fa-female:before{content:""}.fa-male:before{content:""}.fa-gittip:before,.fa-gratipay:before{content:""}.fa-sun-o:before{content:""}.fa-moon-o:before{content:""}.fa-archive:before{content:""}.fa-bug:before{content:""}.fa-vk:before{content:""}.fa-weibo:before{content:""}.fa-renren:before{content:""}.fa-pagelines:before{content:""}.fa-stack-exchange:before{content:""}.fa-arrow-circle-o-right:before{content:""}.fa-arrow-circle-o-left:before{content:""}.fa-caret-square-o-left:before,.fa-toggle-left:before{content:""}.fa-dot-circle-o:before{content:""}.fa-wheelchair:before{content:""}.fa-vimeo-square:before{content:""}.fa-try:before,.fa-turkish-lira:before{content:""}.fa-plus-square-o:before,.wy-menu-vertical li button.toctree-expand:before{content:""}.fa-space-shuttle:before{content:""}.fa-slack:before{content:""}.fa-envelope-square:before{content:""}.fa-wordpress:before{content:""}.fa-openid:before{content:""}.fa-bank:before,.fa-institution:before,.fa-university:before{content:""}.fa-graduation-cap:before,.fa-mortar-board:before{content:""}.fa-yahoo:before{content:""}.fa-google:before{content:""}.fa-reddit:before{content:""}.fa-reddit-square:before{content:""}.fa-stumbleupon-circle:before{content:""}.fa-stumbleupon:before{content:""}.fa-delicious:before{content:""}.fa-digg:before{content:""}.fa-pied-piper-pp:before{content:""}.fa-pied-piper-alt:before{content:""}.fa-drupal:before{content:""}.fa-joomla:before{content:""}.fa-language:before{content:""}.fa-fax:before{content:""}.fa-building:before{content:""}.fa-child:before{content:""}.fa-paw:before{content:""}.fa-spoon:before{content:""}.fa-cube:before{content:""}.fa-cubes:before{content:""}.fa-behance:before{content:""}.fa-behance-square:before{content:""}.fa-steam:before{content:""}.fa-steam-square:before{content:""}.fa-recycle:before{content:""}.fa-automobile:before,.fa-car:before{content:""}.fa-cab:before,.fa-taxi:before{content:""}.fa-tree:before{content:""}.fa-spotify:before{content:""}.fa-deviantart:before{content:""}.fa-soundcloud:before{content:""}.fa-database:before{content:""}.fa-file-pdf-o:before{content:""}.fa-file-word-o:before{content:""}.fa-file-excel-o:before{content:""}.fa-file-powerpoint-o:before{content:""}.fa-file-image-o:before,.fa-file-photo-o:before,.fa-file-picture-o:before{content:""}.fa-file-archive-o:before,.fa-file-zip-o:before{content:""}.fa-file-audio-o:before,.fa-file-sound-o:before{content:""}.fa-file-movie-o:before,.fa-file-video-o:before{content:""}.fa-file-code-o:before{content:""}.fa-vine:before{content:""}.fa-codepen:before{content:""}.fa-jsfiddle:before{content:""}.fa-life-bouy:before,.fa-life-buoy:before,.fa-life-ring:before,.fa-life-saver:before,.fa-support:before{content:""}.fa-circle-o-notch:before{content:""}.fa-ra:before,.fa-rebel:before,.fa-resistance:before{content:""}.fa-empire:before,.fa-ge:before{content:""}.fa-git-square:before{content:""}.fa-git:before{content:""}.fa-hacker-news:before,.fa-y-combinator-square:before,.fa-yc-square:before{content:""}.fa-tencent-weibo:before{content:""}.fa-qq:before{content:""}.fa-wechat:before,.fa-weixin:before{content:""}.fa-paper-plane:before,.fa-send:before{content:""}.fa-paper-plane-o:before,.fa-send-o:before{content:""}.fa-history:before{content:""}.fa-circle-thin:before{content:""}.fa-header:before{content:""}.fa-paragraph:before{content:""}.fa-sliders:before{content:""}.fa-share-alt:before{content:""}.fa-share-alt-square:before{content:""}.fa-bomb:before{content:""}.fa-futbol-o:before,.fa-soccer-ball-o:before{content:""}.fa-tty:before{content:""}.fa-binoculars:before{content:""}.fa-plug:before{content:""}.fa-slideshare:before{content:""}.fa-twitch:before{content:""}.fa-yelp:before{content:""}.fa-newspaper-o:before{content:""}.fa-wifi:before{content:""}.fa-calculator:before{content:""}.fa-paypal:before{content:""}.fa-google-wallet:before{content:""}.fa-cc-visa:before{content:""}.fa-cc-mastercard:before{content:""}.fa-cc-discover:before{content:""}.fa-cc-amex:before{content:""}.fa-cc-paypal:before{content:""}.fa-cc-stripe:before{content:""}.fa-bell-slash:before{content:""}.fa-bell-slash-o:before{content:""}.fa-trash:before{content:""}.fa-copyright:before{content:""}.fa-at:before{content:""}.fa-eyedropper:before{content:""}.fa-paint-brush:before{content:""}.fa-birthday-cake:before{content:""}.fa-area-chart:before{content:""}.fa-pie-chart:before{content:""}.fa-line-chart:before{content:""}.fa-lastfm:before{content:""}.fa-lastfm-square:before{content:""}.fa-toggle-off:before{content:""}.fa-toggle-on:before{content:""}.fa-bicycle:before{content:""}.fa-bus:before{content:""}.fa-ioxhost:before{content:""}.fa-angellist:before{content:""}.fa-cc:before{content:""}.fa-ils:before,.fa-shekel:before,.fa-sheqel:before{content:""}.fa-meanpath:before{content:""}.fa-buysellads:before{content:""}.fa-connectdevelop:before{content:""}.fa-dashcube:before{content:""}.fa-forumbee:before{content:""}.fa-leanpub:before{content:""}.fa-sellsy:before{content:""}.fa-shirtsinbulk:before{content:""}.fa-simplybuilt:before{content:""}.fa-skyatlas:before{content:""}.fa-cart-plus:before{content:""}.fa-cart-arrow-down:before{content:""}.fa-diamond:before{content:""}.fa-ship:before{content:""}.fa-user-secret:before{content:""}.fa-motorcycle:before{content:""}.fa-street-view:before{content:""}.fa-heartbeat:before{content:""}.fa-venus:before{content:""}.fa-mars:before{content:""}.fa-mercury:before{content:""}.fa-intersex:before,.fa-transgender:before{content:""}.fa-transgender-alt:before{content:""}.fa-venus-double:before{content:""}.fa-mars-double:before{content:""}.fa-venus-mars:before{content:""}.fa-mars-stroke:before{content:""}.fa-mars-stroke-v:before{content:""}.fa-mars-stroke-h:before{content:""}.fa-neuter:before{content:""}.fa-genderless:before{content:""}.fa-facebook-official:before{content:""}.fa-pinterest-p:before{content:""}.fa-whatsapp:before{content:""}.fa-server:before{content:""}.fa-user-plus:before{content:""}.fa-user-times:before{content:""}.fa-bed:before,.fa-hotel:before{content:""}.fa-viacoin:before{content:""}.fa-train:before{content:""}.fa-subway:before{content:""}.fa-medium:before{content:""}.fa-y-combinator:before,.fa-yc:before{content:""}.fa-optin-monster:before{content:""}.fa-opencart:before{content:""}.fa-expeditedssl:before{content:""}.fa-battery-4:before,.fa-battery-full:before,.fa-battery:before{content:""}.fa-battery-3:before,.fa-battery-three-quarters:before{content:""}.fa-battery-2:before,.fa-battery-half:before{content:""}.fa-battery-1:before,.fa-battery-quarter:before{content:""}.fa-battery-0:before,.fa-battery-empty:before{content:""}.fa-mouse-pointer:before{content:""}.fa-i-cursor:before{content:""}.fa-object-group:before{content:""}.fa-object-ungroup:before{content:""}.fa-sticky-note:before{content:""}.fa-sticky-note-o:before{content:""}.fa-cc-jcb:before{content:""}.fa-cc-diners-club:before{content:""}.fa-clone:before{content:""}.fa-balance-scale:before{content:""}.fa-hourglass-o:before{content:""}.fa-hourglass-1:before,.fa-hourglass-start:before{content:""}.fa-hourglass-2:before,.fa-hourglass-half:before{content:""}.fa-hourglass-3:before,.fa-hourglass-end:before{content:""}.fa-hourglass:before{content:""}.fa-hand-grab-o:before,.fa-hand-rock-o:before{content:""}.fa-hand-paper-o:before,.fa-hand-stop-o:before{content:""}.fa-hand-scissors-o:before{content:""}.fa-hand-lizard-o:before{content:""}.fa-hand-spock-o:before{content:""}.fa-hand-pointer-o:before{content:""}.fa-hand-peace-o:before{content:""}.fa-trademark:before{content:""}.fa-registered:before{content:""}.fa-creative-commons:before{content:""}.fa-gg:before{content:""}.fa-gg-circle:before{content:""}.fa-tripadvisor:before{content:""}.fa-odnoklassniki:before{content:""}.fa-odnoklassniki-square:before{content:""}.fa-get-pocket:before{content:""}.fa-wikipedia-w:before{content:""}.fa-safari:before{content:""}.fa-chrome:before{content:""}.fa-firefox:before{content:""}.fa-opera:before{content:""}.fa-internet-explorer:before{content:""}.fa-television:before,.fa-tv:before{content:""}.fa-contao:before{content:""}.fa-500px:before{content:""}.fa-amazon:before{content:""}.fa-calendar-plus-o:before{content:""}.fa-calendar-minus-o:before{content:""}.fa-calendar-times-o:before{content:""}.fa-calendar-check-o:before{content:""}.fa-industry:before{content:""}.fa-map-pin:before{content:""}.fa-map-signs:before{content:""}.fa-map-o:before{content:""}.fa-map:before{content:""}.fa-commenting:before{content:""}.fa-commenting-o:before{content:""}.fa-houzz:before{content:""}.fa-vimeo:before{content:""}.fa-black-tie:before{content:""}.fa-fonticons:before{content:""}.fa-reddit-alien:before{content:""}.fa-edge:before{content:""}.fa-credit-card-alt:before{content:""}.fa-codiepie:before{content:""}.fa-modx:before{content:""}.fa-fort-awesome:before{content:""}.fa-usb:before{content:""}.fa-product-hunt:before{content:""}.fa-mixcloud:before{content:""}.fa-scribd:before{content:""}.fa-pause-circle:before{content:""}.fa-pause-circle-o:before{content:""}.fa-stop-circle:before{content:""}.fa-stop-circle-o:before{content:""}.fa-shopping-bag:before{content:""}.fa-shopping-basket:before{content:""}.fa-hashtag:before{content:""}.fa-bluetooth:before{content:""}.fa-bluetooth-b:before{content:""}.fa-percent:before{content:""}.fa-gitlab:before,.icon-gitlab:before{content:""}.fa-wpbeginner:before{content:""}.fa-wpforms:before{content:""}.fa-envira:before{content:""}.fa-universal-access:before{content:""}.fa-wheelchair-alt:before{content:""}.fa-question-circle-o:before{content:""}.fa-blind:before{content:""}.fa-audio-description:before{content:""}.fa-volume-control-phone:before{content:""}.fa-braille:before{content:""}.fa-assistive-listening-systems:before{content:""}.fa-american-sign-language-interpreting:before,.fa-asl-interpreting:before{content:""}.fa-deaf:before,.fa-deafness:before,.fa-hard-of-hearing:before{content:""}.fa-glide:before{content:""}.fa-glide-g:before{content:""}.fa-sign-language:before,.fa-signing:before{content:""}.fa-low-vision:before{content:""}.fa-viadeo:before{content:""}.fa-viadeo-square:before{content:""}.fa-snapchat:before{content:""}.fa-snapchat-ghost:before{content:""}.fa-snapchat-square:before{content:""}.fa-pied-piper:before{content:""}.fa-first-order:before{content:""}.fa-yoast:before{content:""}.fa-themeisle:before{content:""}.fa-google-plus-circle:before,.fa-google-plus-official:before{content:""}.fa-fa:before,.fa-font-awesome:before{content:""}.fa-handshake-o:before{content:""}.fa-envelope-open:before{content:""}.fa-envelope-open-o:before{content:""}.fa-linode:before{content:""}.fa-address-book:before{content:""}.fa-address-book-o:before{content:""}.fa-address-card:before,.fa-vcard:before{content:""}.fa-address-card-o:before,.fa-vcard-o:before{content:""}.fa-user-circle:before{content:""}.fa-user-circle-o:before{content:""}.fa-user-o:before{content:""}.fa-id-badge:before{content:""}.fa-drivers-license:before,.fa-id-card:before{content:""}.fa-drivers-license-o:before,.fa-id-card-o:before{content:""}.fa-quora:before{content:""}.fa-free-code-camp:before{content:""}.fa-telegram:before{content:""}.fa-thermometer-4:before,.fa-thermometer-full:before,.fa-thermometer:before{content:""}.fa-thermometer-3:before,.fa-thermometer-three-quarters:before{content:""}.fa-thermometer-2:before,.fa-thermometer-half:before{content:""}.fa-thermometer-1:before,.fa-thermometer-quarter:before{content:""}.fa-thermometer-0:before,.fa-thermometer-empty:before{content:""}.fa-shower:before{content:""}.fa-bath:before,.fa-bathtub:before,.fa-s15:before{content:""}.fa-podcast:before{content:""}.fa-window-maximize:before{content:""}.fa-window-minimize:before{content:""}.fa-window-restore:before{content:""}.fa-times-rectangle:before,.fa-window-close:before{content:""}.fa-times-rectangle-o:before,.fa-window-close-o:before{content:""}.fa-bandcamp:before{content:""}.fa-grav:before{content:""}.fa-etsy:before{content:""}.fa-imdb:before{content:""}.fa-ravelry:before{content:""}.fa-eercast:before{content:""}.fa-microchip:before{content:""}.fa-snowflake-o:before{content:""}.fa-superpowers:before{content:""}.fa-wpexplorer:before{content:""}.fa-meetup:before{content:""}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);border:0}.sr-only-focusable:active,.sr-only-focusable:focus{position:static;width:auto;height:auto;margin:0;overflow:visible;clip:auto}.fa,.icon,.rst-content .admonition-title,.rst-content .code-block-caption .headerlink,.rst-content .eqno .headerlink,.rst-content code.download span:first-child,.rst-content dl dt .headerlink,.rst-content h1 .headerlink,.rst-content h2 .headerlink,.rst-content h3 .headerlink,.rst-content h4 .headerlink,.rst-content h5 .headerlink,.rst-content h6 .headerlink,.rst-content p.caption .headerlink,.rst-content p .headerlink,.rst-content table>caption .headerlink,.rst-content tt.download span:first-child,.wy-dropdown .caret,.wy-inline-validate.wy-inline-validate-danger .wy-input-context,.wy-inline-validate.wy-inline-validate-info .wy-input-context,.wy-inline-validate.wy-inline-validate-success .wy-input-context,.wy-inline-validate.wy-inline-validate-warning .wy-input-context,.wy-menu-vertical li.current>a button.toctree-expand,.wy-menu-vertical li.on a button.toctree-expand,.wy-menu-vertical li button.toctree-expand{font-family:inherit}.fa:before,.icon:before,.rst-content .admonition-title:before,.rst-content .code-block-caption .headerlink:before,.rst-content .eqno .headerlink:before,.rst-content code.download span:first-child:before,.rst-content dl dt .headerlink:before,.rst-content h1 .headerlink:before,.rst-content h2 .headerlink:before,.rst-content h3 .headerlink:before,.rst-content h4 .headerlink:before,.rst-content h5 .headerlink:before,.rst-content h6 .headerlink:before,.rst-content p.caption .headerlink:before,.rst-content p .headerlink:before,.rst-content table>caption .headerlink:before,.rst-content tt.download span:first-child:before,.wy-dropdown .caret:before,.wy-inline-validate.wy-inline-validate-danger .wy-input-context:before,.wy-inline-validate.wy-inline-validate-info .wy-input-context:before,.wy-inline-validate.wy-inline-validate-success .wy-input-context:before,.wy-inline-validate.wy-inline-validate-warning .wy-input-context:before,.wy-menu-vertical li.current>a button.toctree-expand:before,.wy-menu-vertical li.on a button.toctree-expand:before,.wy-menu-vertical li button.toctree-expand:before{font-family:FontAwesome;display:inline-block;font-style:normal;font-weight:400;line-height:1;text-decoration:inherit}.rst-content .code-block-caption a .headerlink,.rst-content .eqno a .headerlink,.rst-content a .admonition-title,.rst-content code.download a span:first-child,.rst-content dl dt a .headerlink,.rst-content h1 a .headerlink,.rst-content h2 a .headerlink,.rst-content h3 a .headerlink,.rst-content h4 a .headerlink,.rst-content h5 a .headerlink,.rst-content h6 a .headerlink,.rst-content p.caption a .headerlink,.rst-content p a .headerlink,.rst-content table>caption a .headerlink,.rst-content tt.download a span:first-child,.wy-menu-vertical li.current>a button.toctree-expand,.wy-menu-vertical li.on a button.toctree-expand,.wy-menu-vertical li a button.toctree-expand,a .fa,a .icon,a .rst-content .admonition-title,a .rst-content .code-block-caption .headerlink,a .rst-content .eqno .headerlink,a .rst-content code.download span:first-child,a .rst-content dl dt .headerlink,a .rst-content h1 .headerlink,a .rst-content h2 .headerlink,a .rst-content h3 .headerlink,a .rst-content h4 .headerlink,a .rst-content h5 .headerlink,a .rst-content h6 .headerlink,a .rst-content p.caption .headerlink,a .rst-content p .headerlink,a .rst-content table>caption .headerlink,a .rst-content tt.download span:first-child,a .wy-menu-vertical li button.toctree-expand{display:inline-block;text-decoration:inherit}.btn .fa,.btn .icon,.btn .rst-content .admonition-title,.btn .rst-content .code-block-caption .headerlink,.btn .rst-content .eqno .headerlink,.btn .rst-content code.download span:first-child,.btn .rst-content dl dt .headerlink,.btn .rst-content h1 .headerlink,.btn .rst-content h2 .headerlink,.btn .rst-content h3 .headerlink,.btn .rst-content h4 .headerlink,.btn .rst-content h5 .headerlink,.btn .rst-content h6 .headerlink,.btn .rst-content p .headerlink,.btn .rst-content table>caption .headerlink,.btn .rst-content tt.download span:first-child,.btn .wy-menu-vertical li.current>a button.toctree-expand,.btn .wy-menu-vertical li.on a button.toctree-expand,.btn .wy-menu-vertical li button.toctree-expand,.nav .fa,.nav .icon,.nav .rst-content .admonition-title,.nav .rst-content .code-block-caption .headerlink,.nav .rst-content .eqno .headerlink,.nav .rst-content code.download span:first-child,.nav .rst-content dl dt .headerlink,.nav .rst-content h1 .headerlink,.nav .rst-content h2 .headerlink,.nav .rst-content h3 .headerlink,.nav .rst-content h4 .headerlink,.nav .rst-content h5 .headerlink,.nav .rst-content h6 .headerlink,.nav .rst-content p .headerlink,.nav .rst-content table>caption .headerlink,.nav .rst-content tt.download span:first-child,.nav .wy-menu-vertical li.current>a button.toctree-expand,.nav .wy-menu-vertical li.on a button.toctree-expand,.nav .wy-menu-vertical li button.toctree-expand,.rst-content .btn .admonition-title,.rst-content .code-block-caption .btn .headerlink,.rst-content .code-block-caption .nav .headerlink,.rst-content .eqno .btn .headerlink,.rst-content .eqno .nav .headerlink,.rst-content .nav .admonition-title,.rst-content code.download .btn span:first-child,.rst-content code.download .nav span:first-child,.rst-content dl dt .btn .headerlink,.rst-content dl dt .nav .headerlink,.rst-content h1 .btn .headerlink,.rst-content h1 .nav .headerlink,.rst-content h2 .btn .headerlink,.rst-content h2 .nav .headerlink,.rst-content h3 .btn .headerlink,.rst-content h3 .nav .headerlink,.rst-content h4 .btn .headerlink,.rst-content h4 .nav .headerlink,.rst-content h5 .btn .headerlink,.rst-content h5 .nav .headerlink,.rst-content h6 .btn .headerlink,.rst-content h6 .nav .headerlink,.rst-content p .btn .headerlink,.rst-content p .nav .headerlink,.rst-content table>caption .btn .headerlink,.rst-content table>caption .nav .headerlink,.rst-content tt.download .btn span:first-child,.rst-content tt.download .nav span:first-child,.wy-menu-vertical li .btn button.toctree-expand,.wy-menu-vertical li.current>a .btn button.toctree-expand,.wy-menu-vertical li.current>a .nav button.toctree-expand,.wy-menu-vertical li .nav button.toctree-expand,.wy-menu-vertical li.on a .btn button.toctree-expand,.wy-menu-vertical li.on a .nav button.toctree-expand{display:inline}.btn .fa-large.icon,.btn .fa.fa-large,.btn .rst-content .code-block-caption .fa-large.headerlink,.btn .rst-content .eqno .fa-large.headerlink,.btn .rst-content .fa-large.admonition-title,.btn .rst-content code.download span.fa-large:first-child,.btn .rst-content dl dt .fa-large.headerlink,.btn .rst-content h1 .fa-large.headerlink,.btn .rst-content h2 .fa-large.headerlink,.btn .rst-content h3 .fa-large.headerlink,.btn .rst-content h4 .fa-large.headerlink,.btn .rst-content h5 .fa-large.headerlink,.btn .rst-content h6 .fa-large.headerlink,.btn .rst-content p .fa-large.headerlink,.btn .rst-content table>caption .fa-large.headerlink,.btn .rst-content tt.download span.fa-large:first-child,.btn .wy-menu-vertical li button.fa-large.toctree-expand,.nav .fa-large.icon,.nav .fa.fa-large,.nav .rst-content .code-block-caption .fa-large.headerlink,.nav .rst-content .eqno .fa-large.headerlink,.nav .rst-content .fa-large.admonition-title,.nav .rst-content code.download span.fa-large:first-child,.nav .rst-content dl dt .fa-large.headerlink,.nav .rst-content h1 .fa-large.headerlink,.nav .rst-content h2 .fa-large.headerlink,.nav .rst-content h3 .fa-large.headerlink,.nav .rst-content h4 .fa-large.headerlink,.nav .rst-content h5 .fa-large.headerlink,.nav .rst-content h6 .fa-large.headerlink,.nav .rst-content p .fa-large.headerlink,.nav .rst-content table>caption .fa-large.headerlink,.nav .rst-content tt.download span.fa-large:first-child,.nav .wy-menu-vertical li button.fa-large.toctree-expand,.rst-content .btn .fa-large.admonition-title,.rst-content .code-block-caption .btn .fa-large.headerlink,.rst-content .code-block-caption .nav .fa-large.headerlink,.rst-content .eqno .btn .fa-large.headerlink,.rst-content .eqno .nav .fa-large.headerlink,.rst-content .nav .fa-large.admonition-title,.rst-content code.download .btn span.fa-large:first-child,.rst-content code.download .nav span.fa-large:first-child,.rst-content dl dt .btn .fa-large.headerlink,.rst-content dl dt .nav .fa-large.headerlink,.rst-content h1 .btn .fa-large.headerlink,.rst-content h1 .nav .fa-large.headerlink,.rst-content h2 .btn .fa-large.headerlink,.rst-content h2 .nav .fa-large.headerlink,.rst-content h3 .btn .fa-large.headerlink,.rst-content h3 .nav .fa-large.headerlink,.rst-content h4 .btn .fa-large.headerlink,.rst-content h4 .nav .fa-large.headerlink,.rst-content h5 .btn .fa-large.headerlink,.rst-content h5 .nav .fa-large.headerlink,.rst-content h6 .btn .fa-large.headerlink,.rst-content h6 .nav .fa-large.headerlink,.rst-content p .btn .fa-large.headerlink,.rst-content p .nav .fa-large.headerlink,.rst-content table>caption .btn .fa-large.headerlink,.rst-content table>caption .nav .fa-large.headerlink,.rst-content tt.download .btn span.fa-large:first-child,.rst-content tt.download .nav span.fa-large:first-child,.wy-menu-vertical li .btn button.fa-large.toctree-expand,.wy-menu-vertical li .nav button.fa-large.toctree-expand{line-height:.9em}.btn .fa-spin.icon,.btn .fa.fa-spin,.btn .rst-content .code-block-caption .fa-spin.headerlink,.btn .rst-content .eqno .fa-spin.headerlink,.btn .rst-content .fa-spin.admonition-title,.btn .rst-content code.download span.fa-spin:first-child,.btn .rst-content dl dt .fa-spin.headerlink,.btn .rst-content h1 .fa-spin.headerlink,.btn .rst-content h2 .fa-spin.headerlink,.btn .rst-content h3 .fa-spin.headerlink,.btn .rst-content h4 .fa-spin.headerlink,.btn .rst-content h5 .fa-spin.headerlink,.btn .rst-content h6 .fa-spin.headerlink,.btn .rst-content p .fa-spin.headerlink,.btn .rst-content table>caption .fa-spin.headerlink,.btn .rst-content tt.download span.fa-spin:first-child,.btn .wy-menu-vertical li button.fa-spin.toctree-expand,.nav .fa-spin.icon,.nav .fa.fa-spin,.nav .rst-content .code-block-caption .fa-spin.headerlink,.nav .rst-content .eqno .fa-spin.headerlink,.nav .rst-content .fa-spin.admonition-title,.nav .rst-content code.download span.fa-spin:first-child,.nav .rst-content dl dt .fa-spin.headerlink,.nav .rst-content h1 .fa-spin.headerlink,.nav .rst-content h2 .fa-spin.headerlink,.nav .rst-content h3 .fa-spin.headerlink,.nav .rst-content h4 .fa-spin.headerlink,.nav .rst-content h5 .fa-spin.headerlink,.nav .rst-content h6 .fa-spin.headerlink,.nav .rst-content p .fa-spin.headerlink,.nav .rst-content table>caption .fa-spin.headerlink,.nav .rst-content tt.download span.fa-spin:first-child,.nav .wy-menu-vertical li button.fa-spin.toctree-expand,.rst-content .btn .fa-spin.admonition-title,.rst-content .code-block-caption .btn .fa-spin.headerlink,.rst-content .code-block-caption .nav .fa-spin.headerlink,.rst-content .eqno .btn .fa-spin.headerlink,.rst-content .eqno .nav .fa-spin.headerlink,.rst-content .nav .fa-spin.admonition-title,.rst-content code.download .btn span.fa-spin:first-child,.rst-content code.download .nav span.fa-spin:first-child,.rst-content dl dt .btn .fa-spin.headerlink,.rst-content dl dt .nav .fa-spin.headerlink,.rst-content h1 .btn .fa-spin.headerlink,.rst-content h1 .nav .fa-spin.headerlink,.rst-content h2 .btn .fa-spin.headerlink,.rst-content h2 .nav .fa-spin.headerlink,.rst-content h3 .btn .fa-spin.headerlink,.rst-content h3 .nav .fa-spin.headerlink,.rst-content h4 .btn .fa-spin.headerlink,.rst-content h4 .nav .fa-spin.headerlink,.rst-content h5 .btn .fa-spin.headerlink,.rst-content h5 .nav .fa-spin.headerlink,.rst-content h6 .btn .fa-spin.headerlink,.rst-content h6 .nav .fa-spin.headerlink,.rst-content p .btn .fa-spin.headerlink,.rst-content p .nav .fa-spin.headerlink,.rst-content table>caption .btn .fa-spin.headerlink,.rst-content table>caption .nav .fa-spin.headerlink,.rst-content tt.download .btn span.fa-spin:first-child,.rst-content tt.download .nav span.fa-spin:first-child,.wy-menu-vertical li .btn button.fa-spin.toctree-expand,.wy-menu-vertical li .nav button.fa-spin.toctree-expand{display:inline-block}.btn.fa:before,.btn.icon:before,.rst-content .btn.admonition-title:before,.rst-content .code-block-caption .btn.headerlink:before,.rst-content .eqno .btn.headerlink:before,.rst-content code.download span.btn:first-child:before,.rst-content dl dt .btn.headerlink:before,.rst-content h1 .btn.headerlink:before,.rst-content h2 .btn.headerlink:before,.rst-content h3 .btn.headerlink:before,.rst-content h4 .btn.headerlink:before,.rst-content h5 .btn.headerlink:before,.rst-content h6 .btn.headerlink:before,.rst-content p .btn.headerlink:before,.rst-content table>caption .btn.headerlink:before,.rst-content tt.download span.btn:first-child:before,.wy-menu-vertical li button.btn.toctree-expand:before{opacity:.5;-webkit-transition:opacity .05s ease-in;-moz-transition:opacity .05s ease-in;transition:opacity .05s ease-in}.btn.fa:hover:before,.btn.icon:hover:before,.rst-content .btn.admonition-title:hover:before,.rst-content .code-block-caption .btn.headerlink:hover:before,.rst-content .eqno .btn.headerlink:hover:before,.rst-content code.download span.btn:first-child:hover:before,.rst-content dl dt .btn.headerlink:hover:before,.rst-content h1 .btn.headerlink:hover:before,.rst-content h2 .btn.headerlink:hover:before,.rst-content h3 .btn.headerlink:hover:before,.rst-content h4 .btn.headerlink:hover:before,.rst-content h5 .btn.headerlink:hover:before,.rst-content h6 .btn.headerlink:hover:before,.rst-content p .btn.headerlink:hover:before,.rst-content table>caption .btn.headerlink:hover:before,.rst-content tt.download span.btn:first-child:hover:before,.wy-menu-vertical li button.btn.toctree-expand:hover:before{opacity:1}.btn-mini .fa:before,.btn-mini .icon:before,.btn-mini .rst-content .admonition-title:before,.btn-mini .rst-content .code-block-caption .headerlink:before,.btn-mini .rst-content .eqno .headerlink:before,.btn-mini .rst-content code.download span:first-child:before,.btn-mini .rst-content dl dt .headerlink:before,.btn-mini .rst-content h1 .headerlink:before,.btn-mini .rst-content h2 .headerlink:before,.btn-mini .rst-content h3 .headerlink:before,.btn-mini .rst-content h4 .headerlink:before,.btn-mini .rst-content h5 .headerlink:before,.btn-mini .rst-content h6 .headerlink:before,.btn-mini .rst-content p .headerlink:before,.btn-mini .rst-content table>caption .headerlink:before,.btn-mini .rst-content tt.download span:first-child:before,.btn-mini .wy-menu-vertical li button.toctree-expand:before,.rst-content .btn-mini .admonition-title:before,.rst-content .code-block-caption .btn-mini .headerlink:before,.rst-content .eqno .btn-mini .headerlink:before,.rst-content code.download .btn-mini span:first-child:before,.rst-content dl dt .btn-mini .headerlink:before,.rst-content h1 .btn-mini .headerlink:before,.rst-content h2 .btn-mini .headerlink:before,.rst-content h3 .btn-mini .headerlink:before,.rst-content h4 .btn-mini .headerlink:before,.rst-content h5 .btn-mini .headerlink:before,.rst-content h6 .btn-mini .headerlink:before,.rst-content p .btn-mini .headerlink:before,.rst-content table>caption .btn-mini .headerlink:before,.rst-content tt.download .btn-mini span:first-child:before,.wy-menu-vertical li .btn-mini button.toctree-expand:before{font-size:14px;vertical-align:-15%}.rst-content .admonition,.rst-content .admonition-todo,.rst-content .attention,.rst-content .caution,.rst-content .danger,.rst-content .error,.rst-content .hint,.rst-content .important,.rst-content .note,.rst-content .seealso,.rst-content .tip,.rst-content .warning,.wy-alert{padding:12px;line-height:24px;margin-bottom:24px;background:#e7f2fa}.rst-content .admonition-title,.wy-alert-title{font-weight:700;display:block;color:#fff;background:#6ab0de;padding:6px 12px;margin:-12px -12px 12px}.rst-content .danger,.rst-content .error,.rst-content .wy-alert-danger.admonition,.rst-content .wy-alert-danger.admonition-todo,.rst-content .wy-alert-danger.attention,.rst-content .wy-alert-danger.caution,.rst-content .wy-alert-danger.hint,.rst-content .wy-alert-danger.important,.rst-content .wy-alert-danger.note,.rst-content .wy-alert-danger.seealso,.rst-content .wy-alert-danger.tip,.rst-content .wy-alert-danger.warning,.wy-alert.wy-alert-danger{background:#fdf3f2}.rst-content .danger .admonition-title,.rst-content .danger .wy-alert-title,.rst-content .error .admonition-title,.rst-content .error .wy-alert-title,.rst-content .wy-alert-danger.admonition-todo .admonition-title,.rst-content .wy-alert-danger.admonition-todo .wy-alert-title,.rst-content .wy-alert-danger.admonition .admonition-title,.rst-content .wy-alert-danger.admonition .wy-alert-title,.rst-content .wy-alert-danger.attention .admonition-title,.rst-content .wy-alert-danger.attention .wy-alert-title,.rst-content .wy-alert-danger.caution .admonition-title,.rst-content .wy-alert-danger.caution .wy-alert-title,.rst-content .wy-alert-danger.hint .admonition-title,.rst-content .wy-alert-danger.hint .wy-alert-title,.rst-content .wy-alert-danger.important .admonition-title,.rst-content .wy-alert-danger.important .wy-alert-title,.rst-content .wy-alert-danger.note .admonition-title,.rst-content .wy-alert-danger.note .wy-alert-title,.rst-content .wy-alert-danger.seealso .admonition-title,.rst-content .wy-alert-danger.seealso .wy-alert-title,.rst-content .wy-alert-danger.tip .admonition-title,.rst-content .wy-alert-danger.tip .wy-alert-title,.rst-content .wy-alert-danger.warning .admonition-title,.rst-content .wy-alert-danger.warning .wy-alert-title,.rst-content .wy-alert.wy-alert-danger .admonition-title,.wy-alert.wy-alert-danger .rst-content .admonition-title,.wy-alert.wy-alert-danger .wy-alert-title{background:#f29f97}.rst-content .admonition-todo,.rst-content .attention,.rst-content .caution,.rst-content .warning,.rst-content .wy-alert-warning.admonition,.rst-content .wy-alert-warning.danger,.rst-content .wy-alert-warning.error,.rst-content .wy-alert-warning.hint,.rst-content .wy-alert-warning.important,.rst-content .wy-alert-warning.note,.rst-content .wy-alert-warning.seealso,.rst-content .wy-alert-warning.tip,.wy-alert.wy-alert-warning{background:#ffedcc}.rst-content .admonition-todo .admonition-title,.rst-content .admonition-todo .wy-alert-title,.rst-content .attention .admonition-title,.rst-content .attention .wy-alert-title,.rst-content .caution .admonition-title,.rst-content .caution .wy-alert-title,.rst-content .warning .admonition-title,.rst-content .warning .wy-alert-title,.rst-content .wy-alert-warning.admonition .admonition-title,.rst-content .wy-alert-warning.admonition .wy-alert-title,.rst-content .wy-alert-warning.danger .admonition-title,.rst-content .wy-alert-warning.danger .wy-alert-title,.rst-content .wy-alert-warning.error .admonition-title,.rst-content .wy-alert-warning.error .wy-alert-title,.rst-content .wy-alert-warning.hint .admonition-title,.rst-content .wy-alert-warning.hint .wy-alert-title,.rst-content .wy-alert-warning.important .admonition-title,.rst-content .wy-alert-warning.important .wy-alert-title,.rst-content .wy-alert-warning.note .admonition-title,.rst-content .wy-alert-warning.note .wy-alert-title,.rst-content .wy-alert-warning.seealso .admonition-title,.rst-content .wy-alert-warning.seealso .wy-alert-title,.rst-content .wy-alert-warning.tip .admonition-title,.rst-content .wy-alert-warning.tip .wy-alert-title,.rst-content .wy-alert.wy-alert-warning .admonition-title,.wy-alert.wy-alert-warning .rst-content .admonition-title,.wy-alert.wy-alert-warning .wy-alert-title{background:#f0b37e}.rst-content .note,.rst-content .seealso,.rst-content .wy-alert-info.admonition,.rst-content .wy-alert-info.admonition-todo,.rst-content .wy-alert-info.attention,.rst-content .wy-alert-info.caution,.rst-content .wy-alert-info.danger,.rst-content .wy-alert-info.error,.rst-content .wy-alert-info.hint,.rst-content .wy-alert-info.important,.rst-content .wy-alert-info.tip,.rst-content .wy-alert-info.warning,.wy-alert.wy-alert-info{background:#e7f2fa}.rst-content .note .admonition-title,.rst-content .note .wy-alert-title,.rst-content .seealso .admonition-title,.rst-content .seealso .wy-alert-title,.rst-content .wy-alert-info.admonition-todo .admonition-title,.rst-content .wy-alert-info.admonition-todo .wy-alert-title,.rst-content .wy-alert-info.admonition .admonition-title,.rst-content .wy-alert-info.admonition .wy-alert-title,.rst-content .wy-alert-info.attention .admonition-title,.rst-content .wy-alert-info.attention .wy-alert-title,.rst-content .wy-alert-info.caution .admonition-title,.rst-content .wy-alert-info.caution .wy-alert-title,.rst-content .wy-alert-info.danger .admonition-title,.rst-content .wy-alert-info.danger .wy-alert-title,.rst-content .wy-alert-info.error .admonition-title,.rst-content .wy-alert-info.error .wy-alert-title,.rst-content .wy-alert-info.hint .admonition-title,.rst-content .wy-alert-info.hint .wy-alert-title,.rst-content .wy-alert-info.important .admonition-title,.rst-content .wy-alert-info.important .wy-alert-title,.rst-content .wy-alert-info.tip .admonition-title,.rst-content .wy-alert-info.tip .wy-alert-title,.rst-content .wy-alert-info.warning .admonition-title,.rst-content .wy-alert-info.warning .wy-alert-title,.rst-content .wy-alert.wy-alert-info .admonition-title,.wy-alert.wy-alert-info .rst-content .admonition-title,.wy-alert.wy-alert-info .wy-alert-title{background:#6ab0de}.rst-content .hint,.rst-content .important,.rst-content .tip,.rst-content .wy-alert-success.admonition,.rst-content .wy-alert-success.admonition-todo,.rst-content .wy-alert-success.attention,.rst-content .wy-alert-success.caution,.rst-content .wy-alert-success.danger,.rst-content .wy-alert-success.error,.rst-content .wy-alert-success.note,.rst-content .wy-alert-success.seealso,.rst-content .wy-alert-success.warning,.wy-alert.wy-alert-success{background:#dbfaf4}.rst-content .hint .admonition-title,.rst-content .hint .wy-alert-title,.rst-content .important .admonition-title,.rst-content .important .wy-alert-title,.rst-content .tip .admonition-title,.rst-content .tip .wy-alert-title,.rst-content .wy-alert-success.admonition-todo .admonition-title,.rst-content .wy-alert-success.admonition-todo .wy-alert-title,.rst-content .wy-alert-success.admonition .admonition-title,.rst-content .wy-alert-success.admonition .wy-alert-title,.rst-content .wy-alert-success.attention .admonition-title,.rst-content .wy-alert-success.attention .wy-alert-title,.rst-content .wy-alert-success.caution .admonition-title,.rst-content .wy-alert-success.caution .wy-alert-title,.rst-content .wy-alert-success.danger .admonition-title,.rst-content .wy-alert-success.danger .wy-alert-title,.rst-content .wy-alert-success.error .admonition-title,.rst-content .wy-alert-success.error .wy-alert-title,.rst-content .wy-alert-success.note .admonition-title,.rst-content .wy-alert-success.note .wy-alert-title,.rst-content .wy-alert-success.seealso .admonition-title,.rst-content .wy-alert-success.seealso .wy-alert-title,.rst-content .wy-alert-success.warning .admonition-title,.rst-content .wy-alert-success.warning .wy-alert-title,.rst-content .wy-alert.wy-alert-success .admonition-title,.wy-alert.wy-alert-success .rst-content .admonition-title,.wy-alert.wy-alert-success .wy-alert-title{background:#1abc9c}.rst-content .wy-alert-neutral.admonition,.rst-content .wy-alert-neutral.admonition-todo,.rst-content .wy-alert-neutral.attention,.rst-content .wy-alert-neutral.caution,.rst-content .wy-alert-neutral.danger,.rst-content .wy-alert-neutral.error,.rst-content .wy-alert-neutral.hint,.rst-content .wy-alert-neutral.important,.rst-content .wy-alert-neutral.note,.rst-content .wy-alert-neutral.seealso,.rst-content .wy-alert-neutral.tip,.rst-content .wy-alert-neutral.warning,.wy-alert.wy-alert-neutral{background:#f3f6f6}.rst-content .wy-alert-neutral.admonition-todo .admonition-title,.rst-content .wy-alert-neutral.admonition-todo .wy-alert-title,.rst-content .wy-alert-neutral.admonition .admonition-title,.rst-content .wy-alert-neutral.admonition .wy-alert-title,.rst-content .wy-alert-neutral.attention .admonition-title,.rst-content .wy-alert-neutral.attention .wy-alert-title,.rst-content .wy-alert-neutral.caution .admonition-title,.rst-content .wy-alert-neutral.caution .wy-alert-title,.rst-content .wy-alert-neutral.danger .admonition-title,.rst-content .wy-alert-neutral.danger .wy-alert-title,.rst-content .wy-alert-neutral.error .admonition-title,.rst-content .wy-alert-neutral.error .wy-alert-title,.rst-content .wy-alert-neutral.hint .admonition-title,.rst-content .wy-alert-neutral.hint .wy-alert-title,.rst-content .wy-alert-neutral.important .admonition-title,.rst-content .wy-alert-neutral.important .wy-alert-title,.rst-content .wy-alert-neutral.note .admonition-title,.rst-content .wy-alert-neutral.note .wy-alert-title,.rst-content .wy-alert-neutral.seealso .admonition-title,.rst-content .wy-alert-neutral.seealso .wy-alert-title,.rst-content .wy-alert-neutral.tip .admonition-title,.rst-content .wy-alert-neutral.tip .wy-alert-title,.rst-content .wy-alert-neutral.warning .admonition-title,.rst-content .wy-alert-neutral.warning .wy-alert-title,.rst-content .wy-alert.wy-alert-neutral .admonition-title,.wy-alert.wy-alert-neutral .rst-content .admonition-title,.wy-alert.wy-alert-neutral .wy-alert-title{color:#404040;background:#e1e4e5}.rst-content .wy-alert-neutral.admonition-todo a,.rst-content .wy-alert-neutral.admonition a,.rst-content .wy-alert-neutral.attention a,.rst-content .wy-alert-neutral.caution a,.rst-content .wy-alert-neutral.danger a,.rst-content .wy-alert-neutral.error a,.rst-content .wy-alert-neutral.hint a,.rst-content .wy-alert-neutral.important a,.rst-content .wy-alert-neutral.note a,.rst-content .wy-alert-neutral.seealso a,.rst-content .wy-alert-neutral.tip a,.rst-content .wy-alert-neutral.warning a,.wy-alert.wy-alert-neutral a{color:#2980b9}.rst-content .admonition-todo p:last-child,.rst-content .admonition p:last-child,.rst-content .attention p:last-child,.rst-content .caution p:last-child,.rst-content .danger p:last-child,.rst-content .error p:last-child,.rst-content .hint p:last-child,.rst-content .important p:last-child,.rst-content .note p:last-child,.rst-content .seealso p:last-child,.rst-content .tip p:last-child,.rst-content .warning p:last-child,.wy-alert p:last-child{margin-bottom:0}.wy-tray-container{position:fixed;bottom:0;left:0;z-index:600}.wy-tray-container li{display:block;width:300px;background:transparent;color:#fff;text-align:center;box-shadow:0 5px 5px 0 rgba(0,0,0,.1);padding:0 24px;min-width:20%;opacity:0;height:0;line-height:56px;overflow:hidden;-webkit-transition:all .3s ease-in;-moz-transition:all .3s ease-in;transition:all .3s ease-in}.wy-tray-container li.wy-tray-item-success{background:#27ae60}.wy-tray-container li.wy-tray-item-info{background:#2980b9}.wy-tray-container li.wy-tray-item-warning{background:#e67e22}.wy-tray-container li.wy-tray-item-danger{background:#e74c3c}.wy-tray-container li.on{opacity:1;height:56px}@media screen and (max-width:768px){.wy-tray-container{bottom:auto;top:0;width:100%}.wy-tray-container li{width:100%}}button{font-size:100%;margin:0;vertical-align:baseline;*vertical-align:middle;cursor:pointer;line-height:normal;-webkit-appearance:button;*overflow:visible}button::-moz-focus-inner,input::-moz-focus-inner{border:0;padding:0}button[disabled]{cursor:default}.btn{display:inline-block;border-radius:2px;line-height:normal;white-space:nowrap;text-align:center;cursor:pointer;font-size:100%;padding:6px 12px 8px;color:#fff;border:1px solid rgba(0,0,0,.1);background-color:#27ae60;text-decoration:none;font-weight:400;font-family:Lato,proxima-nova,Helvetica Neue,Arial,sans-serif;box-shadow:inset 0 1px 2px -1px hsla(0,0%,100%,.5),inset 0 -2px 0 0 rgba(0,0,0,.1);outline-none:false;vertical-align:middle;*display:inline;zoom:1;-webkit-user-drag:none;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;-webkit-transition:all .1s linear;-moz-transition:all .1s linear;transition:all .1s linear}.btn-hover{background:#2e8ece;color:#fff}.btn:hover{background:#2cc36b;color:#fff}.btn:focus{background:#2cc36b;outline:0}.btn:active{box-shadow:inset 0 -1px 0 0 rgba(0,0,0,.05),inset 0 2px 0 0 rgba(0,0,0,.1);padding:8px 12px 6px}.btn:visited{color:#fff}.btn-disabled,.btn-disabled:active,.btn-disabled:focus,.btn-disabled:hover,.btn:disabled{background-image:none;filter:progid:DXImageTransform.Microsoft.gradient(enabled = false);filter:alpha(opacity=40);opacity:.4;cursor:not-allowed;box-shadow:none}.btn::-moz-focus-inner{padding:0;border:0}.btn-small{font-size:80%}.btn-info{background-color:#2980b9!important}.btn-info:hover{background-color:#2e8ece!important}.btn-neutral{background-color:#f3f6f6!important;color:#404040!important}.btn-neutral:hover{background-color:#e5ebeb!important;color:#404040}.btn-neutral:visited{color:#404040!important}.btn-success{background-color:#27ae60!important}.btn-success:hover{background-color:#295!important}.btn-danger{background-color:#e74c3c!important}.btn-danger:hover{background-color:#ea6153!important}.btn-warning{background-color:#e67e22!important}.btn-warning:hover{background-color:#e98b39!important}.btn-invert{background-color:#222}.btn-invert:hover{background-color:#2f2f2f!important}.btn-link{background-color:transparent!important;color:#2980b9;box-shadow:none;border-color:transparent!important}.btn-link:active,.btn-link:hover{background-color:transparent!important;color:#409ad5!important;box-shadow:none}.btn-link:visited{color:#9b59b6}.wy-btn-group .btn,.wy-control .btn{vertical-align:middle}.wy-btn-group{margin-bottom:24px;*zoom:1}.wy-btn-group:after,.wy-btn-group:before{display:table;content:""}.wy-btn-group:after{clear:both}.wy-dropdown{position:relative;display:inline-block}.wy-dropdown-active .wy-dropdown-menu{display:block}.wy-dropdown-menu{position:absolute;left:0;display:none;float:left;top:100%;min-width:100%;background:#fcfcfc;z-index:100;border:1px solid #cfd7dd;box-shadow:0 2px 2px 0 rgba(0,0,0,.1);padding:12px}.wy-dropdown-menu>dd>a{display:block;clear:both;color:#404040;white-space:nowrap;font-size:90%;padding:0 12px;cursor:pointer}.wy-dropdown-menu>dd>a:hover{background:#2980b9;color:#fff}.wy-dropdown-menu>dd.divider{border-top:1px solid #cfd7dd;margin:6px 0}.wy-dropdown-menu>dd.search{padding-bottom:12px}.wy-dropdown-menu>dd.search input[type=search]{width:100%}.wy-dropdown-menu>dd.call-to-action{background:#e3e3e3;text-transform:uppercase;font-weight:500;font-size:80%}.wy-dropdown-menu>dd.call-to-action:hover{background:#e3e3e3}.wy-dropdown-menu>dd.call-to-action .btn{color:#fff}.wy-dropdown.wy-dropdown-up .wy-dropdown-menu{bottom:100%;top:auto;left:auto;right:0}.wy-dropdown.wy-dropdown-bubble .wy-dropdown-menu{background:#fcfcfc;margin-top:2px}.wy-dropdown.wy-dropdown-bubble .wy-dropdown-menu a{padding:6px 12px}.wy-dropdown.wy-dropdown-bubble .wy-dropdown-menu a:hover{background:#2980b9;color:#fff}.wy-dropdown.wy-dropdown-left .wy-dropdown-menu{right:0;left:auto;text-align:right}.wy-dropdown-arrow:before{content:" ";border-bottom:5px solid #f5f5f5;border-left:5px solid transparent;border-right:5px solid transparent;position:absolute;display:block;top:-4px;left:50%;margin-left:-3px}.wy-dropdown-arrow.wy-dropdown-arrow-left:before{left:11px}.wy-form-stacked select{display:block}.wy-form-aligned .wy-help-inline,.wy-form-aligned input,.wy-form-aligned label,.wy-form-aligned select,.wy-form-aligned textarea{display:inline-block;*display:inline;*zoom:1;vertical-align:middle}.wy-form-aligned .wy-control-group>label{display:inline-block;vertical-align:middle;width:10em;margin:6px 12px 0 0;float:left}.wy-form-aligned .wy-control{float:left}.wy-form-aligned .wy-control label{display:block}.wy-form-aligned .wy-control select{margin-top:6px}fieldset{margin:0}fieldset,legend{border:0;padding:0}legend{width:100%;white-space:normal;margin-bottom:24px;font-size:150%;*margin-left:-7px}label,legend{display:block}label{margin:0 0 .3125em;color:#333;font-size:90%}input,select,textarea{font-size:100%;margin:0;vertical-align:baseline;*vertical-align:middle}.wy-control-group{margin-bottom:24px;max-width:1200px;margin-left:auto;margin-right:auto;*zoom:1}.wy-control-group:after,.wy-control-group:before{display:table;content:""}.wy-control-group:after{clear:both}.wy-control-group.wy-control-group-required>label:after{content:" *";color:#e74c3c}.wy-control-group .wy-form-full,.wy-control-group .wy-form-halves,.wy-control-group .wy-form-thirds{padding-bottom:12px}.wy-control-group .wy-form-full input[type=color],.wy-control-group .wy-form-full input[type=date],.wy-control-group .wy-form-full input[type=datetime-local],.wy-control-group .wy-form-full input[type=datetime],.wy-control-group .wy-form-full input[type=email],.wy-control-group .wy-form-full input[type=month],.wy-control-group .wy-form-full input[type=number],.wy-control-group .wy-form-full input[type=password],.wy-control-group .wy-form-full input[type=search],.wy-control-group .wy-form-full input[type=tel],.wy-control-group .wy-form-full input[type=text],.wy-control-group .wy-form-full input[type=time],.wy-control-group .wy-form-full input[type=url],.wy-control-group .wy-form-full input[type=week],.wy-control-group .wy-form-full select,.wy-control-group .wy-form-halves input[type=color],.wy-control-group .wy-form-halves input[type=date],.wy-control-group .wy-form-halves input[type=datetime-local],.wy-control-group .wy-form-halves input[type=datetime],.wy-control-group .wy-form-halves input[type=email],.wy-control-group .wy-form-halves input[type=month],.wy-control-group .wy-form-halves input[type=number],.wy-control-group .wy-form-halves input[type=password],.wy-control-group .wy-form-halves input[type=search],.wy-control-group .wy-form-halves input[type=tel],.wy-control-group .wy-form-halves input[type=text],.wy-control-group .wy-form-halves input[type=time],.wy-control-group .wy-form-halves input[type=url],.wy-control-group .wy-form-halves input[type=week],.wy-control-group .wy-form-halves select,.wy-control-group .wy-form-thirds input[type=color],.wy-control-group .wy-form-thirds input[type=date],.wy-control-group .wy-form-thirds input[type=datetime-local],.wy-control-group .wy-form-thirds input[type=datetime],.wy-control-group .wy-form-thirds input[type=email],.wy-control-group .wy-form-thirds input[type=month],.wy-control-group .wy-form-thirds input[type=number],.wy-control-group .wy-form-thirds input[type=password],.wy-control-group .wy-form-thirds input[type=search],.wy-control-group .wy-form-thirds input[type=tel],.wy-control-group .wy-form-thirds input[type=text],.wy-control-group .wy-form-thirds input[type=time],.wy-control-group .wy-form-thirds input[type=url],.wy-control-group .wy-form-thirds input[type=week],.wy-control-group .wy-form-thirds select{width:100%}.wy-control-group .wy-form-full{float:left;display:block;width:100%;margin-right:0}.wy-control-group .wy-form-full:last-child{margin-right:0}.wy-control-group .wy-form-halves{float:left;display:block;margin-right:2.35765%;width:48.82117%}.wy-control-group .wy-form-halves:last-child,.wy-control-group .wy-form-halves:nth-of-type(2n){margin-right:0}.wy-control-group .wy-form-halves:nth-of-type(odd){clear:left}.wy-control-group .wy-form-thirds{float:left;display:block;margin-right:2.35765%;width:31.76157%}.wy-control-group .wy-form-thirds:last-child,.wy-control-group .wy-form-thirds:nth-of-type(3n){margin-right:0}.wy-control-group .wy-form-thirds:nth-of-type(3n+1){clear:left}.wy-control-group.wy-control-group-no-input .wy-control,.wy-control-no-input{margin:6px 0 0;font-size:90%}.wy-control-no-input{display:inline-block}.wy-control-group.fluid-input input[type=color],.wy-control-group.fluid-input input[type=date],.wy-control-group.fluid-input input[type=datetime-local],.wy-control-group.fluid-input input[type=datetime],.wy-control-group.fluid-input input[type=email],.wy-control-group.fluid-input input[type=month],.wy-control-group.fluid-input input[type=number],.wy-control-group.fluid-input input[type=password],.wy-control-group.fluid-input input[type=search],.wy-control-group.fluid-input input[type=tel],.wy-control-group.fluid-input input[type=text],.wy-control-group.fluid-input input[type=time],.wy-control-group.fluid-input input[type=url],.wy-control-group.fluid-input input[type=week]{width:100%}.wy-form-message-inline{padding-left:.3em;color:#666;font-size:90%}.wy-form-message{display:block;color:#999;font-size:70%;margin-top:.3125em;font-style:italic}.wy-form-message p{font-size:inherit;font-style:italic;margin-bottom:6px}.wy-form-message p:last-child{margin-bottom:0}input{line-height:normal}input[type=button],input[type=reset],input[type=submit]{-webkit-appearance:button;cursor:pointer;font-family:Lato,proxima-nova,Helvetica Neue,Arial,sans-serif;*overflow:visible}input[type=color],input[type=date],input[type=datetime-local],input[type=datetime],input[type=email],input[type=month],input[type=number],input[type=password],input[type=search],input[type=tel],input[type=text],input[type=time],input[type=url],input[type=week]{-webkit-appearance:none;padding:6px;display:inline-block;border:1px solid #ccc;font-size:80%;font-family:Lato,proxima-nova,Helvetica Neue,Arial,sans-serif;box-shadow:inset 0 1px 3px #ddd;border-radius:0;-webkit-transition:border .3s linear;-moz-transition:border .3s linear;transition:border .3s linear}input[type=datetime-local]{padding:.34375em .625em}input[disabled]{cursor:default}input[type=checkbox],input[type=radio]{padding:0;margin-right:.3125em;*height:13px;*width:13px}input[type=checkbox],input[type=radio],input[type=search]{-webkit-box-sizing:border-box;-moz-box-sizing:border-box;box-sizing:border-box}input[type=search]::-webkit-search-cancel-button,input[type=search]::-webkit-search-decoration{-webkit-appearance:none}input[type=color]:focus,input[type=date]:focus,input[type=datetime-local]:focus,input[type=datetime]:focus,input[type=email]:focus,input[type=month]:focus,input[type=number]:focus,input[type=password]:focus,input[type=search]:focus,input[type=tel]:focus,input[type=text]:focus,input[type=time]:focus,input[type=url]:focus,input[type=week]:focus{outline:0;outline:thin dotted\9;border-color:#333}input.no-focus:focus{border-color:#ccc!important}input[type=checkbox]:focus,input[type=file]:focus,input[type=radio]:focus{outline:thin dotted #333;outline:1px auto #129fea}input[type=color][disabled],input[type=date][disabled],input[type=datetime-local][disabled],input[type=datetime][disabled],input[type=email][disabled],input[type=month][disabled],input[type=number][disabled],input[type=password][disabled],input[type=search][disabled],input[type=tel][disabled],input[type=text][disabled],input[type=time][disabled],input[type=url][disabled],input[type=week][disabled]{cursor:not-allowed;background-color:#fafafa}input:focus:invalid,select:focus:invalid,textarea:focus:invalid{color:#e74c3c;border:1px solid #e74c3c}input:focus:invalid:focus,select:focus:invalid:focus,textarea:focus:invalid:focus{border-color:#e74c3c}input[type=checkbox]:focus:invalid:focus,input[type=file]:focus:invalid:focus,input[type=radio]:focus:invalid:focus{outline-color:#e74c3c}input.wy-input-large{padding:12px;font-size:100%}textarea{overflow:auto;vertical-align:top;width:100%;font-family:Lato,proxima-nova,Helvetica Neue,Arial,sans-serif}select,textarea{padding:.5em .625em;display:inline-block;border:1px solid #ccc;font-size:80%;box-shadow:inset 0 1px 3px #ddd;-webkit-transition:border .3s linear;-moz-transition:border .3s linear;transition:border .3s linear}select{border:1px solid #ccc;background-color:#fff}select[multiple]{height:auto}select:focus,textarea:focus{outline:0}input[readonly],select[disabled],select[readonly],textarea[disabled],textarea[readonly]{cursor:not-allowed;background-color:#fafafa}input[type=checkbox][disabled],input[type=radio][disabled]{cursor:not-allowed}.wy-checkbox,.wy-radio{margin:6px 0;color:#404040;display:block}.wy-checkbox input,.wy-radio input{vertical-align:baseline}.wy-form-message-inline{display:inline-block;*display:inline;*zoom:1;vertical-align:middle}.wy-input-prefix,.wy-input-suffix{white-space:nowrap;padding:6px}.wy-input-prefix .wy-input-context,.wy-input-suffix .wy-input-context{line-height:27px;padding:0 8px;display:inline-block;font-size:80%;background-color:#f3f6f6;border:1px solid #ccc;color:#999}.wy-input-suffix .wy-input-context{border-left:0}.wy-input-prefix .wy-input-context{border-right:0}.wy-switch{position:relative;display:block;height:24px;margin-top:12px;cursor:pointer}.wy-switch:before{left:0;top:0;width:36px;height:12px;background:#ccc}.wy-switch:after,.wy-switch:before{position:absolute;content:"";display:block;border-radius:4px;-webkit-transition:all .2s ease-in-out;-moz-transition:all .2s ease-in-out;transition:all .2s ease-in-out}.wy-switch:after{width:18px;height:18px;background:#999;left:-3px;top:-3px}.wy-switch span{position:absolute;left:48px;display:block;font-size:12px;color:#ccc;line-height:1}.wy-switch.active:before{background:#1e8449}.wy-switch.active:after{left:24px;background:#27ae60}.wy-switch.disabled{cursor:not-allowed;opacity:.8}.wy-control-group.wy-control-group-error .wy-form-message,.wy-control-group.wy-control-group-error>label{color:#e74c3c}.wy-control-group.wy-control-group-error input[type=color],.wy-control-group.wy-control-group-error input[type=date],.wy-control-group.wy-control-group-error input[type=datetime-local],.wy-control-group.wy-control-group-error input[type=datetime],.wy-control-group.wy-control-group-error input[type=email],.wy-control-group.wy-control-group-error input[type=month],.wy-control-group.wy-control-group-error input[type=number],.wy-control-group.wy-control-group-error input[type=password],.wy-control-group.wy-control-group-error input[type=search],.wy-control-group.wy-control-group-error input[type=tel],.wy-control-group.wy-control-group-error input[type=text],.wy-control-group.wy-control-group-error input[type=time],.wy-control-group.wy-control-group-error input[type=url],.wy-control-group.wy-control-group-error input[type=week],.wy-control-group.wy-control-group-error textarea{border:1px solid #e74c3c}.wy-inline-validate{white-space:nowrap}.wy-inline-validate .wy-input-context{padding:.5em .625em;display:inline-block;font-size:80%}.wy-inline-validate.wy-inline-validate-success .wy-input-context{color:#27ae60}.wy-inline-validate.wy-inline-validate-danger .wy-input-context{color:#e74c3c}.wy-inline-validate.wy-inline-validate-warning .wy-input-context{color:#e67e22}.wy-inline-validate.wy-inline-validate-info .wy-input-context{color:#2980b9}.rotate-90{-webkit-transform:rotate(90deg);-moz-transform:rotate(90deg);-ms-transform:rotate(90deg);-o-transform:rotate(90deg);transform:rotate(90deg)}.rotate-180{-webkit-transform:rotate(180deg);-moz-transform:rotate(180deg);-ms-transform:rotate(180deg);-o-transform:rotate(180deg);transform:rotate(180deg)}.rotate-270{-webkit-transform:rotate(270deg);-moz-transform:rotate(270deg);-ms-transform:rotate(270deg);-o-transform:rotate(270deg);transform:rotate(270deg)}.mirror{-webkit-transform:scaleX(-1);-moz-transform:scaleX(-1);-ms-transform:scaleX(-1);-o-transform:scaleX(-1);transform:scaleX(-1)}.mirror.rotate-90{-webkit-transform:scaleX(-1) rotate(90deg);-moz-transform:scaleX(-1) rotate(90deg);-ms-transform:scaleX(-1) rotate(90deg);-o-transform:scaleX(-1) rotate(90deg);transform:scaleX(-1) rotate(90deg)}.mirror.rotate-180{-webkit-transform:scaleX(-1) rotate(180deg);-moz-transform:scaleX(-1) rotate(180deg);-ms-transform:scaleX(-1) rotate(180deg);-o-transform:scaleX(-1) rotate(180deg);transform:scaleX(-1) rotate(180deg)}.mirror.rotate-270{-webkit-transform:scaleX(-1) rotate(270deg);-moz-transform:scaleX(-1) rotate(270deg);-ms-transform:scaleX(-1) rotate(270deg);-o-transform:scaleX(-1) rotate(270deg);transform:scaleX(-1) rotate(270deg)}@media only screen and (max-width:480px){.wy-form button[type=submit]{margin:.7em 0 0}.wy-form input[type=color],.wy-form input[type=date],.wy-form input[type=datetime-local],.wy-form input[type=datetime],.wy-form input[type=email],.wy-form input[type=month],.wy-form input[type=number],.wy-form input[type=password],.wy-form input[type=search],.wy-form input[type=tel],.wy-form input[type=text],.wy-form input[type=time],.wy-form input[type=url],.wy-form input[type=week],.wy-form label{margin-bottom:.3em;display:block}.wy-form input[type=color],.wy-form input[type=date],.wy-form input[type=datetime-local],.wy-form input[type=datetime],.wy-form input[type=email],.wy-form input[type=month],.wy-form input[type=number],.wy-form input[type=password],.wy-form input[type=search],.wy-form input[type=tel],.wy-form input[type=time],.wy-form input[type=url],.wy-form input[type=week]{margin-bottom:0}.wy-form-aligned .wy-control-group label{margin-bottom:.3em;text-align:left;display:block;width:100%}.wy-form-aligned .wy-control{margin:1.5em 0 0}.wy-form-message,.wy-form-message-inline,.wy-form .wy-help-inline{display:block;font-size:80%;padding:6px 0}}@media screen and (max-width:768px){.tablet-hide{display:none}}@media screen and (max-width:480px){.mobile-hide{display:none}}.float-left{float:left}.float-right{float:right}.full-width{width:100%}.rst-content table.docutils,.rst-content table.field-list,.wy-table{border-collapse:collapse;border-spacing:0;empty-cells:show;margin-bottom:24px}.rst-content table.docutils caption,.rst-content table.field-list caption,.wy-table caption{color:#000;font:italic 85%/1 arial,sans-serif;padding:1em 0;text-align:center}.rst-content table.docutils td,.rst-content table.docutils th,.rst-content table.field-list td,.rst-content table.field-list th,.wy-table td,.wy-table th{font-size:90%;margin:0;overflow:visible;padding:8px 16px}.rst-content table.docutils td:first-child,.rst-content table.docutils th:first-child,.rst-content table.field-list td:first-child,.rst-content table.field-list th:first-child,.wy-table td:first-child,.wy-table th:first-child{border-left-width:0}.rst-content table.docutils thead,.rst-content table.field-list thead,.wy-table thead{color:#000;text-align:left;vertical-align:bottom;white-space:nowrap}.rst-content table.docutils thead th,.rst-content table.field-list thead th,.wy-table thead th{font-weight:700;border-bottom:2px solid #e1e4e5}.rst-content table.docutils td,.rst-content table.field-list td,.wy-table td{background-color:transparent;vertical-align:middle}.rst-content table.docutils td p,.rst-content table.field-list td p,.wy-table td p{line-height:18px}.rst-content table.docutils td p:last-child,.rst-content table.field-list td p:last-child,.wy-table td p:last-child{margin-bottom:0}.rst-content table.docutils .wy-table-cell-min,.rst-content table.field-list .wy-table-cell-min,.wy-table .wy-table-cell-min{width:1%;padding-right:0}.rst-content table.docutils .wy-table-cell-min input[type=checkbox],.rst-content table.field-list .wy-table-cell-min input[type=checkbox],.wy-table .wy-table-cell-min input[type=checkbox]{margin:0}.wy-table-secondary{color:grey;font-size:90%}.wy-table-tertiary{color:grey;font-size:80%}.rst-content table.docutils:not(.field-list) tr:nth-child(2n-1) td,.wy-table-backed,.wy-table-odd td,.wy-table-striped tr:nth-child(2n-1) td{background-color:#f3f6f6}.rst-content table.docutils,.wy-table-bordered-all{border:1px solid #e1e4e5}.rst-content table.docutils td,.wy-table-bordered-all td{border-bottom:1px solid #e1e4e5;border-left:1px solid #e1e4e5}.rst-content table.docutils tbody>tr:last-child td,.wy-table-bordered-all tbody>tr:last-child td{border-bottom-width:0}.wy-table-bordered{border:1px solid #e1e4e5}.wy-table-bordered-rows td{border-bottom:1px solid #e1e4e5}.wy-table-bordered-rows tbody>tr:last-child td{border-bottom-width:0}.wy-table-horizontal td,.wy-table-horizontal th{border-width:0 0 1px;border-bottom:1px solid #e1e4e5}.wy-table-horizontal tbody>tr:last-child td{border-bottom-width:0}.wy-table-responsive{margin-bottom:24px;max-width:100%;overflow:auto}.wy-table-responsive table{margin-bottom:0!important}.wy-table-responsive table td,.wy-table-responsive table th{white-space:nowrap}a{color:#2980b9;text-decoration:none;cursor:pointer}a:hover{color:#3091d1}a:visited{color:#9b59b6}html{height:100%}body,html{overflow-x:hidden}body{font-family:Lato,proxima-nova,Helvetica Neue,Arial,sans-serif;font-weight:400;color:#404040;min-height:100%;background:#edf0f2}.wy-text-left{text-align:left}.wy-text-center{text-align:center}.wy-text-right{text-align:right}.wy-text-large{font-size:120%}.wy-text-normal{font-size:100%}.wy-text-small,small{font-size:80%}.wy-text-strike{text-decoration:line-through}.wy-text-warning{color:#e67e22!important}a.wy-text-warning:hover{color:#eb9950!important}.wy-text-info{color:#2980b9!important}a.wy-text-info:hover{color:#409ad5!important}.wy-text-success{color:#27ae60!important}a.wy-text-success:hover{color:#36d278!important}.wy-text-danger{color:#e74c3c!important}a.wy-text-danger:hover{color:#ed7669!important}.wy-text-neutral{color:#404040!important}a.wy-text-neutral:hover{color:#595959!important}.rst-content .toctree-wrapper>p.caption,h1,h2,h3,h4,h5,h6,legend{margin-top:0;font-weight:700;font-family:Roboto Slab,ff-tisa-web-pro,Georgia,Arial,sans-serif}p{line-height:24px;font-size:16px;margin:0 0 24px}h1{font-size:175%}.rst-content .toctree-wrapper>p.caption,h2{font-size:150%}h3{font-size:125%}h4{font-size:115%}h5{font-size:110%}h6{font-size:100%}hr{display:block;height:1px;border:0;border-top:1px solid #e1e4e5;margin:24px 0;padding:0}.rst-content code,.rst-content tt,code{white-space:nowrap;max-width:100%;background:#fff;border:1px solid #e1e4e5;font-size:75%;padding:0 5px;font-family:SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,Courier,monospace;color:#e74c3c;overflow-x:auto}.rst-content tt.code-large,code.code-large{font-size:90%}.rst-content .section ul,.rst-content .toctree-wrapper ul,.rst-content section ul,.wy-plain-list-disc,article ul{list-style:disc;line-height:24px;margin-bottom:24px}.rst-content .section ul li,.rst-content .toctree-wrapper ul li,.rst-content section ul li,.wy-plain-list-disc li,article ul li{list-style:disc;margin-left:24px}.rst-content .section ul li p:last-child,.rst-content .section ul li ul,.rst-content .toctree-wrapper ul li p:last-child,.rst-content .toctree-wrapper ul li ul,.rst-content section ul li p:last-child,.rst-content section ul li ul,.wy-plain-list-disc li p:last-child,.wy-plain-list-disc li ul,article ul li p:last-child,article ul li ul{margin-bottom:0}.rst-content .section ul li li,.rst-content .toctree-wrapper ul li li,.rst-content section ul li li,.wy-plain-list-disc li li,article ul li li{list-style:circle}.rst-content .section ul li li li,.rst-content .toctree-wrapper ul li li li,.rst-content section ul li li li,.wy-plain-list-disc li li li,article ul li li li{list-style:square}.rst-content .section ul li ol li,.rst-content .toctree-wrapper ul li ol li,.rst-content section ul li ol li,.wy-plain-list-disc li ol li,article ul li ol li{list-style:decimal}.rst-content .section ol,.rst-content .section ol.arabic,.rst-content .toctree-wrapper ol,.rst-content .toctree-wrapper ol.arabic,.rst-content section ol,.rst-content section ol.arabic,.wy-plain-list-decimal,article ol{list-style:decimal;line-height:24px;margin-bottom:24px}.rst-content .section ol.arabic li,.rst-content .section ol li,.rst-content .toctree-wrapper ol.arabic li,.rst-content .toctree-wrapper ol li,.rst-content section ol.arabic li,.rst-content section ol li,.wy-plain-list-decimal li,article ol li{list-style:decimal;margin-left:24px}.rst-content .section ol.arabic li ul,.rst-content .section ol li p:last-child,.rst-content .section ol li ul,.rst-content .toctree-wrapper ol.arabic li ul,.rst-content .toctree-wrapper ol li p:last-child,.rst-content .toctree-wrapper ol li ul,.rst-content section ol.arabic li ul,.rst-content section ol li p:last-child,.rst-content section ol li ul,.wy-plain-list-decimal li p:last-child,.wy-plain-list-decimal li ul,article ol li p:last-child,article ol li ul{margin-bottom:0}.rst-content .section ol.arabic li ul li,.rst-content .section ol li ul li,.rst-content .toctree-wrapper ol.arabic li ul li,.rst-content .toctree-wrapper ol li ul li,.rst-content section ol.arabic li ul li,.rst-content section ol li ul li,.wy-plain-list-decimal li ul li,article ol li ul li{list-style:disc}.wy-breadcrumbs{*zoom:1}.wy-breadcrumbs:after,.wy-breadcrumbs:before{display:table;content:""}.wy-breadcrumbs:after{clear:both}.wy-breadcrumbs>li{display:inline-block;padding-top:5px}.wy-breadcrumbs>li.wy-breadcrumbs-aside{float:right}.rst-content .wy-breadcrumbs>li code,.rst-content .wy-breadcrumbs>li tt,.wy-breadcrumbs>li .rst-content tt,.wy-breadcrumbs>li code{all:inherit;color:inherit}.breadcrumb-item:before{content:"/";color:#bbb;font-size:13px;padding:0 6px 0 3px}.wy-breadcrumbs-extra{margin-bottom:0;color:#b3b3b3;font-size:80%;display:inline-block}@media screen and (max-width:480px){.wy-breadcrumbs-extra,.wy-breadcrumbs li.wy-breadcrumbs-aside{display:none}}@media print{.wy-breadcrumbs li.wy-breadcrumbs-aside{display:none}}html{font-size:16px}.wy-affix{position:fixed;top:1.618em}.wy-menu a:hover{text-decoration:none}.wy-menu-horiz{*zoom:1}.wy-menu-horiz:after,.wy-menu-horiz:before{display:table;content:""}.wy-menu-horiz:after{clear:both}.wy-menu-horiz li,.wy-menu-horiz ul{display:inline-block}.wy-menu-horiz li:hover{background:hsla(0,0%,100%,.1)}.wy-menu-horiz li.divide-left{border-left:1px solid #404040}.wy-menu-horiz li.divide-right{border-right:1px solid #404040}.wy-menu-horiz a{height:32px;display:inline-block;line-height:32px;padding:0 16px}.wy-menu-vertical{width:300px}.wy-menu-vertical header,.wy-menu-vertical p.caption{color:#55a5d9;height:32px;line-height:32px;padding:0 1.618em;margin:12px 0 0;display:block;font-weight:700;text-transform:uppercase;font-size:85%;white-space:nowrap}.wy-menu-vertical ul{margin-bottom:0}.wy-menu-vertical li.divide-top{border-top:1px solid #404040}.wy-menu-vertical li.divide-bottom{border-bottom:1px solid #404040}.wy-menu-vertical li.current{background:#e3e3e3}.wy-menu-vertical li.current a{color:grey;border-right:1px solid #c9c9c9;padding:.4045em 2.427em}.wy-menu-vertical li.current a:hover{background:#d6d6d6}.rst-content .wy-menu-vertical li tt,.wy-menu-vertical li .rst-content tt,.wy-menu-vertical li code{border:none;background:inherit;color:inherit;padding-left:0;padding-right:0}.wy-menu-vertical li button.toctree-expand{display:block;float:left;margin-left:-1.2em;line-height:18px;color:#4d4d4d;border:none;background:none;padding:0}.wy-menu-vertical li.current>a,.wy-menu-vertical li.on a{color:#404040;font-weight:700;position:relative;background:#fcfcfc;border:none;padding:.4045em 1.618em}.wy-menu-vertical li.current>a:hover,.wy-menu-vertical li.on a:hover{background:#fcfcfc}.wy-menu-vertical li.current>a:hover button.toctree-expand,.wy-menu-vertical li.on a:hover button.toctree-expand{color:grey}.wy-menu-vertical li.current>a button.toctree-expand,.wy-menu-vertical li.on a button.toctree-expand{display:block;line-height:18px;color:#333}.wy-menu-vertical li.toctree-l1.current>a{border-bottom:1px solid #c9c9c9;border-top:1px solid #c9c9c9}.wy-menu-vertical .toctree-l1.current .toctree-l2>ul,.wy-menu-vertical .toctree-l2.current .toctree-l3>ul,.wy-menu-vertical .toctree-l3.current .toctree-l4>ul,.wy-menu-vertical .toctree-l4.current .toctree-l5>ul,.wy-menu-vertical .toctree-l5.current .toctree-l6>ul,.wy-menu-vertical .toctree-l6.current .toctree-l7>ul,.wy-menu-vertical .toctree-l7.current .toctree-l8>ul,.wy-menu-vertical .toctree-l8.current .toctree-l9>ul,.wy-menu-vertical .toctree-l9.current .toctree-l10>ul,.wy-menu-vertical .toctree-l10.current .toctree-l11>ul{display:none}.wy-menu-vertical .toctree-l1.current .current.toctree-l2>ul,.wy-menu-vertical .toctree-l2.current .current.toctree-l3>ul,.wy-menu-vertical .toctree-l3.current .current.toctree-l4>ul,.wy-menu-vertical .toctree-l4.current .current.toctree-l5>ul,.wy-menu-vertical .toctree-l5.current .current.toctree-l6>ul,.wy-menu-vertical .toctree-l6.current .current.toctree-l7>ul,.wy-menu-vertical .toctree-l7.current .current.toctree-l8>ul,.wy-menu-vertical .toctree-l8.current .current.toctree-l9>ul,.wy-menu-vertical .toctree-l9.current .current.toctree-l10>ul,.wy-menu-vertical .toctree-l10.current .current.toctree-l11>ul{display:block}.wy-menu-vertical li.toctree-l3,.wy-menu-vertical li.toctree-l4{font-size:.9em}.wy-menu-vertical li.toctree-l2 a,.wy-menu-vertical li.toctree-l3 a,.wy-menu-vertical li.toctree-l4 a,.wy-menu-vertical li.toctree-l5 a,.wy-menu-vertical li.toctree-l6 a,.wy-menu-vertical li.toctree-l7 a,.wy-menu-vertical li.toctree-l8 a,.wy-menu-vertical li.toctree-l9 a,.wy-menu-vertical li.toctree-l10 a{color:#404040}.wy-menu-vertical li.toctree-l2 a:hover button.toctree-expand,.wy-menu-vertical li.toctree-l3 a:hover button.toctree-expand,.wy-menu-vertical li.toctree-l4 a:hover button.toctree-expand,.wy-menu-vertical li.toctree-l5 a:hover button.toctree-expand,.wy-menu-vertical li.toctree-l6 a:hover button.toctree-expand,.wy-menu-vertical li.toctree-l7 a:hover button.toctree-expand,.wy-menu-vertical li.toctree-l8 a:hover button.toctree-expand,.wy-menu-vertical li.toctree-l9 a:hover button.toctree-expand,.wy-menu-vertical li.toctree-l10 a:hover button.toctree-expand{color:grey}.wy-menu-vertical li.toctree-l2.current li.toctree-l3>a,.wy-menu-vertical li.toctree-l3.current li.toctree-l4>a,.wy-menu-vertical li.toctree-l4.current li.toctree-l5>a,.wy-menu-vertical li.toctree-l5.current li.toctree-l6>a,.wy-menu-vertical li.toctree-l6.current li.toctree-l7>a,.wy-menu-vertical li.toctree-l7.current li.toctree-l8>a,.wy-menu-vertical li.toctree-l8.current li.toctree-l9>a,.wy-menu-vertical li.toctree-l9.current li.toctree-l10>a,.wy-menu-vertical li.toctree-l10.current li.toctree-l11>a{display:block}.wy-menu-vertical li.toctree-l2.current>a{padding:.4045em 2.427em}.wy-menu-vertical li.toctree-l2.current li.toctree-l3>a{padding:.4045em 1.618em .4045em 4.045em}.wy-menu-vertical li.toctree-l3.current>a{padding:.4045em 4.045em}.wy-menu-vertical li.toctree-l3.current li.toctree-l4>a{padding:.4045em 1.618em .4045em 5.663em}.wy-menu-vertical li.toctree-l4.current>a{padding:.4045em 5.663em}.wy-menu-vertical li.toctree-l4.current li.toctree-l5>a{padding:.4045em 1.618em .4045em 7.281em}.wy-menu-vertical li.toctree-l5.current>a{padding:.4045em 7.281em}.wy-menu-vertical li.toctree-l5.current li.toctree-l6>a{padding:.4045em 1.618em .4045em 8.899em}.wy-menu-vertical li.toctree-l6.current>a{padding:.4045em 8.899em}.wy-menu-vertical li.toctree-l6.current li.toctree-l7>a{padding:.4045em 1.618em .4045em 10.517em}.wy-menu-vertical li.toctree-l7.current>a{padding:.4045em 10.517em}.wy-menu-vertical li.toctree-l7.current li.toctree-l8>a{padding:.4045em 1.618em .4045em 12.135em}.wy-menu-vertical li.toctree-l8.current>a{padding:.4045em 12.135em}.wy-menu-vertical li.toctree-l8.current li.toctree-l9>a{padding:.4045em 1.618em .4045em 13.753em}.wy-menu-vertical li.toctree-l9.current>a{padding:.4045em 13.753em}.wy-menu-vertical li.toctree-l9.current li.toctree-l10>a{padding:.4045em 1.618em .4045em 15.371em}.wy-menu-vertical li.toctree-l10.current>a{padding:.4045em 15.371em}.wy-menu-vertical li.toctree-l10.current li.toctree-l11>a{padding:.4045em 1.618em .4045em 16.989em}.wy-menu-vertical li.toctree-l2.current>a,.wy-menu-vertical li.toctree-l2.current li.toctree-l3>a{background:#c9c9c9}.wy-menu-vertical li.toctree-l2 button.toctree-expand{color:#a3a3a3}.wy-menu-vertical li.toctree-l3.current>a,.wy-menu-vertical li.toctree-l3.current li.toctree-l4>a{background:#bdbdbd}.wy-menu-vertical li.toctree-l3 button.toctree-expand{color:#969696}.wy-menu-vertical li.current ul{display:block}.wy-menu-vertical li ul{margin-bottom:0;display:none}.wy-menu-vertical li ul li a{margin-bottom:0;color:#d9d9d9;font-weight:400}.wy-menu-vertical a{line-height:18px;padding:.4045em 1.618em;display:block;position:relative;font-size:90%;color:#d9d9d9}.wy-menu-vertical a:hover{background-color:#4e4a4a;cursor:pointer}.wy-menu-vertical a:hover button.toctree-expand{color:#d9d9d9}.wy-menu-vertical a:active{background-color:#2980b9;cursor:pointer;color:#fff}.wy-menu-vertical a:active button.toctree-expand{color:#fff}.wy-side-nav-search{display:block;width:300px;padding:.809em;margin-bottom:.809em;z-index:200;background-color:#2980b9;text-align:center;color:#fcfcfc}.wy-side-nav-search input[type=text]{width:100%;border-radius:50px;padding:6px 12px;border-color:#2472a4}.wy-side-nav-search img{display:block;margin:auto auto .809em;height:45px;width:45px;background-color:#2980b9;padding:5px;border-radius:100%}.wy-side-nav-search .wy-dropdown>a,.wy-side-nav-search>a{color:#fcfcfc;font-size:100%;font-weight:700;display:inline-block;padding:4px 6px;margin-bottom:.809em;max-width:100%}.wy-side-nav-search .wy-dropdown>a:hover,.wy-side-nav-search>a:hover{background:hsla(0,0%,100%,.1)}.wy-side-nav-search .wy-dropdown>a img.logo,.wy-side-nav-search>a img.logo{display:block;margin:0 auto;height:auto;width:auto;border-radius:0;max-width:100%;background:transparent}.wy-side-nav-search .wy-dropdown>a.icon img.logo,.wy-side-nav-search>a.icon img.logo{margin-top:.85em}.wy-side-nav-search>div.version{margin-top:-.4045em;margin-bottom:.809em;font-weight:400;color:hsla(0,0%,100%,.3)}.wy-nav .wy-menu-vertical header{color:#2980b9}.wy-nav .wy-menu-vertical a{color:#b3b3b3}.wy-nav .wy-menu-vertical a:hover{background-color:#2980b9;color:#fff}[data-menu-wrap]{-webkit-transition:all .2s ease-in;-moz-transition:all .2s ease-in;transition:all .2s ease-in;position:absolute;opacity:1;width:100%;opacity:0}[data-menu-wrap].move-center{left:0;right:auto;opacity:1}[data-menu-wrap].move-left{right:auto;left:-100%;opacity:0}[data-menu-wrap].move-right{right:-100%;left:auto;opacity:0}.wy-body-for-nav{background:#fcfcfc}.wy-grid-for-nav{position:absolute;width:100%;height:100%}.wy-nav-side{position:fixed;top:0;bottom:0;left:0;padding-bottom:2em;width:300px;overflow-x:hidden;overflow-y:hidden;min-height:100%;color:#9b9b9b;background:#343131;z-index:200}.wy-side-scroll{width:320px;position:relative;overflow-x:hidden;overflow-y:scroll;height:100%}.wy-nav-top{display:none;background:#2980b9;color:#fff;padding:.4045em .809em;position:relative;line-height:50px;text-align:center;font-size:100%;*zoom:1}.wy-nav-top:after,.wy-nav-top:before{display:table;content:""}.wy-nav-top:after{clear:both}.wy-nav-top a{color:#fff;font-weight:700}.wy-nav-top img{margin-right:12px;height:45px;width:45px;background-color:#2980b9;padding:5px;border-radius:100%}.wy-nav-top i{font-size:30px;float:left;cursor:pointer;padding-top:inherit}.wy-nav-content-wrap{margin-left:300px;background:#fcfcfc;min-height:100%}.wy-nav-content{padding:1.618em 3.236em;height:100%;max-width:800px;margin:auto}.wy-body-mask{position:fixed;width:100%;height:100%;background:rgba(0,0,0,.2);display:none;z-index:499}.wy-body-mask.on{display:block}footer{color:grey}footer p{margin-bottom:12px}.rst-content footer span.commit tt,footer span.commit .rst-content tt,footer span.commit code{padding:0;font-family:SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,Courier,monospace;font-size:1em;background:none;border:none;color:grey}.rst-footer-buttons{*zoom:1}.rst-footer-buttons:after,.rst-footer-buttons:before{width:100%;display:table;content:""}.rst-footer-buttons:after{clear:both}.rst-breadcrumbs-buttons{margin-top:12px;*zoom:1}.rst-breadcrumbs-buttons:after,.rst-breadcrumbs-buttons:before{display:table;content:""}.rst-breadcrumbs-buttons:after{clear:both}#search-results .search li{margin-bottom:24px;border-bottom:1px solid #e1e4e5;padding-bottom:24px}#search-results .search li:first-child{border-top:1px solid #e1e4e5;padding-top:24px}#search-results .search li a{font-size:120%;margin-bottom:12px;display:inline-block}#search-results .context{color:grey;font-size:90%}.genindextable li>ul{margin-left:24px}@media screen and (max-width:768px){.wy-body-for-nav{background:#fcfcfc}.wy-nav-top{display:block}.wy-nav-side{left:-300px}.wy-nav-side.shift{width:85%;left:0}.wy-menu.wy-menu-vertical,.wy-side-nav-search,.wy-side-scroll{width:auto}.wy-nav-content-wrap{margin-left:0}.wy-nav-content-wrap .wy-nav-content{padding:1.618em}.wy-nav-content-wrap.shift{position:fixed;min-width:100%;left:85%;top:0;height:100%;overflow:hidden}}@media screen and (min-width:1100px){.wy-nav-content-wrap{background:rgba(0,0,0,.05)}.wy-nav-content{margin:0;background:#fcfcfc}}@media print{.rst-versions,.wy-nav-side,footer{display:none}.wy-nav-content-wrap{margin-left:0}}.rst-versions{position:fixed;bottom:0;left:0;width:300px;color:#fcfcfc;background:#1f1d1d;font-family:Lato,proxima-nova,Helvetica Neue,Arial,sans-serif;z-index:400}.rst-versions a{color:#2980b9;text-decoration:none}.rst-versions .rst-badge-small{display:none}.rst-versions .rst-current-version{padding:12px;background-color:#272525;display:block;text-align:right;font-size:90%;cursor:pointer;color:#27ae60;*zoom:1}.rst-versions .rst-current-version:after,.rst-versions .rst-current-version:before{display:table;content:""}.rst-versions .rst-current-version:after{clear:both}.rst-content .code-block-caption .rst-versions .rst-current-version .headerlink,.rst-content .eqno .rst-versions .rst-current-version .headerlink,.rst-content .rst-versions .rst-current-version .admonition-title,.rst-content code.download .rst-versions .rst-current-version span:first-child,.rst-content dl dt .rst-versions .rst-current-version .headerlink,.rst-content h1 .rst-versions .rst-current-version .headerlink,.rst-content h2 .rst-versions .rst-current-version .headerlink,.rst-content h3 .rst-versions .rst-current-version .headerlink,.rst-content h4 .rst-versions .rst-current-version .headerlink,.rst-content h5 .rst-versions .rst-current-version .headerlink,.rst-content h6 .rst-versions .rst-current-version .headerlink,.rst-content p .rst-versions .rst-current-version .headerlink,.rst-content table>caption .rst-versions .rst-current-version .headerlink,.rst-content tt.download .rst-versions .rst-current-version span:first-child,.rst-versions .rst-current-version .fa,.rst-versions .rst-current-version .icon,.rst-versions .rst-current-version .rst-content .admonition-title,.rst-versions .rst-current-version .rst-content .code-block-caption .headerlink,.rst-versions .rst-current-version .rst-content .eqno .headerlink,.rst-versions .rst-current-version .rst-content code.download span:first-child,.rst-versions .rst-current-version .rst-content dl dt .headerlink,.rst-versions .rst-current-version .rst-content h1 .headerlink,.rst-versions .rst-current-version .rst-content h2 .headerlink,.rst-versions .rst-current-version .rst-content h3 .headerlink,.rst-versions .rst-current-version .rst-content h4 .headerlink,.rst-versions .rst-current-version .rst-content h5 .headerlink,.rst-versions .rst-current-version .rst-content h6 .headerlink,.rst-versions .rst-current-version .rst-content p .headerlink,.rst-versions .rst-current-version .rst-content table>caption .headerlink,.rst-versions .rst-current-version .rst-content tt.download span:first-child,.rst-versions .rst-current-version .wy-menu-vertical li button.toctree-expand,.wy-menu-vertical li .rst-versions .rst-current-version button.toctree-expand{color:#fcfcfc}.rst-versions .rst-current-version .fa-book,.rst-versions .rst-current-version .icon-book{float:left}.rst-versions .rst-current-version.rst-out-of-date{background-color:#e74c3c;color:#fff}.rst-versions .rst-current-version.rst-active-old-version{background-color:#f1c40f;color:#000}.rst-versions.shift-up{height:auto;max-height:100%;overflow-y:scroll}.rst-versions.shift-up .rst-other-versions{display:block}.rst-versions .rst-other-versions{font-size:90%;padding:12px;color:grey;display:none}.rst-versions .rst-other-versions hr{display:block;height:1px;border:0;margin:20px 0;padding:0;border-top:1px solid #413d3d}.rst-versions .rst-other-versions dd{display:inline-block;margin:0}.rst-versions .rst-other-versions dd a{display:inline-block;padding:6px;color:#fcfcfc}.rst-versions.rst-badge{width:auto;bottom:20px;right:20px;left:auto;border:none;max-width:300px;max-height:90%}.rst-versions.rst-badge .fa-book,.rst-versions.rst-badge .icon-book{float:none;line-height:30px}.rst-versions.rst-badge.shift-up .rst-current-version{text-align:right}.rst-versions.rst-badge.shift-up .rst-current-version .fa-book,.rst-versions.rst-badge.shift-up .rst-current-version .icon-book{float:left}.rst-versions.rst-badge>.rst-current-version{width:auto;height:30px;line-height:30px;padding:0 6px;display:block;text-align:center}@media screen and (max-width:768px){.rst-versions{width:85%;display:none}.rst-versions.shift{display:block}}.rst-content .toctree-wrapper>p.caption,.rst-content h1,.rst-content h2,.rst-content h3,.rst-content h4,.rst-content h5,.rst-content h6{margin-bottom:24px}.rst-content img{max-width:100%;height:auto}.rst-content div.figure,.rst-content figure{margin-bottom:24px}.rst-content div.figure .caption-text,.rst-content figure .caption-text{font-style:italic}.rst-content div.figure p:last-child.caption,.rst-content figure p:last-child.caption{margin-bottom:0}.rst-content div.figure.align-center,.rst-content figure.align-center{text-align:center}.rst-content .section>a>img,.rst-content .section>img,.rst-content section>a>img,.rst-content section>img{margin-bottom:24px}.rst-content abbr[title]{text-decoration:none}.rst-content.style-external-links a.reference.external:after{font-family:FontAwesome;content:"\f08e";color:#b3b3b3;vertical-align:super;font-size:60%;margin:0 .2em}.rst-content blockquote{margin-left:24px;line-height:24px;margin-bottom:24px}.rst-content pre.literal-block{white-space:pre;margin:0;padding:12px;font-family:SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,Courier,monospace;display:block;overflow:auto}.rst-content div[class^=highlight],.rst-content pre.literal-block{border:1px solid #e1e4e5;overflow-x:auto;margin:1px 0 24px}.rst-content div[class^=highlight] div[class^=highlight],.rst-content pre.literal-block div[class^=highlight]{padding:0;border:none;margin:0}.rst-content div[class^=highlight] td.code{width:100%}.rst-content .linenodiv pre{border-right:1px solid #e6e9ea;margin:0;padding:12px;font-family:SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,Courier,monospace;user-select:none;pointer-events:none}.rst-content div[class^=highlight] pre{white-space:pre;margin:0;padding:12px;display:block;overflow:auto}.rst-content div[class^=highlight] pre .hll{display:block;margin:0 -12px;padding:0 12px}.rst-content .linenodiv pre,.rst-content div[class^=highlight] pre,.rst-content pre.literal-block{font-family:SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,Courier,monospace;font-size:12px;line-height:1.4}.rst-content div.highlight .gp,.rst-content div.highlight span.linenos{user-select:none;pointer-events:none}.rst-content div.highlight span.linenos{display:inline-block;padding-left:0;padding-right:12px;margin-right:12px;border-right:1px solid #e6e9ea}.rst-content .code-block-caption{font-style:italic;font-size:85%;line-height:1;padding:1em 0;text-align:center}@media print{.rst-content .codeblock,.rst-content div[class^=highlight],.rst-content div[class^=highlight] pre{white-space:pre-wrap}}.rst-content .admonition,.rst-content .admonition-todo,.rst-content .attention,.rst-content .caution,.rst-content .danger,.rst-content .error,.rst-content .hint,.rst-content .important,.rst-content .note,.rst-content .seealso,.rst-content .tip,.rst-content .warning{clear:both}.rst-content .admonition-todo .last,.rst-content .admonition-todo>:last-child,.rst-content .admonition .last,.rst-content .admonition>:last-child,.rst-content .attention .last,.rst-content .attention>:last-child,.rst-content .caution .last,.rst-content .caution>:last-child,.rst-content .danger .last,.rst-content .danger>:last-child,.rst-content .error .last,.rst-content .error>:last-child,.rst-content .hint .last,.rst-content .hint>:last-child,.rst-content .important .last,.rst-content .important>:last-child,.rst-content .note .last,.rst-content .note>:last-child,.rst-content .seealso .last,.rst-content .seealso>:last-child,.rst-content .tip .last,.rst-content .tip>:last-child,.rst-content .warning .last,.rst-content .warning>:last-child{margin-bottom:0}.rst-content .admonition-title:before{margin-right:4px}.rst-content .admonition table{border-color:rgba(0,0,0,.1)}.rst-content .admonition table td,.rst-content .admonition table th{background:transparent!important;border-color:rgba(0,0,0,.1)!important}.rst-content .section ol.loweralpha,.rst-content .section ol.loweralpha>li,.rst-content .toctree-wrapper ol.loweralpha,.rst-content .toctree-wrapper ol.loweralpha>li,.rst-content section ol.loweralpha,.rst-content section ol.loweralpha>li{list-style:lower-alpha}.rst-content .section ol.upperalpha,.rst-content .section ol.upperalpha>li,.rst-content .toctree-wrapper ol.upperalpha,.rst-content .toctree-wrapper ol.upperalpha>li,.rst-content section ol.upperalpha,.rst-content section ol.upperalpha>li{list-style:upper-alpha}.rst-content .section ol li>*,.rst-content .section ul li>*,.rst-content .toctree-wrapper ol li>*,.rst-content .toctree-wrapper ul li>*,.rst-content section ol li>*,.rst-content section ul li>*{margin-top:12px;margin-bottom:12px}.rst-content .section ol li>:first-child,.rst-content .section ul li>:first-child,.rst-content .toctree-wrapper ol li>:first-child,.rst-content .toctree-wrapper ul li>:first-child,.rst-content section ol li>:first-child,.rst-content section ul li>:first-child{margin-top:0}.rst-content .section ol li>p,.rst-content .section ol li>p:last-child,.rst-content .section ul li>p,.rst-content .section ul li>p:last-child,.rst-content .toctree-wrapper ol li>p,.rst-content .toctree-wrapper ol li>p:last-child,.rst-content .toctree-wrapper ul li>p,.rst-content .toctree-wrapper ul li>p:last-child,.rst-content section ol li>p,.rst-content section ol li>p:last-child,.rst-content section ul li>p,.rst-content section ul li>p:last-child{margin-bottom:12px}.rst-content .section ol li>p:only-child,.rst-content .section ol li>p:only-child:last-child,.rst-content .section ul li>p:only-child,.rst-content .section ul li>p:only-child:last-child,.rst-content .toctree-wrapper ol li>p:only-child,.rst-content .toctree-wrapper ol li>p:only-child:last-child,.rst-content .toctree-wrapper ul li>p:only-child,.rst-content .toctree-wrapper ul li>p:only-child:last-child,.rst-content section ol li>p:only-child,.rst-content section ol li>p:only-child:last-child,.rst-content section ul li>p:only-child,.rst-content section ul li>p:only-child:last-child{margin-bottom:0}.rst-content .section ol li>ol,.rst-content .section ol li>ul,.rst-content .section ul li>ol,.rst-content .section ul li>ul,.rst-content .toctree-wrapper ol li>ol,.rst-content .toctree-wrapper ol li>ul,.rst-content .toctree-wrapper ul li>ol,.rst-content .toctree-wrapper ul li>ul,.rst-content section ol li>ol,.rst-content section ol li>ul,.rst-content section ul li>ol,.rst-content section ul li>ul{margin-bottom:12px}.rst-content .section ol.simple li>*,.rst-content .section ol.simple li ol,.rst-content .section ol.simple li ul,.rst-content .section ul.simple li>*,.rst-content .section ul.simple li ol,.rst-content .section ul.simple li ul,.rst-content .toctree-wrapper ol.simple li>*,.rst-content .toctree-wrapper ol.simple li ol,.rst-content .toctree-wrapper ol.simple li ul,.rst-content .toctree-wrapper ul.simple li>*,.rst-content .toctree-wrapper ul.simple li ol,.rst-content .toctree-wrapper ul.simple li ul,.rst-content section ol.simple li>*,.rst-content section ol.simple li ol,.rst-content section ol.simple li ul,.rst-content section ul.simple li>*,.rst-content section ul.simple li ol,.rst-content section ul.simple li ul{margin-top:0;margin-bottom:0}.rst-content .line-block{margin-left:0;margin-bottom:24px;line-height:24px}.rst-content .line-block .line-block{margin-left:24px;margin-bottom:0}.rst-content .topic-title{font-weight:700;margin-bottom:12px}.rst-content .toc-backref{color:#404040}.rst-content .align-right{float:right;margin:0 0 24px 24px}.rst-content .align-left{float:left;margin:0 24px 24px 0}.rst-content .align-center{margin:auto}.rst-content .align-center:not(table){display:block}.rst-content .code-block-caption .headerlink,.rst-content .eqno .headerlink,.rst-content .toctree-wrapper>p.caption .headerlink,.rst-content dl dt .headerlink,.rst-content h1 .headerlink,.rst-content h2 .headerlink,.rst-content h3 .headerlink,.rst-content h4 .headerlink,.rst-content h5 .headerlink,.rst-content h6 .headerlink,.rst-content p.caption .headerlink,.rst-content p .headerlink,.rst-content table>caption .headerlink{opacity:0;font-size:14px;font-family:FontAwesome;margin-left:.5em}.rst-content .code-block-caption .headerlink:focus,.rst-content .code-block-caption:hover .headerlink,.rst-content .eqno .headerlink:focus,.rst-content .eqno:hover .headerlink,.rst-content .toctree-wrapper>p.caption .headerlink:focus,.rst-content .toctree-wrapper>p.caption:hover .headerlink,.rst-content dl dt .headerlink:focus,.rst-content dl dt:hover .headerlink,.rst-content h1 .headerlink:focus,.rst-content h1:hover .headerlink,.rst-content h2 .headerlink:focus,.rst-content h2:hover .headerlink,.rst-content h3 .headerlink:focus,.rst-content h3:hover .headerlink,.rst-content h4 .headerlink:focus,.rst-content h4:hover .headerlink,.rst-content h5 .headerlink:focus,.rst-content h5:hover .headerlink,.rst-content h6 .headerlink:focus,.rst-content h6:hover .headerlink,.rst-content p.caption .headerlink:focus,.rst-content p.caption:hover .headerlink,.rst-content p .headerlink:focus,.rst-content p:hover .headerlink,.rst-content table>caption .headerlink:focus,.rst-content table>caption:hover .headerlink{opacity:1}.rst-content p a{overflow-wrap:anywhere}.rst-content .wy-table td p,.rst-content .wy-table td ul,.rst-content .wy-table th p,.rst-content .wy-table th ul,.rst-content table.docutils td p,.rst-content table.docutils td ul,.rst-content table.docutils th p,.rst-content table.docutils th ul,.rst-content table.field-list td p,.rst-content table.field-list td ul,.rst-content table.field-list th p,.rst-content table.field-list th ul{font-size:inherit}.rst-content .btn:focus{outline:2px solid}.rst-content table>caption .headerlink:after{font-size:12px}.rst-content .centered{text-align:center}.rst-content .sidebar{float:right;width:40%;display:block;margin:0 0 24px 24px;padding:24px;background:#f3f6f6;border:1px solid #e1e4e5}.rst-content .sidebar dl,.rst-content .sidebar p,.rst-content .sidebar ul{font-size:90%}.rst-content .sidebar .last,.rst-content .sidebar>:last-child{margin-bottom:0}.rst-content .sidebar .sidebar-title{display:block;font-family:Roboto Slab,ff-tisa-web-pro,Georgia,Arial,sans-serif;font-weight:700;background:#e1e4e5;padding:6px 12px;margin:-24px -24px 24px;font-size:100%}.rst-content .highlighted{background:#f1c40f;box-shadow:0 0 0 2px #f1c40f;display:inline;font-weight:700}.rst-content .citation-reference,.rst-content .footnote-reference{vertical-align:baseline;position:relative;top:-.4em;line-height:0;font-size:90%}.rst-content .citation-reference>span.fn-bracket,.rst-content .footnote-reference>span.fn-bracket{display:none}.rst-content .hlist{width:100%}.rst-content dl dt span.classifier:before{content:" : "}.rst-content dl dt span.classifier-delimiter{display:none!important}html.writer-html4 .rst-content table.docutils.citation,html.writer-html4 .rst-content table.docutils.footnote{background:none;border:none}html.writer-html4 .rst-content table.docutils.citation td,html.writer-html4 .rst-content table.docutils.citation tr,html.writer-html4 .rst-content table.docutils.footnote td,html.writer-html4 .rst-content table.docutils.footnote tr{border:none;background-color:transparent!important;white-space:normal}html.writer-html4 .rst-content table.docutils.citation td.label,html.writer-html4 .rst-content table.docutils.footnote td.label{padding-left:0;padding-right:0;vertical-align:top}html.writer-html5 .rst-content dl.citation,html.writer-html5 .rst-content dl.field-list,html.writer-html5 .rst-content dl.footnote{display:grid;grid-template-columns:auto minmax(80%,95%)}html.writer-html5 .rst-content dl.citation>dt,html.writer-html5 .rst-content dl.field-list>dt,html.writer-html5 .rst-content dl.footnote>dt{display:inline-grid;grid-template-columns:max-content auto}html.writer-html5 .rst-content aside.citation,html.writer-html5 .rst-content aside.footnote,html.writer-html5 .rst-content div.citation{display:grid;grid-template-columns:auto auto minmax(.65rem,auto) minmax(40%,95%)}html.writer-html5 .rst-content aside.citation>span.label,html.writer-html5 .rst-content aside.footnote>span.label,html.writer-html5 .rst-content div.citation>span.label{grid-column-start:1;grid-column-end:2}html.writer-html5 .rst-content aside.citation>span.backrefs,html.writer-html5 .rst-content aside.footnote>span.backrefs,html.writer-html5 .rst-content div.citation>span.backrefs{grid-column-start:2;grid-column-end:3;grid-row-start:1;grid-row-end:3}html.writer-html5 .rst-content aside.citation>p,html.writer-html5 .rst-content aside.footnote>p,html.writer-html5 .rst-content div.citation>p{grid-column-start:4;grid-column-end:5}html.writer-html5 .rst-content dl.citation,html.writer-html5 .rst-content dl.field-list,html.writer-html5 .rst-content dl.footnote{margin-bottom:24px}html.writer-html5 .rst-content dl.citation>dt,html.writer-html5 .rst-content dl.field-list>dt,html.writer-html5 .rst-content dl.footnote>dt{padding-left:1rem}html.writer-html5 .rst-content dl.citation>dd,html.writer-html5 .rst-content dl.citation>dt,html.writer-html5 .rst-content dl.field-list>dd,html.writer-html5 .rst-content dl.field-list>dt,html.writer-html5 .rst-content dl.footnote>dd,html.writer-html5 .rst-content dl.footnote>dt{margin-bottom:0}html.writer-html5 .rst-content dl.citation,html.writer-html5 .rst-content dl.footnote{font-size:.9rem}html.writer-html5 .rst-content dl.citation>dt,html.writer-html5 .rst-content dl.footnote>dt{margin:0 .5rem .5rem 0;line-height:1.2rem;word-break:break-all;font-weight:400}html.writer-html5 .rst-content dl.citation>dt>span.brackets:before,html.writer-html5 .rst-content dl.footnote>dt>span.brackets:before{content:"["}html.writer-html5 .rst-content dl.citation>dt>span.brackets:after,html.writer-html5 .rst-content dl.footnote>dt>span.brackets:after{content:"]"}html.writer-html5 .rst-content dl.citation>dt>span.fn-backref,html.writer-html5 .rst-content dl.footnote>dt>span.fn-backref{text-align:left;font-style:italic;margin-left:.65rem;word-break:break-word;word-spacing:-.1rem;max-width:5rem}html.writer-html5 .rst-content dl.citation>dt>span.fn-backref>a,html.writer-html5 .rst-content dl.footnote>dt>span.fn-backref>a{word-break:keep-all}html.writer-html5 .rst-content dl.citation>dt>span.fn-backref>a:not(:first-child):before,html.writer-html5 .rst-content dl.footnote>dt>span.fn-backref>a:not(:first-child):before{content:" "}html.writer-html5 .rst-content dl.citation>dd,html.writer-html5 .rst-content dl.footnote>dd{margin:0 0 .5rem;line-height:1.2rem}html.writer-html5 .rst-content dl.citation>dd p,html.writer-html5 .rst-content dl.footnote>dd p{font-size:.9rem}html.writer-html5 .rst-content aside.citation,html.writer-html5 .rst-content aside.footnote,html.writer-html5 .rst-content div.citation{padding-left:1rem;padding-right:1rem;font-size:.9rem;line-height:1.2rem}html.writer-html5 .rst-content aside.citation p,html.writer-html5 .rst-content aside.footnote p,html.writer-html5 .rst-content div.citation p{font-size:.9rem;line-height:1.2rem;margin-bottom:12px}html.writer-html5 .rst-content aside.citation span.backrefs,html.writer-html5 .rst-content aside.footnote span.backrefs,html.writer-html5 .rst-content div.citation span.backrefs{text-align:left;font-style:italic;margin-left:.65rem;word-break:break-word;word-spacing:-.1rem;max-width:5rem}html.writer-html5 .rst-content aside.citation span.backrefs>a,html.writer-html5 .rst-content aside.footnote span.backrefs>a,html.writer-html5 .rst-content div.citation span.backrefs>a{word-break:keep-all}html.writer-html5 .rst-content aside.citation span.backrefs>a:not(:first-child):before,html.writer-html5 .rst-content aside.footnote span.backrefs>a:not(:first-child):before,html.writer-html5 .rst-content div.citation span.backrefs>a:not(:first-child):before{content:" "}html.writer-html5 .rst-content aside.citation span.label,html.writer-html5 .rst-content aside.footnote span.label,html.writer-html5 .rst-content div.citation span.label{line-height:1.2rem}html.writer-html5 .rst-content aside.citation-list,html.writer-html5 .rst-content aside.footnote-list,html.writer-html5 .rst-content div.citation-list{margin-bottom:24px}html.writer-html5 .rst-content dl.option-list kbd{font-size:.9rem}.rst-content table.docutils.footnote,html.writer-html4 .rst-content table.docutils.citation,html.writer-html5 .rst-content aside.footnote,html.writer-html5 .rst-content aside.footnote-list aside.footnote,html.writer-html5 .rst-content div.citation-list>div.citation,html.writer-html5 .rst-content dl.citation,html.writer-html5 .rst-content dl.footnote{color:grey}.rst-content table.docutils.footnote code,.rst-content table.docutils.footnote tt,html.writer-html4 .rst-content table.docutils.citation code,html.writer-html4 .rst-content table.docutils.citation tt,html.writer-html5 .rst-content aside.footnote-list aside.footnote code,html.writer-html5 .rst-content aside.footnote-list aside.footnote tt,html.writer-html5 .rst-content aside.footnote code,html.writer-html5 .rst-content aside.footnote tt,html.writer-html5 .rst-content div.citation-list>div.citation code,html.writer-html5 .rst-content div.citation-list>div.citation tt,html.writer-html5 .rst-content dl.citation code,html.writer-html5 .rst-content dl.citation tt,html.writer-html5 .rst-content dl.footnote code,html.writer-html5 .rst-content dl.footnote tt{color:#555}.rst-content .wy-table-responsive.citation,.rst-content .wy-table-responsive.footnote{margin-bottom:0}.rst-content .wy-table-responsive.citation+:not(.citation),.rst-content .wy-table-responsive.footnote+:not(.footnote){margin-top:24px}.rst-content .wy-table-responsive.citation:last-child,.rst-content .wy-table-responsive.footnote:last-child{margin-bottom:24px}.rst-content table.docutils th{border-color:#e1e4e5}html.writer-html5 .rst-content table.docutils th{border:1px solid #e1e4e5}html.writer-html5 .rst-content table.docutils td>p,html.writer-html5 .rst-content table.docutils th>p{line-height:1rem;margin-bottom:0;font-size:.9rem}.rst-content table.docutils td .last,.rst-content table.docutils td .last>:last-child{margin-bottom:0}.rst-content table.field-list,.rst-content table.field-list td{border:none}.rst-content table.field-list td p{line-height:inherit}.rst-content table.field-list td>strong{display:inline-block}.rst-content table.field-list .field-name{padding-right:10px;text-align:left;white-space:nowrap}.rst-content table.field-list .field-body{text-align:left}.rst-content code,.rst-content tt{color:#000;font-family:SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,Courier,monospace;padding:2px 5px}.rst-content code big,.rst-content code em,.rst-content tt big,.rst-content tt em{font-size:100%!important;line-height:normal}.rst-content code.literal,.rst-content tt.literal{color:#e74c3c;white-space:normal}.rst-content code.xref,.rst-content tt.xref,a .rst-content code,a .rst-content tt{font-weight:700;color:#404040;overflow-wrap:normal}.rst-content kbd,.rst-content pre,.rst-content samp{font-family:SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,Courier,monospace}.rst-content a code,.rst-content a tt{color:#2980b9}.rst-content dl{margin-bottom:24px}.rst-content dl dt{font-weight:700;margin-bottom:12px}.rst-content dl ol,.rst-content dl p,.rst-content dl table,.rst-content dl ul{margin-bottom:12px}.rst-content dl dd{margin:0 0 12px 24px;line-height:24px}.rst-content dl dd>ol:last-child,.rst-content dl dd>p:last-child,.rst-content dl dd>table:last-child,.rst-content dl dd>ul:last-child{margin-bottom:0}html.writer-html4 .rst-content dl:not(.docutils),html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.citation):not(.glossary):not(.simple){margin-bottom:24px}html.writer-html4 .rst-content dl:not(.docutils)>dt,html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.citation):not(.glossary):not(.simple)>dt{display:table;margin:6px 0;font-size:90%;line-height:normal;background:#e7f2fa;color:#2980b9;border-top:3px solid #6ab0de;padding:6px;position:relative}html.writer-html4 .rst-content dl:not(.docutils)>dt:before,html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.citation):not(.glossary):not(.simple)>dt:before{color:#6ab0de}html.writer-html4 .rst-content dl:not(.docutils)>dt .headerlink,html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.citation):not(.glossary):not(.simple)>dt .headerlink{color:#404040;font-size:100%!important}html.writer-html4 .rst-content dl:not(.docutils) dl:not(.option-list):not(.field-list):not(.footnote):not(.citation):not(.glossary):not(.simple)>dt,html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.citation):not(.glossary):not(.simple) dl:not(.option-list):not(.field-list):not(.footnote):not(.citation):not(.glossary):not(.simple)>dt{margin-bottom:6px;border:none;border-left:3px solid #ccc;background:#f0f0f0;color:#555}html.writer-html4 .rst-content dl:not(.docutils) dl:not(.option-list):not(.field-list):not(.footnote):not(.citation):not(.glossary):not(.simple)>dt .headerlink,html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.citation):not(.glossary):not(.simple) dl:not(.option-list):not(.field-list):not(.footnote):not(.citation):not(.glossary):not(.simple)>dt .headerlink{color:#404040;font-size:100%!important}html.writer-html4 .rst-content dl:not(.docutils)>dt:first-child,html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.citation):not(.glossary):not(.simple)>dt:first-child{margin-top:0}html.writer-html4 .rst-content dl:not(.docutils) code.descclassname,html.writer-html4 .rst-content dl:not(.docutils) code.descname,html.writer-html4 .rst-content dl:not(.docutils) tt.descclassname,html.writer-html4 .rst-content dl:not(.docutils) tt.descname,html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.citation):not(.glossary):not(.simple) code.descclassname,html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.citation):not(.glossary):not(.simple) code.descname,html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.citation):not(.glossary):not(.simple) tt.descclassname,html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.citation):not(.glossary):not(.simple) tt.descname{background-color:transparent;border:none;padding:0;font-size:100%!important}html.writer-html4 .rst-content dl:not(.docutils) code.descname,html.writer-html4 .rst-content dl:not(.docutils) tt.descname,html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.citation):not(.glossary):not(.simple) code.descname,html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.citation):not(.glossary):not(.simple) tt.descname{font-weight:700}html.writer-html4 .rst-content dl:not(.docutils) .optional,html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.citation):not(.glossary):not(.simple) .optional{display:inline-block;padding:0 4px;color:#000;font-weight:700}html.writer-html4 .rst-content dl:not(.docutils) .property,html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.citation):not(.glossary):not(.simple) .property{display:inline-block;padding-right:8px;max-width:100%}html.writer-html4 .rst-content dl:not(.docutils) .k,html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.citation):not(.glossary):not(.simple) .k{font-style:italic}html.writer-html4 .rst-content dl:not(.docutils) .descclassname,html.writer-html4 .rst-content dl:not(.docutils) .descname,html.writer-html4 .rst-content dl:not(.docutils) .sig-name,html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.citation):not(.glossary):not(.simple) .descclassname,html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.citation):not(.glossary):not(.simple) .descname,html.writer-html5 .rst-content dl[class]:not(.option-list):not(.field-list):not(.footnote):not(.citation):not(.glossary):not(.simple) .sig-name{font-family:SFMono-Regular,Menlo,Monaco,Consolas,Liberation Mono,Courier New,Courier,monospace;color:#000}.rst-content .viewcode-back,.rst-content .viewcode-link{display:inline-block;color:#27ae60;font-size:80%;padding-left:24px}.rst-content .viewcode-back{display:block;float:right}.rst-content p.rubric{margin-bottom:12px;font-weight:700}.rst-content code.download,.rst-content tt.download{background:inherit;padding:inherit;font-weight:400;font-family:inherit;font-size:inherit;color:inherit;border:inherit;white-space:inherit}.rst-content code.download span:first-child,.rst-content tt.download span:first-child{-webkit-font-smoothing:subpixel-antialiased}.rst-content code.download span:first-child:before,.rst-content tt.download span:first-child:before{margin-right:4px}.rst-content .guilabel,.rst-content .menuselection{font-size:80%;font-weight:700;border-radius:4px;padding:2.4px 6px;margin:auto 2px}.rst-content .guilabel,.rst-content .menuselection{border:1px solid #7fbbe3;background:#e7f2fa}.rst-content :not(dl.option-list)>:not(dt):not(kbd):not(.kbd)>.kbd,.rst-content :not(dl.option-list)>:not(dt):not(kbd):not(.kbd)>kbd{color:inherit;font-size:80%;background-color:#fff;border:1px solid #a6a6a6;border-radius:4px;box-shadow:0 2px grey;padding:2.4px 6px;margin:auto 0}.rst-content .versionmodified{font-style:italic}@media screen and (max-width:480px){.rst-content .sidebar{width:100%}}span[id*=MathJax-Span]{color:#404040}.math{text-align:center}@font-face{font-family:Lato;src:url(fonts/lato-normal.woff2?bd03a2cc277bbbc338d464e679fe9942) format("woff2"),url(fonts/lato-normal.woff?27bd77b9162d388cb8d4c4217c7c5e2a) format("woff");font-weight:400;font-style:normal;font-display:block}@font-face{font-family:Lato;src:url(fonts/lato-bold.woff2?cccb897485813c7c256901dbca54ecf2) format("woff2"),url(fonts/lato-bold.woff?d878b6c29b10beca227e9eef4246111b) format("woff");font-weight:700;font-style:normal;font-display:block}@font-face{font-family:Lato;src:url(fonts/lato-bold-italic.woff2?0b6bb6725576b072c5d0b02ecdd1900d) format("woff2"),url(fonts/lato-bold-italic.woff?9c7e4e9eb485b4a121c760e61bc3707c) format("woff");font-weight:700;font-style:italic;font-display:block}@font-face{font-family:Lato;src:url(fonts/lato-normal-italic.woff2?4eb103b4d12be57cb1d040ed5e162e9d) format("woff2"),url(fonts/lato-normal-italic.woff?f28f2d6482446544ef1ea1ccc6dd5892) format("woff");font-weight:400;font-style:italic;font-display:block}@font-face{font-family:Roboto Slab;font-style:normal;font-weight:400;src:url(fonts/Roboto-Slab-Regular.woff2?7abf5b8d04d26a2cafea937019bca958) format("woff2"),url(fonts/Roboto-Slab-Regular.woff?c1be9284088d487c5e3ff0a10a92e58c) format("woff");font-display:block}@font-face{font-family:Roboto Slab;font-style:normal;font-weight:700;src:url(fonts/Roboto-Slab-Bold.woff2?9984f4a9bda09be08e83f2506954adbe) format("woff2"),url(fonts/Roboto-Slab-Bold.woff?bed5564a116b05148e3b3bea6fb1162a) format("woff");font-display:block} \ No newline at end of file diff --git a/_static/doctools.js b/_static/doctools.js new file mode 100644 index 00000000..4d67807d --- /dev/null +++ b/_static/doctools.js @@ -0,0 +1,156 @@ +/* + * doctools.js + * ~~~~~~~~~~~ + * + * Base JavaScript utilities for all Sphinx HTML documentation. + * + * :copyright: Copyright 2007-2024 by the Sphinx team, see AUTHORS. + * :license: BSD, see LICENSE for details. + * + */ +"use strict"; + +const BLACKLISTED_KEY_CONTROL_ELEMENTS = new Set([ + "TEXTAREA", + "INPUT", + "SELECT", + "BUTTON", +]); + +const _ready = (callback) => { + if (document.readyState !== "loading") { + callback(); + } else { + document.addEventListener("DOMContentLoaded", callback); + } +}; + +/** + * Small JavaScript module for the documentation. + */ +const Documentation = { + init: () => { + Documentation.initDomainIndexTable(); + Documentation.initOnKeyListeners(); + }, + + /** + * i18n support + */ + TRANSLATIONS: {}, + PLURAL_EXPR: (n) => (n === 1 ? 0 : 1), + LOCALE: "unknown", + + // gettext and ngettext don't access this so that the functions + // can safely bound to a different name (_ = Documentation.gettext) + gettext: (string) => { + const translated = Documentation.TRANSLATIONS[string]; + switch (typeof translated) { + case "undefined": + return string; // no translation + case "string": + return translated; // translation exists + default: + return translated[0]; // (singular, plural) translation tuple exists + } + }, + + ngettext: (singular, plural, n) => { + const translated = Documentation.TRANSLATIONS[singular]; + if (typeof translated !== "undefined") + return translated[Documentation.PLURAL_EXPR(n)]; + return n === 1 ? singular : plural; + }, + + addTranslations: (catalog) => { + Object.assign(Documentation.TRANSLATIONS, catalog.messages); + Documentation.PLURAL_EXPR = new Function( + "n", + `return (${catalog.plural_expr})` + ); + Documentation.LOCALE = catalog.locale; + }, + + /** + * helper function to focus on search bar + */ + focusSearchBar: () => { + document.querySelectorAll("input[name=q]")[0]?.focus(); + }, + + /** + * Initialise the domain index toggle buttons + */ + initDomainIndexTable: () => { + const toggler = (el) => { + const idNumber = el.id.substr(7); + const toggledRows = document.querySelectorAll(`tr.cg-${idNumber}`); + if (el.src.substr(-9) === "minus.png") { + el.src = `${el.src.substr(0, el.src.length - 9)}plus.png`; + toggledRows.forEach((el) => (el.style.display = "none")); + } else { + el.src = `${el.src.substr(0, el.src.length - 8)}minus.png`; + toggledRows.forEach((el) => (el.style.display = "")); + } + }; + + const togglerElements = document.querySelectorAll("img.toggler"); + togglerElements.forEach((el) => + el.addEventListener("click", (event) => toggler(event.currentTarget)) + ); + togglerElements.forEach((el) => (el.style.display = "")); + if (DOCUMENTATION_OPTIONS.COLLAPSE_INDEX) togglerElements.forEach(toggler); + }, + + initOnKeyListeners: () => { + // only install a listener if it is really needed + if ( + !DOCUMENTATION_OPTIONS.NAVIGATION_WITH_KEYS && + !DOCUMENTATION_OPTIONS.ENABLE_SEARCH_SHORTCUTS + ) + return; + + document.addEventListener("keydown", (event) => { + // bail for input elements + if (BLACKLISTED_KEY_CONTROL_ELEMENTS.has(document.activeElement.tagName)) return; + // bail with special keys + if (event.altKey || event.ctrlKey || event.metaKey) return; + + if (!event.shiftKey) { + switch (event.key) { + case "ArrowLeft": + if (!DOCUMENTATION_OPTIONS.NAVIGATION_WITH_KEYS) break; + + const prevLink = document.querySelector('link[rel="prev"]'); + if (prevLink && prevLink.href) { + window.location.href = prevLink.href; + event.preventDefault(); + } + break; + case "ArrowRight": + if (!DOCUMENTATION_OPTIONS.NAVIGATION_WITH_KEYS) break; + + const nextLink = document.querySelector('link[rel="next"]'); + if (nextLink && nextLink.href) { + window.location.href = nextLink.href; + event.preventDefault(); + } + break; + } + } + + // some keyboard layouts may need Shift to get / + switch (event.key) { + case "/": + if (!DOCUMENTATION_OPTIONS.ENABLE_SEARCH_SHORTCUTS) break; + Documentation.focusSearchBar(); + event.preventDefault(); + } + }); + }, +}; + +// quick alias for translations +const _ = Documentation.gettext; + +_ready(Documentation.init); diff --git a/_static/documentation_options.js b/_static/documentation_options.js new file mode 100644 index 00000000..7e4c114f --- /dev/null +++ b/_static/documentation_options.js @@ -0,0 +1,13 @@ +const DOCUMENTATION_OPTIONS = { + VERSION: '', + LANGUAGE: 'en', + COLLAPSE_INDEX: false, + BUILDER: 'html', + FILE_SUFFIX: '.html', + LINK_SUFFIX: '.html', + HAS_SOURCE: true, + SOURCELINK_SUFFIX: '.txt', + NAVIGATION_WITH_KEYS: false, + SHOW_SEARCH_SUMMARY: true, + ENABLE_SEARCH_SHORTCUTS: true, +}; \ No newline at end of file diff --git a/_static/file.png b/_static/file.png new file mode 100644 index 00000000..a858a410 Binary files /dev/null and b/_static/file.png differ diff --git a/_static/jquery.js b/_static/jquery.js new file mode 100644 index 00000000..c4c6022f --- /dev/null +++ b/_static/jquery.js @@ -0,0 +1,2 @@ +/*! jQuery v3.6.0 | (c) OpenJS Foundation and other contributors | jquery.org/license */ +!function(e,t){"use strict";"object"==typeof module&&"object"==typeof module.exports?module.exports=e.document?t(e,!0):function(e){if(!e.document)throw new Error("jQuery requires a window with a document");return t(e)}:t(e)}("undefined"!=typeof window?window:this,function(C,e){"use strict";var t=[],r=Object.getPrototypeOf,s=t.slice,g=t.flat?function(e){return t.flat.call(e)}:function(e){return t.concat.apply([],e)},u=t.push,i=t.indexOf,n={},o=n.toString,v=n.hasOwnProperty,a=v.toString,l=a.call(Object),y={},m=function(e){return"function"==typeof e&&"number"!=typeof e.nodeType&&"function"!=typeof e.item},x=function(e){return null!=e&&e===e.window},E=C.document,c={type:!0,src:!0,nonce:!0,noModule:!0};function b(e,t,n){var r,i,o=(n=n||E).createElement("script");if(o.text=e,t)for(r in c)(i=t[r]||t.getAttribute&&t.getAttribute(r))&&o.setAttribute(r,i);n.head.appendChild(o).parentNode.removeChild(o)}function w(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?n[o.call(e)]||"object":typeof e}var f="3.6.0",S=function(e,t){return new S.fn.init(e,t)};function p(e){var t=!!e&&"length"in e&&e.length,n=w(e);return!m(e)&&!x(e)&&("array"===n||0===t||"number"==typeof t&&0+~]|"+M+")"+M+"*"),U=new RegExp(M+"|>"),X=new RegExp(F),V=new RegExp("^"+I+"$"),G={ID:new RegExp("^#("+I+")"),CLASS:new RegExp("^\\.("+I+")"),TAG:new RegExp("^("+I+"|[*])"),ATTR:new RegExp("^"+W),PSEUDO:new RegExp("^"+F),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+M+"*(even|odd|(([+-]|)(\\d*)n|)"+M+"*(?:([+-]|)"+M+"*(\\d+)|))"+M+"*\\)|)","i"),bool:new RegExp("^(?:"+R+")$","i"),needsContext:new RegExp("^"+M+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+M+"*((?:-\\d)?\\d*)"+M+"*\\)|)(?=[^-]|$)","i")},Y=/HTML$/i,Q=/^(?:input|select|textarea|button)$/i,J=/^h\d$/i,K=/^[^{]+\{\s*\[native \w/,Z=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,ee=/[+~]/,te=new RegExp("\\\\[\\da-fA-F]{1,6}"+M+"?|\\\\([^\\r\\n\\f])","g"),ne=function(e,t){var n="0x"+e.slice(1)-65536;return t||(n<0?String.fromCharCode(n+65536):String.fromCharCode(n>>10|55296,1023&n|56320))},re=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\0-\x1f\x7f-\uFFFF\w-]/g,ie=function(e,t){return t?"\0"===e?"\ufffd":e.slice(0,-1)+"\\"+e.charCodeAt(e.length-1).toString(16)+" ":"\\"+e},oe=function(){T()},ae=be(function(e){return!0===e.disabled&&"fieldset"===e.nodeName.toLowerCase()},{dir:"parentNode",next:"legend"});try{H.apply(t=O.call(p.childNodes),p.childNodes),t[p.childNodes.length].nodeType}catch(e){H={apply:t.length?function(e,t){L.apply(e,O.call(t))}:function(e,t){var n=e.length,r=0;while(e[n++]=t[r++]);e.length=n-1}}}function se(t,e,n,r){var i,o,a,s,u,l,c,f=e&&e.ownerDocument,p=e?e.nodeType:9;if(n=n||[],"string"!=typeof t||!t||1!==p&&9!==p&&11!==p)return n;if(!r&&(T(e),e=e||C,E)){if(11!==p&&(u=Z.exec(t)))if(i=u[1]){if(9===p){if(!(a=e.getElementById(i)))return n;if(a.id===i)return n.push(a),n}else if(f&&(a=f.getElementById(i))&&y(e,a)&&a.id===i)return n.push(a),n}else{if(u[2])return H.apply(n,e.getElementsByTagName(t)),n;if((i=u[3])&&d.getElementsByClassName&&e.getElementsByClassName)return H.apply(n,e.getElementsByClassName(i)),n}if(d.qsa&&!N[t+" "]&&(!v||!v.test(t))&&(1!==p||"object"!==e.nodeName.toLowerCase())){if(c=t,f=e,1===p&&(U.test(t)||z.test(t))){(f=ee.test(t)&&ye(e.parentNode)||e)===e&&d.scope||((s=e.getAttribute("id"))?s=s.replace(re,ie):e.setAttribute("id",s=S)),o=(l=h(t)).length;while(o--)l[o]=(s?"#"+s:":scope")+" "+xe(l[o]);c=l.join(",")}try{return H.apply(n,f.querySelectorAll(c)),n}catch(e){N(t,!0)}finally{s===S&&e.removeAttribute("id")}}}return g(t.replace($,"$1"),e,n,r)}function ue(){var r=[];return function e(t,n){return r.push(t+" ")>b.cacheLength&&delete e[r.shift()],e[t+" "]=n}}function le(e){return e[S]=!0,e}function ce(e){var t=C.createElement("fieldset");try{return!!e(t)}catch(e){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function fe(e,t){var n=e.split("|"),r=n.length;while(r--)b.attrHandle[n[r]]=t}function pe(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&e.sourceIndex-t.sourceIndex;if(r)return r;if(n)while(n=n.nextSibling)if(n===t)return-1;return e?1:-1}function de(t){return function(e){return"input"===e.nodeName.toLowerCase()&&e.type===t}}function he(n){return function(e){var t=e.nodeName.toLowerCase();return("input"===t||"button"===t)&&e.type===n}}function ge(t){return function(e){return"form"in e?e.parentNode&&!1===e.disabled?"label"in e?"label"in e.parentNode?e.parentNode.disabled===t:e.disabled===t:e.isDisabled===t||e.isDisabled!==!t&&ae(e)===t:e.disabled===t:"label"in e&&e.disabled===t}}function ve(a){return le(function(o){return o=+o,le(function(e,t){var n,r=a([],e.length,o),i=r.length;while(i--)e[n=r[i]]&&(e[n]=!(t[n]=e[n]))})})}function ye(e){return e&&"undefined"!=typeof e.getElementsByTagName&&e}for(e in d=se.support={},i=se.isXML=function(e){var t=e&&e.namespaceURI,n=e&&(e.ownerDocument||e).documentElement;return!Y.test(t||n&&n.nodeName||"HTML")},T=se.setDocument=function(e){var t,n,r=e?e.ownerDocument||e:p;return r!=C&&9===r.nodeType&&r.documentElement&&(a=(C=r).documentElement,E=!i(C),p!=C&&(n=C.defaultView)&&n.top!==n&&(n.addEventListener?n.addEventListener("unload",oe,!1):n.attachEvent&&n.attachEvent("onunload",oe)),d.scope=ce(function(e){return a.appendChild(e).appendChild(C.createElement("div")),"undefined"!=typeof e.querySelectorAll&&!e.querySelectorAll(":scope fieldset div").length}),d.attributes=ce(function(e){return e.className="i",!e.getAttribute("className")}),d.getElementsByTagName=ce(function(e){return e.appendChild(C.createComment("")),!e.getElementsByTagName("*").length}),d.getElementsByClassName=K.test(C.getElementsByClassName),d.getById=ce(function(e){return a.appendChild(e).id=S,!C.getElementsByName||!C.getElementsByName(S).length}),d.getById?(b.filter.ID=function(e){var t=e.replace(te,ne);return function(e){return e.getAttribute("id")===t}},b.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&E){var n=t.getElementById(e);return n?[n]:[]}}):(b.filter.ID=function(e){var n=e.replace(te,ne);return function(e){var t="undefined"!=typeof e.getAttributeNode&&e.getAttributeNode("id");return t&&t.value===n}},b.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&E){var n,r,i,o=t.getElementById(e);if(o){if((n=o.getAttributeNode("id"))&&n.value===e)return[o];i=t.getElementsByName(e),r=0;while(o=i[r++])if((n=o.getAttributeNode("id"))&&n.value===e)return[o]}return[]}}),b.find.TAG=d.getElementsByTagName?function(e,t){return"undefined"!=typeof t.getElementsByTagName?t.getElementsByTagName(e):d.qsa?t.querySelectorAll(e):void 0}:function(e,t){var n,r=[],i=0,o=t.getElementsByTagName(e);if("*"===e){while(n=o[i++])1===n.nodeType&&r.push(n);return r}return o},b.find.CLASS=d.getElementsByClassName&&function(e,t){if("undefined"!=typeof t.getElementsByClassName&&E)return t.getElementsByClassName(e)},s=[],v=[],(d.qsa=K.test(C.querySelectorAll))&&(ce(function(e){var t;a.appendChild(e).innerHTML="",e.querySelectorAll("[msallowcapture^='']").length&&v.push("[*^$]="+M+"*(?:''|\"\")"),e.querySelectorAll("[selected]").length||v.push("\\["+M+"*(?:value|"+R+")"),e.querySelectorAll("[id~="+S+"-]").length||v.push("~="),(t=C.createElement("input")).setAttribute("name",""),e.appendChild(t),e.querySelectorAll("[name='']").length||v.push("\\["+M+"*name"+M+"*="+M+"*(?:''|\"\")"),e.querySelectorAll(":checked").length||v.push(":checked"),e.querySelectorAll("a#"+S+"+*").length||v.push(".#.+[+~]"),e.querySelectorAll("\\\f"),v.push("[\\r\\n\\f]")}),ce(function(e){e.innerHTML="";var t=C.createElement("input");t.setAttribute("type","hidden"),e.appendChild(t).setAttribute("name","D"),e.querySelectorAll("[name=d]").length&&v.push("name"+M+"*[*^$|!~]?="),2!==e.querySelectorAll(":enabled").length&&v.push(":enabled",":disabled"),a.appendChild(e).disabled=!0,2!==e.querySelectorAll(":disabled").length&&v.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),v.push(",.*:")})),(d.matchesSelector=K.test(c=a.matches||a.webkitMatchesSelector||a.mozMatchesSelector||a.oMatchesSelector||a.msMatchesSelector))&&ce(function(e){d.disconnectedMatch=c.call(e,"*"),c.call(e,"[s!='']:x"),s.push("!=",F)}),v=v.length&&new RegExp(v.join("|")),s=s.length&&new RegExp(s.join("|")),t=K.test(a.compareDocumentPosition),y=t||K.test(a.contains)?function(e,t){var n=9===e.nodeType?e.documentElement:e,r=t&&t.parentNode;return e===r||!(!r||1!==r.nodeType||!(n.contains?n.contains(r):e.compareDocumentPosition&&16&e.compareDocumentPosition(r)))}:function(e,t){if(t)while(t=t.parentNode)if(t===e)return!0;return!1},j=t?function(e,t){if(e===t)return l=!0,0;var n=!e.compareDocumentPosition-!t.compareDocumentPosition;return n||(1&(n=(e.ownerDocument||e)==(t.ownerDocument||t)?e.compareDocumentPosition(t):1)||!d.sortDetached&&t.compareDocumentPosition(e)===n?e==C||e.ownerDocument==p&&y(p,e)?-1:t==C||t.ownerDocument==p&&y(p,t)?1:u?P(u,e)-P(u,t):0:4&n?-1:1)}:function(e,t){if(e===t)return l=!0,0;var n,r=0,i=e.parentNode,o=t.parentNode,a=[e],s=[t];if(!i||!o)return e==C?-1:t==C?1:i?-1:o?1:u?P(u,e)-P(u,t):0;if(i===o)return pe(e,t);n=e;while(n=n.parentNode)a.unshift(n);n=t;while(n=n.parentNode)s.unshift(n);while(a[r]===s[r])r++;return r?pe(a[r],s[r]):a[r]==p?-1:s[r]==p?1:0}),C},se.matches=function(e,t){return se(e,null,null,t)},se.matchesSelector=function(e,t){if(T(e),d.matchesSelector&&E&&!N[t+" "]&&(!s||!s.test(t))&&(!v||!v.test(t)))try{var n=c.call(e,t);if(n||d.disconnectedMatch||e.document&&11!==e.document.nodeType)return n}catch(e){N(t,!0)}return 0":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(te,ne),e[3]=(e[3]||e[4]||e[5]||"").replace(te,ne),"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||se.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&se.error(e[0]),e},PSEUDO:function(e){var t,n=!e[6]&&e[2];return G.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":n&&X.test(n)&&(t=h(n,!0))&&(t=n.indexOf(")",n.length-t)-n.length)&&(e[0]=e[0].slice(0,t),e[2]=n.slice(0,t)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(te,ne).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=m[e+" "];return t||(t=new RegExp("(^|"+M+")"+e+"("+M+"|$)"))&&m(e,function(e){return t.test("string"==typeof e.className&&e.className||"undefined"!=typeof e.getAttribute&&e.getAttribute("class")||"")})},ATTR:function(n,r,i){return function(e){var t=se.attr(e,n);return null==t?"!="===r:!r||(t+="","="===r?t===i:"!="===r?t!==i:"^="===r?i&&0===t.indexOf(i):"*="===r?i&&-1:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;function j(e,n,r){return m(n)?S.grep(e,function(e,t){return!!n.call(e,t,e)!==r}):n.nodeType?S.grep(e,function(e){return e===n!==r}):"string"!=typeof n?S.grep(e,function(e){return-1)[^>]*|#([\w-]+))$/;(S.fn.init=function(e,t,n){var r,i;if(!e)return this;if(n=n||D,"string"==typeof e){if(!(r="<"===e[0]&&">"===e[e.length-1]&&3<=e.length?[null,e,null]:q.exec(e))||!r[1]&&t)return!t||t.jquery?(t||n).find(e):this.constructor(t).find(e);if(r[1]){if(t=t instanceof S?t[0]:t,S.merge(this,S.parseHTML(r[1],t&&t.nodeType?t.ownerDocument||t:E,!0)),N.test(r[1])&&S.isPlainObject(t))for(r in t)m(this[r])?this[r](t[r]):this.attr(r,t[r]);return this}return(i=E.getElementById(r[2]))&&(this[0]=i,this.length=1),this}return e.nodeType?(this[0]=e,this.length=1,this):m(e)?void 0!==n.ready?n.ready(e):e(S):S.makeArray(e,this)}).prototype=S.fn,D=S(E);var L=/^(?:parents|prev(?:Until|All))/,H={children:!0,contents:!0,next:!0,prev:!0};function O(e,t){while((e=e[t])&&1!==e.nodeType);return e}S.fn.extend({has:function(e){var t=S(e,this),n=t.length;return this.filter(function(){for(var e=0;e\x20\t\r\n\f]*)/i,he=/^$|^module$|\/(?:java|ecma)script/i;ce=E.createDocumentFragment().appendChild(E.createElement("div")),(fe=E.createElement("input")).setAttribute("type","radio"),fe.setAttribute("checked","checked"),fe.setAttribute("name","t"),ce.appendChild(fe),y.checkClone=ce.cloneNode(!0).cloneNode(!0).lastChild.checked,ce.innerHTML="",y.noCloneChecked=!!ce.cloneNode(!0).lastChild.defaultValue,ce.innerHTML="",y.option=!!ce.lastChild;var ge={thead:[1,"","
"],col:[2,"","
"],tr:[2,"","
"],td:[3,"","
"],_default:[0,"",""]};function ve(e,t){var n;return n="undefined"!=typeof e.getElementsByTagName?e.getElementsByTagName(t||"*"):"undefined"!=typeof e.querySelectorAll?e.querySelectorAll(t||"*"):[],void 0===t||t&&A(e,t)?S.merge([e],n):n}function ye(e,t){for(var n=0,r=e.length;n",""]);var me=/<|&#?\w+;/;function xe(e,t,n,r,i){for(var o,a,s,u,l,c,f=t.createDocumentFragment(),p=[],d=0,h=e.length;d\s*$/g;function je(e,t){return A(e,"table")&&A(11!==t.nodeType?t:t.firstChild,"tr")&&S(e).children("tbody")[0]||e}function De(e){return e.type=(null!==e.getAttribute("type"))+"/"+e.type,e}function qe(e){return"true/"===(e.type||"").slice(0,5)?e.type=e.type.slice(5):e.removeAttribute("type"),e}function Le(e,t){var n,r,i,o,a,s;if(1===t.nodeType){if(Y.hasData(e)&&(s=Y.get(e).events))for(i in Y.remove(t,"handle events"),s)for(n=0,r=s[i].length;n").attr(n.scriptAttrs||{}).prop({charset:n.scriptCharset,src:n.url}).on("load error",i=function(e){r.remove(),i=null,e&&t("error"===e.type?404:200,e.type)}),E.head.appendChild(r[0])},abort:function(){i&&i()}}});var _t,zt=[],Ut=/(=)\?(?=&|$)|\?\?/;S.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var e=zt.pop()||S.expando+"_"+wt.guid++;return this[e]=!0,e}}),S.ajaxPrefilter("json jsonp",function(e,t,n){var r,i,o,a=!1!==e.jsonp&&(Ut.test(e.url)?"url":"string"==typeof e.data&&0===(e.contentType||"").indexOf("application/x-www-form-urlencoded")&&Ut.test(e.data)&&"data");if(a||"jsonp"===e.dataTypes[0])return r=e.jsonpCallback=m(e.jsonpCallback)?e.jsonpCallback():e.jsonpCallback,a?e[a]=e[a].replace(Ut,"$1"+r):!1!==e.jsonp&&(e.url+=(Tt.test(e.url)?"&":"?")+e.jsonp+"="+r),e.converters["script json"]=function(){return o||S.error(r+" was not called"),o[0]},e.dataTypes[0]="json",i=C[r],C[r]=function(){o=arguments},n.always(function(){void 0===i?S(C).removeProp(r):C[r]=i,e[r]&&(e.jsonpCallback=t.jsonpCallback,zt.push(r)),o&&m(i)&&i(o[0]),o=i=void 0}),"script"}),y.createHTMLDocument=((_t=E.implementation.createHTMLDocument("").body).innerHTML="
",2===_t.childNodes.length),S.parseHTML=function(e,t,n){return"string"!=typeof e?[]:("boolean"==typeof t&&(n=t,t=!1),t||(y.createHTMLDocument?((r=(t=E.implementation.createHTMLDocument("")).createElement("base")).href=E.location.href,t.head.appendChild(r)):t=E),o=!n&&[],(i=N.exec(e))?[t.createElement(i[1])]:(i=xe([e],t,o),o&&o.length&&S(o).remove(),S.merge([],i.childNodes)));var r,i,o},S.fn.load=function(e,t,n){var r,i,o,a=this,s=e.indexOf(" ");return-1").append(S.parseHTML(e)).find(r):e)}).always(n&&function(e,t){a.each(function(){n.apply(this,o||[e.responseText,t,e])})}),this},S.expr.pseudos.animated=function(t){return S.grep(S.timers,function(e){return t===e.elem}).length},S.offset={setOffset:function(e,t,n){var r,i,o,a,s,u,l=S.css(e,"position"),c=S(e),f={};"static"===l&&(e.style.position="relative"),s=c.offset(),o=S.css(e,"top"),u=S.css(e,"left"),("absolute"===l||"fixed"===l)&&-1<(o+u).indexOf("auto")?(a=(r=c.position()).top,i=r.left):(a=parseFloat(o)||0,i=parseFloat(u)||0),m(t)&&(t=t.call(e,n,S.extend({},s))),null!=t.top&&(f.top=t.top-s.top+a),null!=t.left&&(f.left=t.left-s.left+i),"using"in t?t.using.call(e,f):c.css(f)}},S.fn.extend({offset:function(t){if(arguments.length)return void 0===t?this:this.each(function(e){S.offset.setOffset(this,t,e)});var e,n,r=this[0];return r?r.getClientRects().length?(e=r.getBoundingClientRect(),n=r.ownerDocument.defaultView,{top:e.top+n.pageYOffset,left:e.left+n.pageXOffset}):{top:0,left:0}:void 0},position:function(){if(this[0]){var e,t,n,r=this[0],i={top:0,left:0};if("fixed"===S.css(r,"position"))t=r.getBoundingClientRect();else{t=this.offset(),n=r.ownerDocument,e=r.offsetParent||n.documentElement;while(e&&(e===n.body||e===n.documentElement)&&"static"===S.css(e,"position"))e=e.parentNode;e&&e!==r&&1===e.nodeType&&((i=S(e).offset()).top+=S.css(e,"borderTopWidth",!0),i.left+=S.css(e,"borderLeftWidth",!0))}return{top:t.top-i.top-S.css(r,"marginTop",!0),left:t.left-i.left-S.css(r,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){var e=this.offsetParent;while(e&&"static"===S.css(e,"position"))e=e.offsetParent;return e||re})}}),S.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(t,i){var o="pageYOffset"===i;S.fn[t]=function(e){return $(this,function(e,t,n){var r;if(x(e)?r=e:9===e.nodeType&&(r=e.defaultView),void 0===n)return r?r[i]:e[t];r?r.scrollTo(o?r.pageXOffset:n,o?n:r.pageYOffset):e[t]=n},t,e,arguments.length)}}),S.each(["top","left"],function(e,n){S.cssHooks[n]=Fe(y.pixelPosition,function(e,t){if(t)return t=We(e,n),Pe.test(t)?S(e).position()[n]+"px":t})}),S.each({Height:"height",Width:"width"},function(a,s){S.each({padding:"inner"+a,content:s,"":"outer"+a},function(r,o){S.fn[o]=function(e,t){var n=arguments.length&&(r||"boolean"!=typeof e),i=r||(!0===e||!0===t?"margin":"border");return $(this,function(e,t,n){var r;return x(e)?0===o.indexOf("outer")?e["inner"+a]:e.document.documentElement["client"+a]:9===e.nodeType?(r=e.documentElement,Math.max(e.body["scroll"+a],r["scroll"+a],e.body["offset"+a],r["offset"+a],r["client"+a])):void 0===n?S.css(e,t,i):S.style(e,t,n,i)},s,n?e:void 0,n)}})}),S.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(e,t){S.fn[t]=function(e){return this.on(t,e)}}),S.fn.extend({bind:function(e,t,n){return this.on(e,null,t,n)},unbind:function(e,t){return this.off(e,null,t)},delegate:function(e,t,n,r){return this.on(t,e,n,r)},undelegate:function(e,t,n){return 1===arguments.length?this.off(e,"**"):this.off(t,e||"**",n)},hover:function(e,t){return this.mouseenter(e).mouseleave(t||e)}}),S.each("blur focus focusin focusout resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu".split(" "),function(e,n){S.fn[n]=function(e,t){return 0",d.insertBefore(c.lastChild,d.firstChild)}function d(){var a=y.elements;return"string"==typeof a?a.split(" "):a}function e(a,b){var c=y.elements;"string"!=typeof c&&(c=c.join(" ")),"string"!=typeof a&&(a=a.join(" ")),y.elements=c+" "+a,j(b)}function f(a){var b=x[a[v]];return b||(b={},w++,a[v]=w,x[w]=b),b}function g(a,c,d){if(c||(c=b),q)return c.createElement(a);d||(d=f(c));var e;return e=d.cache[a]?d.cache[a].cloneNode():u.test(a)?(d.cache[a]=d.createElem(a)).cloneNode():d.createElem(a),!e.canHaveChildren||t.test(a)||e.tagUrn?e:d.frag.appendChild(e)}function h(a,c){if(a||(a=b),q)return a.createDocumentFragment();c=c||f(a);for(var e=c.frag.cloneNode(),g=0,h=d(),i=h.length;i>g;g++)e.createElement(h[g]);return e}function i(a,b){b.cache||(b.cache={},b.createElem=a.createElement,b.createFrag=a.createDocumentFragment,b.frag=b.createFrag()),a.createElement=function(c){return y.shivMethods?g(c,a,b):b.createElem(c)},a.createDocumentFragment=Function("h,f","return function(){var n=f.cloneNode(),c=n.createElement;h.shivMethods&&("+d().join().replace(/[\w\-:]+/g,function(a){return b.createElem(a),b.frag.createElement(a),'c("'+a+'")'})+");return n}")(y,b.frag)}function j(a){a||(a=b);var d=f(a);return!y.shivCSS||p||d.hasCSS||(d.hasCSS=!!c(a,"article,aside,dialog,figcaption,figure,footer,header,hgroup,main,nav,section{display:block}mark{background:#FF0;color:#000}template{display:none}")),q||i(a,d),a}function k(a){for(var b,c=a.getElementsByTagName("*"),e=c.length,f=RegExp("^(?:"+d().join("|")+")$","i"),g=[];e--;)b=c[e],f.test(b.nodeName)&&g.push(b.applyElement(l(b)));return g}function l(a){for(var b,c=a.attributes,d=c.length,e=a.ownerDocument.createElement(A+":"+a.nodeName);d--;)b=c[d],b.specified&&e.setAttribute(b.nodeName,b.nodeValue);return e.style.cssText=a.style.cssText,e}function m(a){for(var b,c=a.split("{"),e=c.length,f=RegExp("(^|[\\s,>+~])("+d().join("|")+")(?=[[\\s,>+~#.:]|$)","gi"),g="$1"+A+"\\:$2";e--;)b=c[e]=c[e].split("}"),b[b.length-1]=b[b.length-1].replace(f,g),c[e]=b.join("}");return c.join("{")}function n(a){for(var b=a.length;b--;)a[b].removeNode()}function o(a){function b(){clearTimeout(g._removeSheetTimer),d&&d.removeNode(!0),d=null}var d,e,g=f(a),h=a.namespaces,i=a.parentWindow;return!B||a.printShived?a:("undefined"==typeof h[A]&&h.add(A),i.attachEvent("onbeforeprint",function(){b();for(var f,g,h,i=a.styleSheets,j=[],l=i.length,n=Array(l);l--;)n[l]=i[l];for(;h=n.pop();)if(!h.disabled&&z.test(h.media)){try{f=h.imports,g=f.length}catch(o){g=0}for(l=0;g>l;l++)n.push(f[l]);try{j.push(h.cssText)}catch(o){}}j=m(j.reverse().join("")),e=k(a),d=c(a,j)}),i.attachEvent("onafterprint",function(){n(e),clearTimeout(g._removeSheetTimer),g._removeSheetTimer=setTimeout(b,500)}),a.printShived=!0,a)}var p,q,r="3.7.3",s=a.html5||{},t=/^<|^(?:button|map|select|textarea|object|iframe|option|optgroup)$/i,u=/^(?:a|b|code|div|fieldset|h1|h2|h3|h4|h5|h6|i|label|li|ol|p|q|span|strong|style|table|tbody|td|th|tr|ul)$/i,v="_html5shiv",w=0,x={};!function(){try{var a=b.createElement("a");a.innerHTML="",p="hidden"in a,q=1==a.childNodes.length||function(){b.createElement("a");var a=b.createDocumentFragment();return"undefined"==typeof a.cloneNode||"undefined"==typeof a.createDocumentFragment||"undefined"==typeof a.createElement}()}catch(c){p=!0,q=!0}}();var y={elements:s.elements||"abbr article aside audio bdi canvas data datalist details dialog figcaption figure footer header hgroup main mark meter nav output picture progress section summary template time video",version:r,shivCSS:s.shivCSS!==!1,supportsUnknownElements:q,shivMethods:s.shivMethods!==!1,type:"default",shivDocument:j,createElement:g,createDocumentFragment:h,addElements:e};a.html5=y,j(b);var z=/^$|\b(?:all|print)\b/,A="html5shiv",B=!q&&function(){var c=b.documentElement;return!("undefined"==typeof b.namespaces||"undefined"==typeof b.parentWindow||"undefined"==typeof c.applyElement||"undefined"==typeof c.removeNode||"undefined"==typeof a.attachEvent)}();y.type+=" print",y.shivPrint=o,o(b),"object"==typeof module&&module.exports&&(module.exports=y)}("undefined"!=typeof window?window:this,document); \ No newline at end of file diff --git a/_static/js/html5shiv.min.js b/_static/js/html5shiv.min.js new file mode 100644 index 00000000..cd1c674f --- /dev/null +++ b/_static/js/html5shiv.min.js @@ -0,0 +1,4 @@ +/** +* @preserve HTML5 Shiv 3.7.3 | @afarkas @jdalton @jon_neal @rem | MIT/GPL2 Licensed +*/ +!function(a,b){function c(a,b){var c=a.createElement("p"),d=a.getElementsByTagName("head")[0]||a.documentElement;return c.innerHTML="x",d.insertBefore(c.lastChild,d.firstChild)}function d(){var a=t.elements;return"string"==typeof a?a.split(" "):a}function e(a,b){var c=t.elements;"string"!=typeof c&&(c=c.join(" ")),"string"!=typeof a&&(a=a.join(" ")),t.elements=c+" "+a,j(b)}function f(a){var b=s[a[q]];return b||(b={},r++,a[q]=r,s[r]=b),b}function g(a,c,d){if(c||(c=b),l)return c.createElement(a);d||(d=f(c));var e;return e=d.cache[a]?d.cache[a].cloneNode():p.test(a)?(d.cache[a]=d.createElem(a)).cloneNode():d.createElem(a),!e.canHaveChildren||o.test(a)||e.tagUrn?e:d.frag.appendChild(e)}function h(a,c){if(a||(a=b),l)return a.createDocumentFragment();c=c||f(a);for(var e=c.frag.cloneNode(),g=0,h=d(),i=h.length;i>g;g++)e.createElement(h[g]);return e}function i(a,b){b.cache||(b.cache={},b.createElem=a.createElement,b.createFrag=a.createDocumentFragment,b.frag=b.createFrag()),a.createElement=function(c){return t.shivMethods?g(c,a,b):b.createElem(c)},a.createDocumentFragment=Function("h,f","return function(){var n=f.cloneNode(),c=n.createElement;h.shivMethods&&("+d().join().replace(/[\w\-:]+/g,function(a){return b.createElem(a),b.frag.createElement(a),'c("'+a+'")'})+");return n}")(t,b.frag)}function j(a){a||(a=b);var d=f(a);return!t.shivCSS||k||d.hasCSS||(d.hasCSS=!!c(a,"article,aside,dialog,figcaption,figure,footer,header,hgroup,main,nav,section{display:block}mark{background:#FF0;color:#000}template{display:none}")),l||i(a,d),a}var k,l,m="3.7.3-pre",n=a.html5||{},o=/^<|^(?:button|map|select|textarea|object|iframe|option|optgroup)$/i,p=/^(?:a|b|code|div|fieldset|h1|h2|h3|h4|h5|h6|i|label|li|ol|p|q|span|strong|style|table|tbody|td|th|tr|ul)$/i,q="_html5shiv",r=0,s={};!function(){try{var a=b.createElement("a");a.innerHTML="",k="hidden"in a,l=1==a.childNodes.length||function(){b.createElement("a");var a=b.createDocumentFragment();return"undefined"==typeof a.cloneNode||"undefined"==typeof a.createDocumentFragment||"undefined"==typeof a.createElement}()}catch(c){k=!0,l=!0}}();var t={elements:n.elements||"abbr article aside audio bdi canvas data datalist details dialog figcaption figure footer header hgroup main mark meter nav output picture progress section summary template time video",version:m,shivCSS:n.shivCSS!==!1,supportsUnknownElements:l,shivMethods:n.shivMethods!==!1,type:"default",shivDocument:j,createElement:g,createDocumentFragment:h,addElements:e};a.html5=t,j(b),"object"==typeof module&&module.exports&&(module.exports=t)}("undefined"!=typeof window?window:this,document); \ No newline at end of file diff --git a/_static/js/theme.js b/_static/js/theme.js new file mode 100644 index 00000000..1fddb6ee --- /dev/null +++ b/_static/js/theme.js @@ -0,0 +1 @@ +!function(n){var e={};function t(i){if(e[i])return e[i].exports;var o=e[i]={i:i,l:!1,exports:{}};return n[i].call(o.exports,o,o.exports,t),o.l=!0,o.exports}t.m=n,t.c=e,t.d=function(n,e,i){t.o(n,e)||Object.defineProperty(n,e,{enumerable:!0,get:i})},t.r=function(n){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(n,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(n,"__esModule",{value:!0})},t.t=function(n,e){if(1&e&&(n=t(n)),8&e)return n;if(4&e&&"object"==typeof n&&n&&n.__esModule)return n;var i=Object.create(null);if(t.r(i),Object.defineProperty(i,"default",{enumerable:!0,value:n}),2&e&&"string"!=typeof n)for(var o in n)t.d(i,o,function(e){return n[e]}.bind(null,o));return i},t.n=function(n){var e=n&&n.__esModule?function(){return n.default}:function(){return n};return t.d(e,"a",e),e},t.o=function(n,e){return Object.prototype.hasOwnProperty.call(n,e)},t.p="",t(t.s=0)}([function(n,e,t){t(1),n.exports=t(3)},function(n,e,t){(function(){var e="undefined"!=typeof window?window.jQuery:t(2);n.exports.ThemeNav={navBar:null,win:null,winScroll:!1,winResize:!1,linkScroll:!1,winPosition:0,winHeight:null,docHeight:null,isRunning:!1,enable:function(n){var t=this;void 0===n&&(n=!0),t.isRunning||(t.isRunning=!0,e((function(e){t.init(e),t.reset(),t.win.on("hashchange",t.reset),n&&t.win.on("scroll",(function(){t.linkScroll||t.winScroll||(t.winScroll=!0,requestAnimationFrame((function(){t.onScroll()})))})),t.win.on("resize",(function(){t.winResize||(t.winResize=!0,requestAnimationFrame((function(){t.onResize()})))})),t.onResize()})))},enableSticky:function(){this.enable(!0)},init:function(n){n(document);var e=this;this.navBar=n("div.wy-side-scroll:first"),this.win=n(window),n(document).on("click","[data-toggle='wy-nav-top']",(function(){n("[data-toggle='wy-nav-shift']").toggleClass("shift"),n("[data-toggle='rst-versions']").toggleClass("shift")})).on("click",".wy-menu-vertical .current ul li a",(function(){var t=n(this);n("[data-toggle='wy-nav-shift']").removeClass("shift"),n("[data-toggle='rst-versions']").toggleClass("shift"),e.toggleCurrent(t),e.hashChange()})).on("click","[data-toggle='rst-current-version']",(function(){n("[data-toggle='rst-versions']").toggleClass("shift-up")})),n("table.docutils:not(.field-list,.footnote,.citation)").wrap("
"),n("table.docutils.footnote").wrap("
"),n("table.docutils.citation").wrap("
"),n(".wy-menu-vertical ul").not(".simple").siblings("a").each((function(){var t=n(this);expand=n(''),expand.on("click",(function(n){return e.toggleCurrent(t),n.stopPropagation(),!1})),t.prepend(expand)}))},reset:function(){var n=encodeURI(window.location.hash)||"#";try{var e=$(".wy-menu-vertical"),t=e.find('[href="'+n+'"]');if(0===t.length){var i=$('.document [id="'+n.substring(1)+'"]').closest("div.section");0===(t=e.find('[href="#'+i.attr("id")+'"]')).length&&(t=e.find('[href="#"]'))}if(t.length>0){$(".wy-menu-vertical .current").removeClass("current").attr("aria-expanded","false"),t.addClass("current").attr("aria-expanded","true"),t.closest("li.toctree-l1").parent().addClass("current").attr("aria-expanded","true");for(let n=1;n<=10;n++)t.closest("li.toctree-l"+n).addClass("current").attr("aria-expanded","true");t[0].scrollIntoView()}}catch(n){console.log("Error expanding nav for anchor",n)}},onScroll:function(){this.winScroll=!1;var n=this.win.scrollTop(),e=n+this.winHeight,t=this.navBar.scrollTop()+(n-this.winPosition);n<0||e>this.docHeight||(this.navBar.scrollTop(t),this.winPosition=n)},onResize:function(){this.winResize=!1,this.winHeight=this.win.height(),this.docHeight=$(document).height()},hashChange:function(){this.linkScroll=!0,this.win.one("hashchange",(function(){this.linkScroll=!1}))},toggleCurrent:function(n){var e=n.closest("li");e.siblings("li.current").removeClass("current").attr("aria-expanded","false"),e.siblings().find("li.current").removeClass("current").attr("aria-expanded","false");var t=e.find("> ul li");t.length&&(t.removeClass("current").attr("aria-expanded","false"),e.toggleClass("current").attr("aria-expanded",(function(n,e){return"true"==e?"false":"true"})))}},"undefined"!=typeof window&&(window.SphinxRtdTheme={Navigation:n.exports.ThemeNav,StickyNav:n.exports.ThemeNav}),function(){for(var n=0,e=["ms","moz","webkit","o"],t=0;t0 + var meq1 = "^(" + C + ")?" + V + C + "(" + V + ")?$"; // [C]VC[V] is m=1 + var mgr1 = "^(" + C + ")?" + V + C + V + C; // [C]VCVC... is m>1 + var s_v = "^(" + C + ")?" + v; // vowel in stem + + this.stemWord = function (w) { + var stem; + var suffix; + var firstch; + var origword = w; + + if (w.length < 3) + return w; + + var re; + var re2; + var re3; + var re4; + + firstch = w.substr(0,1); + if (firstch == "y") + w = firstch.toUpperCase() + w.substr(1); + + // Step 1a + re = /^(.+?)(ss|i)es$/; + re2 = /^(.+?)([^s])s$/; + + if (re.test(w)) + w = w.replace(re,"$1$2"); + else if (re2.test(w)) + w = w.replace(re2,"$1$2"); + + // Step 1b + re = /^(.+?)eed$/; + re2 = /^(.+?)(ed|ing)$/; + if (re.test(w)) { + var fp = re.exec(w); + re = new RegExp(mgr0); + if (re.test(fp[1])) { + re = /.$/; + w = w.replace(re,""); + } + } + else if (re2.test(w)) { + var fp = re2.exec(w); + stem = fp[1]; + re2 = new RegExp(s_v); + if (re2.test(stem)) { + w = stem; + re2 = /(at|bl|iz)$/; + re3 = new RegExp("([^aeiouylsz])\\1$"); + re4 = new RegExp("^" + C + v + "[^aeiouwxy]$"); + if (re2.test(w)) + w = w + "e"; + else if (re3.test(w)) { + re = /.$/; + w = w.replace(re,""); + } + else if (re4.test(w)) + w = w + "e"; + } + } + + // Step 1c + re = /^(.+?)y$/; + if (re.test(w)) { + var fp = re.exec(w); + stem = fp[1]; + re = new RegExp(s_v); + if (re.test(stem)) + w = stem + "i"; + } + + // Step 2 + re = /^(.+?)(ational|tional|enci|anci|izer|bli|alli|entli|eli|ousli|ization|ation|ator|alism|iveness|fulness|ousness|aliti|iviti|biliti|logi)$/; + if (re.test(w)) { + var fp = re.exec(w); + stem = fp[1]; + suffix = fp[2]; + re = new RegExp(mgr0); + if (re.test(stem)) + w = stem + step2list[suffix]; + } + + // Step 3 + re = /^(.+?)(icate|ative|alize|iciti|ical|ful|ness)$/; + if (re.test(w)) { + var fp = re.exec(w); + stem = fp[1]; + suffix = fp[2]; + re = new RegExp(mgr0); + if (re.test(stem)) + w = stem + step3list[suffix]; + } + + // Step 4 + re = /^(.+?)(al|ance|ence|er|ic|able|ible|ant|ement|ment|ent|ou|ism|ate|iti|ous|ive|ize)$/; + re2 = /^(.+?)(s|t)(ion)$/; + if (re.test(w)) { + var fp = re.exec(w); + stem = fp[1]; + re = new RegExp(mgr1); + if (re.test(stem)) + w = stem; + } + else if (re2.test(w)) { + var fp = re2.exec(w); + stem = fp[1] + fp[2]; + re2 = new RegExp(mgr1); + if (re2.test(stem)) + w = stem; + } + + // Step 5 + re = /^(.+?)e$/; + if (re.test(w)) { + var fp = re.exec(w); + stem = fp[1]; + re = new RegExp(mgr1); + re2 = new RegExp(meq1); + re3 = new RegExp("^" + C + v + "[^aeiouwxy]$"); + if (re.test(stem) || (re2.test(stem) && !(re3.test(stem)))) + w = stem; + } + re = /ll$/; + re2 = new RegExp(mgr1); + if (re.test(w) && re2.test(w)) { + re = /.$/; + w = w.replace(re,""); + } + + // and turn initial Y back to y + if (firstch == "y") + w = firstch.toLowerCase() + w.substr(1); + return w; + } +} + diff --git a/_static/minus.png b/_static/minus.png new file mode 100644 index 00000000..d96755fd Binary files /dev/null and b/_static/minus.png differ diff --git a/_static/plus.png b/_static/plus.png new file mode 100644 index 00000000..7107cec9 Binary files /dev/null and b/_static/plus.png differ diff --git a/_static/pygments.css b/_static/pygments.css new file mode 100644 index 00000000..84ab3030 --- /dev/null +++ b/_static/pygments.css @@ -0,0 +1,75 @@ +pre { line-height: 125%; } +td.linenos .normal { color: inherit; background-color: transparent; padding-left: 5px; padding-right: 5px; } +span.linenos { color: inherit; background-color: transparent; padding-left: 5px; padding-right: 5px; } +td.linenos .special { color: #000000; background-color: #ffffc0; padding-left: 5px; padding-right: 5px; } +span.linenos.special { color: #000000; background-color: #ffffc0; padding-left: 5px; padding-right: 5px; } +.highlight .hll { background-color: #ffffcc } +.highlight { background: #f8f8f8; } +.highlight .c { color: #3D7B7B; font-style: italic } /* Comment */ +.highlight .err { border: 1px solid #FF0000 } /* Error */ +.highlight .k { color: #008000; font-weight: bold } /* Keyword */ +.highlight .o { color: #666666 } /* Operator */ +.highlight .ch { color: #3D7B7B; font-style: italic } /* Comment.Hashbang */ +.highlight .cm { color: #3D7B7B; font-style: italic } /* Comment.Multiline */ +.highlight .cp { color: #9C6500 } /* Comment.Preproc */ +.highlight .cpf { color: #3D7B7B; font-style: italic } /* Comment.PreprocFile */ +.highlight .c1 { color: #3D7B7B; font-style: italic } /* Comment.Single */ +.highlight .cs { color: #3D7B7B; font-style: italic } /* Comment.Special */ +.highlight .gd { color: #A00000 } /* Generic.Deleted */ +.highlight .ge { font-style: italic } /* Generic.Emph */ +.highlight .ges { font-weight: bold; font-style: italic } /* Generic.EmphStrong */ +.highlight .gr { color: #E40000 } /* Generic.Error */ +.highlight .gh { color: #000080; font-weight: bold } /* Generic.Heading */ +.highlight .gi { color: #008400 } /* Generic.Inserted */ +.highlight .go { color: #717171 } /* Generic.Output */ +.highlight .gp { color: #000080; font-weight: bold } /* Generic.Prompt */ +.highlight .gs { font-weight: bold } /* Generic.Strong */ +.highlight .gu { color: #800080; font-weight: bold } /* Generic.Subheading */ +.highlight .gt { color: #0044DD } /* Generic.Traceback */ +.highlight .kc { color: #008000; font-weight: bold } /* Keyword.Constant */ +.highlight .kd { color: #008000; font-weight: bold } /* Keyword.Declaration */ +.highlight .kn { color: #008000; font-weight: bold } /* Keyword.Namespace */ +.highlight .kp { color: #008000 } /* Keyword.Pseudo */ +.highlight .kr { color: #008000; font-weight: bold } /* Keyword.Reserved */ +.highlight .kt { color: #B00040 } /* Keyword.Type */ +.highlight .m { color: #666666 } /* Literal.Number */ +.highlight .s { color: #BA2121 } /* Literal.String */ +.highlight .na { color: #687822 } /* Name.Attribute */ +.highlight .nb { color: #008000 } /* Name.Builtin */ +.highlight .nc { color: #0000FF; font-weight: bold } /* Name.Class */ +.highlight .no { color: #880000 } /* Name.Constant */ +.highlight .nd { color: #AA22FF } /* Name.Decorator */ +.highlight .ni { color: #717171; font-weight: bold } /* Name.Entity */ +.highlight .ne { color: #CB3F38; font-weight: bold } /* Name.Exception */ +.highlight .nf { color: #0000FF } /* Name.Function */ +.highlight .nl { color: #767600 } /* Name.Label */ +.highlight .nn { color: #0000FF; font-weight: bold } /* Name.Namespace */ +.highlight .nt { color: #008000; font-weight: bold } /* Name.Tag */ +.highlight .nv { color: #19177C } /* Name.Variable */ +.highlight .ow { color: #AA22FF; font-weight: bold } /* Operator.Word */ +.highlight .w { color: #bbbbbb } /* Text.Whitespace */ +.highlight .mb { color: #666666 } /* Literal.Number.Bin */ +.highlight .mf { color: #666666 } /* Literal.Number.Float */ +.highlight .mh { color: #666666 } /* Literal.Number.Hex */ +.highlight .mi { color: #666666 } /* Literal.Number.Integer */ +.highlight .mo { color: #666666 } /* Literal.Number.Oct */ +.highlight .sa { color: #BA2121 } /* Literal.String.Affix */ +.highlight .sb { color: #BA2121 } /* Literal.String.Backtick */ +.highlight .sc { color: #BA2121 } /* Literal.String.Char */ +.highlight .dl { color: #BA2121 } /* Literal.String.Delimiter */ +.highlight .sd { color: #BA2121; font-style: italic } /* Literal.String.Doc */ +.highlight .s2 { color: #BA2121 } /* Literal.String.Double */ +.highlight .se { color: #AA5D1F; font-weight: bold } /* Literal.String.Escape */ +.highlight .sh { color: #BA2121 } /* Literal.String.Heredoc */ +.highlight .si { color: #A45A77; font-weight: bold } /* Literal.String.Interpol */ +.highlight .sx { color: #008000 } /* Literal.String.Other */ +.highlight .sr { color: #A45A77 } /* Literal.String.Regex */ +.highlight .s1 { color: #BA2121 } /* Literal.String.Single */ +.highlight .ss { color: #19177C } /* Literal.String.Symbol */ +.highlight .bp { color: #008000 } /* Name.Builtin.Pseudo */ +.highlight .fm { color: #0000FF } /* Name.Function.Magic */ +.highlight .vc { color: #19177C } /* Name.Variable.Class */ +.highlight .vg { color: #19177C } /* Name.Variable.Global */ +.highlight .vi { color: #19177C } /* Name.Variable.Instance */ +.highlight .vm { color: #19177C } /* Name.Variable.Magic */ +.highlight .il { color: #666666 } /* Literal.Number.Integer.Long */ \ No newline at end of file diff --git a/_static/searchtools.js b/_static/searchtools.js new file mode 100644 index 00000000..92da3f8b --- /dev/null +++ b/_static/searchtools.js @@ -0,0 +1,619 @@ +/* + * searchtools.js + * ~~~~~~~~~~~~~~~~ + * + * Sphinx JavaScript utilities for the full-text search. + * + * :copyright: Copyright 2007-2024 by the Sphinx team, see AUTHORS. + * :license: BSD, see LICENSE for details. + * + */ +"use strict"; + +/** + * Simple result scoring code. + */ +if (typeof Scorer === "undefined") { + var Scorer = { + // Implement the following function to further tweak the score for each result + // The function takes a result array [docname, title, anchor, descr, score, filename] + // and returns the new score. + /* + score: result => { + const [docname, title, anchor, descr, score, filename] = result + return score + }, + */ + + // query matches the full name of an object + objNameMatch: 11, + // or matches in the last dotted part of the object name + objPartialMatch: 6, + // Additive scores depending on the priority of the object + objPrio: { + 0: 15, // used to be importantResults + 1: 5, // used to be objectResults + 2: -5, // used to be unimportantResults + }, + // Used when the priority is not in the mapping. + objPrioDefault: 0, + + // query found in title + title: 15, + partialTitle: 7, + // query found in terms + term: 5, + partialTerm: 2, + }; +} + +const _removeChildren = (element) => { + while (element && element.lastChild) element.removeChild(element.lastChild); +}; + +/** + * See https://developer.mozilla.org/en-US/docs/Web/JavaScript/Guide/Regular_Expressions#escaping + */ +const _escapeRegExp = (string) => + string.replace(/[.*+\-?^${}()|[\]\\]/g, "\\$&"); // $& means the whole matched string + +const _displayItem = (item, searchTerms, highlightTerms) => { + const docBuilder = DOCUMENTATION_OPTIONS.BUILDER; + const docFileSuffix = DOCUMENTATION_OPTIONS.FILE_SUFFIX; + const docLinkSuffix = DOCUMENTATION_OPTIONS.LINK_SUFFIX; + const showSearchSummary = DOCUMENTATION_OPTIONS.SHOW_SEARCH_SUMMARY; + const contentRoot = document.documentElement.dataset.content_root; + + const [docName, title, anchor, descr, score, _filename] = item; + + let listItem = document.createElement("li"); + let requestUrl; + let linkUrl; + if (docBuilder === "dirhtml") { + // dirhtml builder + let dirname = docName + "/"; + if (dirname.match(/\/index\/$/)) + dirname = dirname.substring(0, dirname.length - 6); + else if (dirname === "index/") dirname = ""; + requestUrl = contentRoot + dirname; + linkUrl = requestUrl; + } else { + // normal html builders + requestUrl = contentRoot + docName + docFileSuffix; + linkUrl = docName + docLinkSuffix; + } + let linkEl = listItem.appendChild(document.createElement("a")); + linkEl.href = linkUrl + anchor; + linkEl.dataset.score = score; + linkEl.innerHTML = title; + if (descr) { + listItem.appendChild(document.createElement("span")).innerHTML = + " (" + descr + ")"; + // highlight search terms in the description + if (SPHINX_HIGHLIGHT_ENABLED) // set in sphinx_highlight.js + highlightTerms.forEach((term) => _highlightText(listItem, term, "highlighted")); + } + else if (showSearchSummary) + fetch(requestUrl) + .then((responseData) => responseData.text()) + .then((data) => { + if (data) + listItem.appendChild( + Search.makeSearchSummary(data, searchTerms, anchor) + ); + // highlight search terms in the summary + if (SPHINX_HIGHLIGHT_ENABLED) // set in sphinx_highlight.js + highlightTerms.forEach((term) => _highlightText(listItem, term, "highlighted")); + }); + Search.output.appendChild(listItem); +}; +const _finishSearch = (resultCount) => { + Search.stopPulse(); + Search.title.innerText = _("Search Results"); + if (!resultCount) + Search.status.innerText = Documentation.gettext( + "Your search did not match any documents. Please make sure that all words are spelled correctly and that you've selected enough categories." + ); + else + Search.status.innerText = _( + "Search finished, found ${resultCount} page(s) matching the search query." + ).replace('${resultCount}', resultCount); +}; +const _displayNextItem = ( + results, + resultCount, + searchTerms, + highlightTerms, +) => { + // results left, load the summary and display it + // this is intended to be dynamic (don't sub resultsCount) + if (results.length) { + _displayItem(results.pop(), searchTerms, highlightTerms); + setTimeout( + () => _displayNextItem(results, resultCount, searchTerms, highlightTerms), + 5 + ); + } + // search finished, update title and status message + else _finishSearch(resultCount); +}; +// Helper function used by query() to order search results. +// Each input is an array of [docname, title, anchor, descr, score, filename]. +// Order the results by score (in opposite order of appearance, since the +// `_displayNextItem` function uses pop() to retrieve items) and then alphabetically. +const _orderResultsByScoreThenName = (a, b) => { + const leftScore = a[4]; + const rightScore = b[4]; + if (leftScore === rightScore) { + // same score: sort alphabetically + const leftTitle = a[1].toLowerCase(); + const rightTitle = b[1].toLowerCase(); + if (leftTitle === rightTitle) return 0; + return leftTitle > rightTitle ? -1 : 1; // inverted is intentional + } + return leftScore > rightScore ? 1 : -1; +}; + +/** + * Default splitQuery function. Can be overridden in ``sphinx.search`` with a + * custom function per language. + * + * The regular expression works by splitting the string on consecutive characters + * that are not Unicode letters, numbers, underscores, or emoji characters. + * This is the same as ``\W+`` in Python, preserving the surrogate pair area. + */ +if (typeof splitQuery === "undefined") { + var splitQuery = (query) => query + .split(/[^\p{Letter}\p{Number}_\p{Emoji_Presentation}]+/gu) + .filter(term => term) // remove remaining empty strings +} + +/** + * Search Module + */ +const Search = { + _index: null, + _queued_query: null, + _pulse_status: -1, + + htmlToText: (htmlString, anchor) => { + const htmlElement = new DOMParser().parseFromString(htmlString, 'text/html'); + for (const removalQuery of [".headerlinks", "script", "style"]) { + htmlElement.querySelectorAll(removalQuery).forEach((el) => { el.remove() }); + } + if (anchor) { + const anchorContent = htmlElement.querySelector(`[role="main"] ${anchor}`); + if (anchorContent) return anchorContent.textContent; + + console.warn( + `Anchored content block not found. Sphinx search tries to obtain it via DOM query '[role=main] ${anchor}'. Check your theme or template.` + ); + } + + // if anchor not specified or not found, fall back to main content + const docContent = htmlElement.querySelector('[role="main"]'); + if (docContent) return docContent.textContent; + + console.warn( + "Content block not found. Sphinx search tries to obtain it via DOM query '[role=main]'. Check your theme or template." + ); + return ""; + }, + + init: () => { + const query = new URLSearchParams(window.location.search).get("q"); + document + .querySelectorAll('input[name="q"]') + .forEach((el) => (el.value = query)); + if (query) Search.performSearch(query); + }, + + loadIndex: (url) => + (document.body.appendChild(document.createElement("script")).src = url), + + setIndex: (index) => { + Search._index = index; + if (Search._queued_query !== null) { + const query = Search._queued_query; + Search._queued_query = null; + Search.query(query); + } + }, + + hasIndex: () => Search._index !== null, + + deferQuery: (query) => (Search._queued_query = query), + + stopPulse: () => (Search._pulse_status = -1), + + startPulse: () => { + if (Search._pulse_status >= 0) return; + + const pulse = () => { + Search._pulse_status = (Search._pulse_status + 1) % 4; + Search.dots.innerText = ".".repeat(Search._pulse_status); + if (Search._pulse_status >= 0) window.setTimeout(pulse, 500); + }; + pulse(); + }, + + /** + * perform a search for something (or wait until index is loaded) + */ + performSearch: (query) => { + // create the required interface elements + const searchText = document.createElement("h2"); + searchText.textContent = _("Searching"); + const searchSummary = document.createElement("p"); + searchSummary.classList.add("search-summary"); + searchSummary.innerText = ""; + const searchList = document.createElement("ul"); + searchList.classList.add("search"); + + const out = document.getElementById("search-results"); + Search.title = out.appendChild(searchText); + Search.dots = Search.title.appendChild(document.createElement("span")); + Search.status = out.appendChild(searchSummary); + Search.output = out.appendChild(searchList); + + const searchProgress = document.getElementById("search-progress"); + // Some themes don't use the search progress node + if (searchProgress) { + searchProgress.innerText = _("Preparing search..."); + } + Search.startPulse(); + + // index already loaded, the browser was quick! + if (Search.hasIndex()) Search.query(query); + else Search.deferQuery(query); + }, + + _parseQuery: (query) => { + // stem the search terms and add them to the correct list + const stemmer = new Stemmer(); + const searchTerms = new Set(); + const excludedTerms = new Set(); + const highlightTerms = new Set(); + const objectTerms = new Set(splitQuery(query.toLowerCase().trim())); + splitQuery(query.trim()).forEach((queryTerm) => { + const queryTermLower = queryTerm.toLowerCase(); + + // maybe skip this "word" + // stopwords array is from language_data.js + if ( + stopwords.indexOf(queryTermLower) !== -1 || + queryTerm.match(/^\d+$/) + ) + return; + + // stem the word + let word = stemmer.stemWord(queryTermLower); + // select the correct list + if (word[0] === "-") excludedTerms.add(word.substr(1)); + else { + searchTerms.add(word); + highlightTerms.add(queryTermLower); + } + }); + + if (SPHINX_HIGHLIGHT_ENABLED) { // set in sphinx_highlight.js + localStorage.setItem("sphinx_highlight_terms", [...highlightTerms].join(" ")) + } + + // console.debug("SEARCH: searching for:"); + // console.info("required: ", [...searchTerms]); + // console.info("excluded: ", [...excludedTerms]); + + return [query, searchTerms, excludedTerms, highlightTerms, objectTerms]; + }, + + /** + * execute search (requires search index to be loaded) + */ + _performSearch: (query, searchTerms, excludedTerms, highlightTerms, objectTerms) => { + const filenames = Search._index.filenames; + const docNames = Search._index.docnames; + const titles = Search._index.titles; + const allTitles = Search._index.alltitles; + const indexEntries = Search._index.indexentries; + + // Collect multiple result groups to be sorted separately and then ordered. + // Each is an array of [docname, title, anchor, descr, score, filename]. + const normalResults = []; + const nonMainIndexResults = []; + + _removeChildren(document.getElementById("search-progress")); + + const queryLower = query.toLowerCase().trim(); + for (const [title, foundTitles] of Object.entries(allTitles)) { + if (title.toLowerCase().trim().includes(queryLower) && (queryLower.length >= title.length/2)) { + for (const [file, id] of foundTitles) { + let score = Math.round(100 * queryLower.length / title.length) + normalResults.push([ + docNames[file], + titles[file] !== title ? `${titles[file]} > ${title}` : title, + id !== null ? "#" + id : "", + null, + score, + filenames[file], + ]); + } + } + } + + // search for explicit entries in index directives + for (const [entry, foundEntries] of Object.entries(indexEntries)) { + if (entry.includes(queryLower) && (queryLower.length >= entry.length/2)) { + for (const [file, id, isMain] of foundEntries) { + const score = Math.round(100 * queryLower.length / entry.length); + const result = [ + docNames[file], + titles[file], + id ? "#" + id : "", + null, + score, + filenames[file], + ]; + if (isMain) { + normalResults.push(result); + } else { + nonMainIndexResults.push(result); + } + } + } + } + + // lookup as object + objectTerms.forEach((term) => + normalResults.push(...Search.performObjectSearch(term, objectTerms)) + ); + + // lookup as search terms in fulltext + normalResults.push(...Search.performTermsSearch(searchTerms, excludedTerms)); + + // let the scorer override scores with a custom scoring function + if (Scorer.score) { + normalResults.forEach((item) => (item[4] = Scorer.score(item))); + nonMainIndexResults.forEach((item) => (item[4] = Scorer.score(item))); + } + + // Sort each group of results by score and then alphabetically by name. + normalResults.sort(_orderResultsByScoreThenName); + nonMainIndexResults.sort(_orderResultsByScoreThenName); + + // Combine the result groups in (reverse) order. + // Non-main index entries are typically arbitrary cross-references, + // so display them after other results. + let results = [...nonMainIndexResults, ...normalResults]; + + // remove duplicate search results + // note the reversing of results, so that in the case of duplicates, the highest-scoring entry is kept + let seen = new Set(); + results = results.reverse().reduce((acc, result) => { + let resultStr = result.slice(0, 4).concat([result[5]]).map(v => String(v)).join(','); + if (!seen.has(resultStr)) { + acc.push(result); + seen.add(resultStr); + } + return acc; + }, []); + + return results.reverse(); + }, + + query: (query) => { + const [searchQuery, searchTerms, excludedTerms, highlightTerms, objectTerms] = Search._parseQuery(query); + const results = Search._performSearch(searchQuery, searchTerms, excludedTerms, highlightTerms, objectTerms); + + // for debugging + //Search.lastresults = results.slice(); // a copy + // console.info("search results:", Search.lastresults); + + // print the results + _displayNextItem(results, results.length, searchTerms, highlightTerms); + }, + + /** + * search for object names + */ + performObjectSearch: (object, objectTerms) => { + const filenames = Search._index.filenames; + const docNames = Search._index.docnames; + const objects = Search._index.objects; + const objNames = Search._index.objnames; + const titles = Search._index.titles; + + const results = []; + + const objectSearchCallback = (prefix, match) => { + const name = match[4] + const fullname = (prefix ? prefix + "." : "") + name; + const fullnameLower = fullname.toLowerCase(); + if (fullnameLower.indexOf(object) < 0) return; + + let score = 0; + const parts = fullnameLower.split("."); + + // check for different match types: exact matches of full name or + // "last name" (i.e. last dotted part) + if (fullnameLower === object || parts.slice(-1)[0] === object) + score += Scorer.objNameMatch; + else if (parts.slice(-1)[0].indexOf(object) > -1) + score += Scorer.objPartialMatch; // matches in last name + + const objName = objNames[match[1]][2]; + const title = titles[match[0]]; + + // If more than one term searched for, we require other words to be + // found in the name/title/description + const otherTerms = new Set(objectTerms); + otherTerms.delete(object); + if (otherTerms.size > 0) { + const haystack = `${prefix} ${name} ${objName} ${title}`.toLowerCase(); + if ( + [...otherTerms].some((otherTerm) => haystack.indexOf(otherTerm) < 0) + ) + return; + } + + let anchor = match[3]; + if (anchor === "") anchor = fullname; + else if (anchor === "-") anchor = objNames[match[1]][1] + "-" + fullname; + + const descr = objName + _(", in ") + title; + + // add custom score for some objects according to scorer + if (Scorer.objPrio.hasOwnProperty(match[2])) + score += Scorer.objPrio[match[2]]; + else score += Scorer.objPrioDefault; + + results.push([ + docNames[match[0]], + fullname, + "#" + anchor, + descr, + score, + filenames[match[0]], + ]); + }; + Object.keys(objects).forEach((prefix) => + objects[prefix].forEach((array) => + objectSearchCallback(prefix, array) + ) + ); + return results; + }, + + /** + * search for full-text terms in the index + */ + performTermsSearch: (searchTerms, excludedTerms) => { + // prepare search + const terms = Search._index.terms; + const titleTerms = Search._index.titleterms; + const filenames = Search._index.filenames; + const docNames = Search._index.docnames; + const titles = Search._index.titles; + + const scoreMap = new Map(); + const fileMap = new Map(); + + // perform the search on the required terms + searchTerms.forEach((word) => { + const files = []; + const arr = [ + { files: terms[word], score: Scorer.term }, + { files: titleTerms[word], score: Scorer.title }, + ]; + // add support for partial matches + if (word.length > 2) { + const escapedWord = _escapeRegExp(word); + if (!terms.hasOwnProperty(word)) { + Object.keys(terms).forEach((term) => { + if (term.match(escapedWord)) + arr.push({ files: terms[term], score: Scorer.partialTerm }); + }); + } + if (!titleTerms.hasOwnProperty(word)) { + Object.keys(titleTerms).forEach((term) => { + if (term.match(escapedWord)) + arr.push({ files: titleTerms[term], score: Scorer.partialTitle }); + }); + } + } + + // no match but word was a required one + if (arr.every((record) => record.files === undefined)) return; + + // found search word in contents + arr.forEach((record) => { + if (record.files === undefined) return; + + let recordFiles = record.files; + if (recordFiles.length === undefined) recordFiles = [recordFiles]; + files.push(...recordFiles); + + // set score for the word in each file + recordFiles.forEach((file) => { + if (!scoreMap.has(file)) scoreMap.set(file, {}); + scoreMap.get(file)[word] = record.score; + }); + }); + + // create the mapping + files.forEach((file) => { + if (!fileMap.has(file)) fileMap.set(file, [word]); + else if (fileMap.get(file).indexOf(word) === -1) fileMap.get(file).push(word); + }); + }); + + // now check if the files don't contain excluded terms + const results = []; + for (const [file, wordList] of fileMap) { + // check if all requirements are matched + + // as search terms with length < 3 are discarded + const filteredTermCount = [...searchTerms].filter( + (term) => term.length > 2 + ).length; + if ( + wordList.length !== searchTerms.size && + wordList.length !== filteredTermCount + ) + continue; + + // ensure that none of the excluded terms is in the search result + if ( + [...excludedTerms].some( + (term) => + terms[term] === file || + titleTerms[term] === file || + (terms[term] || []).includes(file) || + (titleTerms[term] || []).includes(file) + ) + ) + break; + + // select one (max) score for the file. + const score = Math.max(...wordList.map((w) => scoreMap.get(file)[w])); + // add result to the result list + results.push([ + docNames[file], + titles[file], + "", + null, + score, + filenames[file], + ]); + } + return results; + }, + + /** + * helper function to return a node containing the + * search summary for a given text. keywords is a list + * of stemmed words. + */ + makeSearchSummary: (htmlText, keywords, anchor) => { + const text = Search.htmlToText(htmlText, anchor); + if (text === "") return null; + + const textLower = text.toLowerCase(); + const actualStartPosition = [...keywords] + .map((k) => textLower.indexOf(k.toLowerCase())) + .filter((i) => i > -1) + .slice(-1)[0]; + const startWithContext = Math.max(actualStartPosition - 120, 0); + + const top = startWithContext === 0 ? "" : "..."; + const tail = startWithContext + 240 < text.length ? "..." : ""; + + let summary = document.createElement("p"); + summary.classList.add("context"); + summary.textContent = top + text.substr(startWithContext, 240).trim() + tail; + + return summary; + }, +}; + +_ready(Search.init); diff --git a/_static/sphinx_highlight.js b/_static/sphinx_highlight.js new file mode 100644 index 00000000..8a96c69a --- /dev/null +++ b/_static/sphinx_highlight.js @@ -0,0 +1,154 @@ +/* Highlighting utilities for Sphinx HTML documentation. */ +"use strict"; + +const SPHINX_HIGHLIGHT_ENABLED = true + +/** + * highlight a given string on a node by wrapping it in + * span elements with the given class name. + */ +const _highlight = (node, addItems, text, className) => { + if (node.nodeType === Node.TEXT_NODE) { + const val = node.nodeValue; + const parent = node.parentNode; + const pos = val.toLowerCase().indexOf(text); + if ( + pos >= 0 && + !parent.classList.contains(className) && + !parent.classList.contains("nohighlight") + ) { + let span; + + const closestNode = parent.closest("body, svg, foreignObject"); + const isInSVG = closestNode && closestNode.matches("svg"); + if (isInSVG) { + span = document.createElementNS("http://www.w3.org/2000/svg", "tspan"); + } else { + span = document.createElement("span"); + span.classList.add(className); + } + + span.appendChild(document.createTextNode(val.substr(pos, text.length))); + const rest = document.createTextNode(val.substr(pos + text.length)); + parent.insertBefore( + span, + parent.insertBefore( + rest, + node.nextSibling + ) + ); + node.nodeValue = val.substr(0, pos); + /* There may be more occurrences of search term in this node. So call this + * function recursively on the remaining fragment. + */ + _highlight(rest, addItems, text, className); + + if (isInSVG) { + const rect = document.createElementNS( + "http://www.w3.org/2000/svg", + "rect" + ); + const bbox = parent.getBBox(); + rect.x.baseVal.value = bbox.x; + rect.y.baseVal.value = bbox.y; + rect.width.baseVal.value = bbox.width; + rect.height.baseVal.value = bbox.height; + rect.setAttribute("class", className); + addItems.push({ parent: parent, target: rect }); + } + } + } else if (node.matches && !node.matches("button, select, textarea")) { + node.childNodes.forEach((el) => _highlight(el, addItems, text, className)); + } +}; +const _highlightText = (thisNode, text, className) => { + let addItems = []; + _highlight(thisNode, addItems, text, className); + addItems.forEach((obj) => + obj.parent.insertAdjacentElement("beforebegin", obj.target) + ); +}; + +/** + * Small JavaScript module for the documentation. + */ +const SphinxHighlight = { + + /** + * highlight the search words provided in localstorage in the text + */ + highlightSearchWords: () => { + if (!SPHINX_HIGHLIGHT_ENABLED) return; // bail if no highlight + + // get and clear terms from localstorage + const url = new URL(window.location); + const highlight = + localStorage.getItem("sphinx_highlight_terms") + || url.searchParams.get("highlight") + || ""; + localStorage.removeItem("sphinx_highlight_terms") + url.searchParams.delete("highlight"); + window.history.replaceState({}, "", url); + + // get individual terms from highlight string + const terms = highlight.toLowerCase().split(/\s+/).filter(x => x); + if (terms.length === 0) return; // nothing to do + + // There should never be more than one element matching "div.body" + const divBody = document.querySelectorAll("div.body"); + const body = divBody.length ? divBody[0] : document.querySelector("body"); + window.setTimeout(() => { + terms.forEach((term) => _highlightText(body, term, "highlighted")); + }, 10); + + const searchBox = document.getElementById("searchbox"); + if (searchBox === null) return; + searchBox.appendChild( + document + .createRange() + .createContextualFragment( + '" + ) + ); + }, + + /** + * helper function to hide the search marks again + */ + hideSearchWords: () => { + document + .querySelectorAll("#searchbox .highlight-link") + .forEach((el) => el.remove()); + document + .querySelectorAll("span.highlighted") + .forEach((el) => el.classList.remove("highlighted")); + localStorage.removeItem("sphinx_highlight_terms") + }, + + initEscapeListener: () => { + // only install a listener if it is really needed + if (!DOCUMENTATION_OPTIONS.ENABLE_SEARCH_SHORTCUTS) return; + + document.addEventListener("keydown", (event) => { + // bail for input elements + if (BLACKLISTED_KEY_CONTROL_ELEMENTS.has(document.activeElement.tagName)) return; + // bail with special keys + if (event.shiftKey || event.altKey || event.ctrlKey || event.metaKey) return; + if (DOCUMENTATION_OPTIONS.ENABLE_SEARCH_SHORTCUTS && (event.key === "Escape")) { + SphinxHighlight.hideSearchWords(); + event.preventDefault(); + } + }); + }, +}; + +_ready(() => { + /* Do not call highlightSearchWords() when we are on the search page. + * It will highlight words from the *previous* search query. + */ + if (typeof Search === "undefined") SphinxHighlight.highlightSearchWords(); + SphinxHighlight.initEscapeListener(); +}); diff --git a/api_reference.html b/api_reference.html new file mode 100644 index 00000000..62225607 --- /dev/null +++ b/api_reference.html @@ -0,0 +1,1086 @@ + + + + + + + API Reference — note-c documentation + + + + + + + + + + + + + + + + + + +
+ + +
+ +
+
+
+ +
+
+
+
+ +
+

API Reference

+ +

These pages cover the core functions and types that make up the note-c API.

+
+

Dynamic Memory and Timing Hooks

+
+

Functions

+
+
+void NoteSetFn(mallocFn mallocHook, freeFn freeHook, delayMsFn delayMsHook, getMsFn getMsHook)
+

Set the platform-specific memory and timing hooks.

+
+
Parameters:
+
    +
  • mallocHook – The platform-specific memory allocation function (i.e. malloc).

  • +
  • freeHook – The platform-specific memory free function (i.e. free).

  • +
  • delayMsHook – The platform-specific millisecond delay function.

  • +
  • getMsHook – The platform-specific millisecond counter function.

  • +
+
+
+
+ +
+
+

Types

+
+
+typedef void *(*mallocFn)(size_t size)
+

The type for the memory allocation hook.

+
+
Param size:
+

The number of bytes to allocate.

+
+
Return:
+

A pointer to the newly allocated memory or NULL on failure.

+
+
+
+ +
+
+typedef void (*freeFn)(void *mem)
+

The type for the memory freeing hook.

+
+
Param mem:
+

Pointer to the memory to free.

+
+
+
+ +
+
+typedef void (*delayMsFn)(uint32_t ms)
+

The type for the millisecond delay hook.

+
+
Param ms:
+

The number of milliseconds to delay for.

+
+
+
+ +
+
+typedef uint32_t (*getMsFn)(void)
+

The type for the millisecond counter hook.

+
+
Return:
+

The value of the millisecond counter.

+
+
+
+ +
+
+
+

I/O Hooks

+
+

Serial Hooks

+
+

Functions

+
+
+void NoteSetFnSerial(serialResetFn resetFn, serialTransmitFn transmitFn, serialAvailableFn availFn, serialReceiveFn receiveFn)
+

Set the platform-specific hooks for communicating with the Notecard over serial.

+
+
Parameters:
+
    +
  • resetFn – The platform-specific serial reset function.

  • +
  • transmitFn – The platform-specific serial transmit function.

  • +
  • availFn – The platform-specific serial available function.

  • +
  • receiveFn – The platform-specific serial receive function.

  • +
+
+
+
+ +
+
+

Types

+
+
+typedef bool (*serialResetFn)(void)
+

The type for the serial reset hook.

+

This hook is used to reset the serial peripheral used to communicate with the Notecard.

+
+
Return:
+

true on success and false on failure.

+
+
+
+ +
+
+typedef void (*serialTransmitFn)(uint8_t *txBuf, size_t txBufSize, bool flush)
+

The type for the serial transmit hook.

+
+
Param txBuf:
+

A buffer of bytes to transmit to the Notecard.

+
+
Param txBufSize:
+

The size, in bytes, of txBuf.

+
+
Param flush:
+

If true, flush the serial peripheral’s transmit buffer.

+
+
+
+ +
+
+typedef bool (*serialAvailableFn)(void)
+

The type for the serial available hook.

+
+
Return:
+

true if there’s data to read and false otherwise.

+
+
+
+ +
+
+typedef char (*serialReceiveFn)(void)
+

The type for the serial receive hook.

+
+
Return:
+

The received byte.

+
+
+
+ +
+
+
+

I2C

+
+

Functions

+
+
+void NoteSetFnI2C(uint32_t notecardAddr, uint32_t maxTransmitSize, i2cResetFn resetFn, i2cTransmitFn transmitFn, i2cReceiveFn receiveFn)
+

Set the platform-specific hooks for communicating with the Notecard over I2C, as well as the I2C address of the Notecard and maximum transmission size.

+
+
Parameters:
+
    +
  • notecardAddr – The I2C address of the Notecard. Pass 0 to use the default address.

  • +
  • maxTransmitSize – The max number of bytes to send to the Notecard in a single I2C segment. Pass 0 to use the default maximum transmission size.

  • +
  • resetFn – The platform-specific I2C reset function.

  • +
  • transmitFn – The platform-specific I2C transmit function.

  • +
  • receiveFn – The platform-specific I2C receive function.

  • +
+
+
+
+ +
+
+

Types

+
+
+typedef bool (*i2cResetFn)(uint16_t address)
+

The type for the I2C reset hook.

+

This hook is used to reset the I2C peripheral used to communicate with the Notecard.

+
+
Param address:
+

The I2C address of the Notecard.

+
+
+
+ +
+
+typedef const char *(*i2cTransmitFn)(uint16_t address, uint8_t *txBuf, uint16_t txBufSize)
+

The type for the I2C transmit hook.

+

This hook is used to send a buffer of bytes to the Notecard.

+
+
Param address:
+

The I2C address of the Notecard to transmit the data to.

+
+
Param txBuf:
+

A buffer of bytes to transmit to the Notecard.

+
+
Param txBufSize:
+

The size, in bytes, of txBuf.

+
+
Return:
+

NULL on success and an error string on failure.

+
+
+
+ +
+
+typedef const char *(*i2cReceiveFn)(uint16_t address, uint8_t *rxBuf, uint16_t rxBufSize, uint32_t *available)
+

The type for the I2C receive hook.

+

This hook is used to receive a buffer of bytes from the Notecard.

+
+
Param address:
+

The I2C address of the Notecard sending the data to receive.

+
+
Param rxBuf:
+

A buffer to hold the data received from the Notecard.

+
+
Param rxBufSize:
+

The size, in bytes, of rxBuf.

+
+
Param available:
+

The number of bytes remaining to be received, if any.

+
+
Return:
+

NULL on success and an error string on failure.

+
+
+
+ +
+
+

Macros

+
+
+NOTE_I2C_ADDR_DEFAULT
+

The default I2C address of the Notecard.

+
+ +
+
+NOTE_I2C_MAX_DEFAULT
+

The maximum number of bytes to request from or transmit to the Notecard in a single chunk.

+
+ +
+
+
+
+

Mutex Hooks

+
+

Notecard Mutex

+
+

Functions

+
+
+void NoteSetFnNoteMutex(mutexFn lockFn, mutexFn unlockFn)
+

Set the platform-specific mutex functions for the Notecard.

+
+
Parameters:
+
    +
  • lockFn – The platform-specific Notecard lock function.

  • +
  • unlockFn – The platform-specific Notecard unlock function.

  • +
+
+
+
+ +
+
+

Types

+
+
+typedef void (*mutexFn)(void)
+

The type for the various mutex (i.e. lock/unlock) hooks.

+
+ +
+
+
+

I2C Mutex

+
+

Functions

+
+
+void NoteSetFnI2CMutex(mutexFn lockI2Cfn, mutexFn unlockI2Cfn)
+

Set the platform-specific mutex functions for I2C.

+
+
Parameters:
+
    +
  • lockI2Cfn – The platform-specific I2C lock function.

  • +
  • unlockI2Cfn – The platform-specific I2C unlock function.

  • +
+
+
+
+ +
+
+

Types

+

See mutexFn.

+
+
+
+
+

Notecard API Calls

+
+

Functions

+
+
+J *NoteNewRequest(const char *request)
+

Create a new JSON request.

+

Creates a dynamically allocated J object with one field "req" whose value is the passed in request string.

+
+
Parameters:
+
    +
  • request – The name of the request, for example hub.set.

  • +
+
+
Returns:
+

A J object with the “req” field populated.

+
+
+
+ +
+
+J *NoteRequestResponse(J *req)
+

Send a request to the Notecard and return the response.

+

The passed in request object is always freed, regardless of if the request was successful or not.

+

+

See also

+

NoteResponseError to check the response for errors.

+
+

+
+
Parameters:
+
    +
  • req – Pointer to a J request object.

  • +
+
+
Returns:
+

A J object with the response or NULL if there was an error sending the request.

+
+
+
+ +
+
+J *NoteRequestResponseWithRetry(J *req, uint32_t timeoutSeconds)
+

Send a request to the Notecard, retrying it until it succeeds or it times out, and return the response.

+

The passed in request object is always freed, regardless of if the request was successful or not.

+

+

See also

+

NoteResponseError to check the response for errors.

+
+

+
+
Parameters:
+
    +
  • req – Pointer to a J request object.

  • +
  • timeoutSeconds – Time limit for retires, in seconds, if there is no response, or if the response contains an I/O error.

  • +
+
+
Returns:
+

A J object with the response or NULL if there was an error sending the request.

+
+
+
+ +
+
+bool NoteRequest(J *req)
+

Send a request to the Notecard.

+

The passed in request object is always freed, regardless of if the request was successful or not. The response from the Notecard, if any, is freed and not returned to the caller.

+

+

See also

+

NoteRequestResponse if you need to work with the response.

+
+

+
+
Parameters:
+
    +
  • req – Pointer to a J request object.

  • +
+
+
Returns:
+

true if successful and false if an error occurs (e.g. out of memory or the response from the Notecard has an “err” field). If req is a command rather than a request, a true return value indicates that the command was sent without error. However, since the Notecard sends no response to commands, it does not guarantee that the command was received and processed by the Notecard.

+
+
+
+ +
+
+bool NoteRequestWithRetry(J *req, uint32_t timeoutSeconds)
+

Send a request to the Notecard, retrying it until it succeeds or it times out.

+

The passed in request object is always freed, regardless of if the request was successful or not. The response from the Notecard, if any, is freed and not returned to the caller.

+

+

See also

+

NoteRequestResponseWithRetry if you need to work with the response.

+
+

+
+
Parameters:
+
    +
  • req – Pointer to a J request object.

  • +
  • timeoutSeconds – Time limit for retires, in seconds, if there is no response, or if the response contains an I/O error.

  • +
+
+
Returns:
+

true if successful and false if an error occurs (e.g. out of memory or the response from the Notecard has an “err” field).

+
+
+
+ +
+
+NoteResponseError(rsp)
+

Check if the Notecard response contains an error.

+
+
Parameters:
+
    +
  • rsp – The response to check.

  • +
+
+
Returns:
+

true if there’s an error and false if there’s not.

+
+
+
+ +
+
+NoteDeleteResponse(rsp)
+

Free a response from the Notecard.

+
+
Parameters:
+
    +
  • rsp – The response to free.

  • +
+
+
+
+ +
+
+char *NoteRequestResponseJSON(const char *reqJSON)
+

Send a request to the Notecard and return the response.

+

Unlike NoteRequestResponse, this function expects the request to be a valid JSON C-string, rather than a J object. The string is expected to be newline-terminated, otherwise the call produces undefined behavior. The response is returned as a dynamically allocated JSON C-string. The response string is verbatim what was sent by the Notecard, which IS newline-terminated. The caller is responsible for freeing the response string. If the request was a command (i.e. it uses “cmd” instead of “req”), this function returns NULL, because the Notecard does not send a response to commands.

+
+

Note

+

When a “cmd” is sent, it is not possible to determine if an error occurred.

+
+
+
Parameters:
+
    +
  • reqJSON – A valid newline-terminated JSON C-string containing the request.

  • +
+
+
Returns:
+

A newline-terminated JSON C-string with the response, or NULL if there was no response or if there was an error.

+
+
+
+ +
+
+
+

JSON Manipulation

+
+

Functions

+
+
+bool JAddBinaryToObject(J *json, const char *fieldName, const void *binaryData, uint32_t binaryDataLen)
+

Add binary data as a Base64-encoded string field to a JSON object.

+
+
Parameters:
+
    +
  • json – The JSON object.

  • +
  • fieldName – The name to use for the field.

  • +
  • binaryData – A buffer of binary data to encode.

  • +
  • binaryDataLen – The length of the binary data in bytes.

  • +
+
+
Returns:
+

True if the string was successfully encoded and added to the object, otherwise false.

+
+
+
+ +
+
+J *JAddBoolToObject(J *const object, const char *const name, const Jbool boolean)
+

Add a boolean field to a J object.

+
+
Parameters:
+
    +
  • object – The object to add the field to.

  • +
  • name – The name of the field.

  • +
  • boolean – The value of the field.

  • +
+
+
Returns:
+

A pointer to the newly-added boolean field or NULL on error.

+
+
+
+ +
+
+J *JAddNumberToObject(J *const object, const char *const name, const JNUMBER number)
+

Add a number field to a J object.

+
+
Parameters:
+
    +
  • object – The object to add the field to.

  • +
  • name – The name of the field.

  • +
  • number – The value of the field.

  • +
+
+
Returns:
+

A pointer to the newly-added number field or NULL on error.

+
+
+
+ +
+
+J *JAddStringToObject(J *const object, const char *const name, const char *const string)
+

Add a string field to a J object.

+
+
Parameters:
+
    +
  • object – The object to add the field to.

  • +
  • name – The name of the field.

  • +
  • string – The value of the field.

  • +
+
+
Returns:
+

A pointer to the newly-added string field or NULL on error.

+
+
+
+ +
+
+J *JAddObjectToObject(J *const object, const char *const name)
+

Add an object field to another J object.

+
+
Parameters:
+
    +
  • object – The object to add the field to.

  • +
  • name – The name of the field.

  • +
+
+
Returns:
+

A pointer to the newly-added object field or NULL on error.

+
+
+
+ +
+
+J *JAddArrayToObject(J *const object, const char *const name)
+

Add an array field to a J object.

+
+
Parameters:
+
    +
  • object – The object to add the field to.

  • +
  • name – The name of the field.

  • +
+
+
Returns:
+

A pointer to the newly-added array field or NULL on error.

+
+
+
+ +
+
+J *JCreateObject(void)
+

Create a new J object.

+

To free the object, use JDelete.

+
+
Returns:
+

A pointer to the newly-created object.

+
+
+
+ +
+
+void JDelete(J *c)
+

Free a J object.

+
+
Parameters:
+
    +
  • item – A pointer to the object.

  • +
+
+
+
+ +
+
+void JFree(void *object)
+

Free a block of dynamically allocated memory.

+

This is simply a wrapper around the memory free function provided by the user via NoteSetFn.

+
+
Parameters:
+
    +
  • p – A pointer to the block of memory to free.

  • +
+
+
+
+ +
+
+J *JGetArray(J *json, const char *field)
+

Get the value of an array field from a JSON object.

+
+

Note

+

The returned JSON object is a pointer to the array contained in the parent JSON object. It is not a copy, so once the parent JSON object is freed, the pointer is no longer valid.

+
+
+
Parameters:
+
    +
  • json – The JSON object.

  • +
  • field – The array field to query.

  • +
+
+
Returns:
+

A pointer to the array, which is itself a JSON object (J *), if the field exists and is an array, otherwise NULL.

+
+
+
+ +
+
+bool JGetBinaryFromObject(J *json, const char *fieldName, uint8_t **retBinaryData, uint32_t *retBinaryDataLen)
+

Decode a Base64-encoded string field in a JSON object and return the decoded bytes.

+
+

Note

+

The returned binary buffer must be freed by the user with JFree when it is no longer needed.

+
+
+

Note

+

On error, the returned binary buffer and data length shall be set to NULL and zero (0), respectively.

+
+
+
Parameters:
+
    +
  • json – The JSON object.

  • +
  • fieldName – The name of the field.

  • +
  • retBinaryData – A pointer to a pointer, used to hold the pointer to the decoded bytes.

  • +
  • retBinaryDataLen – A pointer to an unsigned integer, used to hold the length of the decoded bytes.

  • +
+
+
Returns:
+

True if the string was successfully decoded and returned, otherwise false.

+
+
+
+ +
+
+bool JGetBool(J *json, const char *field)
+

Get the value of a boolean field from a JSON object.

+

+

See also

+

JGetInt

+
+
+

See also

+

JGetNumber

+
+

+
+
Parameters:
+
    +
  • json – The JSON object.

  • +
  • field – The boolean field to query.

  • +
+
+
Returns:
+

The value of the boolean field if it exists and is a boolean, otherwise false.

+
+
+
+ +
+
+JINTEGER JGetInt(J *json, const char *field)
+

Get the integer value of a number field from a JSON object.

+

+

See also

+

JGetBool

+
+
+

See also

+

JGetNumber

+
+

+
+

Note

+

The returned value is the integer representation of the number.

+
+
+
Parameters:
+
    +
  • json – The JSON object.

  • +
  • field – The number field to query.

  • +
+
+
Returns:
+

The value of the number field if the field exists and is a number, otherwise 0.

+
+
+
+ +
+
+JNUMBER JGetNumber(J *json, const char *field)
+

Get the floating point value of a number field from a JSON object.

+

+

See also

+

JGetInt

+
+
+

See also

+

JGetBool

+
+

+
+

Note

+

The returned value is the floating point representation of the number.

+
+
+
Parameters:
+
    +
  • json – The JSON object.

  • +
  • field – The number field to query.

  • +
+
+
Returns:
+

The value of the number field if the field exists and is a number, otherwise 0.0.

+
+
+
+ +
+
+J *JGetObject(J *json, const char *field)
+

Get the value of an object field from a JSON object.

+
+

Note

+

The returned JSON object is a pointer to the object contained in the parent JSON object. It is not a copy, so once the parent JSON object is freed, the pointer is no longer valid.

+
+
+
Parameters:
+
    +
  • json – The JSON object.

  • +
  • field – The object field to query.

  • +
+
+
Returns:
+

A pointer to the object, which is itself a JSON object (J *), if the field exists and is an object, otherwise NULL.

+
+
+
+ +
+
+char *JGetString(J *json, const char *field)
+

Get the value of a string field from a JSON object.

+
+

Note

+

The returned string is a pointer to the string contained in the JSON object. It is not a copy of the string, so once the JSON object is freed, the pointer is no longer valid.

+
+
+
Parameters:
+
    +
  • json – The JSON object.

  • +
  • field – The string field to query.

  • +
+
+
Returns:
+

A pointer to the string if the field exists and is a string, otherwise the empty string (“”).

+
+
+
+ +
+
+bool JIsPresent(J *json, const char *field)
+

Determine if a field is present in a JSON object.

+
+
Parameters:
+
    +
  • json – The JSON object.

  • +
  • field – The field to find.

  • +
+
+
Returns:
+

True if the field is present, or false if the field is not present or the JSON object is NULL.

+
+
+
+ +
+
+void *JMalloc(size_t size)
+

Dynamically allocate a block of memory of the given size.

+

This is simply a wrapper around the memory allocation function provided by the user via NoteSetFn.

+
+
Parameters:
+
    +
  • size – The number of bytes to allocate.

  • +
+
+
Returns:
+

A pointer to the first byte of the allocated memory or NULL on error.

+
+
+
+ +
+
+J *JParse(const char *value)
+

Parse the passed in C-string as JSON and return a J object representing it.

+
+
Parameters:
+
    +
  • value – The JSON object as a C-string.

  • +
+
+
Returns:
+

A J object or NULL on error (e.g. the string was invalid JSON).

+
+
+
+ +
+
+char *JPrintUnformatted(const J *item)
+

Get the unformatted string representation of a J object.

+

The string returned by this function is dynamically allocated and MUST be freed by the caller with JFree. Unformatted means that the minimum JSON string is produced, without any additional whitespace.

+
+
Parameters:
+
    +
  • item – The JSON object to get the unformatted string representation of.

  • +
+
+
Returns:
+

The string or NULL on error.

+
+
+
+ +
+
+

Types

+
+
+struct J
+

The core JSON object type used by note-c.

+

When using note-c, treat this struct as opaque. You should never have to work directly with its members.

+
+ +
+
+typedef double JNUMBER
+

The floating point type used for JSON handling in note-c.

+
+ +
+
+typedef int64_t JINTEGER
+

The signed integer type used for JSON handling in note-c.

+
+ +
+
+typedef uint64_t JUINTEGER
+

The unsigned integer type used for JSON handling in note-c.

+
+ +
+
+

Macros

+
+
+N_CJSON_NESTING_LIMIT
+

The maximum nesting level for JSON objects before a parsing error.

+

Default value: 100

+

For example, if you have a JSON object that contains multiple, nested objects like this

{
+    "x":
+    {
+        "x:"
+        {
+            .
+            .
+            .
+        }
+    }
+}
+
+
+ And the nesting level exceeds N_CJSON_NESTING_LIMIT, then calling JParse on a J * representing this object will return an error (NULL).

+

This exists to prevent the cJSON parser from causing a stack overflow. The user may override this macro at build time (e.g. -DN_CJSON_NESTING_LIMIT=200) to increase or reduce the limit.

+
+ +
+
+
+ + +
+
+ +
+
+
+
+ + + + \ No newline at end of file diff --git a/build.log b/build.log new file mode 100644 index 00000000..e69de29b diff --git a/calling_the_notecard_api.html b/calling_the_notecard_api.html new file mode 100644 index 00000000..58de61ee --- /dev/null +++ b/calling_the_notecard_api.html @@ -0,0 +1,176 @@ + + + + + + + Calling the Notecard API — note-c documentation + + + + + + + + + + + + + + + + + + + +
+ + +
+ +
+
+
+ +
+
+
+
+ +
+

Calling the Notecard API

+

The Notecard API is JSON-based. note-c uses a modified version of the cJSON library for working with JSON. The core JSON struct used in note-c is J. You should treat this type as opaque; you will only ever need to work with J * when using note-c.

+

To make a Notecard API call, first create a JSON request:

+
J *req = NoteNewRequest("note.add");
+
+
+

When req is serialized to a string, it looks like this:

+
{"req": "note.add"}
+
+
+

To add fields to the request, there are a number of JAdd* functions:

+ +

For example, to add the field "file": "data.qo" to req, use JAddStringToObject():

+
JAddStringToObject(req, "file", "data.qo")
+
+
+

Now, when req is serialized, it will have the "file" field:

+
{"req": "note.add", "file": "data.qo"}
+
+
+

Once the request has been prepared, send it to the Notecard with NoteRequestResponse():

+
J *rsp = NoteRequestResponse(req);
+
+
+

rsp holds the JSON response from the Notecard. Use NoteResponseError() to check the response for errors:

+
if (rsp == NULL || NoteResponseError(rsp)) {
+   // handle error
+}
+
+
+

NoteRequestResponse will take care of freeing the passed in request object, but you must free the response with NoteDeleteResponse():

+
NoteDeleteResponse(rsp);
+
+
+

The function NoteRequest() is useful when you don’t care about the details of the Notecard’s response, just whether the API call was successful or not. It returns true if the API call was successful and false if there was an error sending the request or if there was an error in the response (i.e. it calls NoteResponseError() internally):

+
if (NoteRequest(req)) {
+   // success
+}
+else {
+   // handle error
+}
+
+
+

NoteRequest() frees the request object for you.

+
+

Note

+

To use plain C-strings as the JSON interface into note-c, rather than J *, check out NoteRequestResponseJSON()

+
+
+

Examples

+

For examples of real applications calling the Notecard API with note-c, check out some of the Zephyr-based Blues App Accelerators:

+ +
+
+ + +
+
+ +
+
+
+
+ + + + \ No newline at end of file diff --git a/cmake_install.cmake b/cmake_install.cmake new file mode 100644 index 00000000..d7335f3c --- /dev/null +++ b/cmake_install.cmake @@ -0,0 +1,44 @@ +# Install script for directory: /home/runner/work/note-c/note-c/docs + +# Set the install prefix +if(NOT DEFINED CMAKE_INSTALL_PREFIX) + set(CMAKE_INSTALL_PREFIX "/usr/local") +endif() +string(REGEX REPLACE "/$" "" CMAKE_INSTALL_PREFIX "${CMAKE_INSTALL_PREFIX}") + +# Set the install configuration name. +if(NOT DEFINED CMAKE_INSTALL_CONFIG_NAME) + if(BUILD_TYPE) + string(REGEX REPLACE "^[^A-Za-z0-9_]+" "" + CMAKE_INSTALL_CONFIG_NAME "${BUILD_TYPE}") + else() + set(CMAKE_INSTALL_CONFIG_NAME "") + endif() + message(STATUS "Install configuration: \"${CMAKE_INSTALL_CONFIG_NAME}\"") +endif() + +# Set the component getting installed. +if(NOT CMAKE_INSTALL_COMPONENT) + if(COMPONENT) + message(STATUS "Install component: \"${COMPONENT}\"") + set(CMAKE_INSTALL_COMPONENT "${COMPONENT}") + else() + set(CMAKE_INSTALL_COMPONENT) + endif() +endif() + +# Install shared libraries without execute permission? +if(NOT DEFINED CMAKE_INSTALL_SO_NO_EXE) + set(CMAKE_INSTALL_SO_NO_EXE "1") +endif() + +# Is this installation the result of a crosscompile? +if(NOT DEFINED CMAKE_CROSSCOMPILING) + set(CMAKE_CROSSCOMPILING "FALSE") +endif() + +# Set default install directory permissions. +if(NOT DEFINED CMAKE_OBJDUMP) + set(CMAKE_OBJDUMP "/usr/bin/objdump") +endif() + diff --git a/doxygen/html/annotated.html b/doxygen/html/annotated.html new file mode 100644 index 00000000..0c7e0cda --- /dev/null +++ b/doxygen/html/annotated.html @@ -0,0 +1,88 @@ + + + + + + + +note-c: Data Structures + + + + + + + + + +
+
+ + + + + + + +
+
note-c +  1.0 +
+
An easy to use Notecard Library for C/C++
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
+
Data Structures
+
+
+
Here are the data structures with brief descriptions:
+ + + + + + + + +
 Cerror
 CJThe core JSON object type used by note-c
 CJHooks
 CNoteMD5Context
 CNotePayloadDesc
 Cparse_buffer
 Cprintbuffer
+
+
+ + + + diff --git a/doxygen/html/bc_s.png b/doxygen/html/bc_s.png new file mode 100644 index 00000000..224b29aa Binary files /dev/null and b/doxygen/html/bc_s.png differ diff --git a/doxygen/html/bdwn.png b/doxygen/html/bdwn.png new file mode 100644 index 00000000..940a0b95 Binary files /dev/null and b/doxygen/html/bdwn.png differ diff --git a/doxygen/html/blues_logo_no_text.png b/doxygen/html/blues_logo_no_text.png new file mode 100644 index 00000000..1598330d Binary files /dev/null and b/doxygen/html/blues_logo_no_text.png differ diff --git a/doxygen/html/classes.html b/doxygen/html/classes.html new file mode 100644 index 00000000..bf54c1cd --- /dev/null +++ b/doxygen/html/classes.html @@ -0,0 +1,92 @@ + + + + + + + +note-c: Data Structure Index + + + + + + + + + +
+
+ + + + + + + +
+
note-c +  1.0 +
+
An easy to use Notecard Library for C/C++
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
+
Data Structure Index
+
+ + + + + diff --git a/doxygen/html/closed.png b/doxygen/html/closed.png new file mode 100644 index 00000000..98cc2c90 Binary files /dev/null and b/doxygen/html/closed.png differ diff --git a/doxygen/html/doc.png b/doxygen/html/doc.png new file mode 100644 index 00000000..17edabff Binary files /dev/null and b/doxygen/html/doc.png differ diff --git a/doxygen/html/doxygen.css b/doxygen/html/doxygen.css new file mode 100644 index 00000000..ffbff022 --- /dev/null +++ b/doxygen/html/doxygen.css @@ -0,0 +1,1793 @@ +/* The standard CSS for doxygen 1.9.1 */ + +body, table, div, p, dl { + font: 400 14px/22px Roboto,sans-serif; +} + +p.reference, p.definition { + font: 400 14px/22px Roboto,sans-serif; +} + +/* @group Heading Levels */ + +h1.groupheader { + font-size: 150%; +} + +.title { + font: 400 14px/28px Roboto,sans-serif; + font-size: 150%; + font-weight: bold; + margin: 10px 2px; +} + +h2.groupheader { + border-bottom: 1px solid #879ECB; + color: #354C7B; + font-size: 150%; + font-weight: normal; + margin-top: 1.75em; + padding-top: 8px; + padding-bottom: 4px; + width: 100%; +} + +h3.groupheader { + font-size: 100%; +} + +h1, h2, h3, h4, h5, h6 { + -webkit-transition: text-shadow 0.5s linear; + -moz-transition: text-shadow 0.5s linear; + -ms-transition: text-shadow 0.5s linear; + -o-transition: text-shadow 0.5s linear; + transition: text-shadow 0.5s linear; + margin-right: 15px; +} + +h1.glow, h2.glow, h3.glow, h4.glow, h5.glow, h6.glow { + text-shadow: 0 0 15px cyan; +} + +dt { + font-weight: bold; +} + +ul.multicol { + -moz-column-gap: 1em; + -webkit-column-gap: 1em; + column-gap: 1em; + -moz-column-count: 3; + -webkit-column-count: 3; + column-count: 3; +} + +p.startli, p.startdd { + margin-top: 2px; +} + +th p.starttd, th p.intertd, th p.endtd { + font-size: 100%; + font-weight: 700; +} + +p.starttd { + margin-top: 0px; +} + +p.endli { + margin-bottom: 0px; +} + +p.enddd { + margin-bottom: 4px; +} + +p.endtd { + margin-bottom: 2px; +} + +p.interli { +} + +p.interdd { +} + +p.intertd { +} + +/* @end */ + +caption { + font-weight: bold; +} + +span.legend { + font-size: 70%; + text-align: center; +} + +h3.version { + font-size: 90%; + text-align: center; +} + +div.navtab { + border-right: 1px solid #A3B4D7; + padding-right: 15px; + text-align: right; + line-height: 110%; +} + +div.navtab table { + border-spacing: 0; +} + +td.navtab { + padding-right: 6px; + padding-left: 6px; +} +td.navtabHL { + background-image: url('tab_a.png'); + background-repeat:repeat-x; + padding-right: 6px; + padding-left: 6px; +} + +td.navtabHL a, td.navtabHL a:visited { + color: #fff; + text-shadow: 0px 1px 1px rgba(0, 0, 0, 1.0); +} + +a.navtab { + font-weight: bold; +} + +div.qindex{ + text-align: center; + width: 100%; + line-height: 140%; + font-size: 130%; + color: #A0A0A0; +} + +dt.alphachar{ + font-size: 180%; + font-weight: bold; +} + +.alphachar a{ + color: black; +} + +.alphachar a:hover, .alphachar a:visited{ + text-decoration: none; +} + +.classindex dl { + padding: 25px; + column-count:1 +} + +.classindex dd { + display:inline-block; + margin-left: 50px; + width: 90%; + line-height: 1.15em; +} + +.classindex dl.odd { + background-color: #F8F9FC; +} + +@media(min-width: 1120px) { + .classindex dl { + column-count:2 + } +} + +@media(min-width: 1320px) { + .classindex dl { + column-count:3 + } +} + + +/* @group Link Styling */ + +a { + color: #3D578C; + font-weight: normal; + text-decoration: none; +} + +.contents a:visited { + color: #4665A2; +} + +a:hover { + text-decoration: underline; +} + +.contents a.qindexHL:visited { + color: #FFFFFF; +} + +a.el { + font-weight: bold; +} + +a.elRef { +} + +a.code, a.code:visited, a.line, a.line:visited { + color: #4665A2; +} + +a.codeRef, a.codeRef:visited, a.lineRef, a.lineRef:visited { + color: #4665A2; +} + +/* @end */ + +dl.el { + margin-left: -1cm; +} + +ul { + overflow: hidden; /*Fixed: list item bullets overlap floating elements*/ +} + +#side-nav ul { + overflow: visible; /* reset ul rule for scroll bar in GENERATE_TREEVIEW window */ +} + +#main-nav ul { + overflow: visible; /* reset ul rule for the navigation bar drop down lists */ +} + +.fragment { + text-align: left; + direction: ltr; + overflow-x: auto; /*Fixed: fragment lines overlap floating elements*/ + overflow-y: hidden; +} + +pre.fragment { + border: 1px solid #C4CFE5; + background-color: #FBFCFD; + padding: 4px 6px; + margin: 4px 8px 4px 2px; + overflow: auto; + word-wrap: break-word; + font-size: 9pt; + line-height: 125%; + font-family: monospace, fixed; + font-size: 105%; +} + +div.fragment { + padding: 0 0 1px 0; /*Fixed: last line underline overlap border*/ + margin: 4px 8px 4px 2px; + background-color: #FBFCFD; + border: 1px solid #C4CFE5; +} + +div.line { + font-family: monospace, fixed; + font-size: 13px; + min-height: 13px; + line-height: 1.0; + text-wrap: unrestricted; + white-space: -moz-pre-wrap; /* Moz */ + white-space: -pre-wrap; /* Opera 4-6 */ + white-space: -o-pre-wrap; /* Opera 7 */ + white-space: pre-wrap; /* CSS3 */ + word-wrap: break-word; /* IE 5.5+ */ + text-indent: -53px; + padding-left: 53px; + padding-bottom: 0px; + margin: 0px; + -webkit-transition-property: background-color, box-shadow; + -webkit-transition-duration: 0.5s; + -moz-transition-property: background-color, box-shadow; + -moz-transition-duration: 0.5s; + -ms-transition-property: background-color, box-shadow; + -ms-transition-duration: 0.5s; + -o-transition-property: background-color, box-shadow; + -o-transition-duration: 0.5s; + transition-property: background-color, box-shadow; + transition-duration: 0.5s; +} + +div.line:after { + content:"\000A"; + white-space: pre; +} + +div.line.glow { + background-color: cyan; + box-shadow: 0 0 10px cyan; +} + + +span.lineno { + padding-right: 4px; + text-align: right; + border-right: 2px solid #0F0; + background-color: #E8E8E8; + white-space: pre; +} +span.lineno a { + background-color: #D8D8D8; +} + +span.lineno a:hover { + background-color: #C8C8C8; +} + +.lineno { + -webkit-touch-callout: none; + -webkit-user-select: none; + -khtml-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; +} + +div.ah, span.ah { + background-color: black; + font-weight: bold; + color: #FFFFFF; + margin-bottom: 3px; + margin-top: 3px; + padding: 0.2em; + border: solid thin #333; + border-radius: 0.5em; + -webkit-border-radius: .5em; + -moz-border-radius: .5em; + box-shadow: 2px 2px 3px #999; + -webkit-box-shadow: 2px 2px 3px #999; + -moz-box-shadow: rgba(0, 0, 0, 0.15) 2px 2px 2px; + background-image: -webkit-gradient(linear, left top, left bottom, from(#eee), to(#000),color-stop(0.3, #444)); + background-image: -moz-linear-gradient(center top, #eee 0%, #444 40%, #000 110%); +} + +div.classindex ul { + list-style: none; + padding-left: 0; +} + +div.classindex span.ai { + display: inline-block; +} + +div.groupHeader { + margin-left: 16px; + margin-top: 12px; + font-weight: bold; +} + +div.groupText { + margin-left: 16px; + font-style: italic; +} + +body { + background-color: white; + color: black; + margin: 0; +} + +div.contents { + margin-top: 10px; + margin-left: 12px; + margin-right: 8px; +} + +td.indexkey { + background-color: #EBEFF6; + font-weight: bold; + border: 1px solid #C4CFE5; + margin: 2px 0px 2px 0; + padding: 2px 10px; + white-space: nowrap; + vertical-align: top; +} + +td.indexvalue { + background-color: #EBEFF6; + border: 1px solid #C4CFE5; + padding: 2px 10px; + margin: 2px 0px; +} + +tr.memlist { + background-color: #EEF1F7; +} + +p.formulaDsp { + text-align: center; +} + +img.formulaDsp { + +} + +img.formulaInl, img.inline { + vertical-align: middle; +} + +div.center { + text-align: center; + margin-top: 0px; + margin-bottom: 0px; + padding: 0px; +} + +div.center img { + border: 0px; +} + +address.footer { + text-align: right; + padding-right: 12px; +} + +img.footer { + border: 0px; + vertical-align: middle; +} + +/* @group Code Colorization */ + +span.keyword { + color: #008000 +} + +span.keywordtype { + color: #604020 +} + +span.keywordflow { + color: #e08000 +} + +span.comment { + color: #800000 +} + +span.preprocessor { + color: #806020 +} + +span.stringliteral { + color: #002080 +} + +span.charliteral { + color: #008080 +} + +span.vhdldigit { + color: #ff00ff +} + +span.vhdlchar { + color: #000000 +} + +span.vhdlkeyword { + color: #700070 +} + +span.vhdllogic { + color: #ff0000 +} + +blockquote { + background-color: #F7F8FB; + border-left: 2px solid #9CAFD4; + margin: 0 24px 0 4px; + padding: 0 12px 0 16px; +} + +blockquote.DocNodeRTL { + border-left: 0; + border-right: 2px solid #9CAFD4; + margin: 0 4px 0 24px; + padding: 0 16px 0 12px; +} + +/* @end */ + +/* +.search { + color: #003399; + font-weight: bold; +} + +form.search { + margin-bottom: 0px; + margin-top: 0px; +} + +input.search { + font-size: 75%; + color: #000080; + font-weight: normal; + background-color: #e8eef2; +} +*/ + +td.tiny { + font-size: 75%; +} + +.dirtab { + padding: 4px; + border-collapse: collapse; + border: 1px solid #A3B4D7; +} + +th.dirtab { + background: #EBEFF6; + font-weight: bold; +} + +hr { + height: 0px; + border: none; + border-top: 1px solid #4A6AAA; +} + +hr.footer { + height: 1px; +} + +/* @group Member Descriptions */ + +table.memberdecls { + border-spacing: 0px; + padding: 0px; +} + +.memberdecls td, .fieldtable tr { + -webkit-transition-property: background-color, box-shadow; + -webkit-transition-duration: 0.5s; + -moz-transition-property: background-color, box-shadow; + -moz-transition-duration: 0.5s; + -ms-transition-property: background-color, box-shadow; + -ms-transition-duration: 0.5s; + -o-transition-property: background-color, box-shadow; + -o-transition-duration: 0.5s; + transition-property: background-color, box-shadow; + transition-duration: 0.5s; +} + +.memberdecls td.glow, .fieldtable tr.glow { + background-color: cyan; + box-shadow: 0 0 15px cyan; +} + +.mdescLeft, .mdescRight, +.memItemLeft, .memItemRight, +.memTemplItemLeft, .memTemplItemRight, .memTemplParams { + background-color: #F9FAFC; + border: none; + margin: 4px; + padding: 1px 0 0 8px; +} + +.mdescLeft, .mdescRight { + padding: 0px 8px 4px 8px; + color: #555; +} + +.memSeparator { + border-bottom: 1px solid #DEE4F0; + line-height: 1px; + margin: 0px; + padding: 0px; +} + +.memItemLeft, .memTemplItemLeft { + white-space: nowrap; +} + +.memItemRight, .memTemplItemRight { + width: 100%; +} + +.memTemplParams { + color: #4665A2; + white-space: nowrap; + font-size: 80%; +} + +/* @end */ + +/* @group Member Details */ + +/* Styles for detailed member documentation */ + +.memtitle { + padding: 8px; + border-top: 1px solid #A8B8D9; + border-left: 1px solid #A8B8D9; + border-right: 1px solid #A8B8D9; + border-top-right-radius: 4px; + border-top-left-radius: 4px; + margin-bottom: -1px; + background-image: url('nav_f.png'); + background-repeat: repeat-x; + background-color: #E2E8F2; + line-height: 1.25; + font-weight: 300; + float:left; +} + +.permalink +{ + font-size: 65%; + display: inline-block; + vertical-align: middle; +} + +.memtemplate { + font-size: 80%; + color: #4665A2; + font-weight: normal; + margin-left: 9px; +} + +.memnav { + background-color: #EBEFF6; + border: 1px solid #A3B4D7; + text-align: center; + margin: 2px; + margin-right: 15px; + padding: 2px; +} + +.mempage { + width: 100%; +} + +.memitem { + padding: 0; + margin-bottom: 10px; + margin-right: 5px; + -webkit-transition: box-shadow 0.5s linear; + -moz-transition: box-shadow 0.5s linear; + -ms-transition: box-shadow 0.5s linear; + -o-transition: box-shadow 0.5s linear; + transition: box-shadow 0.5s linear; + display: table !important; + width: 100%; +} + +.memitem.glow { + box-shadow: 0 0 15px cyan; +} + +.memname { + font-weight: 400; + margin-left: 6px; +} + +.memname td { + vertical-align: bottom; +} + +.memproto, dl.reflist dt { + border-top: 1px solid #A8B8D9; + border-left: 1px solid #A8B8D9; + border-right: 1px solid #A8B8D9; + padding: 6px 0px 6px 0px; + color: #253555; + font-weight: bold; + text-shadow: 0px 1px 1px rgba(255, 255, 255, 0.9); + background-color: #DFE5F1; + /* opera specific markup */ + box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); + border-top-right-radius: 4px; + /* firefox specific markup */ + -moz-box-shadow: rgba(0, 0, 0, 0.15) 5px 5px 5px; + -moz-border-radius-topright: 4px; + /* webkit specific markup */ + -webkit-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); + -webkit-border-top-right-radius: 4px; + +} + +.overload { + font-family: "courier new",courier,monospace; + font-size: 65%; +} + +.memdoc, dl.reflist dd { + border-bottom: 1px solid #A8B8D9; + border-left: 1px solid #A8B8D9; + border-right: 1px solid #A8B8D9; + padding: 6px 10px 2px 10px; + background-color: #FBFCFD; + border-top-width: 0; + background-image:url('nav_g.png'); + background-repeat:repeat-x; + background-color: #FFFFFF; + /* opera specific markup */ + border-bottom-left-radius: 4px; + border-bottom-right-radius: 4px; + box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); + /* firefox specific markup */ + -moz-border-radius-bottomleft: 4px; + -moz-border-radius-bottomright: 4px; + -moz-box-shadow: rgba(0, 0, 0, 0.15) 5px 5px 5px; + /* webkit specific markup */ + -webkit-border-bottom-left-radius: 4px; + -webkit-border-bottom-right-radius: 4px; + -webkit-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); +} + +dl.reflist dt { + padding: 5px; +} + +dl.reflist dd { + margin: 0px 0px 10px 0px; + padding: 5px; +} + +.paramkey { + text-align: right; +} + +.paramtype { + white-space: nowrap; +} + +.paramname { + color: #602020; + white-space: nowrap; +} +.paramname em { + font-style: normal; +} +.paramname code { + line-height: 14px; +} + +.params, .retval, .exception, .tparams { + margin-left: 0px; + padding-left: 0px; +} + +.params .paramname, .retval .paramname, .tparams .paramname, .exception .paramname { + font-weight: bold; + vertical-align: top; +} + +.params .paramtype, .tparams .paramtype { + font-style: italic; + vertical-align: top; +} + +.params .paramdir, .tparams .paramdir { + font-family: "courier new",courier,monospace; + vertical-align: top; +} + +table.mlabels { + border-spacing: 0px; +} + +td.mlabels-left { + width: 100%; + padding: 0px; +} + +td.mlabels-right { + vertical-align: bottom; + padding: 0px; + white-space: nowrap; +} + +span.mlabels { + margin-left: 8px; +} + +span.mlabel { + background-color: #728DC1; + border-top:1px solid #5373B4; + border-left:1px solid #5373B4; + border-right:1px solid #C4CFE5; + border-bottom:1px solid #C4CFE5; + text-shadow: none; + color: white; + margin-right: 4px; + padding: 2px 3px; + border-radius: 3px; + font-size: 7pt; + white-space: nowrap; + vertical-align: middle; +} + + + +/* @end */ + +/* these are for tree view inside a (index) page */ + +div.directory { + margin: 10px 0px; + border-top: 1px solid #9CAFD4; + border-bottom: 1px solid #9CAFD4; + width: 100%; +} + +.directory table { + border-collapse:collapse; +} + +.directory td { + margin: 0px; + padding: 0px; + vertical-align: top; +} + +.directory td.entry { + white-space: nowrap; + padding-right: 6px; + padding-top: 3px; +} + +.directory td.entry a { + outline:none; +} + +.directory td.entry a img { + border: none; +} + +.directory td.desc { + width: 100%; + padding-left: 6px; + padding-right: 6px; + padding-top: 3px; + border-left: 1px solid rgba(0,0,0,0.05); +} + +.directory tr.even { + padding-left: 6px; + background-color: #F7F8FB; +} + +.directory img { + vertical-align: -30%; +} + +.directory .levels { + white-space: nowrap; + width: 100%; + text-align: right; + font-size: 9pt; +} + +.directory .levels span { + cursor: pointer; + padding-left: 2px; + padding-right: 2px; + color: #3D578C; +} + +.arrow { + color: #9CAFD4; + -webkit-user-select: none; + -khtml-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; + cursor: pointer; + font-size: 80%; + display: inline-block; + width: 16px; + height: 22px; +} + +.icon { + font-family: Arial, Helvetica; + font-weight: bold; + font-size: 12px; + height: 14px; + width: 16px; + display: inline-block; + background-color: #728DC1; + color: white; + text-align: center; + border-radius: 4px; + margin-left: 2px; + margin-right: 2px; +} + +.icona { + width: 24px; + height: 22px; + display: inline-block; +} + +.iconfopen { + width: 24px; + height: 18px; + margin-bottom: 4px; + background-image:url('folderopen.png'); + background-position: 0px -4px; + background-repeat: repeat-y; + vertical-align:top; + display: inline-block; +} + +.iconfclosed { + width: 24px; + height: 18px; + margin-bottom: 4px; + background-image:url('folderclosed.png'); + background-position: 0px -4px; + background-repeat: repeat-y; + vertical-align:top; + display: inline-block; +} + +.icondoc { + width: 24px; + height: 18px; + margin-bottom: 4px; + background-image:url('doc.png'); + background-position: 0px -4px; + background-repeat: repeat-y; + vertical-align:top; + display: inline-block; +} + +table.directory { + font: 400 14px Roboto,sans-serif; +} + +/* @end */ + +div.dynheader { + margin-top: 8px; + -webkit-touch-callout: none; + -webkit-user-select: none; + -khtml-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; +} + +address { + font-style: normal; + color: #2A3D61; +} + +table.doxtable caption { + caption-side: top; +} + +table.doxtable { + border-collapse:collapse; + margin-top: 4px; + margin-bottom: 4px; +} + +table.doxtable td, table.doxtable th { + border: 1px solid #2D4068; + padding: 3px 7px 2px; +} + +table.doxtable th { + background-color: #374F7F; + color: #FFFFFF; + font-size: 110%; + padding-bottom: 4px; + padding-top: 5px; +} + +table.fieldtable { + /*width: 100%;*/ + margin-bottom: 10px; + border: 1px solid #A8B8D9; + border-spacing: 0px; + -moz-border-radius: 4px; + -webkit-border-radius: 4px; + border-radius: 4px; + -moz-box-shadow: rgba(0, 0, 0, 0.15) 2px 2px 2px; + -webkit-box-shadow: 2px 2px 2px rgba(0, 0, 0, 0.15); + box-shadow: 2px 2px 2px rgba(0, 0, 0, 0.15); +} + +.fieldtable td, .fieldtable th { + padding: 3px 7px 2px; +} + +.fieldtable td.fieldtype, .fieldtable td.fieldname { + white-space: nowrap; + border-right: 1px solid #A8B8D9; + border-bottom: 1px solid #A8B8D9; + vertical-align: top; +} + +.fieldtable td.fieldname { + padding-top: 3px; +} + +.fieldtable td.fielddoc { + border-bottom: 1px solid #A8B8D9; + /*width: 100%;*/ +} + +.fieldtable td.fielddoc p:first-child { + margin-top: 0px; +} + +.fieldtable td.fielddoc p:last-child { + margin-bottom: 2px; +} + +.fieldtable tr:last-child td { + border-bottom: none; +} + +.fieldtable th { + background-image:url('nav_f.png'); + background-repeat:repeat-x; + background-color: #E2E8F2; + font-size: 90%; + color: #253555; + padding-bottom: 4px; + padding-top: 5px; + text-align:left; + font-weight: 400; + -moz-border-radius-topleft: 4px; + -moz-border-radius-topright: 4px; + -webkit-border-top-left-radius: 4px; + -webkit-border-top-right-radius: 4px; + border-top-left-radius: 4px; + border-top-right-radius: 4px; + border-bottom: 1px solid #A8B8D9; +} + + +.tabsearch { + top: 0px; + left: 10px; + height: 36px; + background-image: url('tab_b.png'); + z-index: 101; + overflow: hidden; + font-size: 13px; +} + +.navpath ul +{ + font-size: 11px; + background-image:url('tab_b.png'); + background-repeat:repeat-x; + background-position: 0 -5px; + height:30px; + line-height:30px; + color:#8AA0CC; + border:solid 1px #C2CDE4; + overflow:hidden; + margin:0px; + padding:0px; +} + +.navpath li +{ + list-style-type:none; + float:left; + padding-left:10px; + padding-right:15px; + background-image:url('bc_s.png'); + background-repeat:no-repeat; + background-position:right; + color:#364D7C; +} + +.navpath li.navelem a +{ + height:32px; + display:block; + text-decoration: none; + outline: none; + color: #283A5D; + font-family: 'Lucida Grande',Geneva,Helvetica,Arial,sans-serif; + text-shadow: 0px 1px 1px rgba(255, 255, 255, 0.9); + text-decoration: none; +} + +.navpath li.navelem a:hover +{ + color:#6884BD; +} + +.navpath li.footer +{ + list-style-type:none; + float:right; + padding-left:10px; + padding-right:15px; + background-image:none; + background-repeat:no-repeat; + background-position:right; + color:#364D7C; + font-size: 8pt; +} + + +div.summary +{ + float: right; + font-size: 8pt; + padding-right: 5px; + width: 50%; + text-align: right; +} + +div.summary a +{ + white-space: nowrap; +} + +table.classindex +{ + margin: 10px; + white-space: nowrap; + margin-left: 3%; + margin-right: 3%; + width: 94%; + border: 0; + border-spacing: 0; + padding: 0; +} + +div.ingroups +{ + font-size: 8pt; + width: 50%; + text-align: left; +} + +div.ingroups a +{ + white-space: nowrap; +} + +div.header +{ + background-image:url('nav_h.png'); + background-repeat:repeat-x; + background-color: #F9FAFC; + margin: 0px; + border-bottom: 1px solid #C4CFE5; +} + +div.headertitle +{ + padding: 5px 5px 5px 10px; +} + +.PageDocRTL-title div.headertitle { + text-align: right; + direction: rtl; +} + +dl { + padding: 0 0 0 0; +} + +/* dl.note, dl.warning, dl.attention, dl.pre, dl.post, dl.invariant, dl.deprecated, dl.todo, dl.test, dl.bug, dl.examples */ +dl.section { + margin-left: 0px; + padding-left: 0px; +} + +dl.section.DocNodeRTL { + margin-right: 0px; + padding-right: 0px; +} + +dl.note { + margin-left: -7px; + padding-left: 3px; + border-left: 4px solid; + border-color: #D0C000; +} + +dl.note.DocNodeRTL { + margin-left: 0; + padding-left: 0; + border-left: 0; + margin-right: -7px; + padding-right: 3px; + border-right: 4px solid; + border-color: #D0C000; +} + +dl.warning, dl.attention { + margin-left: -7px; + padding-left: 3px; + border-left: 4px solid; + border-color: #FF0000; +} + +dl.warning.DocNodeRTL, dl.attention.DocNodeRTL { + margin-left: 0; + padding-left: 0; + border-left: 0; + margin-right: -7px; + padding-right: 3px; + border-right: 4px solid; + border-color: #FF0000; +} + +dl.pre, dl.post, dl.invariant { + margin-left: -7px; + padding-left: 3px; + border-left: 4px solid; + border-color: #00D000; +} + +dl.pre.DocNodeRTL, dl.post.DocNodeRTL, dl.invariant.DocNodeRTL { + margin-left: 0; + padding-left: 0; + border-left: 0; + margin-right: -7px; + padding-right: 3px; + border-right: 4px solid; + border-color: #00D000; +} + +dl.deprecated { + margin-left: -7px; + padding-left: 3px; + border-left: 4px solid; + border-color: #505050; +} + +dl.deprecated.DocNodeRTL { + margin-left: 0; + padding-left: 0; + border-left: 0; + margin-right: -7px; + padding-right: 3px; + border-right: 4px solid; + border-color: #505050; +} + +dl.todo { + margin-left: -7px; + padding-left: 3px; + border-left: 4px solid; + border-color: #00C0E0; +} + +dl.todo.DocNodeRTL { + margin-left: 0; + padding-left: 0; + border-left: 0; + margin-right: -7px; + padding-right: 3px; + border-right: 4px solid; + border-color: #00C0E0; +} + +dl.test { + margin-left: -7px; + padding-left: 3px; + border-left: 4px solid; + border-color: #3030E0; +} + +dl.test.DocNodeRTL { + margin-left: 0; + padding-left: 0; + border-left: 0; + margin-right: -7px; + padding-right: 3px; + border-right: 4px solid; + border-color: #3030E0; +} + +dl.bug { + margin-left: -7px; + padding-left: 3px; + border-left: 4px solid; + border-color: #C08050; +} + +dl.bug.DocNodeRTL { + margin-left: 0; + padding-left: 0; + border-left: 0; + margin-right: -7px; + padding-right: 3px; + border-right: 4px solid; + border-color: #C08050; +} + +dl.section dd { + margin-bottom: 6px; +} + + +#projectlogo +{ + text-align: center; + vertical-align: bottom; + border-collapse: separate; +} + +#projectlogo img +{ + border: 0px none; +} + +#projectalign +{ + vertical-align: middle; +} + +#projectname +{ + font: 300% Tahoma, Arial,sans-serif; + margin: 0px; + padding: 2px 0px; +} + +#projectbrief +{ + font: 120% Tahoma, Arial,sans-serif; + margin: 0px; + padding: 0px; +} + +#projectnumber +{ + font: 50% Tahoma, Arial,sans-serif; + margin: 0px; + padding: 0px; +} + +#titlearea +{ + padding: 0px; + margin: 0px; + width: 100%; + border-bottom: 1px solid #5373B4; +} + +.image +{ + text-align: center; +} + +.dotgraph +{ + text-align: center; +} + +.mscgraph +{ + text-align: center; +} + +.plantumlgraph +{ + text-align: center; +} + +.diagraph +{ + text-align: center; +} + +.caption +{ + font-weight: bold; +} + +div.zoom +{ + border: 1px solid #90A5CE; +} + +dl.citelist { + margin-bottom:50px; +} + +dl.citelist dt { + color:#334975; + float:left; + font-weight:bold; + margin-right:10px; + padding:5px; + text-align:right; + width:52px; +} + +dl.citelist dd { + margin:2px 0 2px 72px; + padding:5px 0; +} + +div.toc { + padding: 14px 25px; + background-color: #F4F6FA; + border: 1px solid #D8DFEE; + border-radius: 7px 7px 7px 7px; + float: right; + height: auto; + margin: 0 8px 10px 10px; + width: 200px; +} + +.PageDocRTL-title div.toc { + float: left !important; + text-align: right; +} + +div.toc li { + background: url("bdwn.png") no-repeat scroll 0 5px transparent; + font: 10px/1.2 Verdana,DejaVu Sans,Geneva,sans-serif; + margin-top: 5px; + padding-left: 10px; + padding-top: 2px; +} + +.PageDocRTL-title div.toc li { + background-position-x: right !important; + padding-left: 0 !important; + padding-right: 10px; +} + +div.toc h3 { + font: bold 12px/1.2 Arial,FreeSans,sans-serif; + color: #4665A2; + border-bottom: 0 none; + margin: 0; +} + +div.toc ul { + list-style: none outside none; + border: medium none; + padding: 0px; +} + +div.toc li.level1 { + margin-left: 0px; +} + +div.toc li.level2 { + margin-left: 15px; +} + +div.toc li.level3 { + margin-left: 30px; +} + +div.toc li.level4 { + margin-left: 45px; +} + +span.emoji { + /* font family used at the site: https://unicode.org/emoji/charts/full-emoji-list.html + * font-family: "Noto Color Emoji", "Apple Color Emoji", "Segoe UI Emoji", Times, Symbola, Aegyptus, Code2000, Code2001, Code2002, Musica, serif, LastResort; + */ +} + +.PageDocRTL-title div.toc li.level1 { + margin-left: 0 !important; + margin-right: 0; +} + +.PageDocRTL-title div.toc li.level2 { + margin-left: 0 !important; + margin-right: 15px; +} + +.PageDocRTL-title div.toc li.level3 { + margin-left: 0 !important; + margin-right: 30px; +} + +.PageDocRTL-title div.toc li.level4 { + margin-left: 0 !important; + margin-right: 45px; +} + +.inherit_header { + font-weight: bold; + color: gray; + cursor: pointer; + -webkit-touch-callout: none; + -webkit-user-select: none; + -khtml-user-select: none; + -moz-user-select: none; + -ms-user-select: none; + user-select: none; +} + +.inherit_header td { + padding: 6px 0px 2px 5px; +} + +.inherit { + display: none; +} + +tr.heading h2 { + margin-top: 12px; + margin-bottom: 4px; +} + +/* tooltip related style info */ + +.ttc { + position: absolute; + display: none; +} + +#powerTip { + cursor: default; + white-space: nowrap; + background-color: white; + border: 1px solid gray; + border-radius: 4px 4px 4px 4px; + box-shadow: 1px 1px 7px gray; + display: none; + font-size: smaller; + max-width: 80%; + opacity: 0.9; + padding: 1ex 1em 1em; + position: absolute; + z-index: 2147483647; +} + +#powerTip div.ttdoc { + color: grey; + font-style: italic; +} + +#powerTip div.ttname a { + font-weight: bold; +} + +#powerTip div.ttname { + font-weight: bold; +} + +#powerTip div.ttdeci { + color: #006318; +} + +#powerTip div { + margin: 0px; + padding: 0px; + font: 12px/16px Roboto,sans-serif; +} + +#powerTip:before, #powerTip:after { + content: ""; + position: absolute; + margin: 0px; +} + +#powerTip.n:after, #powerTip.n:before, +#powerTip.s:after, #powerTip.s:before, +#powerTip.w:after, #powerTip.w:before, +#powerTip.e:after, #powerTip.e:before, +#powerTip.ne:after, #powerTip.ne:before, +#powerTip.se:after, #powerTip.se:before, +#powerTip.nw:after, #powerTip.nw:before, +#powerTip.sw:after, #powerTip.sw:before { + border: solid transparent; + content: " "; + height: 0; + width: 0; + position: absolute; +} + +#powerTip.n:after, #powerTip.s:after, +#powerTip.w:after, #powerTip.e:after, +#powerTip.nw:after, #powerTip.ne:after, +#powerTip.sw:after, #powerTip.se:after { + border-color: rgba(255, 255, 255, 0); +} + +#powerTip.n:before, #powerTip.s:before, +#powerTip.w:before, #powerTip.e:before, +#powerTip.nw:before, #powerTip.ne:before, +#powerTip.sw:before, #powerTip.se:before { + border-color: rgba(128, 128, 128, 0); +} + +#powerTip.n:after, #powerTip.n:before, +#powerTip.ne:after, #powerTip.ne:before, +#powerTip.nw:after, #powerTip.nw:before { + top: 100%; +} + +#powerTip.n:after, #powerTip.ne:after, #powerTip.nw:after { + border-top-color: #FFFFFF; + border-width: 10px; + margin: 0px -10px; +} +#powerTip.n:before { + border-top-color: #808080; + border-width: 11px; + margin: 0px -11px; +} +#powerTip.n:after, #powerTip.n:before { + left: 50%; +} + +#powerTip.nw:after, #powerTip.nw:before { + right: 14px; +} + +#powerTip.ne:after, #powerTip.ne:before { + left: 14px; +} + +#powerTip.s:after, #powerTip.s:before, +#powerTip.se:after, #powerTip.se:before, +#powerTip.sw:after, #powerTip.sw:before { + bottom: 100%; +} + +#powerTip.s:after, #powerTip.se:after, #powerTip.sw:after { + border-bottom-color: #FFFFFF; + border-width: 10px; + margin: 0px -10px; +} + +#powerTip.s:before, #powerTip.se:before, #powerTip.sw:before { + border-bottom-color: #808080; + border-width: 11px; + margin: 0px -11px; +} + +#powerTip.s:after, #powerTip.s:before { + left: 50%; +} + +#powerTip.sw:after, #powerTip.sw:before { + right: 14px; +} + +#powerTip.se:after, #powerTip.se:before { + left: 14px; +} + +#powerTip.e:after, #powerTip.e:before { + left: 100%; +} +#powerTip.e:after { + border-left-color: #FFFFFF; + border-width: 10px; + top: 50%; + margin-top: -10px; +} +#powerTip.e:before { + border-left-color: #808080; + border-width: 11px; + top: 50%; + margin-top: -11px; +} + +#powerTip.w:after, #powerTip.w:before { + right: 100%; +} +#powerTip.w:after { + border-right-color: #FFFFFF; + border-width: 10px; + top: 50%; + margin-top: -10px; +} +#powerTip.w:before { + border-right-color: #808080; + border-width: 11px; + top: 50%; + margin-top: -11px; +} + +@media print +{ + #top { display: none; } + #side-nav { display: none; } + #nav-path { display: none; } + body { overflow:visible; } + h1, h2, h3, h4, h5, h6 { page-break-after: avoid; } + .summary { display: none; } + .memitem { page-break-inside: avoid; } + #doc-content + { + margin-left:0 !important; + height:auto !important; + width:auto !important; + overflow:inherit; + display:inline; + } +} + +/* @group Markdown */ + +table.markdownTable { + border-collapse:collapse; + margin-top: 4px; + margin-bottom: 4px; +} + +table.markdownTable td, table.markdownTable th { + border: 1px solid #2D4068; + padding: 3px 7px 2px; +} + +table.markdownTable tr { +} + +th.markdownTableHeadLeft, th.markdownTableHeadRight, th.markdownTableHeadCenter, th.markdownTableHeadNone { + background-color: #374F7F; + color: #FFFFFF; + font-size: 110%; + padding-bottom: 4px; + padding-top: 5px; +} + +th.markdownTableHeadLeft, td.markdownTableBodyLeft { + text-align: left +} + +th.markdownTableHeadRight, td.markdownTableBodyRight { + text-align: right +} + +th.markdownTableHeadCenter, td.markdownTableBodyCenter { + text-align: center +} + +.DocNodeRTL { + text-align: right; + direction: rtl; +} + +.DocNodeLTR { + text-align: left; + direction: ltr; +} + +table.DocNodeRTL { + width: auto; + margin-right: 0; + margin-left: auto; +} + +table.DocNodeLTR { + width: auto; + margin-right: auto; + margin-left: 0; +} + +tt, code, kbd, samp +{ + display: inline-block; + direction:ltr; +} +/* @end */ + +u { + text-decoration: underline; +} + diff --git a/doxygen/html/doxygen.svg b/doxygen/html/doxygen.svg new file mode 100644 index 00000000..d42dad52 --- /dev/null +++ b/doxygen/html/doxygen.svg @@ -0,0 +1,26 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/doxygen/html/dynsections.js b/doxygen/html/dynsections.js new file mode 100644 index 00000000..3174bd7b --- /dev/null +++ b/doxygen/html/dynsections.js @@ -0,0 +1,121 @@ +/* + @licstart The following is the entire license notice for the JavaScript code in this file. + + The MIT License (MIT) + + Copyright (C) 1997-2020 by Dimitri van Heesch + + 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. + + @licend The above is the entire license notice for the JavaScript code in this file + */ +function toggleVisibility(linkObj) +{ + var base = $(linkObj).attr('id'); + var summary = $('#'+base+'-summary'); + var content = $('#'+base+'-content'); + var trigger = $('#'+base+'-trigger'); + var src=$(trigger).attr('src'); + if (content.is(':visible')===true) { + content.hide(); + summary.show(); + $(linkObj).addClass('closed').removeClass('opened'); + $(trigger).attr('src',src.substring(0,src.length-8)+'closed.png'); + } else { + content.show(); + summary.hide(); + $(linkObj).removeClass('closed').addClass('opened'); + $(trigger).attr('src',src.substring(0,src.length-10)+'open.png'); + } + return false; +} + +function updateStripes() +{ + $('table.directory tr'). + removeClass('even').filter(':visible:even').addClass('even'); +} + +function toggleLevel(level) +{ + $('table.directory tr').each(function() { + var l = this.id.split('_').length-1; + var i = $('#img'+this.id.substring(3)); + var a = $('#arr'+this.id.substring(3)); + if (l + + + + + + +note-c: File List + + + + + + + + + +
+
+ + + + + + + +
+
note-c +  1.0 +
+
An easy to use Notecard Library for C/C++
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
+
File List
+
+
+
Here is a list of all files with brief descriptions:
+
+ + + + diff --git a/doxygen/html/folderclosed.png b/doxygen/html/folderclosed.png new file mode 100644 index 00000000..bb8ab35e Binary files /dev/null and b/doxygen/html/folderclosed.png differ diff --git a/doxygen/html/folderopen.png b/doxygen/html/folderopen.png new file mode 100644 index 00000000..d6c7f676 Binary files /dev/null and b/doxygen/html/folderopen.png differ diff --git a/doxygen/html/functions.html b/doxygen/html/functions.html new file mode 100644 index 00000000..9f6d704d --- /dev/null +++ b/doxygen/html/functions.html @@ -0,0 +1,154 @@ + + + + + + + +note-c: Data Fields + + + + + + + + + +
+
+ + + + + + + +
+
note-c +  1.0 +
+
An easy to use Notecard Library for C/C++
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
Here is a list of all struct and union fields with links to the structures/unions they belong to:
+
+ + + + diff --git a/doxygen/html/functions_vars.html b/doxygen/html/functions_vars.html new file mode 100644 index 00000000..39d9ee6e --- /dev/null +++ b/doxygen/html/functions_vars.html @@ -0,0 +1,154 @@ + + + + + + + +note-c: Data Fields - Variables + + + + + + + + + +
+
+ + + + + + + +
+
note-c +  1.0 +
+
An easy to use Notecard Library for C/C++
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
+ + + + diff --git a/doxygen/html/globals.html b/doxygen/html/globals.html new file mode 100644 index 00000000..e9400030 --- /dev/null +++ b/doxygen/html/globals.html @@ -0,0 +1,80 @@ + + + + + + + +note-c: Globals + + + + + + + + + +
+
+ + + + + + + +
+
note-c +  1.0 +
+
An easy to use Notecard Library for C/C++
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
Here is a list of all functions, variables, defines, enums, and typedefs with links to the files they belong to:
+ +

- _ -

    +
  • _NOTE_C_STRINGIZE +: note.h +
  • +
+
+ + + + diff --git a/doxygen/html/globals_b.html b/doxygen/html/globals_b.html new file mode 100644 index 00000000..51350c30 --- /dev/null +++ b/doxygen/html/globals_b.html @@ -0,0 +1,80 @@ + + + + + + + +note-c: Globals + + + + + + + + + +
+
+ + + + + + + +
+
note-c +  1.0 +
+
An easy to use Notecard Library for C/C++
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
Here is a list of all functions, variables, defines, enums, and typedefs with links to the files they belong to:
+ +

- b -

+
+ + + + diff --git a/doxygen/html/globals_c.html b/doxygen/html/globals_c.html new file mode 100644 index 00000000..deedaabe --- /dev/null +++ b/doxygen/html/globals_c.html @@ -0,0 +1,98 @@ + + + + + + + +note-c: Globals + + + + + + + + + +
+
+ + + + + + + +
+
note-c +  1.0 +
+
An easy to use Notecard Library for C/C++
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
Here is a list of all functions, variables, defines, enums, and typedefs with links to the files they belong to:
+ +

- c -

+
+ + + + diff --git a/doxygen/html/globals_d.html b/doxygen/html/globals_d.html new file mode 100644 index 00000000..6474c3e7 --- /dev/null +++ b/doxygen/html/globals_d.html @@ -0,0 +1,83 @@ + + + + + + + +note-c: Globals + + + + + + + + + +
+
+ + + + + + + +
+
note-c +  1.0 +
+
An easy to use Notecard Library for C/C++
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
Here is a list of all functions, variables, defines, enums, and typedefs with links to the files they belong to:
+ +

- d -

+
+ + + + diff --git a/doxygen/html/globals_defs.html b/doxygen/html/globals_defs.html new file mode 100644 index 00000000..1b1ed2a5 --- /dev/null +++ b/doxygen/html/globals_defs.html @@ -0,0 +1,444 @@ + + + + + + + +note-c: Globals + + + + + + + + + +
+
+ + + + + + + +
+
note-c +  1.0 +
+
An easy to use Notecard Library for C/C++
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+  + +

- _ -

    +
  • _NOTE_C_STRINGIZE +: note.h +
  • +
+ + +

- b -

+ + +

- c -

+ + +

- e -

+ + +

- i -

+ + +

- j -

+ + +

- n -

+ + +

- p -

+ + +

- s -

    +
  • SYNCSTATUS_LEVEL_ALGORITHMIC +: note.h +
  • +
  • SYNCSTATUS_LEVEL_ALL +: note.h +
  • +
  • SYNCSTATUS_LEVEL_DETAILED +: note.h +
  • +
  • SYNCSTATUS_LEVEL_MAJOR +: note.h +
  • +
  • SYNCSTATUS_LEVEL_MINOR +: note.h +
  • +
+ + +

- t -

+
+ + + + diff --git a/doxygen/html/globals_e.html b/doxygen/html/globals_e.html new file mode 100644 index 00000000..1f4bcc5e --- /dev/null +++ b/doxygen/html/globals_e.html @@ -0,0 +1,80 @@ + + + + + + + +note-c: Globals + + + + + + + + + +
+
+ + + + + + + +
+
note-c +  1.0 +
+
An easy to use Notecard Library for C/C++
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
Here is a list of all functions, variables, defines, enums, and typedefs with links to the files they belong to:
+ +

- e -

+
+ + + + diff --git a/doxygen/html/globals_f.html b/doxygen/html/globals_f.html new file mode 100644 index 00000000..45afcb90 --- /dev/null +++ b/doxygen/html/globals_f.html @@ -0,0 +1,80 @@ + + + + + + + +note-c: Globals + + + + + + + + + +
+
+ + + + + + + +
+
note-c +  1.0 +
+
An easy to use Notecard Library for C/C++
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
Here is a list of all functions, variables, defines, enums, and typedefs with links to the files they belong to:
+ +

- f -

+
+ + + + diff --git a/doxygen/html/globals_func.html b/doxygen/html/globals_func.html new file mode 100644 index 00000000..48656b80 --- /dev/null +++ b/doxygen/html/globals_func.html @@ -0,0 +1,500 @@ + + + + + + + +note-c: Globals + + + + + + + + + +
+
+ + + + + + + +
+
note-c +  1.0 +
+
An easy to use Notecard Library for C/C++
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+  + +

- j -

+
+ + + + diff --git a/doxygen/html/globals_func_n.html b/doxygen/html/globals_func_n.html new file mode 100644 index 00000000..f719833f --- /dev/null +++ b/doxygen/html/globals_func_n.html @@ -0,0 +1,529 @@ + + + + + + + +note-c: Globals + + + + + + + + + +
+
+ + + + + + + +
+
note-c +  1.0 +
+
An easy to use Notecard Library for C/C++
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+  + +

- n -

+
+ + + + diff --git a/doxygen/html/globals_func_s.html b/doxygen/html/globals_func_s.html new file mode 100644 index 00000000..38547743 --- /dev/null +++ b/doxygen/html/globals_func_s.html @@ -0,0 +1,83 @@ + + + + + + + +note-c: Globals + + + + + + + + + +
+
+ + + + + + + +
+
note-c +  1.0 +
+
An easy to use Notecard Library for C/C++
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+  + +

- s -

+
+ + + + diff --git a/doxygen/html/globals_g.html b/doxygen/html/globals_g.html new file mode 100644 index 00000000..fccd7ea2 --- /dev/null +++ b/doxygen/html/globals_g.html @@ -0,0 +1,80 @@ + + + + + + + +note-c: Globals + + + + + + + + + +
+
+ + + + + + + +
+
note-c +  1.0 +
+
An easy to use Notecard Library for C/C++
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
Here is a list of all functions, variables, defines, enums, and typedefs with links to the files they belong to:
+ +

- g -

+
+ + + + diff --git a/doxygen/html/globals_h.html b/doxygen/html/globals_h.html new file mode 100644 index 00000000..2f252f76 --- /dev/null +++ b/doxygen/html/globals_h.html @@ -0,0 +1,134 @@ + + + + + + + +note-c: Globals + + + + + + + + + +
+
+ + + + + + + +
+
note-c +  1.0 +
+
An easy to use Notecard Library for C/C++
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
Here is a list of all functions, variables, defines, enums, and typedefs with links to the files they belong to:
+ +

- h -

+
+ + + + diff --git a/doxygen/html/globals_i.html b/doxygen/html/globals_i.html new file mode 100644 index 00000000..77039721 --- /dev/null +++ b/doxygen/html/globals_i.html @@ -0,0 +1,101 @@ + + + + + + + +note-c: Globals + + + + + + + + + +
+
+ + + + + + + +
+
note-c +  1.0 +
+
An easy to use Notecard Library for C/C++
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
Here is a list of all functions, variables, defines, enums, and typedefs with links to the files they belong to:
+ +

- i -

+
+ + + + diff --git a/doxygen/html/globals_j.html b/doxygen/html/globals_j.html new file mode 100644 index 00000000..852843cb --- /dev/null +++ b/doxygen/html/globals_j.html @@ -0,0 +1,635 @@ + + + + + + + +note-c: Globals + + + + + + + + + +
+
+ + + + + + + +
+
note-c +  1.0 +
+
An easy to use Notecard Library for C/C++
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
Here is a list of all functions, variables, defines, enums, and typedefs with links to the files they belong to:
+ +

- j -

+
+ + + + diff --git a/doxygen/html/globals_m.html b/doxygen/html/globals_m.html new file mode 100644 index 00000000..9a7695c2 --- /dev/null +++ b/doxygen/html/globals_m.html @@ -0,0 +1,83 @@ + + + + + + + +note-c: Globals + + + + + + + + + +
+
+ + + + + + + +
+
note-c +  1.0 +
+
An easy to use Notecard Library for C/C++
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
Here is a list of all functions, variables, defines, enums, and typedefs with links to the files they belong to:
+ +

- m -

+
+ + + + diff --git a/doxygen/html/globals_n.html b/doxygen/html/globals_n.html new file mode 100644 index 00000000..7cbc08d1 --- /dev/null +++ b/doxygen/html/globals_n.html @@ -0,0 +1,656 @@ + + + + + + + +note-c: Globals + + + + + + + + + +
+
+ + + + + + + +
+
note-c +  1.0 +
+
An easy to use Notecard Library for C/C++
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
Here is a list of all functions, variables, defines, enums, and typedefs with links to the files they belong to:
+ +

- n -

+
+ + + + diff --git a/doxygen/html/globals_p.html b/doxygen/html/globals_p.html new file mode 100644 index 00000000..09ce7209 --- /dev/null +++ b/doxygen/html/globals_p.html @@ -0,0 +1,80 @@ + + + + + + + +note-c: Globals + + + + + + + + + +
+
+ + + + + + + +
+
note-c +  1.0 +
+
An easy to use Notecard Library for C/C++
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
Here is a list of all functions, variables, defines, enums, and typedefs with links to the files they belong to:
+ +

- p -

+
+ + + + diff --git a/doxygen/html/globals_s.html b/doxygen/html/globals_s.html new file mode 100644 index 00000000..d8964a47 --- /dev/null +++ b/doxygen/html/globals_s.html @@ -0,0 +1,110 @@ + + + + + + + +note-c: Globals + + + + + + + + + +
+
+ + + + + + + +
+
note-c +  1.0 +
+
An easy to use Notecard Library for C/C++
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
Here is a list of all functions, variables, defines, enums, and typedefs with links to the files they belong to:
+ +

- s -

    +
  • serialAvailableFn +: note.h +
  • +
  • serialReceiveFn +: note.h +
  • +
  • serialResetFn +: note.h +
  • +
  • serialTransmitFn +: note.h +
  • +
  • strlcat() +: note.h +
  • +
  • strlcpy() +: note.h +
  • +
  • SYNCSTATUS_LEVEL_ALGORITHMIC +: note.h +
  • +
  • SYNCSTATUS_LEVEL_ALL +: note.h +
  • +
  • SYNCSTATUS_LEVEL_DETAILED +: note.h +
  • +
  • SYNCSTATUS_LEVEL_MAJOR +: note.h +
  • +
  • SYNCSTATUS_LEVEL_MINOR +: note.h +
  • +
+
+ + + + diff --git a/doxygen/html/globals_t.html b/doxygen/html/globals_t.html new file mode 100644 index 00000000..1f834990 --- /dev/null +++ b/doxygen/html/globals_t.html @@ -0,0 +1,128 @@ + + + + + + + +note-c: Globals + + + + + + + + + +
+
+ + + + + + + +
+
note-c +  1.0 +
+
An easy to use Notecard Library for C/C++
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
Here is a list of all functions, variables, defines, enums, and typedefs with links to the files they belong to:
+ +

- t -

+
+ + + + diff --git a/doxygen/html/globals_type.html b/doxygen/html/globals_type.html new file mode 100644 index 00000000..a135e541 --- /dev/null +++ b/doxygen/html/globals_type.html @@ -0,0 +1,153 @@ + + + + + + + +note-c: Globals + + + + + + + + + +
+
+ + + + + + + +
+
note-c +  1.0 +
+
An easy to use Notecard Library for C/C++
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
+ + + + diff --git a/doxygen/html/globals_vars.html b/doxygen/html/globals_vars.html new file mode 100644 index 00000000..e516de98 --- /dev/null +++ b/doxygen/html/globals_vars.html @@ -0,0 +1,138 @@ + + + + + + + +note-c: Globals + + + + + + + + + +
+
+ + + + + + + +
+
note-c +  1.0 +
+
An easy to use Notecard Library for C/C++
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
+ + + + diff --git a/doxygen/html/index.html b/doxygen/html/index.html new file mode 100644 index 00000000..50888d2b --- /dev/null +++ b/doxygen/html/index.html @@ -0,0 +1,77 @@ + + + + + + + +note-c: Main Page + + + + + + + + + +
+
+ + + + + + + +
+
note-c +  1.0 +
+
An easy to use Notecard Library for C/C++
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
+
note-c Documentation
+
+
+
+ + + + diff --git a/doxygen/html/jquery.js b/doxygen/html/jquery.js new file mode 100644 index 00000000..103c32d7 --- /dev/null +++ b/doxygen/html/jquery.js @@ -0,0 +1,35 @@ +/*! jQuery v3.4.1 | (c) JS Foundation and other contributors | jquery.org/license */ +!function(e,t){"use strict";"object"==typeof module&&"object"==typeof module.exports?module.exports=e.document?t(e,!0):function(e){if(!e.document)throw new Error("jQuery requires a window with a document");return t(e)}:t(e)}("undefined"!=typeof window?window:this,function(C,e){"use strict";var t=[],E=C.document,r=Object.getPrototypeOf,s=t.slice,g=t.concat,u=t.push,i=t.indexOf,n={},o=n.toString,v=n.hasOwnProperty,a=v.toString,l=a.call(Object),y={},m=function(e){return"function"==typeof e&&"number"!=typeof e.nodeType},x=function(e){return null!=e&&e===e.window},c={type:!0,src:!0,nonce:!0,noModule:!0};function b(e,t,n){var r,i,o=(n=n||E).createElement("script");if(o.text=e,t)for(r in c)(i=t[r]||t.getAttribute&&t.getAttribute(r))&&o.setAttribute(r,i);n.head.appendChild(o).parentNode.removeChild(o)}function w(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?n[o.call(e)]||"object":typeof e}var f="3.4.1",k=function(e,t){return new k.fn.init(e,t)},p=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g;function d(e){var t=!!e&&"length"in e&&e.length,n=w(e);return!m(e)&&!x(e)&&("array"===n||0===t||"number"==typeof t&&0+~]|"+M+")"+M+"*"),U=new RegExp(M+"|>"),X=new RegExp($),V=new RegExp("^"+I+"$"),G={ID:new RegExp("^#("+I+")"),CLASS:new RegExp("^\\.("+I+")"),TAG:new RegExp("^("+I+"|[*])"),ATTR:new RegExp("^"+W),PSEUDO:new RegExp("^"+$),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+M+"*(even|odd|(([+-]|)(\\d*)n|)"+M+"*(?:([+-]|)"+M+"*(\\d+)|))"+M+"*\\)|)","i"),bool:new RegExp("^(?:"+R+")$","i"),needsContext:new RegExp("^"+M+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+M+"*((?:-\\d)?\\d*)"+M+"*\\)|)(?=[^-]|$)","i")},Y=/HTML$/i,Q=/^(?:input|select|textarea|button)$/i,J=/^h\d$/i,K=/^[^{]+\{\s*\[native \w/,Z=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,ee=/[+~]/,te=new RegExp("\\\\([\\da-f]{1,6}"+M+"?|("+M+")|.)","ig"),ne=function(e,t,n){var r="0x"+t-65536;return r!=r||n?t:r<0?String.fromCharCode(r+65536):String.fromCharCode(r>>10|55296,1023&r|56320)},re=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\0-\x1f\x7f-\uFFFF\w-]/g,ie=function(e,t){return t?"\0"===e?"\ufffd":e.slice(0,-1)+"\\"+e.charCodeAt(e.length-1).toString(16)+" ":"\\"+e},oe=function(){T()},ae=be(function(e){return!0===e.disabled&&"fieldset"===e.nodeName.toLowerCase()},{dir:"parentNode",next:"legend"});try{H.apply(t=O.call(m.childNodes),m.childNodes),t[m.childNodes.length].nodeType}catch(e){H={apply:t.length?function(e,t){L.apply(e,O.call(t))}:function(e,t){var n=e.length,r=0;while(e[n++]=t[r++]);e.length=n-1}}}function se(t,e,n,r){var i,o,a,s,u,l,c,f=e&&e.ownerDocument,p=e?e.nodeType:9;if(n=n||[],"string"!=typeof t||!t||1!==p&&9!==p&&11!==p)return n;if(!r&&((e?e.ownerDocument||e:m)!==C&&T(e),e=e||C,E)){if(11!==p&&(u=Z.exec(t)))if(i=u[1]){if(9===p){if(!(a=e.getElementById(i)))return n;if(a.id===i)return n.push(a),n}else if(f&&(a=f.getElementById(i))&&y(e,a)&&a.id===i)return n.push(a),n}else{if(u[2])return H.apply(n,e.getElementsByTagName(t)),n;if((i=u[3])&&d.getElementsByClassName&&e.getElementsByClassName)return H.apply(n,e.getElementsByClassName(i)),n}if(d.qsa&&!A[t+" "]&&(!v||!v.test(t))&&(1!==p||"object"!==e.nodeName.toLowerCase())){if(c=t,f=e,1===p&&U.test(t)){(s=e.getAttribute("id"))?s=s.replace(re,ie):e.setAttribute("id",s=k),o=(l=h(t)).length;while(o--)l[o]="#"+s+" "+xe(l[o]);c=l.join(","),f=ee.test(t)&&ye(e.parentNode)||e}try{return H.apply(n,f.querySelectorAll(c)),n}catch(e){A(t,!0)}finally{s===k&&e.removeAttribute("id")}}}return g(t.replace(B,"$1"),e,n,r)}function ue(){var r=[];return function e(t,n){return r.push(t+" ")>b.cacheLength&&delete e[r.shift()],e[t+" "]=n}}function le(e){return e[k]=!0,e}function ce(e){var t=C.createElement("fieldset");try{return!!e(t)}catch(e){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function fe(e,t){var n=e.split("|"),r=n.length;while(r--)b.attrHandle[n[r]]=t}function pe(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&e.sourceIndex-t.sourceIndex;if(r)return r;if(n)while(n=n.nextSibling)if(n===t)return-1;return e?1:-1}function de(t){return function(e){return"input"===e.nodeName.toLowerCase()&&e.type===t}}function he(n){return function(e){var t=e.nodeName.toLowerCase();return("input"===t||"button"===t)&&e.type===n}}function ge(t){return function(e){return"form"in e?e.parentNode&&!1===e.disabled?"label"in e?"label"in e.parentNode?e.parentNode.disabled===t:e.disabled===t:e.isDisabled===t||e.isDisabled!==!t&&ae(e)===t:e.disabled===t:"label"in e&&e.disabled===t}}function ve(a){return le(function(o){return o=+o,le(function(e,t){var n,r=a([],e.length,o),i=r.length;while(i--)e[n=r[i]]&&(e[n]=!(t[n]=e[n]))})})}function ye(e){return e&&"undefined"!=typeof e.getElementsByTagName&&e}for(e in d=se.support={},i=se.isXML=function(e){var t=e.namespaceURI,n=(e.ownerDocument||e).documentElement;return!Y.test(t||n&&n.nodeName||"HTML")},T=se.setDocument=function(e){var t,n,r=e?e.ownerDocument||e:m;return r!==C&&9===r.nodeType&&r.documentElement&&(a=(C=r).documentElement,E=!i(C),m!==C&&(n=C.defaultView)&&n.top!==n&&(n.addEventListener?n.addEventListener("unload",oe,!1):n.attachEvent&&n.attachEvent("onunload",oe)),d.attributes=ce(function(e){return e.className="i",!e.getAttribute("className")}),d.getElementsByTagName=ce(function(e){return e.appendChild(C.createComment("")),!e.getElementsByTagName("*").length}),d.getElementsByClassName=K.test(C.getElementsByClassName),d.getById=ce(function(e){return a.appendChild(e).id=k,!C.getElementsByName||!C.getElementsByName(k).length}),d.getById?(b.filter.ID=function(e){var t=e.replace(te,ne);return function(e){return e.getAttribute("id")===t}},b.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&E){var n=t.getElementById(e);return n?[n]:[]}}):(b.filter.ID=function(e){var n=e.replace(te,ne);return function(e){var t="undefined"!=typeof e.getAttributeNode&&e.getAttributeNode("id");return t&&t.value===n}},b.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&E){var n,r,i,o=t.getElementById(e);if(o){if((n=o.getAttributeNode("id"))&&n.value===e)return[o];i=t.getElementsByName(e),r=0;while(o=i[r++])if((n=o.getAttributeNode("id"))&&n.value===e)return[o]}return[]}}),b.find.TAG=d.getElementsByTagName?function(e,t){return"undefined"!=typeof t.getElementsByTagName?t.getElementsByTagName(e):d.qsa?t.querySelectorAll(e):void 0}:function(e,t){var n,r=[],i=0,o=t.getElementsByTagName(e);if("*"===e){while(n=o[i++])1===n.nodeType&&r.push(n);return r}return o},b.find.CLASS=d.getElementsByClassName&&function(e,t){if("undefined"!=typeof t.getElementsByClassName&&E)return t.getElementsByClassName(e)},s=[],v=[],(d.qsa=K.test(C.querySelectorAll))&&(ce(function(e){a.appendChild(e).innerHTML="",e.querySelectorAll("[msallowcapture^='']").length&&v.push("[*^$]="+M+"*(?:''|\"\")"),e.querySelectorAll("[selected]").length||v.push("\\["+M+"*(?:value|"+R+")"),e.querySelectorAll("[id~="+k+"-]").length||v.push("~="),e.querySelectorAll(":checked").length||v.push(":checked"),e.querySelectorAll("a#"+k+"+*").length||v.push(".#.+[+~]")}),ce(function(e){e.innerHTML="";var t=C.createElement("input");t.setAttribute("type","hidden"),e.appendChild(t).setAttribute("name","D"),e.querySelectorAll("[name=d]").length&&v.push("name"+M+"*[*^$|!~]?="),2!==e.querySelectorAll(":enabled").length&&v.push(":enabled",":disabled"),a.appendChild(e).disabled=!0,2!==e.querySelectorAll(":disabled").length&&v.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),v.push(",.*:")})),(d.matchesSelector=K.test(c=a.matches||a.webkitMatchesSelector||a.mozMatchesSelector||a.oMatchesSelector||a.msMatchesSelector))&&ce(function(e){d.disconnectedMatch=c.call(e,"*"),c.call(e,"[s!='']:x"),s.push("!=",$)}),v=v.length&&new RegExp(v.join("|")),s=s.length&&new RegExp(s.join("|")),t=K.test(a.compareDocumentPosition),y=t||K.test(a.contains)?function(e,t){var n=9===e.nodeType?e.documentElement:e,r=t&&t.parentNode;return e===r||!(!r||1!==r.nodeType||!(n.contains?n.contains(r):e.compareDocumentPosition&&16&e.compareDocumentPosition(r)))}:function(e,t){if(t)while(t=t.parentNode)if(t===e)return!0;return!1},D=t?function(e,t){if(e===t)return l=!0,0;var n=!e.compareDocumentPosition-!t.compareDocumentPosition;return n||(1&(n=(e.ownerDocument||e)===(t.ownerDocument||t)?e.compareDocumentPosition(t):1)||!d.sortDetached&&t.compareDocumentPosition(e)===n?e===C||e.ownerDocument===m&&y(m,e)?-1:t===C||t.ownerDocument===m&&y(m,t)?1:u?P(u,e)-P(u,t):0:4&n?-1:1)}:function(e,t){if(e===t)return l=!0,0;var n,r=0,i=e.parentNode,o=t.parentNode,a=[e],s=[t];if(!i||!o)return e===C?-1:t===C?1:i?-1:o?1:u?P(u,e)-P(u,t):0;if(i===o)return pe(e,t);n=e;while(n=n.parentNode)a.unshift(n);n=t;while(n=n.parentNode)s.unshift(n);while(a[r]===s[r])r++;return r?pe(a[r],s[r]):a[r]===m?-1:s[r]===m?1:0}),C},se.matches=function(e,t){return se(e,null,null,t)},se.matchesSelector=function(e,t){if((e.ownerDocument||e)!==C&&T(e),d.matchesSelector&&E&&!A[t+" "]&&(!s||!s.test(t))&&(!v||!v.test(t)))try{var n=c.call(e,t);if(n||d.disconnectedMatch||e.document&&11!==e.document.nodeType)return n}catch(e){A(t,!0)}return 0":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(te,ne),e[3]=(e[3]||e[4]||e[5]||"").replace(te,ne),"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||se.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&se.error(e[0]),e},PSEUDO:function(e){var t,n=!e[6]&&e[2];return G.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":n&&X.test(n)&&(t=h(n,!0))&&(t=n.indexOf(")",n.length-t)-n.length)&&(e[0]=e[0].slice(0,t),e[2]=n.slice(0,t)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(te,ne).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=p[e+" "];return t||(t=new RegExp("(^|"+M+")"+e+"("+M+"|$)"))&&p(e,function(e){return t.test("string"==typeof e.className&&e.className||"undefined"!=typeof e.getAttribute&&e.getAttribute("class")||"")})},ATTR:function(n,r,i){return function(e){var t=se.attr(e,n);return null==t?"!="===r:!r||(t+="","="===r?t===i:"!="===r?t!==i:"^="===r?i&&0===t.indexOf(i):"*="===r?i&&-1:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;function j(e,n,r){return m(n)?k.grep(e,function(e,t){return!!n.call(e,t,e)!==r}):n.nodeType?k.grep(e,function(e){return e===n!==r}):"string"!=typeof n?k.grep(e,function(e){return-1)[^>]*|#([\w-]+))$/;(k.fn.init=function(e,t,n){var r,i;if(!e)return this;if(n=n||q,"string"==typeof e){if(!(r="<"===e[0]&&">"===e[e.length-1]&&3<=e.length?[null,e,null]:L.exec(e))||!r[1]&&t)return!t||t.jquery?(t||n).find(e):this.constructor(t).find(e);if(r[1]){if(t=t instanceof k?t[0]:t,k.merge(this,k.parseHTML(r[1],t&&t.nodeType?t.ownerDocument||t:E,!0)),D.test(r[1])&&k.isPlainObject(t))for(r in t)m(this[r])?this[r](t[r]):this.attr(r,t[r]);return this}return(i=E.getElementById(r[2]))&&(this[0]=i,this.length=1),this}return e.nodeType?(this[0]=e,this.length=1,this):m(e)?void 0!==n.ready?n.ready(e):e(k):k.makeArray(e,this)}).prototype=k.fn,q=k(E);var H=/^(?:parents|prev(?:Until|All))/,O={children:!0,contents:!0,next:!0,prev:!0};function P(e,t){while((e=e[t])&&1!==e.nodeType);return e}k.fn.extend({has:function(e){var t=k(e,this),n=t.length;return this.filter(function(){for(var e=0;e\x20\t\r\n\f]*)/i,he=/^$|^module$|\/(?:java|ecma)script/i,ge={option:[1,""],thead:[1,"","
"],col:[2,"","
"],tr:[2,"","
"],td:[3,"","
"],_default:[0,"",""]};function ve(e,t){var n;return n="undefined"!=typeof e.getElementsByTagName?e.getElementsByTagName(t||"*"):"undefined"!=typeof e.querySelectorAll?e.querySelectorAll(t||"*"):[],void 0===t||t&&A(e,t)?k.merge([e],n):n}function ye(e,t){for(var n=0,r=e.length;nx",y.noCloneChecked=!!me.cloneNode(!0).lastChild.defaultValue;var Te=/^key/,Ce=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,Ee=/^([^.]*)(?:\.(.+)|)/;function ke(){return!0}function Se(){return!1}function Ne(e,t){return e===function(){try{return E.activeElement}catch(e){}}()==("focus"===t)}function Ae(e,t,n,r,i,o){var a,s;if("object"==typeof t){for(s in"string"!=typeof n&&(r=r||n,n=void 0),t)Ae(e,s,n,r,t[s],o);return e}if(null==r&&null==i?(i=n,r=n=void 0):null==i&&("string"==typeof n?(i=r,r=void 0):(i=r,r=n,n=void 0)),!1===i)i=Se;else if(!i)return e;return 1===o&&(a=i,(i=function(e){return k().off(e),a.apply(this,arguments)}).guid=a.guid||(a.guid=k.guid++)),e.each(function(){k.event.add(this,t,i,r,n)})}function De(e,i,o){o?(Q.set(e,i,!1),k.event.add(e,i,{namespace:!1,handler:function(e){var t,n,r=Q.get(this,i);if(1&e.isTrigger&&this[i]){if(r.length)(k.event.special[i]||{}).delegateType&&e.stopPropagation();else if(r=s.call(arguments),Q.set(this,i,r),t=o(this,i),this[i](),r!==(n=Q.get(this,i))||t?Q.set(this,i,!1):n={},r!==n)return e.stopImmediatePropagation(),e.preventDefault(),n.value}else r.length&&(Q.set(this,i,{value:k.event.trigger(k.extend(r[0],k.Event.prototype),r.slice(1),this)}),e.stopImmediatePropagation())}})):void 0===Q.get(e,i)&&k.event.add(e,i,ke)}k.event={global:{},add:function(t,e,n,r,i){var o,a,s,u,l,c,f,p,d,h,g,v=Q.get(t);if(v){n.handler&&(n=(o=n).handler,i=o.selector),i&&k.find.matchesSelector(ie,i),n.guid||(n.guid=k.guid++),(u=v.events)||(u=v.events={}),(a=v.handle)||(a=v.handle=function(e){return"undefined"!=typeof k&&k.event.triggered!==e.type?k.event.dispatch.apply(t,arguments):void 0}),l=(e=(e||"").match(R)||[""]).length;while(l--)d=g=(s=Ee.exec(e[l])||[])[1],h=(s[2]||"").split(".").sort(),d&&(f=k.event.special[d]||{},d=(i?f.delegateType:f.bindType)||d,f=k.event.special[d]||{},c=k.extend({type:d,origType:g,data:r,handler:n,guid:n.guid,selector:i,needsContext:i&&k.expr.match.needsContext.test(i),namespace:h.join(".")},o),(p=u[d])||((p=u[d]=[]).delegateCount=0,f.setup&&!1!==f.setup.call(t,r,h,a)||t.addEventListener&&t.addEventListener(d,a)),f.add&&(f.add.call(t,c),c.handler.guid||(c.handler.guid=n.guid)),i?p.splice(p.delegateCount++,0,c):p.push(c),k.event.global[d]=!0)}},remove:function(e,t,n,r,i){var o,a,s,u,l,c,f,p,d,h,g,v=Q.hasData(e)&&Q.get(e);if(v&&(u=v.events)){l=(t=(t||"").match(R)||[""]).length;while(l--)if(d=g=(s=Ee.exec(t[l])||[])[1],h=(s[2]||"").split(".").sort(),d){f=k.event.special[d]||{},p=u[d=(r?f.delegateType:f.bindType)||d]||[],s=s[2]&&new RegExp("(^|\\.)"+h.join("\\.(?:.*\\.|)")+"(\\.|$)"),a=o=p.length;while(o--)c=p[o],!i&&g!==c.origType||n&&n.guid!==c.guid||s&&!s.test(c.namespace)||r&&r!==c.selector&&("**"!==r||!c.selector)||(p.splice(o,1),c.selector&&p.delegateCount--,f.remove&&f.remove.call(e,c));a&&!p.length&&(f.teardown&&!1!==f.teardown.call(e,h,v.handle)||k.removeEvent(e,d,v.handle),delete u[d])}else for(d in u)k.event.remove(e,d+t[l],n,r,!0);k.isEmptyObject(u)&&Q.remove(e,"handle events")}},dispatch:function(e){var t,n,r,i,o,a,s=k.event.fix(e),u=new Array(arguments.length),l=(Q.get(this,"events")||{})[s.type]||[],c=k.event.special[s.type]||{};for(u[0]=s,t=1;t\x20\t\r\n\f]*)[^>]*)\/>/gi,qe=/\s*$/g;function Oe(e,t){return A(e,"table")&&A(11!==t.nodeType?t:t.firstChild,"tr")&&k(e).children("tbody")[0]||e}function Pe(e){return e.type=(null!==e.getAttribute("type"))+"/"+e.type,e}function Re(e){return"true/"===(e.type||"").slice(0,5)?e.type=e.type.slice(5):e.removeAttribute("type"),e}function Me(e,t){var n,r,i,o,a,s,u,l;if(1===t.nodeType){if(Q.hasData(e)&&(o=Q.access(e),a=Q.set(t,o),l=o.events))for(i in delete a.handle,a.events={},l)for(n=0,r=l[i].length;n")},clone:function(e,t,n){var r,i,o,a,s,u,l,c=e.cloneNode(!0),f=oe(e);if(!(y.noCloneChecked||1!==e.nodeType&&11!==e.nodeType||k.isXMLDoc(e)))for(a=ve(c),r=0,i=(o=ve(e)).length;r").attr(n.scriptAttrs||{}).prop({charset:n.scriptCharset,src:n.url}).on("load error",i=function(e){r.remove(),i=null,e&&t("error"===e.type?404:200,e.type)}),E.head.appendChild(r[0])},abort:function(){i&&i()}}});var Vt,Gt=[],Yt=/(=)\?(?=&|$)|\?\?/;k.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var e=Gt.pop()||k.expando+"_"+kt++;return this[e]=!0,e}}),k.ajaxPrefilter("json jsonp",function(e,t,n){var r,i,o,a=!1!==e.jsonp&&(Yt.test(e.url)?"url":"string"==typeof e.data&&0===(e.contentType||"").indexOf("application/x-www-form-urlencoded")&&Yt.test(e.data)&&"data");if(a||"jsonp"===e.dataTypes[0])return r=e.jsonpCallback=m(e.jsonpCallback)?e.jsonpCallback():e.jsonpCallback,a?e[a]=e[a].replace(Yt,"$1"+r):!1!==e.jsonp&&(e.url+=(St.test(e.url)?"&":"?")+e.jsonp+"="+r),e.converters["script json"]=function(){return o||k.error(r+" was not called"),o[0]},e.dataTypes[0]="json",i=C[r],C[r]=function(){o=arguments},n.always(function(){void 0===i?k(C).removeProp(r):C[r]=i,e[r]&&(e.jsonpCallback=t.jsonpCallback,Gt.push(r)),o&&m(i)&&i(o[0]),o=i=void 0}),"script"}),y.createHTMLDocument=((Vt=E.implementation.createHTMLDocument("").body).innerHTML="
",2===Vt.childNodes.length),k.parseHTML=function(e,t,n){return"string"!=typeof e?[]:("boolean"==typeof t&&(n=t,t=!1),t||(y.createHTMLDocument?((r=(t=E.implementation.createHTMLDocument("")).createElement("base")).href=E.location.href,t.head.appendChild(r)):t=E),o=!n&&[],(i=D.exec(e))?[t.createElement(i[1])]:(i=we([e],t,o),o&&o.length&&k(o).remove(),k.merge([],i.childNodes)));var r,i,o},k.fn.load=function(e,t,n){var r,i,o,a=this,s=e.indexOf(" ");return-1").append(k.parseHTML(e)).find(r):e)}).always(n&&function(e,t){a.each(function(){n.apply(this,o||[e.responseText,t,e])})}),this},k.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(e,t){k.fn[t]=function(e){return this.on(t,e)}}),k.expr.pseudos.animated=function(t){return k.grep(k.timers,function(e){return t===e.elem}).length},k.offset={setOffset:function(e,t,n){var r,i,o,a,s,u,l=k.css(e,"position"),c=k(e),f={};"static"===l&&(e.style.position="relative"),s=c.offset(),o=k.css(e,"top"),u=k.css(e,"left"),("absolute"===l||"fixed"===l)&&-1<(o+u).indexOf("auto")?(a=(r=c.position()).top,i=r.left):(a=parseFloat(o)||0,i=parseFloat(u)||0),m(t)&&(t=t.call(e,n,k.extend({},s))),null!=t.top&&(f.top=t.top-s.top+a),null!=t.left&&(f.left=t.left-s.left+i),"using"in t?t.using.call(e,f):c.css(f)}},k.fn.extend({offset:function(t){if(arguments.length)return void 0===t?this:this.each(function(e){k.offset.setOffset(this,t,e)});var e,n,r=this[0];return r?r.getClientRects().length?(e=r.getBoundingClientRect(),n=r.ownerDocument.defaultView,{top:e.top+n.pageYOffset,left:e.left+n.pageXOffset}):{top:0,left:0}:void 0},position:function(){if(this[0]){var e,t,n,r=this[0],i={top:0,left:0};if("fixed"===k.css(r,"position"))t=r.getBoundingClientRect();else{t=this.offset(),n=r.ownerDocument,e=r.offsetParent||n.documentElement;while(e&&(e===n.body||e===n.documentElement)&&"static"===k.css(e,"position"))e=e.parentNode;e&&e!==r&&1===e.nodeType&&((i=k(e).offset()).top+=k.css(e,"borderTopWidth",!0),i.left+=k.css(e,"borderLeftWidth",!0))}return{top:t.top-i.top-k.css(r,"marginTop",!0),left:t.left-i.left-k.css(r,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){var e=this.offsetParent;while(e&&"static"===k.css(e,"position"))e=e.offsetParent;return e||ie})}}),k.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(t,i){var o="pageYOffset"===i;k.fn[t]=function(e){return _(this,function(e,t,n){var r;if(x(e)?r=e:9===e.nodeType&&(r=e.defaultView),void 0===n)return r?r[i]:e[t];r?r.scrollTo(o?r.pageXOffset:n,o?n:r.pageYOffset):e[t]=n},t,e,arguments.length)}}),k.each(["top","left"],function(e,n){k.cssHooks[n]=ze(y.pixelPosition,function(e,t){if(t)return t=_e(e,n),$e.test(t)?k(e).position()[n]+"px":t})}),k.each({Height:"height",Width:"width"},function(a,s){k.each({padding:"inner"+a,content:s,"":"outer"+a},function(r,o){k.fn[o]=function(e,t){var n=arguments.length&&(r||"boolean"!=typeof e),i=r||(!0===e||!0===t?"margin":"border");return _(this,function(e,t,n){var r;return x(e)?0===o.indexOf("outer")?e["inner"+a]:e.document.documentElement["client"+a]:9===e.nodeType?(r=e.documentElement,Math.max(e.body["scroll"+a],r["scroll"+a],e.body["offset"+a],r["offset"+a],r["client"+a])):void 0===n?k.css(e,t,i):k.style(e,t,n,i)},s,n?e:void 0,n)}})}),k.each("blur focus focusin focusout resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu".split(" "),function(e,n){k.fn[n]=function(e,t){return 0a;a++)for(i in o[a])n=o[a][i],o[a].hasOwnProperty(i)&&void 0!==n&&(e[i]=t.isPlainObject(n)?t.isPlainObject(e[i])?t.widget.extend({},e[i],n):t.widget.extend({},n):n);return e},t.widget.bridge=function(e,i){var n=i.prototype.widgetFullName||e;t.fn[e]=function(o){var a="string"==typeof o,r=s.call(arguments,1),h=this;return a?this.length||"instance"!==o?this.each(function(){var i,s=t.data(this,n);return"instance"===o?(h=s,!1):s?t.isFunction(s[o])&&"_"!==o.charAt(0)?(i=s[o].apply(s,r),i!==s&&void 0!==i?(h=i&&i.jquery?h.pushStack(i.get()):i,!1):void 0):t.error("no such method '"+o+"' for "+e+" widget instance"):t.error("cannot call methods on "+e+" prior to initialization; "+"attempted to call method '"+o+"'")}):h=void 0:(r.length&&(o=t.widget.extend.apply(null,[o].concat(r))),this.each(function(){var e=t.data(this,n);e?(e.option(o||{}),e._init&&e._init()):t.data(this,n,new i(o,this))})),h}},t.Widget=function(){},t.Widget._childConstructors=[],t.Widget.prototype={widgetName:"widget",widgetEventPrefix:"",defaultElement:"
",options:{classes:{},disabled:!1,create:null},_createWidget:function(e,s){s=t(s||this.defaultElement||this)[0],this.element=t(s),this.uuid=i++,this.eventNamespace="."+this.widgetName+this.uuid,this.bindings=t(),this.hoverable=t(),this.focusable=t(),this.classesElementLookup={},s!==this&&(t.data(s,this.widgetFullName,this),this._on(!0,this.element,{remove:function(t){t.target===s&&this.destroy()}}),this.document=t(s.style?s.ownerDocument:s.document||s),this.window=t(this.document[0].defaultView||this.document[0].parentWindow)),this.options=t.widget.extend({},this.options,this._getCreateOptions(),e),this._create(),this.options.disabled&&this._setOptionDisabled(this.options.disabled),this._trigger("create",null,this._getCreateEventData()),this._init()},_getCreateOptions:function(){return{}},_getCreateEventData:t.noop,_create:t.noop,_init:t.noop,destroy:function(){var e=this;this._destroy(),t.each(this.classesElementLookup,function(t,i){e._removeClass(i,t)}),this.element.off(this.eventNamespace).removeData(this.widgetFullName),this.widget().off(this.eventNamespace).removeAttr("aria-disabled"),this.bindings.off(this.eventNamespace)},_destroy:t.noop,widget:function(){return this.element},option:function(e,i){var s,n,o,a=e;if(0===arguments.length)return t.widget.extend({},this.options);if("string"==typeof e)if(a={},s=e.split("."),e=s.shift(),s.length){for(n=a[e]=t.widget.extend({},this.options[e]),o=0;s.length-1>o;o++)n[s[o]]=n[s[o]]||{},n=n[s[o]];if(e=s.pop(),1===arguments.length)return void 0===n[e]?null:n[e];n[e]=i}else{if(1===arguments.length)return void 0===this.options[e]?null:this.options[e];a[e]=i}return this._setOptions(a),this},_setOptions:function(t){var e;for(e in t)this._setOption(e,t[e]);return this},_setOption:function(t,e){return"classes"===t&&this._setOptionClasses(e),this.options[t]=e,"disabled"===t&&this._setOptionDisabled(e),this},_setOptionClasses:function(e){var i,s,n;for(i in e)n=this.classesElementLookup[i],e[i]!==this.options.classes[i]&&n&&n.length&&(s=t(n.get()),this._removeClass(n,i),s.addClass(this._classes({element:s,keys:i,classes:e,add:!0})))},_setOptionDisabled:function(t){this._toggleClass(this.widget(),this.widgetFullName+"-disabled",null,!!t),t&&(this._removeClass(this.hoverable,null,"ui-state-hover"),this._removeClass(this.focusable,null,"ui-state-focus"))},enable:function(){return this._setOptions({disabled:!1})},disable:function(){return this._setOptions({disabled:!0})},_classes:function(e){function i(i,o){var a,r;for(r=0;i.length>r;r++)a=n.classesElementLookup[i[r]]||t(),a=e.add?t(t.unique(a.get().concat(e.element.get()))):t(a.not(e.element).get()),n.classesElementLookup[i[r]]=a,s.push(i[r]),o&&e.classes[i[r]]&&s.push(e.classes[i[r]])}var s=[],n=this;return e=t.extend({element:this.element,classes:this.options.classes||{}},e),this._on(e.element,{remove:"_untrackClassesElement"}),e.keys&&i(e.keys.match(/\S+/g)||[],!0),e.extra&&i(e.extra.match(/\S+/g)||[]),s.join(" ")},_untrackClassesElement:function(e){var i=this;t.each(i.classesElementLookup,function(s,n){-1!==t.inArray(e.target,n)&&(i.classesElementLookup[s]=t(n.not(e.target).get()))})},_removeClass:function(t,e,i){return this._toggleClass(t,e,i,!1)},_addClass:function(t,e,i){return this._toggleClass(t,e,i,!0)},_toggleClass:function(t,e,i,s){s="boolean"==typeof s?s:i;var n="string"==typeof t||null===t,o={extra:n?e:i,keys:n?t:e,element:n?this.element:t,add:s};return o.element.toggleClass(this._classes(o),s),this},_on:function(e,i,s){var n,o=this;"boolean"!=typeof e&&(s=i,i=e,e=!1),s?(i=n=t(i),this.bindings=this.bindings.add(i)):(s=i,i=this.element,n=this.widget()),t.each(s,function(s,a){function r(){return e||o.options.disabled!==!0&&!t(this).hasClass("ui-state-disabled")?("string"==typeof a?o[a]:a).apply(o,arguments):void 0}"string"!=typeof a&&(r.guid=a.guid=a.guid||r.guid||t.guid++);var h=s.match(/^([\w:-]*)\s*(.*)$/),l=h[1]+o.eventNamespace,c=h[2];c?n.on(l,c,r):i.on(l,r)})},_off:function(e,i){i=(i||"").split(" ").join(this.eventNamespace+" ")+this.eventNamespace,e.off(i).off(i),this.bindings=t(this.bindings.not(e).get()),this.focusable=t(this.focusable.not(e).get()),this.hoverable=t(this.hoverable.not(e).get())},_delay:function(t,e){function i(){return("string"==typeof t?s[t]:t).apply(s,arguments)}var s=this;return setTimeout(i,e||0)},_hoverable:function(e){this.hoverable=this.hoverable.add(e),this._on(e,{mouseenter:function(e){this._addClass(t(e.currentTarget),null,"ui-state-hover")},mouseleave:function(e){this._removeClass(t(e.currentTarget),null,"ui-state-hover")}})},_focusable:function(e){this.focusable=this.focusable.add(e),this._on(e,{focusin:function(e){this._addClass(t(e.currentTarget),null,"ui-state-focus")},focusout:function(e){this._removeClass(t(e.currentTarget),null,"ui-state-focus")}})},_trigger:function(e,i,s){var n,o,a=this.options[e];if(s=s||{},i=t.Event(i),i.type=(e===this.widgetEventPrefix?e:this.widgetEventPrefix+e).toLowerCase(),i.target=this.element[0],o=i.originalEvent)for(n in o)n in i||(i[n]=o[n]);return this.element.trigger(i,s),!(t.isFunction(a)&&a.apply(this.element[0],[i].concat(s))===!1||i.isDefaultPrevented())}},t.each({show:"fadeIn",hide:"fadeOut"},function(e,i){t.Widget.prototype["_"+e]=function(s,n,o){"string"==typeof n&&(n={effect:n});var a,r=n?n===!0||"number"==typeof n?i:n.effect||i:e;n=n||{},"number"==typeof n&&(n={duration:n}),a=!t.isEmptyObject(n),n.complete=o,n.delay&&s.delay(n.delay),a&&t.effects&&t.effects.effect[r]?s[e](n):r!==e&&s[r]?s[r](n.duration,n.easing,o):s.queue(function(i){t(this)[e](),o&&o.call(s[0]),i()})}}),t.widget,function(){function e(t,e,i){return[parseFloat(t[0])*(u.test(t[0])?e/100:1),parseFloat(t[1])*(u.test(t[1])?i/100:1)]}function i(e,i){return parseInt(t.css(e,i),10)||0}function s(e){var i=e[0];return 9===i.nodeType?{width:e.width(),height:e.height(),offset:{top:0,left:0}}:t.isWindow(i)?{width:e.width(),height:e.height(),offset:{top:e.scrollTop(),left:e.scrollLeft()}}:i.preventDefault?{width:0,height:0,offset:{top:i.pageY,left:i.pageX}}:{width:e.outerWidth(),height:e.outerHeight(),offset:e.offset()}}var n,o=Math.max,a=Math.abs,r=/left|center|right/,h=/top|center|bottom/,l=/[\+\-]\d+(\.[\d]+)?%?/,c=/^\w+/,u=/%$/,d=t.fn.position;t.position={scrollbarWidth:function(){if(void 0!==n)return n;var e,i,s=t("
"),o=s.children()[0];return t("body").append(s),e=o.offsetWidth,s.css("overflow","scroll"),i=o.offsetWidth,e===i&&(i=s[0].clientWidth),s.remove(),n=e-i},getScrollInfo:function(e){var i=e.isWindow||e.isDocument?"":e.element.css("overflow-x"),s=e.isWindow||e.isDocument?"":e.element.css("overflow-y"),n="scroll"===i||"auto"===i&&e.widthi?"left":e>0?"right":"center",vertical:0>r?"top":s>0?"bottom":"middle"};l>p&&p>a(e+i)&&(u.horizontal="center"),c>f&&f>a(s+r)&&(u.vertical="middle"),u.important=o(a(e),a(i))>o(a(s),a(r))?"horizontal":"vertical",n.using.call(this,t,u)}),h.offset(t.extend(D,{using:r}))})},t.ui.position={fit:{left:function(t,e){var i,s=e.within,n=s.isWindow?s.scrollLeft:s.offset.left,a=s.width,r=t.left-e.collisionPosition.marginLeft,h=n-r,l=r+e.collisionWidth-a-n;e.collisionWidth>a?h>0&&0>=l?(i=t.left+h+e.collisionWidth-a-n,t.left+=h-i):t.left=l>0&&0>=h?n:h>l?n+a-e.collisionWidth:n:h>0?t.left+=h:l>0?t.left-=l:t.left=o(t.left-r,t.left)},top:function(t,e){var i,s=e.within,n=s.isWindow?s.scrollTop:s.offset.top,a=e.within.height,r=t.top-e.collisionPosition.marginTop,h=n-r,l=r+e.collisionHeight-a-n;e.collisionHeight>a?h>0&&0>=l?(i=t.top+h+e.collisionHeight-a-n,t.top+=h-i):t.top=l>0&&0>=h?n:h>l?n+a-e.collisionHeight:n:h>0?t.top+=h:l>0?t.top-=l:t.top=o(t.top-r,t.top)}},flip:{left:function(t,e){var i,s,n=e.within,o=n.offset.left+n.scrollLeft,r=n.width,h=n.isWindow?n.scrollLeft:n.offset.left,l=t.left-e.collisionPosition.marginLeft,c=l-h,u=l+e.collisionWidth-r-h,d="left"===e.my[0]?-e.elemWidth:"right"===e.my[0]?e.elemWidth:0,p="left"===e.at[0]?e.targetWidth:"right"===e.at[0]?-e.targetWidth:0,f=-2*e.offset[0];0>c?(i=t.left+d+p+f+e.collisionWidth-r-o,(0>i||a(c)>i)&&(t.left+=d+p+f)):u>0&&(s=t.left-e.collisionPosition.marginLeft+d+p+f-h,(s>0||u>a(s))&&(t.left+=d+p+f))},top:function(t,e){var i,s,n=e.within,o=n.offset.top+n.scrollTop,r=n.height,h=n.isWindow?n.scrollTop:n.offset.top,l=t.top-e.collisionPosition.marginTop,c=l-h,u=l+e.collisionHeight-r-h,d="top"===e.my[1],p=d?-e.elemHeight:"bottom"===e.my[1]?e.elemHeight:0,f="top"===e.at[1]?e.targetHeight:"bottom"===e.at[1]?-e.targetHeight:0,m=-2*e.offset[1];0>c?(s=t.top+p+f+m+e.collisionHeight-r-o,(0>s||a(c)>s)&&(t.top+=p+f+m)):u>0&&(i=t.top-e.collisionPosition.marginTop+p+f+m-h,(i>0||u>a(i))&&(t.top+=p+f+m))}},flipfit:{left:function(){t.ui.position.flip.left.apply(this,arguments),t.ui.position.fit.left.apply(this,arguments)},top:function(){t.ui.position.flip.top.apply(this,arguments),t.ui.position.fit.top.apply(this,arguments)}}}}(),t.ui.position,t.extend(t.expr[":"],{data:t.expr.createPseudo?t.expr.createPseudo(function(e){return function(i){return!!t.data(i,e)}}):function(e,i,s){return!!t.data(e,s[3])}}),t.fn.extend({disableSelection:function(){var t="onselectstart"in document.createElement("div")?"selectstart":"mousedown";return function(){return this.on(t+".ui-disableSelection",function(t){t.preventDefault()})}}(),enableSelection:function(){return this.off(".ui-disableSelection")}}),t.ui.focusable=function(i,s){var n,o,a,r,h,l=i.nodeName.toLowerCase();return"area"===l?(n=i.parentNode,o=n.name,i.href&&o&&"map"===n.nodeName.toLowerCase()?(a=t("img[usemap='#"+o+"']"),a.length>0&&a.is(":visible")):!1):(/^(input|select|textarea|button|object)$/.test(l)?(r=!i.disabled,r&&(h=t(i).closest("fieldset")[0],h&&(r=!h.disabled))):r="a"===l?i.href||s:s,r&&t(i).is(":visible")&&e(t(i)))},t.extend(t.expr[":"],{focusable:function(e){return t.ui.focusable(e,null!=t.attr(e,"tabindex"))}}),t.ui.focusable,t.fn.form=function(){return"string"==typeof this[0].form?this.closest("form"):t(this[0].form)},t.ui.formResetMixin={_formResetHandler:function(){var e=t(this);setTimeout(function(){var i=e.data("ui-form-reset-instances");t.each(i,function(){this.refresh()})})},_bindFormResetHandler:function(){if(this.form=this.element.form(),this.form.length){var t=this.form.data("ui-form-reset-instances")||[];t.length||this.form.on("reset.ui-form-reset",this._formResetHandler),t.push(this),this.form.data("ui-form-reset-instances",t)}},_unbindFormResetHandler:function(){if(this.form.length){var e=this.form.data("ui-form-reset-instances");e.splice(t.inArray(this,e),1),e.length?this.form.data("ui-form-reset-instances",e):this.form.removeData("ui-form-reset-instances").off("reset.ui-form-reset")}}},"1.7"===t.fn.jquery.substring(0,3)&&(t.each(["Width","Height"],function(e,i){function s(e,i,s,o){return t.each(n,function(){i-=parseFloat(t.css(e,"padding"+this))||0,s&&(i-=parseFloat(t.css(e,"border"+this+"Width"))||0),o&&(i-=parseFloat(t.css(e,"margin"+this))||0)}),i}var n="Width"===i?["Left","Right"]:["Top","Bottom"],o=i.toLowerCase(),a={innerWidth:t.fn.innerWidth,innerHeight:t.fn.innerHeight,outerWidth:t.fn.outerWidth,outerHeight:t.fn.outerHeight};t.fn["inner"+i]=function(e){return void 0===e?a["inner"+i].call(this):this.each(function(){t(this).css(o,s(this,e)+"px")})},t.fn["outer"+i]=function(e,n){return"number"!=typeof e?a["outer"+i].call(this,e):this.each(function(){t(this).css(o,s(this,e,!0,n)+"px")})}}),t.fn.addBack=function(t){return this.add(null==t?this.prevObject:this.prevObject.filter(t))}),t.ui.keyCode={BACKSPACE:8,COMMA:188,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,LEFT:37,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SPACE:32,TAB:9,UP:38},t.ui.escapeSelector=function(){var t=/([!"#$%&'()*+,./:;<=>?@[\]^`{|}~])/g;return function(e){return e.replace(t,"\\$1")}}(),t.fn.labels=function(){var e,i,s,n,o;return this[0].labels&&this[0].labels.length?this.pushStack(this[0].labels):(n=this.eq(0).parents("label"),s=this.attr("id"),s&&(e=this.eq(0).parents().last(),o=e.add(e.length?e.siblings():this.siblings()),i="label[for='"+t.ui.escapeSelector(s)+"']",n=n.add(o.find(i).addBack(i))),this.pushStack(n))},t.fn.scrollParent=function(e){var i=this.css("position"),s="absolute"===i,n=e?/(auto|scroll|hidden)/:/(auto|scroll)/,o=this.parents().filter(function(){var e=t(this);return s&&"static"===e.css("position")?!1:n.test(e.css("overflow")+e.css("overflow-y")+e.css("overflow-x"))}).eq(0);return"fixed"!==i&&o.length?o:t(this[0].ownerDocument||document)},t.extend(t.expr[":"],{tabbable:function(e){var i=t.attr(e,"tabindex"),s=null!=i;return(!s||i>=0)&&t.ui.focusable(e,s)}}),t.fn.extend({uniqueId:function(){var t=0;return function(){return this.each(function(){this.id||(this.id="ui-id-"+ ++t)})}}(),removeUniqueId:function(){return this.each(function(){/^ui-id-\d+$/.test(this.id)&&t(this).removeAttr("id")})}}),t.ui.ie=!!/msie [\w.]+/.exec(navigator.userAgent.toLowerCase());var n=!1;t(document).on("mouseup",function(){n=!1}),t.widget("ui.mouse",{version:"1.12.1",options:{cancel:"input, textarea, button, select, option",distance:1,delay:0},_mouseInit:function(){var e=this;this.element.on("mousedown."+this.widgetName,function(t){return e._mouseDown(t)}).on("click."+this.widgetName,function(i){return!0===t.data(i.target,e.widgetName+".preventClickEvent")?(t.removeData(i.target,e.widgetName+".preventClickEvent"),i.stopImmediatePropagation(),!1):void 0}),this.started=!1},_mouseDestroy:function(){this.element.off("."+this.widgetName),this._mouseMoveDelegate&&this.document.off("mousemove."+this.widgetName,this._mouseMoveDelegate).off("mouseup."+this.widgetName,this._mouseUpDelegate)},_mouseDown:function(e){if(!n){this._mouseMoved=!1,this._mouseStarted&&this._mouseUp(e),this._mouseDownEvent=e;var i=this,s=1===e.which,o="string"==typeof this.options.cancel&&e.target.nodeName?t(e.target).closest(this.options.cancel).length:!1;return s&&!o&&this._mouseCapture(e)?(this.mouseDelayMet=!this.options.delay,this.mouseDelayMet||(this._mouseDelayTimer=setTimeout(function(){i.mouseDelayMet=!0},this.options.delay)),this._mouseDistanceMet(e)&&this._mouseDelayMet(e)&&(this._mouseStarted=this._mouseStart(e)!==!1,!this._mouseStarted)?(e.preventDefault(),!0):(!0===t.data(e.target,this.widgetName+".preventClickEvent")&&t.removeData(e.target,this.widgetName+".preventClickEvent"),this._mouseMoveDelegate=function(t){return i._mouseMove(t)},this._mouseUpDelegate=function(t){return i._mouseUp(t)},this.document.on("mousemove."+this.widgetName,this._mouseMoveDelegate).on("mouseup."+this.widgetName,this._mouseUpDelegate),e.preventDefault(),n=!0,!0)):!0}},_mouseMove:function(e){if(this._mouseMoved){if(t.ui.ie&&(!document.documentMode||9>document.documentMode)&&!e.button)return this._mouseUp(e);if(!e.which)if(e.originalEvent.altKey||e.originalEvent.ctrlKey||e.originalEvent.metaKey||e.originalEvent.shiftKey)this.ignoreMissingWhich=!0;else if(!this.ignoreMissingWhich)return this._mouseUp(e)}return(e.which||e.button)&&(this._mouseMoved=!0),this._mouseStarted?(this._mouseDrag(e),e.preventDefault()):(this._mouseDistanceMet(e)&&this._mouseDelayMet(e)&&(this._mouseStarted=this._mouseStart(this._mouseDownEvent,e)!==!1,this._mouseStarted?this._mouseDrag(e):this._mouseUp(e)),!this._mouseStarted)},_mouseUp:function(e){this.document.off("mousemove."+this.widgetName,this._mouseMoveDelegate).off("mouseup."+this.widgetName,this._mouseUpDelegate),this._mouseStarted&&(this._mouseStarted=!1,e.target===this._mouseDownEvent.target&&t.data(e.target,this.widgetName+".preventClickEvent",!0),this._mouseStop(e)),this._mouseDelayTimer&&(clearTimeout(this._mouseDelayTimer),delete this._mouseDelayTimer),this.ignoreMissingWhich=!1,n=!1,e.preventDefault()},_mouseDistanceMet:function(t){return Math.max(Math.abs(this._mouseDownEvent.pageX-t.pageX),Math.abs(this._mouseDownEvent.pageY-t.pageY))>=this.options.distance},_mouseDelayMet:function(){return this.mouseDelayMet},_mouseStart:function(){},_mouseDrag:function(){},_mouseStop:function(){},_mouseCapture:function(){return!0}}),t.ui.plugin={add:function(e,i,s){var n,o=t.ui[e].prototype;for(n in s)o.plugins[n]=o.plugins[n]||[],o.plugins[n].push([i,s[n]])},call:function(t,e,i,s){var n,o=t.plugins[e];if(o&&(s||t.element[0].parentNode&&11!==t.element[0].parentNode.nodeType))for(n=0;o.length>n;n++)t.options[o[n][0]]&&o[n][1].apply(t.element,i)}},t.widget("ui.resizable",t.ui.mouse,{version:"1.12.1",widgetEventPrefix:"resize",options:{alsoResize:!1,animate:!1,animateDuration:"slow",animateEasing:"swing",aspectRatio:!1,autoHide:!1,classes:{"ui-resizable-se":"ui-icon ui-icon-gripsmall-diagonal-se"},containment:!1,ghost:!1,grid:!1,handles:"e,s,se",helper:!1,maxHeight:null,maxWidth:null,minHeight:10,minWidth:10,zIndex:90,resize:null,start:null,stop:null},_num:function(t){return parseFloat(t)||0},_isNumber:function(t){return!isNaN(parseFloat(t))},_hasScroll:function(e,i){if("hidden"===t(e).css("overflow"))return!1;var s=i&&"left"===i?"scrollLeft":"scrollTop",n=!1;return e[s]>0?!0:(e[s]=1,n=e[s]>0,e[s]=0,n)},_create:function(){var e,i=this.options,s=this;this._addClass("ui-resizable"),t.extend(this,{_aspectRatio:!!i.aspectRatio,aspectRatio:i.aspectRatio,originalElement:this.element,_proportionallyResizeElements:[],_helper:i.helper||i.ghost||i.animate?i.helper||"ui-resizable-helper":null}),this.element[0].nodeName.match(/^(canvas|textarea|input|select|button|img)$/i)&&(this.element.wrap(t("
").css({position:this.element.css("position"),width:this.element.outerWidth(),height:this.element.outerHeight(),top:this.element.css("top"),left:this.element.css("left")})),this.element=this.element.parent().data("ui-resizable",this.element.resizable("instance")),this.elementIsWrapper=!0,e={marginTop:this.originalElement.css("marginTop"),marginRight:this.originalElement.css("marginRight"),marginBottom:this.originalElement.css("marginBottom"),marginLeft:this.originalElement.css("marginLeft")},this.element.css(e),this.originalElement.css("margin",0),this.originalResizeStyle=this.originalElement.css("resize"),this.originalElement.css("resize","none"),this._proportionallyResizeElements.push(this.originalElement.css({position:"static",zoom:1,display:"block"})),this.originalElement.css(e),this._proportionallyResize()),this._setupHandles(),i.autoHide&&t(this.element).on("mouseenter",function(){i.disabled||(s._removeClass("ui-resizable-autohide"),s._handles.show())}).on("mouseleave",function(){i.disabled||s.resizing||(s._addClass("ui-resizable-autohide"),s._handles.hide())}),this._mouseInit()},_destroy:function(){this._mouseDestroy();var e,i=function(e){t(e).removeData("resizable").removeData("ui-resizable").off(".resizable").find(".ui-resizable-handle").remove()};return this.elementIsWrapper&&(i(this.element),e=this.element,this.originalElement.css({position:e.css("position"),width:e.outerWidth(),height:e.outerHeight(),top:e.css("top"),left:e.css("left")}).insertAfter(e),e.remove()),this.originalElement.css("resize",this.originalResizeStyle),i(this.originalElement),this},_setOption:function(t,e){switch(this._super(t,e),t){case"handles":this._removeHandles(),this._setupHandles();break;default:}},_setupHandles:function(){var e,i,s,n,o,a=this.options,r=this;if(this.handles=a.handles||(t(".ui-resizable-handle",this.element).length?{n:".ui-resizable-n",e:".ui-resizable-e",s:".ui-resizable-s",w:".ui-resizable-w",se:".ui-resizable-se",sw:".ui-resizable-sw",ne:".ui-resizable-ne",nw:".ui-resizable-nw"}:"e,s,se"),this._handles=t(),this.handles.constructor===String)for("all"===this.handles&&(this.handles="n,e,s,w,se,sw,ne,nw"),s=this.handles.split(","),this.handles={},i=0;s.length>i;i++)e=t.trim(s[i]),n="ui-resizable-"+e,o=t("
"),this._addClass(o,"ui-resizable-handle "+n),o.css({zIndex:a.zIndex}),this.handles[e]=".ui-resizable-"+e,this.element.append(o);this._renderAxis=function(e){var i,s,n,o;e=e||this.element;for(i in this.handles)this.handles[i].constructor===String?this.handles[i]=this.element.children(this.handles[i]).first().show():(this.handles[i].jquery||this.handles[i].nodeType)&&(this.handles[i]=t(this.handles[i]),this._on(this.handles[i],{mousedown:r._mouseDown})),this.elementIsWrapper&&this.originalElement[0].nodeName.match(/^(textarea|input|select|button)$/i)&&(s=t(this.handles[i],this.element),o=/sw|ne|nw|se|n|s/.test(i)?s.outerHeight():s.outerWidth(),n=["padding",/ne|nw|n/.test(i)?"Top":/se|sw|s/.test(i)?"Bottom":/^e$/.test(i)?"Right":"Left"].join(""),e.css(n,o),this._proportionallyResize()),this._handles=this._handles.add(this.handles[i])},this._renderAxis(this.element),this._handles=this._handles.add(this.element.find(".ui-resizable-handle")),this._handles.disableSelection(),this._handles.on("mouseover",function(){r.resizing||(this.className&&(o=this.className.match(/ui-resizable-(se|sw|ne|nw|n|e|s|w)/i)),r.axis=o&&o[1]?o[1]:"se")}),a.autoHide&&(this._handles.hide(),this._addClass("ui-resizable-autohide"))},_removeHandles:function(){this._handles.remove()},_mouseCapture:function(e){var i,s,n=!1;for(i in this.handles)s=t(this.handles[i])[0],(s===e.target||t.contains(s,e.target))&&(n=!0);return!this.options.disabled&&n},_mouseStart:function(e){var i,s,n,o=this.options,a=this.element;return this.resizing=!0,this._renderProxy(),i=this._num(this.helper.css("left")),s=this._num(this.helper.css("top")),o.containment&&(i+=t(o.containment).scrollLeft()||0,s+=t(o.containment).scrollTop()||0),this.offset=this.helper.offset(),this.position={left:i,top:s},this.size=this._helper?{width:this.helper.width(),height:this.helper.height()}:{width:a.width(),height:a.height()},this.originalSize=this._helper?{width:a.outerWidth(),height:a.outerHeight()}:{width:a.width(),height:a.height()},this.sizeDiff={width:a.outerWidth()-a.width(),height:a.outerHeight()-a.height()},this.originalPosition={left:i,top:s},this.originalMousePosition={left:e.pageX,top:e.pageY},this.aspectRatio="number"==typeof o.aspectRatio?o.aspectRatio:this.originalSize.width/this.originalSize.height||1,n=t(".ui-resizable-"+this.axis).css("cursor"),t("body").css("cursor","auto"===n?this.axis+"-resize":n),this._addClass("ui-resizable-resizing"),this._propagate("start",e),!0},_mouseDrag:function(e){var i,s,n=this.originalMousePosition,o=this.axis,a=e.pageX-n.left||0,r=e.pageY-n.top||0,h=this._change[o];return this._updatePrevProperties(),h?(i=h.apply(this,[e,a,r]),this._updateVirtualBoundaries(e.shiftKey),(this._aspectRatio||e.shiftKey)&&(i=this._updateRatio(i,e)),i=this._respectSize(i,e),this._updateCache(i),this._propagate("resize",e),s=this._applyChanges(),!this._helper&&this._proportionallyResizeElements.length&&this._proportionallyResize(),t.isEmptyObject(s)||(this._updatePrevProperties(),this._trigger("resize",e,this.ui()),this._applyChanges()),!1):!1},_mouseStop:function(e){this.resizing=!1;var i,s,n,o,a,r,h,l=this.options,c=this;return this._helper&&(i=this._proportionallyResizeElements,s=i.length&&/textarea/i.test(i[0].nodeName),n=s&&this._hasScroll(i[0],"left")?0:c.sizeDiff.height,o=s?0:c.sizeDiff.width,a={width:c.helper.width()-o,height:c.helper.height()-n},r=parseFloat(c.element.css("left"))+(c.position.left-c.originalPosition.left)||null,h=parseFloat(c.element.css("top"))+(c.position.top-c.originalPosition.top)||null,l.animate||this.element.css(t.extend(a,{top:h,left:r})),c.helper.height(c.size.height),c.helper.width(c.size.width),this._helper&&!l.animate&&this._proportionallyResize()),t("body").css("cursor","auto"),this._removeClass("ui-resizable-resizing"),this._propagate("stop",e),this._helper&&this.helper.remove(),!1},_updatePrevProperties:function(){this.prevPosition={top:this.position.top,left:this.position.left},this.prevSize={width:this.size.width,height:this.size.height}},_applyChanges:function(){var t={};return this.position.top!==this.prevPosition.top&&(t.top=this.position.top+"px"),this.position.left!==this.prevPosition.left&&(t.left=this.position.left+"px"),this.size.width!==this.prevSize.width&&(t.width=this.size.width+"px"),this.size.height!==this.prevSize.height&&(t.height=this.size.height+"px"),this.helper.css(t),t},_updateVirtualBoundaries:function(t){var e,i,s,n,o,a=this.options;o={minWidth:this._isNumber(a.minWidth)?a.minWidth:0,maxWidth:this._isNumber(a.maxWidth)?a.maxWidth:1/0,minHeight:this._isNumber(a.minHeight)?a.minHeight:0,maxHeight:this._isNumber(a.maxHeight)?a.maxHeight:1/0},(this._aspectRatio||t)&&(e=o.minHeight*this.aspectRatio,s=o.minWidth/this.aspectRatio,i=o.maxHeight*this.aspectRatio,n=o.maxWidth/this.aspectRatio,e>o.minWidth&&(o.minWidth=e),s>o.minHeight&&(o.minHeight=s),o.maxWidth>i&&(o.maxWidth=i),o.maxHeight>n&&(o.maxHeight=n)),this._vBoundaries=o},_updateCache:function(t){this.offset=this.helper.offset(),this._isNumber(t.left)&&(this.position.left=t.left),this._isNumber(t.top)&&(this.position.top=t.top),this._isNumber(t.height)&&(this.size.height=t.height),this._isNumber(t.width)&&(this.size.width=t.width)},_updateRatio:function(t){var e=this.position,i=this.size,s=this.axis;return this._isNumber(t.height)?t.width=t.height*this.aspectRatio:this._isNumber(t.width)&&(t.height=t.width/this.aspectRatio),"sw"===s&&(t.left=e.left+(i.width-t.width),t.top=null),"nw"===s&&(t.top=e.top+(i.height-t.height),t.left=e.left+(i.width-t.width)),t},_respectSize:function(t){var e=this._vBoundaries,i=this.axis,s=this._isNumber(t.width)&&e.maxWidth&&e.maxWidtht.width,a=this._isNumber(t.height)&&e.minHeight&&e.minHeight>t.height,r=this.originalPosition.left+this.originalSize.width,h=this.originalPosition.top+this.originalSize.height,l=/sw|nw|w/.test(i),c=/nw|ne|n/.test(i);return o&&(t.width=e.minWidth),a&&(t.height=e.minHeight),s&&(t.width=e.maxWidth),n&&(t.height=e.maxHeight),o&&l&&(t.left=r-e.minWidth),s&&l&&(t.left=r-e.maxWidth),a&&c&&(t.top=h-e.minHeight),n&&c&&(t.top=h-e.maxHeight),t.width||t.height||t.left||!t.top?t.width||t.height||t.top||!t.left||(t.left=null):t.top=null,t},_getPaddingPlusBorderDimensions:function(t){for(var e=0,i=[],s=[t.css("borderTopWidth"),t.css("borderRightWidth"),t.css("borderBottomWidth"),t.css("borderLeftWidth")],n=[t.css("paddingTop"),t.css("paddingRight"),t.css("paddingBottom"),t.css("paddingLeft")];4>e;e++)i[e]=parseFloat(s[e])||0,i[e]+=parseFloat(n[e])||0;return{height:i[0]+i[2],width:i[1]+i[3]}},_proportionallyResize:function(){if(this._proportionallyResizeElements.length)for(var t,e=0,i=this.helper||this.element;this._proportionallyResizeElements.length>e;e++)t=this._proportionallyResizeElements[e],this.outerDimensions||(this.outerDimensions=this._getPaddingPlusBorderDimensions(t)),t.css({height:i.height()-this.outerDimensions.height||0,width:i.width()-this.outerDimensions.width||0})},_renderProxy:function(){var e=this.element,i=this.options;this.elementOffset=e.offset(),this._helper?(this.helper=this.helper||t("
"),this._addClass(this.helper,this._helper),this.helper.css({width:this.element.outerWidth(),height:this.element.outerHeight(),position:"absolute",left:this.elementOffset.left+"px",top:this.elementOffset.top+"px",zIndex:++i.zIndex}),this.helper.appendTo("body").disableSelection()):this.helper=this.element +},_change:{e:function(t,e){return{width:this.originalSize.width+e}},w:function(t,e){var i=this.originalSize,s=this.originalPosition;return{left:s.left+e,width:i.width-e}},n:function(t,e,i){var s=this.originalSize,n=this.originalPosition;return{top:n.top+i,height:s.height-i}},s:function(t,e,i){return{height:this.originalSize.height+i}},se:function(e,i,s){return t.extend(this._change.s.apply(this,arguments),this._change.e.apply(this,[e,i,s]))},sw:function(e,i,s){return t.extend(this._change.s.apply(this,arguments),this._change.w.apply(this,[e,i,s]))},ne:function(e,i,s){return t.extend(this._change.n.apply(this,arguments),this._change.e.apply(this,[e,i,s]))},nw:function(e,i,s){return t.extend(this._change.n.apply(this,arguments),this._change.w.apply(this,[e,i,s]))}},_propagate:function(e,i){t.ui.plugin.call(this,e,[i,this.ui()]),"resize"!==e&&this._trigger(e,i,this.ui())},plugins:{},ui:function(){return{originalElement:this.originalElement,element:this.element,helper:this.helper,position:this.position,size:this.size,originalSize:this.originalSize,originalPosition:this.originalPosition}}}),t.ui.plugin.add("resizable","animate",{stop:function(e){var i=t(this).resizable("instance"),s=i.options,n=i._proportionallyResizeElements,o=n.length&&/textarea/i.test(n[0].nodeName),a=o&&i._hasScroll(n[0],"left")?0:i.sizeDiff.height,r=o?0:i.sizeDiff.width,h={width:i.size.width-r,height:i.size.height-a},l=parseFloat(i.element.css("left"))+(i.position.left-i.originalPosition.left)||null,c=parseFloat(i.element.css("top"))+(i.position.top-i.originalPosition.top)||null;i.element.animate(t.extend(h,c&&l?{top:c,left:l}:{}),{duration:s.animateDuration,easing:s.animateEasing,step:function(){var s={width:parseFloat(i.element.css("width")),height:parseFloat(i.element.css("height")),top:parseFloat(i.element.css("top")),left:parseFloat(i.element.css("left"))};n&&n.length&&t(n[0]).css({width:s.width,height:s.height}),i._updateCache(s),i._propagate("resize",e)}})}}),t.ui.plugin.add("resizable","containment",{start:function(){var e,i,s,n,o,a,r,h=t(this).resizable("instance"),l=h.options,c=h.element,u=l.containment,d=u instanceof t?u.get(0):/parent/.test(u)?c.parent().get(0):u;d&&(h.containerElement=t(d),/document/.test(u)||u===document?(h.containerOffset={left:0,top:0},h.containerPosition={left:0,top:0},h.parentData={element:t(document),left:0,top:0,width:t(document).width(),height:t(document).height()||document.body.parentNode.scrollHeight}):(e=t(d),i=[],t(["Top","Right","Left","Bottom"]).each(function(t,s){i[t]=h._num(e.css("padding"+s))}),h.containerOffset=e.offset(),h.containerPosition=e.position(),h.containerSize={height:e.innerHeight()-i[3],width:e.innerWidth()-i[1]},s=h.containerOffset,n=h.containerSize.height,o=h.containerSize.width,a=h._hasScroll(d,"left")?d.scrollWidth:o,r=h._hasScroll(d)?d.scrollHeight:n,h.parentData={element:d,left:s.left,top:s.top,width:a,height:r}))},resize:function(e){var i,s,n,o,a=t(this).resizable("instance"),r=a.options,h=a.containerOffset,l=a.position,c=a._aspectRatio||e.shiftKey,u={top:0,left:0},d=a.containerElement,p=!0;d[0]!==document&&/static/.test(d.css("position"))&&(u=h),l.left<(a._helper?h.left:0)&&(a.size.width=a.size.width+(a._helper?a.position.left-h.left:a.position.left-u.left),c&&(a.size.height=a.size.width/a.aspectRatio,p=!1),a.position.left=r.helper?h.left:0),l.top<(a._helper?h.top:0)&&(a.size.height=a.size.height+(a._helper?a.position.top-h.top:a.position.top),c&&(a.size.width=a.size.height*a.aspectRatio,p=!1),a.position.top=a._helper?h.top:0),n=a.containerElement.get(0)===a.element.parent().get(0),o=/relative|absolute/.test(a.containerElement.css("position")),n&&o?(a.offset.left=a.parentData.left+a.position.left,a.offset.top=a.parentData.top+a.position.top):(a.offset.left=a.element.offset().left,a.offset.top=a.element.offset().top),i=Math.abs(a.sizeDiff.width+(a._helper?a.offset.left-u.left:a.offset.left-h.left)),s=Math.abs(a.sizeDiff.height+(a._helper?a.offset.top-u.top:a.offset.top-h.top)),i+a.size.width>=a.parentData.width&&(a.size.width=a.parentData.width-i,c&&(a.size.height=a.size.width/a.aspectRatio,p=!1)),s+a.size.height>=a.parentData.height&&(a.size.height=a.parentData.height-s,c&&(a.size.width=a.size.height*a.aspectRatio,p=!1)),p||(a.position.left=a.prevPosition.left,a.position.top=a.prevPosition.top,a.size.width=a.prevSize.width,a.size.height=a.prevSize.height)},stop:function(){var e=t(this).resizable("instance"),i=e.options,s=e.containerOffset,n=e.containerPosition,o=e.containerElement,a=t(e.helper),r=a.offset(),h=a.outerWidth()-e.sizeDiff.width,l=a.outerHeight()-e.sizeDiff.height;e._helper&&!i.animate&&/relative/.test(o.css("position"))&&t(this).css({left:r.left-n.left-s.left,width:h,height:l}),e._helper&&!i.animate&&/static/.test(o.css("position"))&&t(this).css({left:r.left-n.left-s.left,width:h,height:l})}}),t.ui.plugin.add("resizable","alsoResize",{start:function(){var e=t(this).resizable("instance"),i=e.options;t(i.alsoResize).each(function(){var e=t(this);e.data("ui-resizable-alsoresize",{width:parseFloat(e.width()),height:parseFloat(e.height()),left:parseFloat(e.css("left")),top:parseFloat(e.css("top"))})})},resize:function(e,i){var s=t(this).resizable("instance"),n=s.options,o=s.originalSize,a=s.originalPosition,r={height:s.size.height-o.height||0,width:s.size.width-o.width||0,top:s.position.top-a.top||0,left:s.position.left-a.left||0};t(n.alsoResize).each(function(){var e=t(this),s=t(this).data("ui-resizable-alsoresize"),n={},o=e.parents(i.originalElement[0]).length?["width","height"]:["width","height","top","left"];t.each(o,function(t,e){var i=(s[e]||0)+(r[e]||0);i&&i>=0&&(n[e]=i||null)}),e.css(n)})},stop:function(){t(this).removeData("ui-resizable-alsoresize")}}),t.ui.plugin.add("resizable","ghost",{start:function(){var e=t(this).resizable("instance"),i=e.size;e.ghost=e.originalElement.clone(),e.ghost.css({opacity:.25,display:"block",position:"relative",height:i.height,width:i.width,margin:0,left:0,top:0}),e._addClass(e.ghost,"ui-resizable-ghost"),t.uiBackCompat!==!1&&"string"==typeof e.options.ghost&&e.ghost.addClass(this.options.ghost),e.ghost.appendTo(e.helper)},resize:function(){var e=t(this).resizable("instance");e.ghost&&e.ghost.css({position:"relative",height:e.size.height,width:e.size.width})},stop:function(){var e=t(this).resizable("instance");e.ghost&&e.helper&&e.helper.get(0).removeChild(e.ghost.get(0))}}),t.ui.plugin.add("resizable","grid",{resize:function(){var e,i=t(this).resizable("instance"),s=i.options,n=i.size,o=i.originalSize,a=i.originalPosition,r=i.axis,h="number"==typeof s.grid?[s.grid,s.grid]:s.grid,l=h[0]||1,c=h[1]||1,u=Math.round((n.width-o.width)/l)*l,d=Math.round((n.height-o.height)/c)*c,p=o.width+u,f=o.height+d,m=s.maxWidth&&p>s.maxWidth,g=s.maxHeight&&f>s.maxHeight,_=s.minWidth&&s.minWidth>p,v=s.minHeight&&s.minHeight>f;s.grid=h,_&&(p+=l),v&&(f+=c),m&&(p-=l),g&&(f-=c),/^(se|s|e)$/.test(r)?(i.size.width=p,i.size.height=f):/^(ne)$/.test(r)?(i.size.width=p,i.size.height=f,i.position.top=a.top-d):/^(sw)$/.test(r)?(i.size.width=p,i.size.height=f,i.position.left=a.left-u):((0>=f-c||0>=p-l)&&(e=i._getPaddingPlusBorderDimensions(this)),f-c>0?(i.size.height=f,i.position.top=a.top-d):(f=c-e.height,i.size.height=f,i.position.top=a.top+o.height-f),p-l>0?(i.size.width=p,i.position.left=a.left-u):(p=l-e.width,i.size.width=p,i.position.left=a.left+o.width-p))}}),t.ui.resizable});/** + * Copyright (c) 2007 Ariel Flesler - aflesler ○ gmail • com | https://github.com/flesler + * Licensed under MIT + * @author Ariel Flesler + * @version 2.1.2 + */ +;(function(f){"use strict";"function"===typeof define&&define.amd?define(["jquery"],f):"undefined"!==typeof module&&module.exports?module.exports=f(require("jquery")):f(jQuery)})(function($){"use strict";function n(a){return!a.nodeName||-1!==$.inArray(a.nodeName.toLowerCase(),["iframe","#document","html","body"])}function h(a){return $.isFunction(a)||$.isPlainObject(a)?a:{top:a,left:a}}var p=$.scrollTo=function(a,d,b){return $(window).scrollTo(a,d,b)};p.defaults={axis:"xy",duration:0,limit:!0};$.fn.scrollTo=function(a,d,b){"object"=== typeof d&&(b=d,d=0);"function"===typeof b&&(b={onAfter:b});"max"===a&&(a=9E9);b=$.extend({},p.defaults,b);d=d||b.duration;var u=b.queue&&1=f[g]?0:Math.min(f[g],n));!a&&1-1){targetElements.on(evt+EVENT_NAMESPACE,function elementToggle(event){$.powerTip.toggle(this,event)})}else{targetElements.on(evt+EVENT_NAMESPACE,function elementOpen(event){$.powerTip.show(this,event)})}});$.each(options.closeEvents,function(idx,evt){if($.inArray(evt,options.openEvents)<0){targetElements.on(evt+EVENT_NAMESPACE,function elementClose(event){$.powerTip.hide(this,!isMouseEvent(event))})}});targetElements.on("keydown"+EVENT_NAMESPACE,function elementKeyDown(event){if(event.keyCode===27){$.powerTip.hide(this,true)}})}return targetElements};$.fn.powerTip.defaults={fadeInTime:200,fadeOutTime:100,followMouse:false,popupId:"powerTip",popupClass:null,intentSensitivity:7,intentPollInterval:100,closeDelay:100,placement:"n",smartPlacement:false,offset:10,mouseOnToPopup:false,manual:false,openEvents:["mouseenter","focus"],closeEvents:["mouseleave","blur"]};$.fn.powerTip.smartPlacementLists={n:["n","ne","nw","s"],e:["e","ne","se","w","nw","sw","n","s","e"],s:["s","se","sw","n"],w:["w","nw","sw","e","ne","se","n","s","w"],nw:["nw","w","sw","n","s","se","nw"],ne:["ne","e","se","n","s","sw","ne"],sw:["sw","w","nw","s","n","ne","sw"],se:["se","e","ne","s","n","nw","se"],"nw-alt":["nw-alt","n","ne-alt","sw-alt","s","se-alt","w","e"],"ne-alt":["ne-alt","n","nw-alt","se-alt","s","sw-alt","e","w"],"sw-alt":["sw-alt","s","se-alt","nw-alt","n","ne-alt","w","e"],"se-alt":["se-alt","s","sw-alt","ne-alt","n","nw-alt","e","w"]};$.powerTip={show:function apiShowTip(element,event){if(isMouseEvent(event)){trackMouse(event);session.previousX=event.pageX;session.previousY=event.pageY;$(element).data(DATA_DISPLAYCONTROLLER).show()}else{$(element).first().data(DATA_DISPLAYCONTROLLER).show(true,true)}return element},reposition:function apiResetPosition(element){$(element).first().data(DATA_DISPLAYCONTROLLER).resetPosition();return element},hide:function apiCloseTip(element,immediate){var displayController;immediate=element?immediate:true;if(element){displayController=$(element).first().data(DATA_DISPLAYCONTROLLER)}else if(session.activeHover){displayController=session.activeHover.data(DATA_DISPLAYCONTROLLER)}if(displayController){displayController.hide(immediate)}return element},toggle:function apiToggle(element,event){if(session.activeHover&&session.activeHover.is(element)){$.powerTip.hide(element,!isMouseEvent(event))}else{$.powerTip.show(element,event)}return element}};$.powerTip.showTip=$.powerTip.show;$.powerTip.closeTip=$.powerTip.hide;function CSSCoordinates(){var me=this;me.top="auto";me.left="auto";me.right="auto";me.bottom="auto";me.set=function(property,value){if($.isNumeric(value)){me[property]=Math.round(value)}}}function DisplayController(element,options,tipController){var hoverTimer=null,myCloseDelay=null;function openTooltip(immediate,forceOpen){cancelTimer();if(!element.data(DATA_HASACTIVEHOVER)){if(!immediate){session.tipOpenImminent=true;hoverTimer=setTimeout(function intentDelay(){hoverTimer=null;checkForIntent()},options.intentPollInterval)}else{if(forceOpen){element.data(DATA_FORCEDOPEN,true)}closeAnyDelayed();tipController.showTip(element)}}else{cancelClose()}}function closeTooltip(disableDelay){if(myCloseDelay){myCloseDelay=session.closeDelayTimeout=clearTimeout(myCloseDelay);session.delayInProgress=false}cancelTimer();session.tipOpenImminent=false;if(element.data(DATA_HASACTIVEHOVER)){element.data(DATA_FORCEDOPEN,false);if(!disableDelay){session.delayInProgress=true;session.closeDelayTimeout=setTimeout(function closeDelay(){session.closeDelayTimeout=null;tipController.hideTip(element);session.delayInProgress=false;myCloseDelay=null},options.closeDelay);myCloseDelay=session.closeDelayTimeout}else{tipController.hideTip(element)}}}function checkForIntent(){var xDifference=Math.abs(session.previousX-session.currentX),yDifference=Math.abs(session.previousY-session.currentY),totalDifference=xDifference+yDifference;if(totalDifference",{id:options.popupId});if($body.length===0){$body=$("body")}$body.append(tipElement);session.tooltips=session.tooltips?session.tooltips.add(tipElement):tipElement}if(options.followMouse){if(!tipElement.data(DATA_HASMOUSEMOVE)){$document.on("mousemove"+EVENT_NAMESPACE,positionTipOnCursor);$window.on("scroll"+EVENT_NAMESPACE,positionTipOnCursor);tipElement.data(DATA_HASMOUSEMOVE,true)}}function beginShowTip(element){element.data(DATA_HASACTIVEHOVER,true);tipElement.queue(function queueTipInit(next){showTip(element);next()})}function showTip(element){var tipContent;if(!element.data(DATA_HASACTIVEHOVER)){return}if(session.isTipOpen){if(!session.isClosing){hideTip(session.activeHover)}tipElement.delay(100).queue(function queueTipAgain(next){showTip(element);next()});return}element.trigger("powerTipPreRender");tipContent=getTooltipContent(element);if(tipContent){tipElement.empty().append(tipContent)}else{return}element.trigger("powerTipRender");session.activeHover=element;session.isTipOpen=true;tipElement.data(DATA_MOUSEONTOTIP,options.mouseOnToPopup);tipElement.addClass(options.popupClass);if(!options.followMouse||element.data(DATA_FORCEDOPEN)){positionTipOnElement(element);session.isFixedTipOpen=true}else{positionTipOnCursor()}if(!element.data(DATA_FORCEDOPEN)&&!options.followMouse){$document.on("click"+EVENT_NAMESPACE,function documentClick(event){var target=event.target;if(target!==element[0]){if(options.mouseOnToPopup){if(target!==tipElement[0]&&!$.contains(tipElement[0],target)){$.powerTip.hide()}}else{$.powerTip.hide()}}})}if(options.mouseOnToPopup&&!options.manual){tipElement.on("mouseenter"+EVENT_NAMESPACE,function tipMouseEnter(){if(session.activeHover){session.activeHover.data(DATA_DISPLAYCONTROLLER).cancel()}});tipElement.on("mouseleave"+EVENT_NAMESPACE,function tipMouseLeave(){if(session.activeHover){session.activeHover.data(DATA_DISPLAYCONTROLLER).hide()}})}tipElement.fadeIn(options.fadeInTime,function fadeInCallback(){if(!session.desyncTimeout){session.desyncTimeout=setInterval(closeDesyncedTip,500)}element.trigger("powerTipOpen")})}function hideTip(element){session.isClosing=true;session.isTipOpen=false;session.desyncTimeout=clearInterval(session.desyncTimeout);element.data(DATA_HASACTIVEHOVER,false);element.data(DATA_FORCEDOPEN,false);$document.off("click"+EVENT_NAMESPACE);tipElement.off(EVENT_NAMESPACE);tipElement.fadeOut(options.fadeOutTime,function fadeOutCallback(){var coords=new CSSCoordinates;session.activeHover=null;session.isClosing=false;session.isFixedTipOpen=false;tipElement.removeClass();coords.set("top",session.currentY+options.offset);coords.set("left",session.currentX+options.offset);tipElement.css(coords);element.trigger("powerTipClose")})}function positionTipOnCursor(){var tipWidth,tipHeight,coords,collisions,collisionCount;if(!session.isFixedTipOpen&&(session.isTipOpen||session.tipOpenImminent&&tipElement.data(DATA_HASMOUSEMOVE))){tipWidth=tipElement.outerWidth();tipHeight=tipElement.outerHeight();coords=new CSSCoordinates;coords.set("top",session.currentY+options.offset);coords.set("left",session.currentX+options.offset);collisions=getViewportCollisions(coords,tipWidth,tipHeight);if(collisions!==Collision.none){collisionCount=countFlags(collisions);if(collisionCount===1){if(collisions===Collision.right){coords.set("left",session.scrollLeft+session.windowWidth-tipWidth)}else if(collisions===Collision.bottom){coords.set("top",session.scrollTop+session.windowHeight-tipHeight)}}else{coords.set("left",session.currentX-tipWidth-options.offset);coords.set("top",session.currentY-tipHeight-options.offset)}}tipElement.css(coords)}}function positionTipOnElement(element){var priorityList,finalPlacement;if(options.smartPlacement||options.followMouse&&element.data(DATA_FORCEDOPEN)){priorityList=$.fn.powerTip.smartPlacementLists[options.placement];$.each(priorityList,function(idx,pos){var collisions=getViewportCollisions(placeTooltip(element,pos),tipElement.outerWidth(),tipElement.outerHeight());finalPlacement=pos;return collisions!==Collision.none})}else{placeTooltip(element,options.placement);finalPlacement=options.placement}tipElement.removeClass("w nw sw e ne se n s w se-alt sw-alt ne-alt nw-alt");tipElement.addClass(finalPlacement)}function placeTooltip(element,placement){var iterationCount=0,tipWidth,tipHeight,coords=new CSSCoordinates;coords.set("top",0);coords.set("left",0);tipElement.css(coords);do{tipWidth=tipElement.outerWidth();tipHeight=tipElement.outerHeight();coords=placementCalculator.compute(element,placement,tipWidth,tipHeight,options.offset);tipElement.css(coords)}while(++iterationCount<=5&&(tipWidth!==tipElement.outerWidth()||tipHeight!==tipElement.outerHeight()));return coords}function closeDesyncedTip(){var isDesynced=false,hasDesyncableCloseEvent=$.grep(["mouseleave","mouseout","blur","focusout"],function(eventType){return $.inArray(eventType,options.closeEvents)!==-1}).length>0;if(session.isTipOpen&&!session.isClosing&&!session.delayInProgress&&hasDesyncableCloseEvent){if(session.activeHover.data(DATA_HASACTIVEHOVER)===false||session.activeHover.is(":disabled")){isDesynced=true}else if(!isMouseOver(session.activeHover)&&!session.activeHover.is(":focus")&&!session.activeHover.data(DATA_FORCEDOPEN)){if(tipElement.data(DATA_MOUSEONTOTIP)){if(!isMouseOver(tipElement)){isDesynced=true}}else{isDesynced=true}}if(isDesynced){hideTip(session.activeHover)}}}this.showTip=beginShowTip;this.hideTip=hideTip;this.resetPosition=positionTipOnElement}function isSvgElement(element){return Boolean(window.SVGElement&&element[0]instanceof SVGElement)}function isMouseEvent(event){return Boolean(event&&$.inArray(event.type,MOUSE_EVENTS)>-1&&typeof event.pageX==="number")}function initTracking(){if(!session.mouseTrackingActive){session.mouseTrackingActive=true;getViewportDimensions();$(getViewportDimensions);$document.on("mousemove"+EVENT_NAMESPACE,trackMouse);$window.on("resize"+EVENT_NAMESPACE,trackResize);$window.on("scroll"+EVENT_NAMESPACE,trackScroll)}}function getViewportDimensions(){session.scrollLeft=$window.scrollLeft();session.scrollTop=$window.scrollTop();session.windowWidth=$window.width();session.windowHeight=$window.height()}function trackResize(){session.windowWidth=$window.width();session.windowHeight=$window.height()}function trackScroll(){var x=$window.scrollLeft(),y=$window.scrollTop();if(x!==session.scrollLeft){session.currentX+=x-session.scrollLeft;session.scrollLeft=x}if(y!==session.scrollTop){session.currentY+=y-session.scrollTop;session.scrollTop=y}}function trackMouse(event){session.currentX=event.pageX;session.currentY=event.pageY}function isMouseOver(element){var elementPosition=element.offset(),elementBox=element[0].getBoundingClientRect(),elementWidth=elementBox.right-elementBox.left,elementHeight=elementBox.bottom-elementBox.top;return session.currentX>=elementPosition.left&&session.currentX<=elementPosition.left+elementWidth&&session.currentY>=elementPosition.top&&session.currentY<=elementPosition.top+elementHeight}function getTooltipContent(element){var tipText=element.data(DATA_POWERTIP),tipObject=element.data(DATA_POWERTIPJQ),tipTarget=element.data(DATA_POWERTIPTARGET),targetElement,content;if(tipText){if($.isFunction(tipText)){tipText=tipText.call(element[0])}content=tipText}else if(tipObject){if($.isFunction(tipObject)){tipObject=tipObject.call(element[0])}if(tipObject.length>0){content=tipObject.clone(true,true)}}else if(tipTarget){targetElement=$("#"+tipTarget);if(targetElement.length>0){content=targetElement.html()}}return content}function getViewportCollisions(coords,elementWidth,elementHeight){var viewportTop=session.scrollTop,viewportLeft=session.scrollLeft,viewportBottom=viewportTop+session.windowHeight,viewportRight=viewportLeft+session.windowWidth,collisions=Collision.none;if(coords.topviewportBottom||Math.abs(coords.bottom-session.windowHeight)>viewportBottom){collisions|=Collision.bottom}if(coords.leftviewportRight){collisions|=Collision.left}if(coords.left+elementWidth>viewportRight||coords.right1)){a.preventDefault();var c=a.originalEvent.changedTouches[0],d=document.createEvent("MouseEvents");d.initMouseEvent(b,!0,!0,window,1,c.screenX,c.screenY,c.clientX,c.clientY,!1,!1,!1,!1,0,null),a.target.dispatchEvent(d)}}if(a.support.touch="ontouchend"in document,a.support.touch){var e,b=a.ui.mouse.prototype,c=b._mouseInit,d=b._mouseDestroy;b._touchStart=function(a){var b=this;!e&&b._mouseCapture(a.originalEvent.changedTouches[0])&&(e=!0,b._touchMoved=!1,f(a,"mouseover"),f(a,"mousemove"),f(a,"mousedown"))},b._touchMove=function(a){e&&(this._touchMoved=!0,f(a,"mousemove"))},b._touchEnd=function(a){e&&(f(a,"mouseup"),f(a,"mouseout"),this._touchMoved||f(a,"click"),e=!1)},b._mouseInit=function(){var b=this;b.element.bind({touchstart:a.proxy(b,"_touchStart"),touchmove:a.proxy(b,"_touchMove"),touchend:a.proxy(b,"_touchEnd")}),c.call(b)},b._mouseDestroy=function(){var b=this;b.element.unbind({touchstart:a.proxy(b,"_touchStart"),touchmove:a.proxy(b,"_touchMove"),touchend:a.proxy(b,"_touchEnd")}),d.call(b)}}}(jQuery);/*! SmartMenus jQuery Plugin - v1.1.0 - September 17, 2017 + * http://www.smartmenus.org/ + * Copyright Vasil Dinkov, Vadikom Web Ltd. http://vadikom.com; Licensed MIT */(function(t){"function"==typeof define&&define.amd?define(["jquery"],t):"object"==typeof module&&"object"==typeof module.exports?module.exports=t(require("jquery")):t(jQuery)})(function($){function initMouseDetection(t){var e=".smartmenus_mouse";if(mouseDetectionEnabled||t)mouseDetectionEnabled&&t&&($(document).off(e),mouseDetectionEnabled=!1);else{var i=!0,s=null,o={mousemove:function(t){var e={x:t.pageX,y:t.pageY,timeStamp:(new Date).getTime()};if(s){var o=Math.abs(s.x-e.x),a=Math.abs(s.y-e.y);if((o>0||a>0)&&2>=o&&2>=a&&300>=e.timeStamp-s.timeStamp&&(mouse=!0,i)){var n=$(t.target).closest("a");n.is("a")&&$.each(menuTrees,function(){return $.contains(this.$root[0],n[0])?(this.itemEnter({currentTarget:n[0]}),!1):void 0}),i=!1}}s=e}};o[touchEvents?"touchstart":"pointerover pointermove pointerout MSPointerOver MSPointerMove MSPointerOut"]=function(t){isTouchEvent(t.originalEvent)&&(mouse=!1)},$(document).on(getEventsNS(o,e)),mouseDetectionEnabled=!0}}function isTouchEvent(t){return!/^(4|mouse)$/.test(t.pointerType)}function getEventsNS(t,e){e||(e="");var i={};for(var s in t)i[s.split(" ").join(e+" ")+e]=t[s];return i}var menuTrees=[],mouse=!1,touchEvents="ontouchstart"in window,mouseDetectionEnabled=!1,requestAnimationFrame=window.requestAnimationFrame||function(t){return setTimeout(t,1e3/60)},cancelAnimationFrame=window.cancelAnimationFrame||function(t){clearTimeout(t)},canAnimate=!!$.fn.animate;return $.SmartMenus=function(t,e){this.$root=$(t),this.opts=e,this.rootId="",this.accessIdPrefix="",this.$subArrow=null,this.activatedItems=[],this.visibleSubMenus=[],this.showTimeout=0,this.hideTimeout=0,this.scrollTimeout=0,this.clickActivated=!1,this.focusActivated=!1,this.zIndexInc=0,this.idInc=0,this.$firstLink=null,this.$firstSub=null,this.disabled=!1,this.$disableOverlay=null,this.$touchScrollingSub=null,this.cssTransforms3d="perspective"in t.style||"webkitPerspective"in t.style,this.wasCollapsible=!1,this.init()},$.extend($.SmartMenus,{hideAll:function(){$.each(menuTrees,function(){this.menuHideAll()})},destroy:function(){for(;menuTrees.length;)menuTrees[0].destroy();initMouseDetection(!0)},prototype:{init:function(t){var e=this;if(!t){menuTrees.push(this),this.rootId=((new Date).getTime()+Math.random()+"").replace(/\D/g,""),this.accessIdPrefix="sm-"+this.rootId+"-",this.$root.hasClass("sm-rtl")&&(this.opts.rightToLeftSubMenus=!0);var i=".smartmenus";this.$root.data("smartmenus",this).attr("data-smartmenus-id",this.rootId).dataSM("level",1).on(getEventsNS({"mouseover focusin":$.proxy(this.rootOver,this),"mouseout focusout":$.proxy(this.rootOut,this),keydown:$.proxy(this.rootKeyDown,this)},i)).on(getEventsNS({mouseenter:$.proxy(this.itemEnter,this),mouseleave:$.proxy(this.itemLeave,this),mousedown:$.proxy(this.itemDown,this),focus:$.proxy(this.itemFocus,this),blur:$.proxy(this.itemBlur,this),click:$.proxy(this.itemClick,this)},i),"a"),i+=this.rootId,this.opts.hideOnClick&&$(document).on(getEventsNS({touchstart:$.proxy(this.docTouchStart,this),touchmove:$.proxy(this.docTouchMove,this),touchend:$.proxy(this.docTouchEnd,this),click:$.proxy(this.docClick,this)},i)),$(window).on(getEventsNS({"resize orientationchange":$.proxy(this.winResize,this)},i)),this.opts.subIndicators&&(this.$subArrow=$("").addClass("sub-arrow"),this.opts.subIndicatorsText&&this.$subArrow.html(this.opts.subIndicatorsText)),initMouseDetection()}if(this.$firstSub=this.$root.find("ul").each(function(){e.menuInit($(this))}).eq(0),this.$firstLink=this.$root.find("a").eq(0),this.opts.markCurrentItem){var s=/(index|default)\.[^#\?\/]*/i,o=/#.*/,a=window.location.href.replace(s,""),n=a.replace(o,"");this.$root.find("a").each(function(){var t=this.href.replace(s,""),i=$(this);(t==a||t==n)&&(i.addClass("current"),e.opts.markCurrentTree&&i.parentsUntil("[data-smartmenus-id]","ul").each(function(){$(this).dataSM("parent-a").addClass("current")}))})}this.wasCollapsible=this.isCollapsible()},destroy:function(t){if(!t){var e=".smartmenus";this.$root.removeData("smartmenus").removeAttr("data-smartmenus-id").removeDataSM("level").off(e),e+=this.rootId,$(document).off(e),$(window).off(e),this.opts.subIndicators&&(this.$subArrow=null)}this.menuHideAll();var i=this;this.$root.find("ul").each(function(){var t=$(this);t.dataSM("scroll-arrows")&&t.dataSM("scroll-arrows").remove(),t.dataSM("shown-before")&&((i.opts.subMenusMinWidth||i.opts.subMenusMaxWidth)&&t.css({width:"",minWidth:"",maxWidth:""}).removeClass("sm-nowrap"),t.dataSM("scroll-arrows")&&t.dataSM("scroll-arrows").remove(),t.css({zIndex:"",top:"",left:"",marginLeft:"",marginTop:"",display:""})),0==(t.attr("id")||"").indexOf(i.accessIdPrefix)&&t.removeAttr("id")}).removeDataSM("in-mega").removeDataSM("shown-before").removeDataSM("scroll-arrows").removeDataSM("parent-a").removeDataSM("level").removeDataSM("beforefirstshowfired").removeAttr("role").removeAttr("aria-hidden").removeAttr("aria-labelledby").removeAttr("aria-expanded"),this.$root.find("a.has-submenu").each(function(){var t=$(this);0==t.attr("id").indexOf(i.accessIdPrefix)&&t.removeAttr("id")}).removeClass("has-submenu").removeDataSM("sub").removeAttr("aria-haspopup").removeAttr("aria-controls").removeAttr("aria-expanded").closest("li").removeDataSM("sub"),this.opts.subIndicators&&this.$root.find("span.sub-arrow").remove(),this.opts.markCurrentItem&&this.$root.find("a.current").removeClass("current"),t||(this.$root=null,this.$firstLink=null,this.$firstSub=null,this.$disableOverlay&&(this.$disableOverlay.remove(),this.$disableOverlay=null),menuTrees.splice($.inArray(this,menuTrees),1))},disable:function(t){if(!this.disabled){if(this.menuHideAll(),!t&&!this.opts.isPopup&&this.$root.is(":visible")){var e=this.$root.offset();this.$disableOverlay=$('
').css({position:"absolute",top:e.top,left:e.left,width:this.$root.outerWidth(),height:this.$root.outerHeight(),zIndex:this.getStartZIndex(!0),opacity:0}).appendTo(document.body)}this.disabled=!0}},docClick:function(t){return this.$touchScrollingSub?(this.$touchScrollingSub=null,void 0):((this.visibleSubMenus.length&&!$.contains(this.$root[0],t.target)||$(t.target).closest("a").length)&&this.menuHideAll(),void 0)},docTouchEnd:function(){if(this.lastTouch){if(!(!this.visibleSubMenus.length||void 0!==this.lastTouch.x2&&this.lastTouch.x1!=this.lastTouch.x2||void 0!==this.lastTouch.y2&&this.lastTouch.y1!=this.lastTouch.y2||this.lastTouch.target&&$.contains(this.$root[0],this.lastTouch.target))){this.hideTimeout&&(clearTimeout(this.hideTimeout),this.hideTimeout=0);var t=this;this.hideTimeout=setTimeout(function(){t.menuHideAll()},350)}this.lastTouch=null}},docTouchMove:function(t){if(this.lastTouch){var e=t.originalEvent.touches[0];this.lastTouch.x2=e.pageX,this.lastTouch.y2=e.pageY}},docTouchStart:function(t){var e=t.originalEvent.touches[0];this.lastTouch={x1:e.pageX,y1:e.pageY,target:e.target}},enable:function(){this.disabled&&(this.$disableOverlay&&(this.$disableOverlay.remove(),this.$disableOverlay=null),this.disabled=!1)},getClosestMenu:function(t){for(var e=$(t).closest("ul");e.dataSM("in-mega");)e=e.parent().closest("ul");return e[0]||null},getHeight:function(t){return this.getOffset(t,!0)},getOffset:function(t,e){var i;"none"==t.css("display")&&(i={position:t[0].style.position,visibility:t[0].style.visibility},t.css({position:"absolute",visibility:"hidden"}).show());var s=t[0].getBoundingClientRect&&t[0].getBoundingClientRect(),o=s&&(e?s.height||s.bottom-s.top:s.width||s.right-s.left);return o||0===o||(o=e?t[0].offsetHeight:t[0].offsetWidth),i&&t.hide().css(i),o},getStartZIndex:function(t){var e=parseInt(this[t?"$root":"$firstSub"].css("z-index"));return!t&&isNaN(e)&&(e=parseInt(this.$root.css("z-index"))),isNaN(e)?1:e},getTouchPoint:function(t){return t.touches&&t.touches[0]||t.changedTouches&&t.changedTouches[0]||t},getViewport:function(t){var e=t?"Height":"Width",i=document.documentElement["client"+e],s=window["inner"+e];return s&&(i=Math.min(i,s)),i},getViewportHeight:function(){return this.getViewport(!0)},getViewportWidth:function(){return this.getViewport()},getWidth:function(t){return this.getOffset(t)},handleEvents:function(){return!this.disabled&&this.isCSSOn()},handleItemEvents:function(t){return this.handleEvents()&&!this.isLinkInMegaMenu(t)},isCollapsible:function(){return"static"==this.$firstSub.css("position")},isCSSOn:function(){return"inline"!=this.$firstLink.css("display")},isFixed:function(){var t="fixed"==this.$root.css("position");return t||this.$root.parentsUntil("body").each(function(){return"fixed"==$(this).css("position")?(t=!0,!1):void 0}),t},isLinkInMegaMenu:function(t){return $(this.getClosestMenu(t[0])).hasClass("mega-menu")},isTouchMode:function(){return!mouse||this.opts.noMouseOver||this.isCollapsible()},itemActivate:function(t,e){var i=t.closest("ul"),s=i.dataSM("level");if(s>1&&(!this.activatedItems[s-2]||this.activatedItems[s-2][0]!=i.dataSM("parent-a")[0])){var o=this;$(i.parentsUntil("[data-smartmenus-id]","ul").get().reverse()).add(i).each(function(){o.itemActivate($(this).dataSM("parent-a"))})}if((!this.isCollapsible()||e)&&this.menuHideSubMenus(this.activatedItems[s-1]&&this.activatedItems[s-1][0]==t[0]?s:s-1),this.activatedItems[s-1]=t,this.$root.triggerHandler("activate.smapi",t[0])!==!1){var a=t.dataSM("sub");a&&(this.isTouchMode()||!this.opts.showOnClick||this.clickActivated)&&this.menuShow(a)}},itemBlur:function(t){var e=$(t.currentTarget);this.handleItemEvents(e)&&this.$root.triggerHandler("blur.smapi",e[0])},itemClick:function(t){var e=$(t.currentTarget);if(this.handleItemEvents(e)){if(this.$touchScrollingSub&&this.$touchScrollingSub[0]==e.closest("ul")[0])return this.$touchScrollingSub=null,t.stopPropagation(),!1;if(this.$root.triggerHandler("click.smapi",e[0])===!1)return!1;var i=$(t.target).is(".sub-arrow"),s=e.dataSM("sub"),o=s?2==s.dataSM("level"):!1,a=this.isCollapsible(),n=/toggle$/.test(this.opts.collapsibleBehavior),r=/link$/.test(this.opts.collapsibleBehavior),h=/^accordion/.test(this.opts.collapsibleBehavior);if(s&&!s.is(":visible")){if((!r||!a||i)&&(this.opts.showOnClick&&o&&(this.clickActivated=!0),this.itemActivate(e,h),s.is(":visible")))return this.focusActivated=!0,!1}else if(a&&(n||i))return this.itemActivate(e,h),this.menuHide(s),n&&(this.focusActivated=!1),!1;return this.opts.showOnClick&&o||e.hasClass("disabled")||this.$root.triggerHandler("select.smapi",e[0])===!1?!1:void 0}},itemDown:function(t){var e=$(t.currentTarget);this.handleItemEvents(e)&&e.dataSM("mousedown",!0)},itemEnter:function(t){var e=$(t.currentTarget);if(this.handleItemEvents(e)){if(!this.isTouchMode()){this.showTimeout&&(clearTimeout(this.showTimeout),this.showTimeout=0);var i=this;this.showTimeout=setTimeout(function(){i.itemActivate(e)},this.opts.showOnClick&&1==e.closest("ul").dataSM("level")?1:this.opts.showTimeout)}this.$root.triggerHandler("mouseenter.smapi",e[0])}},itemFocus:function(t){var e=$(t.currentTarget);this.handleItemEvents(e)&&(!this.focusActivated||this.isTouchMode()&&e.dataSM("mousedown")||this.activatedItems.length&&this.activatedItems[this.activatedItems.length-1][0]==e[0]||this.itemActivate(e,!0),this.$root.triggerHandler("focus.smapi",e[0]))},itemLeave:function(t){var e=$(t.currentTarget);this.handleItemEvents(e)&&(this.isTouchMode()||(e[0].blur(),this.showTimeout&&(clearTimeout(this.showTimeout),this.showTimeout=0)),e.removeDataSM("mousedown"),this.$root.triggerHandler("mouseleave.smapi",e[0]))},menuHide:function(t){if(this.$root.triggerHandler("beforehide.smapi",t[0])!==!1&&(canAnimate&&t.stop(!0,!0),"none"!=t.css("display"))){var e=function(){t.css("z-index","")};this.isCollapsible()?canAnimate&&this.opts.collapsibleHideFunction?this.opts.collapsibleHideFunction.call(this,t,e):t.hide(this.opts.collapsibleHideDuration,e):canAnimate&&this.opts.hideFunction?this.opts.hideFunction.call(this,t,e):t.hide(this.opts.hideDuration,e),t.dataSM("scroll")&&(this.menuScrollStop(t),t.css({"touch-action":"","-ms-touch-action":"","-webkit-transform":"",transform:""}).off(".smartmenus_scroll").removeDataSM("scroll").dataSM("scroll-arrows").hide()),t.dataSM("parent-a").removeClass("highlighted").attr("aria-expanded","false"),t.attr({"aria-expanded":"false","aria-hidden":"true"});var i=t.dataSM("level");this.activatedItems.splice(i-1,1),this.visibleSubMenus.splice($.inArray(t,this.visibleSubMenus),1),this.$root.triggerHandler("hide.smapi",t[0])}},menuHideAll:function(){this.showTimeout&&(clearTimeout(this.showTimeout),this.showTimeout=0);for(var t=this.opts.isPopup?1:0,e=this.visibleSubMenus.length-1;e>=t;e--)this.menuHide(this.visibleSubMenus[e]);this.opts.isPopup&&(canAnimate&&this.$root.stop(!0,!0),this.$root.is(":visible")&&(canAnimate&&this.opts.hideFunction?this.opts.hideFunction.call(this,this.$root):this.$root.hide(this.opts.hideDuration))),this.activatedItems=[],this.visibleSubMenus=[],this.clickActivated=!1,this.focusActivated=!1,this.zIndexInc=0,this.$root.triggerHandler("hideAll.smapi")},menuHideSubMenus:function(t){for(var e=this.activatedItems.length-1;e>=t;e--){var i=this.activatedItems[e].dataSM("sub");i&&this.menuHide(i)}},menuInit:function(t){if(!t.dataSM("in-mega")){t.hasClass("mega-menu")&&t.find("ul").dataSM("in-mega",!0);for(var e=2,i=t[0];(i=i.parentNode.parentNode)!=this.$root[0];)e++;var s=t.prevAll("a").eq(-1);s.length||(s=t.prevAll().find("a").eq(-1)),s.addClass("has-submenu").dataSM("sub",t),t.dataSM("parent-a",s).dataSM("level",e).parent().dataSM("sub",t);var o=s.attr("id")||this.accessIdPrefix+ ++this.idInc,a=t.attr("id")||this.accessIdPrefix+ ++this.idInc;s.attr({id:o,"aria-haspopup":"true","aria-controls":a,"aria-expanded":"false"}),t.attr({id:a,role:"group","aria-hidden":"true","aria-labelledby":o,"aria-expanded":"false"}),this.opts.subIndicators&&s[this.opts.subIndicatorsPos](this.$subArrow.clone())}},menuPosition:function(t){var e,i,s=t.dataSM("parent-a"),o=s.closest("li"),a=o.parent(),n=t.dataSM("level"),r=this.getWidth(t),h=this.getHeight(t),u=s.offset(),l=u.left,c=u.top,d=this.getWidth(s),m=this.getHeight(s),p=$(window),f=p.scrollLeft(),v=p.scrollTop(),b=this.getViewportWidth(),S=this.getViewportHeight(),g=a.parent().is("[data-sm-horizontal-sub]")||2==n&&!a.hasClass("sm-vertical"),M=this.opts.rightToLeftSubMenus&&!o.is("[data-sm-reverse]")||!this.opts.rightToLeftSubMenus&&o.is("[data-sm-reverse]"),w=2==n?this.opts.mainMenuSubOffsetX:this.opts.subMenusSubOffsetX,T=2==n?this.opts.mainMenuSubOffsetY:this.opts.subMenusSubOffsetY;if(g?(e=M?d-r-w:w,i=this.opts.bottomToTopSubMenus?-h-T:m+T):(e=M?w-r:d-w,i=this.opts.bottomToTopSubMenus?m-T-h:T),this.opts.keepInViewport){var y=l+e,I=c+i;if(M&&f>y?e=g?f-y+e:d-w:!M&&y+r>f+b&&(e=g?f+b-r-y+e:w-r),g||(S>h&&I+h>v+S?i+=v+S-h-I:(h>=S||v>I)&&(i+=v-I)),g&&(I+h>v+S+.49||v>I)||!g&&h>S+.49){var x=this;t.dataSM("scroll-arrows")||t.dataSM("scroll-arrows",$([$('')[0],$('')[0]]).on({mouseenter:function(){t.dataSM("scroll").up=$(this).hasClass("scroll-up"),x.menuScroll(t)},mouseleave:function(e){x.menuScrollStop(t),x.menuScrollOut(t,e)},"mousewheel DOMMouseScroll":function(t){t.preventDefault()}}).insertAfter(t));var A=".smartmenus_scroll";if(t.dataSM("scroll",{y:this.cssTransforms3d?0:i-m,step:1,itemH:m,subH:h,arrowDownH:this.getHeight(t.dataSM("scroll-arrows").eq(1))}).on(getEventsNS({mouseover:function(e){x.menuScrollOver(t,e)},mouseout:function(e){x.menuScrollOut(t,e)},"mousewheel DOMMouseScroll":function(e){x.menuScrollMousewheel(t,e)}},A)).dataSM("scroll-arrows").css({top:"auto",left:"0",marginLeft:e+(parseInt(t.css("border-left-width"))||0),width:r-(parseInt(t.css("border-left-width"))||0)-(parseInt(t.css("border-right-width"))||0),zIndex:t.css("z-index")}).eq(g&&this.opts.bottomToTopSubMenus?0:1).show(),this.isFixed()){var C={};C[touchEvents?"touchstart touchmove touchend":"pointerdown pointermove pointerup MSPointerDown MSPointerMove MSPointerUp"]=function(e){x.menuScrollTouch(t,e)},t.css({"touch-action":"none","-ms-touch-action":"none"}).on(getEventsNS(C,A))}}}t.css({top:"auto",left:"0",marginLeft:e,marginTop:i-m})},menuScroll:function(t,e,i){var s,o=t.dataSM("scroll"),a=t.dataSM("scroll-arrows"),n=o.up?o.upEnd:o.downEnd;if(!e&&o.momentum){if(o.momentum*=.92,s=o.momentum,.5>s)return this.menuScrollStop(t),void 0}else s=i||(e||!this.opts.scrollAccelerate?this.opts.scrollStep:Math.floor(o.step));var r=t.dataSM("level");if(this.activatedItems[r-1]&&this.activatedItems[r-1].dataSM("sub")&&this.activatedItems[r-1].dataSM("sub").is(":visible")&&this.menuHideSubMenus(r-1),o.y=o.up&&o.y>=n||!o.up&&n>=o.y?o.y:Math.abs(n-o.y)>s?o.y+(o.up?s:-s):n,t.css(this.cssTransforms3d?{"-webkit-transform":"translate3d(0, "+o.y+"px, 0)",transform:"translate3d(0, "+o.y+"px, 0)"}:{marginTop:o.y}),mouse&&(o.up&&o.y>o.downEnd||!o.up&&o.y0;t.dataSM("scroll-arrows").eq(i?0:1).is(":visible")&&(t.dataSM("scroll").up=i,this.menuScroll(t,!0))}e.preventDefault()},menuScrollOut:function(t,e){mouse&&(/^scroll-(up|down)/.test((e.relatedTarget||"").className)||(t[0]==e.relatedTarget||$.contains(t[0],e.relatedTarget))&&this.getClosestMenu(e.relatedTarget)==t[0]||t.dataSM("scroll-arrows").css("visibility","hidden"))},menuScrollOver:function(t,e){if(mouse&&!/^scroll-(up|down)/.test(e.target.className)&&this.getClosestMenu(e.target)==t[0]){this.menuScrollRefreshData(t);var i=t.dataSM("scroll"),s=$(window).scrollTop()-t.dataSM("parent-a").offset().top-i.itemH;t.dataSM("scroll-arrows").eq(0).css("margin-top",s).end().eq(1).css("margin-top",s+this.getViewportHeight()-i.arrowDownH).end().css("visibility","visible")}},menuScrollRefreshData:function(t){var e=t.dataSM("scroll"),i=$(window).scrollTop()-t.dataSM("parent-a").offset().top-e.itemH;this.cssTransforms3d&&(i=-(parseFloat(t.css("margin-top"))-i)),$.extend(e,{upEnd:i,downEnd:i+this.getViewportHeight()-e.subH})},menuScrollStop:function(t){return this.scrollTimeout?(cancelAnimationFrame(this.scrollTimeout),this.scrollTimeout=0,t.dataSM("scroll").step=1,!0):void 0},menuScrollTouch:function(t,e){if(e=e.originalEvent,isTouchEvent(e)){var i=this.getTouchPoint(e);if(this.getClosestMenu(i.target)==t[0]){var s=t.dataSM("scroll");if(/(start|down)$/i.test(e.type))this.menuScrollStop(t)?(e.preventDefault(),this.$touchScrollingSub=t):this.$touchScrollingSub=null,this.menuScrollRefreshData(t),$.extend(s,{touchStartY:i.pageY,touchStartTime:e.timeStamp});else if(/move$/i.test(e.type)){var o=void 0!==s.touchY?s.touchY:s.touchStartY;if(void 0!==o&&o!=i.pageY){this.$touchScrollingSub=t;var a=i.pageY>o;void 0!==s.up&&s.up!=a&&$.extend(s,{touchStartY:i.pageY,touchStartTime:e.timeStamp}),$.extend(s,{up:a,touchY:i.pageY}),this.menuScroll(t,!0,Math.abs(i.pageY-o))}e.preventDefault()}else void 0!==s.touchY&&((s.momentum=15*Math.pow(Math.abs(i.pageY-s.touchStartY)/(e.timeStamp-s.touchStartTime),2))&&(this.menuScrollStop(t),this.menuScroll(t),e.preventDefault()),delete s.touchY)}}},menuShow:function(t){if((t.dataSM("beforefirstshowfired")||(t.dataSM("beforefirstshowfired",!0),this.$root.triggerHandler("beforefirstshow.smapi",t[0])!==!1))&&this.$root.triggerHandler("beforeshow.smapi",t[0])!==!1&&(t.dataSM("shown-before",!0),canAnimate&&t.stop(!0,!0),!t.is(":visible"))){var e=t.dataSM("parent-a"),i=this.isCollapsible();if((this.opts.keepHighlighted||i)&&e.addClass("highlighted"),i)t.removeClass("sm-nowrap").css({zIndex:"",width:"auto",minWidth:"",maxWidth:"",top:"",left:"",marginLeft:"",marginTop:""});else{if(t.css("z-index",this.zIndexInc=(this.zIndexInc||this.getStartZIndex())+1),(this.opts.subMenusMinWidth||this.opts.subMenusMaxWidth)&&(t.css({width:"auto",minWidth:"",maxWidth:""}).addClass("sm-nowrap"),this.opts.subMenusMinWidth&&t.css("min-width",this.opts.subMenusMinWidth),this.opts.subMenusMaxWidth)){var s=this.getWidth(t);t.css("max-width",this.opts.subMenusMaxWidth),s>this.getWidth(t)&&t.removeClass("sm-nowrap").css("width",this.opts.subMenusMaxWidth)}this.menuPosition(t)}var o=function(){t.css("overflow","")};i?canAnimate&&this.opts.collapsibleShowFunction?this.opts.collapsibleShowFunction.call(this,t,o):t.show(this.opts.collapsibleShowDuration,o):canAnimate&&this.opts.showFunction?this.opts.showFunction.call(this,t,o):t.show(this.opts.showDuration,o),e.attr("aria-expanded","true"),t.attr({"aria-expanded":"true","aria-hidden":"false"}),this.visibleSubMenus.push(t),this.$root.triggerHandler("show.smapi",t[0])}},popupHide:function(t){this.hideTimeout&&(clearTimeout(this.hideTimeout),this.hideTimeout=0);var e=this;this.hideTimeout=setTimeout(function(){e.menuHideAll()},t?1:this.opts.hideTimeout)},popupShow:function(t,e){if(!this.opts.isPopup)return alert('SmartMenus jQuery Error:\n\nIf you want to show this menu via the "popupShow" method, set the isPopup:true option.'),void 0;if(this.hideTimeout&&(clearTimeout(this.hideTimeout),this.hideTimeout=0),this.$root.dataSM("shown-before",!0),canAnimate&&this.$root.stop(!0,!0),!this.$root.is(":visible")){this.$root.css({left:t,top:e});var i=this,s=function(){i.$root.css("overflow","")};canAnimate&&this.opts.showFunction?this.opts.showFunction.call(this,this.$root,s):this.$root.show(this.opts.showDuration,s),this.visibleSubMenus[0]=this.$root}},refresh:function(){this.destroy(!0),this.init(!0)},rootKeyDown:function(t){if(this.handleEvents())switch(t.keyCode){case 27:var e=this.activatedItems[0];if(e){this.menuHideAll(),e[0].focus();var i=e.dataSM("sub");i&&this.menuHide(i)}break;case 32:var s=$(t.target);if(s.is("a")&&this.handleItemEvents(s)){var i=s.dataSM("sub");i&&!i.is(":visible")&&(this.itemClick({currentTarget:t.target}),t.preventDefault())}}},rootOut:function(t){if(this.handleEvents()&&!this.isTouchMode()&&t.target!=this.$root[0]&&(this.hideTimeout&&(clearTimeout(this.hideTimeout),this.hideTimeout=0),!this.opts.showOnClick||!this.opts.hideOnClick)){var e=this;this.hideTimeout=setTimeout(function(){e.menuHideAll()},this.opts.hideTimeout)}},rootOver:function(t){this.handleEvents()&&!this.isTouchMode()&&t.target!=this.$root[0]&&this.hideTimeout&&(clearTimeout(this.hideTimeout),this.hideTimeout=0)},winResize:function(t){if(this.handleEvents()){if(!("onorientationchange"in window)||"orientationchange"==t.type){var e=this.isCollapsible();this.wasCollapsible&&e||(this.activatedItems.length&&this.activatedItems[this.activatedItems.length-1][0].blur(),this.menuHideAll()),this.wasCollapsible=e}}else if(this.$disableOverlay){var i=this.$root.offset();this.$disableOverlay.css({top:i.top,left:i.left,width:this.$root.outerWidth(),height:this.$root.outerHeight()})}}}}),$.fn.dataSM=function(t,e){return e?this.data(t+"_smartmenus",e):this.data(t+"_smartmenus")},$.fn.removeDataSM=function(t){return this.removeData(t+"_smartmenus")},$.fn.smartmenus=function(options){if("string"==typeof options){var args=arguments,method=options;return Array.prototype.shift.call(args),this.each(function(){var t=$(this).data("smartmenus");t&&t[method]&&t[method].apply(t,args)})}return this.each(function(){var dataOpts=$(this).data("sm-options")||null;if(dataOpts)try{dataOpts=eval("("+dataOpts+")")}catch(e){dataOpts=null,alert('ERROR\n\nSmartMenus jQuery init:\nInvalid "data-sm-options" attribute value syntax.')}new $.SmartMenus(this,$.extend({},$.fn.smartmenus.defaults,options,dataOpts))})},$.fn.smartmenus.defaults={isPopup:!1,mainMenuSubOffsetX:0,mainMenuSubOffsetY:0,subMenusSubOffsetX:0,subMenusSubOffsetY:0,subMenusMinWidth:"10em",subMenusMaxWidth:"20em",subIndicators:!0,subIndicatorsPos:"append",subIndicatorsText:"",scrollStep:30,scrollAccelerate:!0,showTimeout:250,hideTimeout:500,showDuration:0,showFunction:null,hideDuration:0,hideFunction:function(t,e){t.fadeOut(200,e)},collapsibleShowDuration:0,collapsibleShowFunction:function(t,e){t.slideDown(200,e)},collapsibleHideDuration:0,collapsibleHideFunction:function(t,e){t.slideUp(200,e)},showOnClick:!1,hideOnClick:!0,noMouseOver:!1,keepInViewport:!0,keepHighlighted:!0,markCurrentItem:!1,markCurrentTree:!0,rightToLeftSubMenus:!1,bottomToTopSubMenus:!1,collapsibleBehavior:"default"},$}); \ No newline at end of file diff --git a/doxygen/html/menu.js b/doxygen/html/menu.js new file mode 100644 index 00000000..2fe2214f --- /dev/null +++ b/doxygen/html/menu.js @@ -0,0 +1,51 @@ +/* + @licstart The following is the entire license notice for the JavaScript code in this file. + + The MIT License (MIT) + + Copyright (C) 1997-2020 by Dimitri van Heesch + + 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. + + @licend The above is the entire license notice for the JavaScript code in this file + */ +function initMenu(relPath,searchEnabled,serverSide,searchPage,search) { + function makeTree(data,relPath) { + var result=''; + if ('children' in data) { + result+=''; + } + return result; + } + + $('#main-nav').append(makeTree(menudata,relPath)); + $('#main-nav').children(':first').addClass('sm sm-dox').attr('id','main-menu'); + if (searchEnabled) { + if (serverSide) { + $('#main-menu').append('
  • '); + } else { + $('#main-menu').append('
  • '); + } + } + $('#main-menu').smartmenus(); +} +/* @license-end */ diff --git a/doxygen/html/menudata.js b/doxygen/html/menudata.js new file mode 100644 index 00000000..87c88ac8 --- /dev/null +++ b/doxygen/html/menudata.js @@ -0,0 +1,68 @@ +/* + @licstart The following is the entire license notice for the JavaScript code in this file. + + The MIT License (MIT) + + Copyright (C) 1997-2020 by Dimitri van Heesch + + 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. + + @licend The above is the entire license notice for the JavaScript code in this file +*/ +var menudata={children:[ +{text:"Main Page",url:"index.html"}, +{text:"Data Structures",url:"annotated.html",children:[ +{text:"Data Structures",url:"annotated.html"}, +{text:"Data Structure Index",url:"classes.html"}, +{text:"Data Fields",url:"functions.html",children:[ +{text:"All",url:"functions.html"}, +{text:"Variables",url:"functions_vars.html"}]}]}, +{text:"Files",url:"files.html",children:[ +{text:"File List",url:"files.html"}, +{text:"Globals",url:"globals.html",children:[ +{text:"All",url:"globals.html",children:[ +{text:"_",url:"globals.html#index__5F"}, +{text:"b",url:"globals_b.html#index_b"}, +{text:"c",url:"globals_c.html#index_c"}, +{text:"d",url:"globals_d.html#index_d"}, +{text:"e",url:"globals_e.html#index_e"}, +{text:"f",url:"globals_f.html#index_f"}, +{text:"g",url:"globals_g.html#index_g"}, +{text:"h",url:"globals_h.html#index_h"}, +{text:"i",url:"globals_i.html#index_i"}, +{text:"j",url:"globals_j.html#index_j"}, +{text:"m",url:"globals_m.html#index_m"}, +{text:"n",url:"globals_n.html#index_n"}, +{text:"p",url:"globals_p.html#index_p"}, +{text:"s",url:"globals_s.html#index_s"}, +{text:"t",url:"globals_t.html#index_t"}]}, +{text:"Functions",url:"globals_func.html",children:[ +{text:"j",url:"globals_func.html#index_j"}, +{text:"n",url:"globals_func_n.html#index_n"}, +{text:"s",url:"globals_func_s.html#index_s"}]}, +{text:"Variables",url:"globals_vars.html"}, +{text:"Typedefs",url:"globals_type.html"}, +{text:"Macros",url:"globals_defs.html",children:[ +{text:"_",url:"globals_defs.html#index__5F"}, +{text:"b",url:"globals_defs.html#index_b"}, +{text:"c",url:"globals_defs.html#index_c"}, +{text:"e",url:"globals_defs.html#index_e"}, +{text:"i",url:"globals_defs.html#index_i"}, +{text:"j",url:"globals_defs.html#index_j"}, +{text:"n",url:"globals_defs.html#index_n"}, +{text:"p",url:"globals_defs.html#index_p"}, +{text:"s",url:"globals_defs.html#index_s"}, +{text:"t",url:"globals_defs.html#index_t"}]}]}]}]} diff --git a/doxygen/html/n__cjson_8c.html b/doxygen/html/n__cjson_8c.html new file mode 100644 index 00000000..932e334b --- /dev/null +++ b/doxygen/html/n__cjson_8c.html @@ -0,0 +1,2451 @@ + + + + + + + +note-c: /home/runner/work/note-c/note-c/n_cjson.c File Reference + + + + + + + + + +
    +
    + + + + + + + +
    +
    note-c +  1.0 +
    +
    An easy to use Notecard Library for C/C++
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + +
    +
    + +
    +
    /home/runner/work/note-c/note-c/n_cjson.c File Reference
    +
    +
    +
    #include <string.h>
    +#include <stdio.h>
    +#include <math.h>
    +#include <stdlib.h>
    +#include <limits.h>
    +#include <ctype.h>
    +#include "n_lib.h"
    +
    + + + + + + + +

    +Data Structures

    struct  error
     
    struct  parse_buffer
     
    struct  printbuffer
     
    + + + + + + + + + + + + + + + +

    +Macros

    #define PRINT_TAB_CHARS   4
     
    #define NOTE_C_STATIC   static
     
    #define can_read(buffer, size)   ((buffer != NULL) && (((buffer)->offset + size) <= (buffer)->length))
     
    #define can_access_at_index(buffer, index)   ((buffer != NULL) && (((buffer)->offset + index) < (buffer)->length))
     
    #define cannot_access_at_index(buffer, index)   (!can_access_at_index(buffer, index))
     
    #define buffer_at_offset(buffer)   ((buffer)->content + (buffer)->offset)
     
    #define cjson_min(a, b)   ((a < b) ? a : b)
     
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

    +Functions

    const char * JGetErrorPtr (void)
     
    char * JGetStringValue (J *item)
     
    const char * JVersion (void)
     
    void * JMalloc (size_t size)
     Dynamically allocate a block of memory of the given size. More...
     
    void JFree (void *p)
     Free a block of dynamically allocated memory. More...
     
    void JDelete (J *item)
     Free a J object. More...
     
    JNUMBER JSetNumberHelper (J *object, JNUMBER number)
     
    void n_htoa16 (uint16_t n, unsigned char *p)
     
    JJParseWithOpts (const char *value, const char **return_parse_end, Jbool require_null_terminated)
     
    JJParse (const char *value)
     Parse the passed in C-string as JSON and return a J object representing it. More...
     
    char * JPrint (const J *item)
     
    char * JPrintUnformatted (const J *item)
     Get the unformatted string representation of a J object. More...
     
    char * JPrintUnformattedOmitEmpty (const J *item)
     
    char * JPrintBuffered (const J *item, int prebuffer, Jbool fmt)
     
    Jbool JPrintPreallocatedOmitEmpty (J *item, char *buf, const int len, const Jbool fmt)
     
    Jbool JPrintPreallocated (J *item, char *buf, const int len, const Jbool fmt)
     
    int JGetArraySize (const J *array)
     
    JJGetArrayItem (const J *array, int index)
     
    JJGetObjectItem (const J *const object, const char *const string)
     
    JJGetObjectItemCaseSensitive (const J *const object, const char *const string)
     
    Jbool JHasObjectItem (const J *object, const char *string)
     
    void JAddItemToArray (J *array, J *item)
     
    void JAddItemToObject (J *object, const char *string, J *item)
     
    void JAddItemToObjectCS (J *object, const char *string, J *item)
     
    void JAddItemReferenceToArray (J *array, J *item)
     
    void JAddItemReferenceToObject (J *object, const char *string, J *item)
     
    JJAddTrueToObject (J *const object, const char *const name)
     
    JJAddFalseToObject (J *const object, const char *const name)
     
    JJAddBoolToObject (J *const object, const char *const name, const Jbool boolean)
     Add a boolean field to a J object. More...
     
    JJAddNumberToObject (J *const object, const char *const name, const JNUMBER number)
     Add a number field to a J object. More...
     
    JJAddIntToObject (J *const object, const char *const name, const JINTEGER integer)
     
    JJAddStringToObject (J *const object, const char *const name, const char *const string)
     Add a string field to a J object. More...
     
    JJAddRawToObject (J *const object, const char *const name, const char *const raw)
     
    JJAddObjectToObject (J *const object, const char *const name)
     Add an object field to another J object. More...
     
    JJAddArrayToObject (J *const object, const char *const name)
     Add an array field to a J object. More...
     
    JJDetachItemViaPointer (J *parent, J *const item)
     
    JJDetachItemFromArray (J *array, int which)
     
    void JDeleteItemFromArray (J *array, int which)
     
    JJDetachItemFromObject (J *object, const char *string)
     
    JJDetachItemFromObjectCaseSensitive (J *object, const char *string)
     
    void JDeleteItemFromObject (J *object, const char *string)
     
    void JDeleteItemFromObjectCaseSensitive (J *object, const char *string)
     
    void JInsertItemInArray (J *array, int which, J *newitem)
     
    Jbool JReplaceItemViaPointer (J *const parent, J *const item, J *replacement)
     
    void JReplaceItemInArray (J *array, int which, J *newitem)
     
    void JReplaceItemInObject (J *object, const char *string, J *newitem)
     
    void JReplaceItemInObjectCaseSensitive (J *object, const char *string, J *newitem)
     
    JJCreateTrue (void)
     
    JJCreateFalse (void)
     
    JJCreateBool (Jbool b)
     
    JJCreateNumber (JNUMBER num)
     
    JJCreateInteger (JINTEGER integer)
     
    JJCreateString (const char *string)
     
    JJCreateStringValue (const char *string)
     
    JJCreateStringReference (const char *string)
     
    JJCreateObjectReference (const J *child)
     
    JJCreateArrayReference (const J *child)
     
    JJCreateRaw (const char *raw)
     
    JJCreateArray (void)
     
    JJCreateObject (void)
     Create a new J object. More...
     
    JJCreateIntArray (const long int *numbers, int count)
     
    JJCreateNumberArray (const JNUMBER *numbers, int count)
     
    JJCreateStringArray (const char **strings, int count)
     
    JJDuplicate (const J *item, Jbool recurse)
     
    void JMinify (char *json)
     
    Jbool JIsInvalid (const J *const item)
     
    Jbool JIsFalse (const J *const item)
     
    Jbool JIsTrue (const J *const item)
     
    Jbool JIsBool (const J *const item)
     
    Jbool JIsNull (const J *const item)
     
    Jbool JIsNumber (const J *const item)
     
    Jbool JIsString (const J *const item)
     
    Jbool JIsArray (const J *const item)
     
    Jbool JIsObject (const J *const item)
     
    Jbool JIsRaw (const J *const item)
     
    Jbool JCompare (const J *const a, const J *const b, const Jbool case_sensitive)
     
    +

    Detailed Description

    +

    Written by Ray Ozzie and Blues Inc. team.

    +

    Portions Copyright (c) 2019 Blues Inc. MIT License. Use of this source code is governed by licenses granted by the copyright holder including that found in the LICENSE file.

    +

    MODIFIED for use in notecard primarily by altering default memory allocator and by renaming the functions so that they won't conflict with a developer's own decision to incorporate the actual production cJSON into their own app. In no way shall this interfere with a production cJSON.

    +

    Renaming was done as follows: CJSON_ -> N_CJSON_ cJSON_ -> J cJSON -> J

    +

    Portions Copyright (c) 2009-2017 Dave Gamble and cJSON contributors

    +

    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 i 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.

    +

    Macro Definition Documentation

    + +

    ◆ buffer_at_offset

    + +
    +
    + + + + + + + + +
    #define buffer_at_offset( buffer)   ((buffer)->content + (buffer)->offset)
    +
    + +
    +
    + +

    ◆ can_access_at_index

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    #define can_access_at_index( buffer,
     index 
    )   ((buffer != NULL) && (((buffer)->offset + index) < (buffer)->length))
    +
    + +
    +
    + +

    ◆ can_read

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    #define can_read( buffer,
     size 
    )   ((buffer != NULL) && (((buffer)->offset + size) <= (buffer)->length))
    +
    + +
    +
    + +

    ◆ cannot_access_at_index

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    #define cannot_access_at_index( buffer,
     index 
    )   (!can_access_at_index(buffer, index))
    +
    + +
    +
    + +

    ◆ cjson_min

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    #define cjson_min( a,
     
    )   ((a < b) ? a : b)
    +
    + +
    +
    + +

    ◆ NOTE_C_STATIC

    + +
    +
    + + + + +
    #define NOTE_C_STATIC   static
    +
    + +
    +
    + +

    ◆ PRINT_TAB_CHARS

    + +
    +
    + + + + +
    #define PRINT_TAB_CHARS   4
    +
    + +
    +
    +

    Function Documentation

    + +

    ◆ JAddArrayToObject()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    J* JAddArrayToObject (J *const object,
    const char *const name 
    )
    +
    + +

    Add an array field to a J object.

    +
    Parameters
    + + + +
    objectThe object to add the field to.
    nameThe name of the field.
    +
    +
    +
    Returns
    A pointer to the newly-added array field or NULL on error.
    + +
    +
    + +

    ◆ JAddBoolToObject()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    J* JAddBoolToObject (J *const object,
    const char *const name,
    const Jbool boolean 
    )
    +
    + +

    Add a boolean field to a J object.

    +
    Parameters
    + + + + +
    objectThe object to add the field to.
    nameThe name of the field.
    booleanThe value of the field.
    +
    +
    +
    Returns
    A pointer to the newly-added boolean field or NULL on error.
    + +
    +
    + +

    ◆ JAddFalseToObject()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    J* JAddFalseToObject (J *const object,
    const char *const name 
    )
    +
    + +
    +
    + +

    ◆ JAddIntToObject()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    J* JAddIntToObject (J *const object,
    const char *const name,
    const JINTEGER integer 
    )
    +
    + +
    +
    + +

    ◆ JAddItemReferenceToArray()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    void JAddItemReferenceToArray (Jarray,
    Jitem 
    )
    +
    + +
    +
    + +

    ◆ JAddItemReferenceToObject()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    void JAddItemReferenceToObject (Jobject,
    const char * string,
    Jitem 
    )
    +
    + +
    +
    + +

    ◆ JAddItemToArray()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    void JAddItemToArray (Jarray,
    Jitem 
    )
    +
    + +
    +
    + +

    ◆ JAddItemToObject()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    void JAddItemToObject (Jobject,
    const char * string,
    Jitem 
    )
    +
    + +
    +
    + +

    ◆ JAddItemToObjectCS()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    void JAddItemToObjectCS (Jobject,
    const char * string,
    Jitem 
    )
    +
    + +
    +
    + +

    ◆ JAddNumberToObject()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    J* JAddNumberToObject (J *const object,
    const char *const name,
    const JNUMBER number 
    )
    +
    + +

    Add a number field to a J object.

    +
    Parameters
    + + + + +
    objectThe object to add the field to.
    nameThe name of the field.
    numberThe value of the field.
    +
    +
    +
    Returns
    A pointer to the newly-added number field or NULL on error.
    + +
    +
    + +

    ◆ JAddObjectToObject()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    J* JAddObjectToObject (J *const object,
    const char *const name 
    )
    +
    + +

    Add an object field to another J object.

    +
    Parameters
    + + + +
    objectThe object to add the field to.
    nameThe name of the field.
    +
    +
    +
    Returns
    A pointer to the newly-added object field or NULL on error.
    + +
    +
    + +

    ◆ JAddRawToObject()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    J* JAddRawToObject (J *const object,
    const char *const name,
    const char *const raw 
    )
    +
    + +
    +
    + +

    ◆ JAddStringToObject()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    J* JAddStringToObject (J *const object,
    const char *const name,
    const char *const string 
    )
    +
    + +

    Add a string field to a J object.

    +
    Parameters
    + + + + +
    objectThe object to add the field to.
    nameThe name of the field.
    stringThe value of the field.
    +
    +
    +
    Returns
    A pointer to the newly-added string field or NULL on error.
    + +
    +
    + +

    ◆ JAddTrueToObject()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    J* JAddTrueToObject (J *const object,
    const char *const name 
    )
    +
    + +
    +
    + +

    ◆ JCompare()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    Jbool JCompare (const J *const a,
    const J *const b,
    const Jbool case_sensitive 
    )
    +
    + +
    +
    + +

    ◆ JCreateArray()

    + +
    +
    + + + + + + + + +
    J* JCreateArray (void )
    +
    + +
    +
    + +

    ◆ JCreateArrayReference()

    + +
    +
    + + + + + + + + +
    J* JCreateArrayReference (const Jchild)
    +
    + +
    +
    + +

    ◆ JCreateBool()

    + +
    +
    + + + + + + + + +
    J* JCreateBool (Jbool b)
    +
    + +
    +
    + +

    ◆ JCreateFalse()

    + +
    +
    + + + + + + + + +
    J* JCreateFalse (void )
    +
    + +
    +
    + +

    ◆ JCreateIntArray()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    J* JCreateIntArray (const long int * numbers,
    int count 
    )
    +
    + +
    +
    + +

    ◆ JCreateInteger()

    + +
    +
    + + + + + + + + +
    J* JCreateInteger (JINTEGER integer)
    +
    + +
    +
    + +

    ◆ JCreateNumber()

    + +
    +
    + + + + + + + + +
    J* JCreateNumber (JNUMBER num)
    +
    + +
    +
    + +

    ◆ JCreateNumberArray()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    J* JCreateNumberArray (const JNUMBERnumbers,
    int count 
    )
    +
    + +
    +
    + +

    ◆ JCreateObject()

    + +
    +
    + + + + + + + + +
    J* JCreateObject (void )
    +
    + +

    Create a new J object.

    +

    To free the object, use JDelete.

    +
    Returns
    A pointer to the newly-created object.
    + +
    +
    + +

    ◆ JCreateObjectReference()

    + +
    +
    + + + + + + + + +
    J* JCreateObjectReference (const Jchild)
    +
    + +
    +
    + +

    ◆ JCreateRaw()

    + +
    +
    + + + + + + + + +
    J* JCreateRaw (const char * raw)
    +
    + +
    +
    + +

    ◆ JCreateString()

    + +
    +
    + + + + + + + + +
    J* JCreateString (const char * string)
    +
    + +
    +
    + +

    ◆ JCreateStringArray()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    J* JCreateStringArray (const char ** strings,
    int count 
    )
    +
    + +
    +
    + +

    ◆ JCreateStringReference()

    + +
    +
    + + + + + + + + +
    J* JCreateStringReference (const char * string)
    +
    + +
    +
    + +

    ◆ JCreateStringValue()

    + +
    +
    + + + + + + + + +
    J* JCreateStringValue (const char * string)
    +
    + +
    +
    + +

    ◆ JCreateTrue()

    + +
    +
    + + + + + + + + +
    J* JCreateTrue (void )
    +
    + +
    +
    + +

    ◆ JDelete()

    + +
    +
    + + + + + + + + +
    void JDelete (Jitem)
    +
    + +

    Free a J object.

    +
    Parameters
    + + +
    itemA pointer to the object.
    +
    +
    + +
    +
    + +

    ◆ JDeleteItemFromArray()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    void JDeleteItemFromArray (Jarray,
    int which 
    )
    +
    + +
    +
    + +

    ◆ JDeleteItemFromObject()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    void JDeleteItemFromObject (Jobject,
    const char * string 
    )
    +
    + +
    +
    + +

    ◆ JDeleteItemFromObjectCaseSensitive()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    void JDeleteItemFromObjectCaseSensitive (Jobject,
    const char * string 
    )
    +
    + +
    +
    + +

    ◆ JDetachItemFromArray()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    J* JDetachItemFromArray (Jarray,
    int which 
    )
    +
    + +
    +
    + +

    ◆ JDetachItemFromObject()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    J* JDetachItemFromObject (Jobject,
    const char * string 
    )
    +
    + +
    +
    + +

    ◆ JDetachItemFromObjectCaseSensitive()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    J* JDetachItemFromObjectCaseSensitive (Jobject,
    const char * string 
    )
    +
    + +
    +
    + +

    ◆ JDetachItemViaPointer()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    J* JDetachItemViaPointer (Jparent,
    J *const item 
    )
    +
    + +
    +
    + +

    ◆ JDuplicate()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    J* JDuplicate (const Jitem,
    Jbool recurse 
    )
    +
    + +
    +
    + +

    ◆ JFree()

    + +
    +
    + + + + + + + + +
    void JFree (void * p)
    +
    + +

    Free a block of dynamically allocated memory.

    +

    This is simply a wrapper around the memory free function provided by the user via NoteSetFn.

    +
    Parameters
    + + +
    pA pointer to the block of memory to free.
    +
    +
    + +
    +
    + +

    ◆ JGetArrayItem()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    J* JGetArrayItem (const Jarray,
    int index 
    )
    +
    + +
    +
    + +

    ◆ JGetArraySize()

    + +
    +
    + + + + + + + + +
    int JGetArraySize (const Jarray)
    +
    + +
    +
    + +

    ◆ JGetErrorPtr()

    + +
    +
    + + + + + + + + +
    const char* JGetErrorPtr (void )
    +
    + +
    +
    + +

    ◆ JGetObjectItem()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    J* JGetObjectItem (const J *const object,
    const char *const string 
    )
    +
    + +
    +
    + +

    ◆ JGetObjectItemCaseSensitive()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    J* JGetObjectItemCaseSensitive (const J *const object,
    const char *const string 
    )
    +
    + +
    +
    + +

    ◆ JGetStringValue()

    + +
    +
    + + + + + + + + +
    char* JGetStringValue (Jitem)
    +
    + +
    +
    + +

    ◆ JHasObjectItem()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    Jbool JHasObjectItem (const Jobject,
    const char * string 
    )
    +
    + +
    +
    + +

    ◆ JInsertItemInArray()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    void JInsertItemInArray (Jarray,
    int which,
    Jnewitem 
    )
    +
    + +
    +
    + +

    ◆ JIsArray()

    + +
    +
    + + + + + + + + +
    Jbool JIsArray (const J *const item)
    +
    + +
    +
    + +

    ◆ JIsBool()

    + +
    +
    + + + + + + + + +
    Jbool JIsBool (const J *const item)
    +
    + +
    +
    + +

    ◆ JIsFalse()

    + +
    +
    + + + + + + + + +
    Jbool JIsFalse (const J *const item)
    +
    + +
    +
    + +

    ◆ JIsInvalid()

    + +
    +
    + + + + + + + + +
    Jbool JIsInvalid (const J *const item)
    +
    + +
    +
    + +

    ◆ JIsNull()

    + +
    +
    + + + + + + + + +
    Jbool JIsNull (const J *const item)
    +
    + +
    +
    + +

    ◆ JIsNumber()

    + +
    +
    + + + + + + + + +
    Jbool JIsNumber (const J *const item)
    +
    + +
    +
    + +

    ◆ JIsObject()

    + +
    +
    + + + + + + + + +
    Jbool JIsObject (const J *const item)
    +
    + +
    +
    + +

    ◆ JIsRaw()

    + +
    +
    + + + + + + + + +
    Jbool JIsRaw (const J *const item)
    +
    + +
    +
    + +

    ◆ JIsString()

    + +
    +
    + + + + + + + + +
    Jbool JIsString (const J *const item)
    +
    + +
    +
    + +

    ◆ JIsTrue()

    + +
    +
    + + + + + + + + +
    Jbool JIsTrue (const J *const item)
    +
    + +
    +
    + +

    ◆ JMalloc()

    + +
    +
    + + + + + + + + +
    void* JMalloc (size_t size)
    +
    + +

    Dynamically allocate a block of memory of the given size.

    +

    This is simply a wrapper around the memory allocation function provided by the user via NoteSetFn.

    +
    Parameters
    + + +
    sizeThe number of bytes to allocate.
    +
    +
    +
    Returns
    A pointer to the first byte of the allocated memory or NULL on error.
    + +
    +
    + +

    ◆ JMinify()

    + +
    +
    + + + + + + + + +
    void JMinify (char * json)
    +
    + +
    +
    + +

    ◆ JParse()

    + +
    +
    + + + + + + + + +
    J* JParse (const char * value)
    +
    + +

    Parse the passed in C-string as JSON and return a J object representing it.

    +
    Parameters
    + + +
    valueThe JSON object as a C-string.
    +
    +
    +
    Returns
    A J object or NULL on error (e.g. the string was invalid JSON).
    + +
    +
    + +

    ◆ JParseWithOpts()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    J* JParseWithOpts (const char * value,
    const char ** return_parse_end,
    Jbool require_null_terminated 
    )
    +
    + +
    +
    + +

    ◆ JPrint()

    + +
    +
    + + + + + + + + +
    char* JPrint (const Jitem)
    +
    + +
    +
    + +

    ◆ JPrintBuffered()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    char* JPrintBuffered (const Jitem,
    int prebuffer,
    Jbool fmt 
    )
    +
    + +
    +
    + +

    ◆ JPrintPreallocated()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    Jbool JPrintPreallocated (Jitem,
    char * buf,
    const int len,
    const Jbool fmt 
    )
    +
    + +
    +
    + +

    ◆ JPrintPreallocatedOmitEmpty()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    Jbool JPrintPreallocatedOmitEmpty (Jitem,
    char * buf,
    const int len,
    const Jbool fmt 
    )
    +
    + +
    +
    + +

    ◆ JPrintUnformatted()

    + +
    +
    + + + + + + + + +
    char* JPrintUnformatted (const Jitem)
    +
    + +

    Get the unformatted string representation of a J object.

    +

    The string returned by this function is dynamically allocated and MUST be freed by the caller with JFree. Unformatted means that the minimum JSON string is produced, without any additional whitespace.

    +
    Parameters
    + + +
    itemThe JSON object to get the unformatted string representation of.
    +
    +
    +
    Returns
    The string or NULL on error.
    + +
    +
    + +

    ◆ JPrintUnformattedOmitEmpty()

    + +
    +
    + + + + + + + + +
    char* JPrintUnformattedOmitEmpty (const Jitem)
    +
    + +
    +
    + +

    ◆ JReplaceItemInArray()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    void JReplaceItemInArray (Jarray,
    int which,
    Jnewitem 
    )
    +
    + +
    +
    + +

    ◆ JReplaceItemInObject()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    void JReplaceItemInObject (Jobject,
    const char * string,
    Jnewitem 
    )
    +
    + +
    +
    + +

    ◆ JReplaceItemInObjectCaseSensitive()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    void JReplaceItemInObjectCaseSensitive (Jobject,
    const char * string,
    Jnewitem 
    )
    +
    + +
    +
    + +

    ◆ JReplaceItemViaPointer()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    Jbool JReplaceItemViaPointer (J *const parent,
    J *const item,
    Jreplacement 
    )
    +
    + +
    +
    + +

    ◆ JSetNumberHelper()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    JNUMBER JSetNumberHelper (Jobject,
    JNUMBER number 
    )
    +
    + +
    +
    + +

    ◆ JVersion()

    + +
    +
    + + + + + + + + +
    const char* JVersion (void )
    +
    + +
    +
    + +

    ◆ n_htoa16()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    void n_htoa16 (uint16_t n,
    unsigned char * p 
    )
    +
    + +
    +
    +
    + + + + diff --git a/doxygen/html/n__cjson_8h.html b/doxygen/html/n__cjson_8h.html new file mode 100644 index 00000000..f88b0d83 --- /dev/null +++ b/doxygen/html/n__cjson_8h.html @@ -0,0 +1,2766 @@ + + + + + + + +note-c: /home/runner/work/note-c/note-c/n_cjson.h File Reference + + + + + + + + + +
    +
    + + + + + + + +
    +
    note-c +  1.0 +
    +
    An easy to use Notecard Library for C/C++
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + +
    +
    + +
    +
    /home/runner/work/note-c/note-c/n_cjson.h File Reference
    +
    +
    +
    #include <stddef.h>
    +
    +

    Go to the source code of this file.

    + + + + + + + +

    +Data Structures

    struct  J
     The core JSON object type used by note-c. More...
     
    struct  JHooks
     
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

    +Macros

    #define N_CJSON_VERSION_MAJOR   1
     
    #define N_CJSON_VERSION_MINOR   7
     
    #define N_CJSON_VERSION_PATCH   7
     
    #define JInvalid   (0)
     
    #define JFalse   (1 << 0)
     
    #define JTrue   (1 << 1)
     
    #define JNULL   (1 << 2)
     
    #define JNumber   (1 << 3)
     
    #define JString   (1 << 4)
     
    #define JArray   (1 << 5)
     
    #define JObject   (1 << 6)
     
    #define JRaw   (1 << 7) /* raw json */
     
    #define JIsReference   256
     
    #define JStringIsConst   512
     
    #define N_CJSON_PUBLIC(type)   type
     
    #define N_CJSON_NESTING_LIMIT   100
     The maximum nesting level for JSON objects before a parsing error. More...
     
    #define JGetObjectItems   JGetArraySize
     
    #define JConvertToJSONString   JPrintUnformatted
     
    #define JConvertFromJSONString   JParse
     
    #define JSetIntValue(object, number)   ((object) ? (object)->valueint = (object)->valuenumber = (number) : (number))
     
    #define JSetNumberValue(object, number)   ((object != NULL) ? JSetNumberHelper(object, (JNUMBER)number) : (number))
     
    #define JArrayForEach(element, array)   for(element = (array != NULL) ? (array)->child : NULL; element != NULL; element = element->next)
     
    #define JObjectForEach(element, array)   JArrayForEach(element, array)
     
    + + + + + + + + +

    +Typedefs

    typedef struct J J
     The core JSON object type used by note-c. More...
     
    typedef struct JHooks JHooks
     
    typedef int Jbool
     
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

    +Functions

    const char * JVersion (void)
     
    void JInitHooks (JHooks *hooks)
     
    JJParse (const char *value)
     Parse the passed in C-string as JSON and return a J object representing it. More...
     
    JJParseWithOpts (const char *value, const char **return_parse_end, Jbool require_null_terminated)
     
    char * JPrint (const J *item)
     
    char * JPrintUnformatted (const J *item)
     Get the unformatted string representation of a J object. More...
     
    char * JPrintUnformattedOmitEmpty (const J *item)
     
    char * JPrintBuffered (const J *item, int prebuffer, Jbool fmt)
     
    Jbool JPrintPreallocated (J *item, char *buffer, const int length, const Jbool format)
     
    Jbool JPrintPreallocatedOmitEmpty (J *item, char *buffer, const int length, const Jbool format)
     
    void JDelete (J *c)
     Free a J object. More...
     
    int JGetArraySize (const J *array)
     
    JJGetArrayItem (const J *array, int index)
     
    JJGetObjectItem (const J *const object, const char *const string)
     
    JJGetObjectItemCaseSensitive (const J *const object, const char *const string)
     
    Jbool JHasObjectItem (const J *object, const char *string)
     
    const char * JGetErrorPtr (void)
     
    char * JGetStringValue (J *item)
     
    Jbool JIsInvalid (const J *const item)
     
    Jbool JIsFalse (const J *const item)
     
    Jbool JIsTrue (const J *const item)
     
    Jbool JIsBool (const J *const item)
     
    Jbool JIsNull (const J *const item)
     
    Jbool JIsNumber (const J *const item)
     
    Jbool JIsString (const J *const item)
     
    Jbool JIsArray (const J *const item)
     
    Jbool JIsObject (const J *const item)
     
    Jbool JIsRaw (const J *const item)
     
    JJCreateTrue (void)
     
    JJCreateFalse (void)
     
    JJCreateBool (Jbool boolean)
     
    JJCreateNumber (JNUMBER num)
     
    JJCreateInteger (JINTEGER integer)
     
    JJCreateString (const char *string)
     
    JJCreateRaw (const char *raw)
     
    JJCreateArray (void)
     
    JJCreateObject (void)
     Create a new J object. More...
     
    JJCreateStringValue (const char *string)
     
    JJCreateStringReference (const char *string)
     
    JJCreateObjectReference (const J *child)
     
    JJCreateArrayReference (const J *child)
     
    JJCreateIntArray (const long int *numbers, int count)
     
    JJCreateNumberArray (const JNUMBER *numbers, int count)
     
    JJCreateStringArray (const char **strings, int count)
     
    void JAddItemToArray (J *array, J *item)
     
    void JAddItemToObject (J *object, const char *string, J *item)
     
    void JAddItemToObjectCS (J *object, const char *string, J *item)
     
    void JAddItemReferenceToArray (J *array, J *item)
     
    void JAddItemReferenceToObject (J *object, const char *string, J *item)
     
    JJDetachItemViaPointer (J *parent, J *const item)
     
    JJDetachItemFromArray (J *array, int which)
     
    void JDeleteItemFromArray (J *array, int which)
     
    JJDetachItemFromObject (J *object, const char *string)
     
    JJDetachItemFromObjectCaseSensitive (J *object, const char *string)
     
    void JDeleteItemFromObject (J *object, const char *string)
     
    void JDeleteItemFromObjectCaseSensitive (J *object, const char *string)
     
    void JInsertItemInArray (J *array, int which, J *newitem)
     
    Jbool JReplaceItemViaPointer (J *const parent, J *const item, J *replacement)
     
    void JReplaceItemInArray (J *array, int which, J *newitem)
     
    void JReplaceItemInObject (J *object, const char *string, J *newitem)
     
    void JReplaceItemInObjectCaseSensitive (J *object, const char *string, J *newitem)
     
    JJDuplicate (const J *item, Jbool recurse)
     
    Jbool JCompare (const J *const a, const J *const b, const Jbool case_sensitive)
     
    void JMinify (char *json)
     
    JJAddTrueToObject (J *const object, const char *const name)
     
    JJAddFalseToObject (J *const object, const char *const name)
     
    JJAddBoolToObject (J *const object, const char *const name, const Jbool boolean)
     Add a boolean field to a J object. More...
     
    JJAddNumberToObject (J *const object, const char *const name, const JNUMBER number)
     Add a number field to a J object. More...
     
    JJAddIntToObject (J *const object, const char *const name, const JINTEGER integer)
     
    JJAddStringToObject (J *const object, const char *const name, const char *const string)
     Add a string field to a J object. More...
     
    JJAddRawToObject (J *const object, const char *const name, const char *const raw)
     
    JJAddObjectToObject (J *const object, const char *const name)
     Add an object field to another J object. More...
     
    JJAddArrayToObject (J *const object, const char *const name)
     Add an array field to a J object. More...
     
    JNUMBER JSetNumberHelper (J *object, JNUMBER number)
     
    void * JMalloc (size_t size)
     Dynamically allocate a block of memory of the given size. More...
     
    void JFree (void *object)
     Free a block of dynamically allocated memory. More...
     
    +

    Detailed Description

    +

    Written by Ray Ozzie and Blues Inc. team.

    +

    Portions Copyright (c) 2019 Blues Inc. MIT License. Use of this source code is governed by licenses granted by the copyright holder including that found in the LICENSE file.

    +

    MODIFIED for use in notecard primarily by altering default memory allocator and by renaming the functions so that they won't conflict with a developer's own decision to incorporate the actual production cJSON into their own app. In no way shall this interfere with a production cJSON.

    +

    Renaming was done as follows: CJSON_ -> N_CJSON_ cJSON_ -> J cJSON -> J

    +

    Portions Copyright (c) 2009-2017 Dave Gamble and cJSON contributors

    +

    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 i 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.

    +

    Macro Definition Documentation

    + +

    ◆ JArray

    + +
    +
    + + + + +
    #define JArray   (1 << 5)
    +
    + +
    +
    + +

    ◆ JArrayForEach

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    #define JArrayForEach( element,
     array 
    )   for(element = (array != NULL) ? (array)->child : NULL; element != NULL; element = element->next)
    +
    + +
    +
    + +

    ◆ JConvertFromJSONString

    + +
    +
    + + + + +
    #define JConvertFromJSONString   JParse
    +
    + +
    +
    + +

    ◆ JConvertToJSONString

    + +
    +
    + + + + +
    #define JConvertToJSONString   JPrintUnformatted
    +
    + +
    +
    + +

    ◆ JFalse

    + +
    +
    + + + + +
    #define JFalse   (1 << 0)
    +
    + +
    +
    + +

    ◆ JGetObjectItems

    + +
    +
    + + + + +
    #define JGetObjectItems   JGetArraySize
    +
    + +
    +
    + +

    ◆ JInvalid

    + +
    +
    + + + + +
    #define JInvalid   (0)
    +
    + +
    +
    + +

    ◆ JIsReference

    + +
    +
    + + + + +
    #define JIsReference   256
    +
    + +
    +
    + +

    ◆ JNULL

    + +
    +
    + + + + +
    #define JNULL   (1 << 2)
    +
    + +
    +
    + +

    ◆ JNumber

    + +
    +
    + + + + +
    #define JNumber   (1 << 3)
    +
    + +
    +
    + +

    ◆ JObject

    + +
    +
    + + + + +
    #define JObject   (1 << 6)
    +
    + +
    +
    + +

    ◆ JObjectForEach

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    #define JObjectForEach( element,
     array 
    )   JArrayForEach(element, array)
    +
    + +
    +
    + +

    ◆ JRaw

    + +
    +
    + + + + +
    #define JRaw   (1 << 7) /* raw json */
    +
    + +
    +
    + +

    ◆ JSetIntValue

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    #define JSetIntValue( object,
     number 
    )   ((object) ? (object)->valueint = (object)->valuenumber = (number) : (number))
    +
    + +
    +
    + +

    ◆ JSetNumberValue

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    #define JSetNumberValue( object,
     number 
    )   ((object != NULL) ? JSetNumberHelper(object, (JNUMBER)number) : (number))
    +
    + +
    +
    + +

    ◆ JString

    + +
    +
    + + + + +
    #define JString   (1 << 4)
    +
    + +
    +
    + +

    ◆ JStringIsConst

    + +
    +
    + + + + +
    #define JStringIsConst   512
    +
    + +
    +
    + +

    ◆ JTrue

    + +
    +
    + + + + +
    #define JTrue   (1 << 1)
    +
    + +
    +
    + +

    ◆ N_CJSON_NESTING_LIMIT

    + +
    +
    + + + + +
    #define N_CJSON_NESTING_LIMIT   100
    +
    + +

    The maximum nesting level for JSON objects before a parsing error.

    +

    Default value: 100

    +

    For example, if you have a JSON object that contains multiple, nested objects like this

    {
    +    "x":
    +    {
    +        "x:"
    +        {
    +            .
    +            .
    +            .
    +        }
    +    }
    +}
    +

    And the nesting level exceeds N_CJSON_NESTING_LIMIT, then calling JParse on a J * representing this object will return an error (NULL).

    +

    This exists to prevent the cJSON parser from causing a stack overflow. The user may override this macro at build time (e.g. -DN_CJSON_NESTING_LIMIT=200) to increase or reduce the limit.

    + +
    +
    + +

    ◆ N_CJSON_PUBLIC

    + +
    +
    + + + + + + + + +
    #define N_CJSON_PUBLIC( type)   type
    +
    + +
    +
    + +

    ◆ N_CJSON_VERSION_MAJOR

    + +
    +
    + + + + +
    #define N_CJSON_VERSION_MAJOR   1
    +
    + +
    +
    + +

    ◆ N_CJSON_VERSION_MINOR

    + +
    +
    + + + + +
    #define N_CJSON_VERSION_MINOR   7
    +
    + +
    +
    + +

    ◆ N_CJSON_VERSION_PATCH

    + +
    +
    + + + + +
    #define N_CJSON_VERSION_PATCH   7
    +
    + +
    +
    +

    Typedef Documentation

    + +

    ◆ J

    + +
    +
    + + + + +
    typedef struct J J
    +
    + +

    The core JSON object type used by note-c.

    +

    When using note-c, treat this struct as opaque. You should never have to work directly with its members.

    + +
    +
    + +

    ◆ Jbool

    + +
    +
    + + + + +
    typedef int Jbool
    +
    + +
    +
    + +

    ◆ JHooks

    + +
    +
    + + + + +
    typedef struct JHooks JHooks
    +
    + +
    +
    +

    Function Documentation

    + +

    ◆ JAddArrayToObject()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    J* JAddArrayToObject (J *const object,
    const char *const name 
    )
    +
    + +

    Add an array field to a J object.

    +
    Parameters
    + + + +
    objectThe object to add the field to.
    nameThe name of the field.
    +
    +
    +
    Returns
    A pointer to the newly-added array field or NULL on error.
    + +
    +
    + +

    ◆ JAddBoolToObject()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    J* JAddBoolToObject (J *const object,
    const char *const name,
    const Jbool boolean 
    )
    +
    + +

    Add a boolean field to a J object.

    +
    Parameters
    + + + + +
    objectThe object to add the field to.
    nameThe name of the field.
    booleanThe value of the field.
    +
    +
    +
    Returns
    A pointer to the newly-added boolean field or NULL on error.
    + +
    +
    + +

    ◆ JAddFalseToObject()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    J* JAddFalseToObject (J *const object,
    const char *const name 
    )
    +
    + +
    +
    + +

    ◆ JAddIntToObject()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    J* JAddIntToObject (J *const object,
    const char *const name,
    const JINTEGER integer 
    )
    +
    + +
    +
    + +

    ◆ JAddItemReferenceToArray()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    void JAddItemReferenceToArray (Jarray,
    Jitem 
    )
    +
    + +
    +
    + +

    ◆ JAddItemReferenceToObject()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    void JAddItemReferenceToObject (Jobject,
    const char * string,
    Jitem 
    )
    +
    + +
    +
    + +

    ◆ JAddItemToArray()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    void JAddItemToArray (Jarray,
    Jitem 
    )
    +
    + +
    +
    + +

    ◆ JAddItemToObject()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    void JAddItemToObject (Jobject,
    const char * string,
    Jitem 
    )
    +
    + +
    +
    + +

    ◆ JAddItemToObjectCS()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    void JAddItemToObjectCS (Jobject,
    const char * string,
    Jitem 
    )
    +
    + +
    +
    + +

    ◆ JAddNumberToObject()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    J* JAddNumberToObject (J *const object,
    const char *const name,
    const JNUMBER number 
    )
    +
    + +

    Add a number field to a J object.

    +
    Parameters
    + + + + +
    objectThe object to add the field to.
    nameThe name of the field.
    numberThe value of the field.
    +
    +
    +
    Returns
    A pointer to the newly-added number field or NULL on error.
    + +
    +
    + +

    ◆ JAddObjectToObject()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    J* JAddObjectToObject (J *const object,
    const char *const name 
    )
    +
    + +

    Add an object field to another J object.

    +
    Parameters
    + + + +
    objectThe object to add the field to.
    nameThe name of the field.
    +
    +
    +
    Returns
    A pointer to the newly-added object field or NULL on error.
    + +
    +
    + +

    ◆ JAddRawToObject()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    J* JAddRawToObject (J *const object,
    const char *const name,
    const char *const raw 
    )
    +
    + +
    +
    + +

    ◆ JAddStringToObject()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    J* JAddStringToObject (J *const object,
    const char *const name,
    const char *const string 
    )
    +
    + +

    Add a string field to a J object.

    +
    Parameters
    + + + + +
    objectThe object to add the field to.
    nameThe name of the field.
    stringThe value of the field.
    +
    +
    +
    Returns
    A pointer to the newly-added string field or NULL on error.
    + +
    +
    + +

    ◆ JAddTrueToObject()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    J* JAddTrueToObject (J *const object,
    const char *const name 
    )
    +
    + +
    +
    + +

    ◆ JCompare()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    Jbool JCompare (const J *const a,
    const J *const b,
    const Jbool case_sensitive 
    )
    +
    + +
    +
    + +

    ◆ JCreateArray()

    + +
    +
    + + + + + + + + +
    J* JCreateArray (void )
    +
    + +
    +
    + +

    ◆ JCreateArrayReference()

    + +
    +
    + + + + + + + + +
    J* JCreateArrayReference (const Jchild)
    +
    + +
    +
    + +

    ◆ JCreateBool()

    + +
    +
    + + + + + + + + +
    J* JCreateBool (Jbool boolean)
    +
    + +
    +
    + +

    ◆ JCreateFalse()

    + +
    +
    + + + + + + + + +
    J* JCreateFalse (void )
    +
    + +
    +
    + +

    ◆ JCreateIntArray()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    J* JCreateIntArray (const long int * numbers,
    int count 
    )
    +
    + +
    +
    + +

    ◆ JCreateInteger()

    + +
    +
    + + + + + + + + +
    J* JCreateInteger (JINTEGER integer)
    +
    + +
    +
    + +

    ◆ JCreateNumber()

    + +
    +
    + + + + + + + + +
    J* JCreateNumber (JNUMBER num)
    +
    + +
    +
    + +

    ◆ JCreateNumberArray()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    J* JCreateNumberArray (const JNUMBERnumbers,
    int count 
    )
    +
    + +
    +
    + +

    ◆ JCreateObject()

    + +
    +
    + + + + + + + + +
    J* JCreateObject (void )
    +
    + +

    Create a new J object.

    +

    To free the object, use JDelete.

    +
    Returns
    A pointer to the newly-created object.
    + +
    +
    + +

    ◆ JCreateObjectReference()

    + +
    +
    + + + + + + + + +
    J* JCreateObjectReference (const Jchild)
    +
    + +
    +
    + +

    ◆ JCreateRaw()

    + +
    +
    + + + + + + + + +
    J* JCreateRaw (const char * raw)
    +
    + +
    +
    + +

    ◆ JCreateString()

    + +
    +
    + + + + + + + + +
    J* JCreateString (const char * string)
    +
    + +
    +
    + +

    ◆ JCreateStringArray()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    J* JCreateStringArray (const char ** strings,
    int count 
    )
    +
    + +
    +
    + +

    ◆ JCreateStringReference()

    + +
    +
    + + + + + + + + +
    J* JCreateStringReference (const char * string)
    +
    + +
    +
    + +

    ◆ JCreateStringValue()

    + +
    +
    + + + + + + + + +
    J* JCreateStringValue (const char * string)
    +
    + +
    +
    + +

    ◆ JCreateTrue()

    + +
    +
    + + + + + + + + +
    J* JCreateTrue (void )
    +
    + +
    +
    + +

    ◆ JDelete()

    + +
    +
    + + + + + + + + +
    void JDelete (Jitem)
    +
    + +

    Free a J object.

    +
    Parameters
    + + +
    itemA pointer to the object.
    +
    +
    + +
    +
    + +

    ◆ JDeleteItemFromArray()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    void JDeleteItemFromArray (Jarray,
    int which 
    )
    +
    + +
    +
    + +

    ◆ JDeleteItemFromObject()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    void JDeleteItemFromObject (Jobject,
    const char * string 
    )
    +
    + +
    +
    + +

    ◆ JDeleteItemFromObjectCaseSensitive()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    void JDeleteItemFromObjectCaseSensitive (Jobject,
    const char * string 
    )
    +
    + +
    +
    + +

    ◆ JDetachItemFromArray()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    J* JDetachItemFromArray (Jarray,
    int which 
    )
    +
    + +
    +
    + +

    ◆ JDetachItemFromObject()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    J* JDetachItemFromObject (Jobject,
    const char * string 
    )
    +
    + +
    +
    + +

    ◆ JDetachItemFromObjectCaseSensitive()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    J* JDetachItemFromObjectCaseSensitive (Jobject,
    const char * string 
    )
    +
    + +
    +
    + +

    ◆ JDetachItemViaPointer()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    J* JDetachItemViaPointer (Jparent,
    J *const item 
    )
    +
    + +
    +
    + +

    ◆ JDuplicate()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    J* JDuplicate (const Jitem,
    Jbool recurse 
    )
    +
    + +
    +
    + +

    ◆ JFree()

    + +
    +
    + + + + + + + + +
    void JFree (void * p)
    +
    + +

    Free a block of dynamically allocated memory.

    +

    This is simply a wrapper around the memory free function provided by the user via NoteSetFn.

    +
    Parameters
    + + +
    pA pointer to the block of memory to free.
    +
    +
    + +
    +
    + +

    ◆ JGetArrayItem()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    J* JGetArrayItem (const Jarray,
    int index 
    )
    +
    + +
    +
    + +

    ◆ JGetArraySize()

    + +
    +
    + + + + + + + + +
    int JGetArraySize (const Jarray)
    +
    + +
    +
    + +

    ◆ JGetErrorPtr()

    + +
    +
    + + + + + + + + +
    const char* JGetErrorPtr (void )
    +
    + +
    +
    + +

    ◆ JGetObjectItem()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    J* JGetObjectItem (const J *const object,
    const char *const string 
    )
    +
    + +
    +
    + +

    ◆ JGetObjectItemCaseSensitive()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    J* JGetObjectItemCaseSensitive (const J *const object,
    const char *const string 
    )
    +
    + +
    +
    + +

    ◆ JGetStringValue()

    + +
    +
    + + + + + + + + +
    char* JGetStringValue (Jitem)
    +
    + +
    +
    + +

    ◆ JHasObjectItem()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    Jbool JHasObjectItem (const Jobject,
    const char * string 
    )
    +
    + +
    +
    + +

    ◆ JInitHooks()

    + +
    +
    + + + + + + + + +
    void JInitHooks (JHookshooks)
    +
    + +
    +
    + +

    ◆ JInsertItemInArray()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    void JInsertItemInArray (Jarray,
    int which,
    Jnewitem 
    )
    +
    + +
    +
    + +

    ◆ JIsArray()

    + +
    +
    + + + + + + + + +
    Jbool JIsArray (const J *const item)
    +
    + +
    +
    + +

    ◆ JIsBool()

    + +
    +
    + + + + + + + + +
    Jbool JIsBool (const J *const item)
    +
    + +
    +
    + +

    ◆ JIsFalse()

    + +
    +
    + + + + + + + + +
    Jbool JIsFalse (const J *const item)
    +
    + +
    +
    + +

    ◆ JIsInvalid()

    + +
    +
    + + + + + + + + +
    Jbool JIsInvalid (const J *const item)
    +
    + +
    +
    + +

    ◆ JIsNull()

    + +
    +
    + + + + + + + + +
    Jbool JIsNull (const J *const item)
    +
    + +
    +
    + +

    ◆ JIsNumber()

    + +
    +
    + + + + + + + + +
    Jbool JIsNumber (const J *const item)
    +
    + +
    +
    + +

    ◆ JIsObject()

    + +
    +
    + + + + + + + + +
    Jbool JIsObject (const J *const item)
    +
    + +
    +
    + +

    ◆ JIsRaw()

    + +
    +
    + + + + + + + + +
    Jbool JIsRaw (const J *const item)
    +
    + +
    +
    + +

    ◆ JIsString()

    + +
    +
    + + + + + + + + +
    Jbool JIsString (const J *const item)
    +
    + +
    +
    + +

    ◆ JIsTrue()

    + +
    +
    + + + + + + + + +
    Jbool JIsTrue (const J *const item)
    +
    + +
    +
    + +

    ◆ JMalloc()

    + +
    +
    + + + + + + + + +
    void* JMalloc (size_t size)
    +
    + +

    Dynamically allocate a block of memory of the given size.

    +

    This is simply a wrapper around the memory allocation function provided by the user via NoteSetFn.

    +
    Parameters
    + + +
    sizeThe number of bytes to allocate.
    +
    +
    +
    Returns
    A pointer to the first byte of the allocated memory or NULL on error.
    + +
    +
    + +

    ◆ JMinify()

    + +
    +
    + + + + + + + + +
    void JMinify (char * json)
    +
    + +
    +
    + +

    ◆ JParse()

    + +
    +
    + + + + + + + + +
    J* JParse (const char * value)
    +
    + +

    Parse the passed in C-string as JSON and return a J object representing it.

    +
    Parameters
    + + +
    valueThe JSON object as a C-string.
    +
    +
    +
    Returns
    A J object or NULL on error (e.g. the string was invalid JSON).
    + +
    +
    + +

    ◆ JParseWithOpts()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    J* JParseWithOpts (const char * value,
    const char ** return_parse_end,
    Jbool require_null_terminated 
    )
    +
    + +
    +
    + +

    ◆ JPrint()

    + +
    +
    + + + + + + + + +
    char* JPrint (const Jitem)
    +
    + +
    +
    + +

    ◆ JPrintBuffered()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    char* JPrintBuffered (const Jitem,
    int prebuffer,
    Jbool fmt 
    )
    +
    + +
    +
    + +

    ◆ JPrintPreallocated()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    Jbool JPrintPreallocated (Jitem,
    char * buffer,
    const int length,
    const Jbool format 
    )
    +
    + +
    +
    + +

    ◆ JPrintPreallocatedOmitEmpty()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    Jbool JPrintPreallocatedOmitEmpty (Jitem,
    char * buffer,
    const int length,
    const Jbool format 
    )
    +
    + +
    +
    + +

    ◆ JPrintUnformatted()

    + +
    +
    + + + + + + + + +
    char* JPrintUnformatted (const Jitem)
    +
    + +

    Get the unformatted string representation of a J object.

    +

    The string returned by this function is dynamically allocated and MUST be freed by the caller with JFree. Unformatted means that the minimum JSON string is produced, without any additional whitespace.

    +
    Parameters
    + + +
    itemThe JSON object to get the unformatted string representation of.
    +
    +
    +
    Returns
    The string or NULL on error.
    + +
    +
    + +

    ◆ JPrintUnformattedOmitEmpty()

    + +
    +
    + + + + + + + + +
    char* JPrintUnformattedOmitEmpty (const Jitem)
    +
    + +
    +
    + +

    ◆ JReplaceItemInArray()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    void JReplaceItemInArray (Jarray,
    int which,
    Jnewitem 
    )
    +
    + +
    +
    + +

    ◆ JReplaceItemInObject()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    void JReplaceItemInObject (Jobject,
    const char * string,
    Jnewitem 
    )
    +
    + +
    +
    + +

    ◆ JReplaceItemInObjectCaseSensitive()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    void JReplaceItemInObjectCaseSensitive (Jobject,
    const char * string,
    Jnewitem 
    )
    +
    + +
    +
    + +

    ◆ JReplaceItemViaPointer()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    Jbool JReplaceItemViaPointer (J *const parent,
    J *const item,
    Jreplacement 
    )
    +
    + +
    +
    + +

    ◆ JSetNumberHelper()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    JNUMBER JSetNumberHelper (Jobject,
    JNUMBER number 
    )
    +
    + +
    +
    + +

    ◆ JVersion()

    + +
    +
    + + + + + + + + +
    const char* JVersion (void )
    +
    + +
    +
    +
    + + + + diff --git a/doxygen/html/n__cjson_8h_source.html b/doxygen/html/n__cjson_8h_source.html new file mode 100644 index 00000000..0ee453e6 --- /dev/null +++ b/doxygen/html/n__cjson_8h_source.html @@ -0,0 +1,428 @@ + + + + + + + +note-c: /home/runner/work/note-c/note-c/n_cjson.h Source File + + + + + + + + + +
    +
    + + + + + + + +
    +
    note-c +  1.0 +
    +
    An easy to use Notecard Library for C/C++
    +
    +
    + + + + + + + +
    + +
    +
    + + +
    + +
    + +
    +
    +
    /home/runner/work/note-c/note-c/n_cjson.h
    +
    +
    +Go to the documentation of this file.
    1 
    +
    43 #ifndef J_h
    +
    44 #define J_h
    +
    45 
    +
    46 #ifdef __cplusplus
    +
    47 extern "C"
    +
    48 {
    +
    49 #endif
    +
    50 
    +
    51 /* project version */
    +
    52 #define N_CJSON_VERSION_MAJOR 1
    +
    53 #define N_CJSON_VERSION_MINOR 7
    +
    54 #define N_CJSON_VERSION_PATCH 7
    +
    55 
    +
    56 #include <stddef.h>
    +
    57 
    +
    58 /* J Types: */
    +
    59 #define JInvalid (0)
    +
    60 #define JFalse (1 << 0)
    +
    61 #define JTrue (1 << 1)
    +
    62 #define JNULL (1 << 2)
    +
    63 #define JNumber (1 << 3)
    +
    64 #define JString (1 << 4)
    +
    65 #define JArray (1 << 5)
    +
    66 #define JObject (1 << 6)
    +
    67 #define JRaw (1 << 7) /* raw json */
    +
    68 
    +
    69 #define JIsReference 256
    +
    70 #define JStringIsConst 512
    +
    71 
    +
    78 typedef struct J {
    +
    79  /* next/prev allow you to walk array/object chains. Alternatively, use GetArraySize/GetArrayItem/GetObjectItem */
    +
    80  struct J *next;
    +
    81  struct J *prev;
    +
    82  /* An array or object item will have a child pointer pointing to a chain of the items in the array/object. */
    +
    83  struct J *child;
    +
    84 
    +
    85  /* The type of the item, as above. */
    +
    86  int type;
    +
    87 
    +
    88  /* The item's string, if type==JString and type == JRaw */
    +
    89  char *valuestring;
    +
    90  /* writing to valueint is DEPRECATED, use JSetNumberValue instead */
    + +
    92  /* The item's number, if type==JNumber */
    + +
    94  /* The item's name string, if this item is the child of, or is in the list of subitems of an object. */
    +
    95  char *string;
    +
    96 } J;
    +
    97 
    +
    98 typedef struct JHooks {
    +
    99  void *(*malloc_fn)(size_t sz);
    +
    100  void (*free_fn)(void *ptr);
    + +
    102 
    +
    103 typedef int Jbool;
    +
    104 
    +
    105 #if !defined(__WINDOWS__) && (defined(WIN32) || defined(WIN64) || defined(_MSC_VER) || defined(_WIN32))
    +
    106 #define __WINDOWS__
    +
    107 #endif
    +
    108 #ifdef __WINDOWS__
    +
    109 
    +
    110 /* When compiling for windows, we specify a specific calling convention to avoid issues where we are being called from a project with a different default calling convention. For windows you have 2 define options:
    +
    111 
    +
    112 N_CJSON_HIDE_SYMBOLS - Define this in the case where you don't want to ever dllexport symbols
    +
    113 N_CJSON_EXPORT_SYMBOLS - Define this on library build when you want to dllexport symbols (default)
    +
    114 N_CJSON_IMPORT_SYMBOLS - Define this if you want to dllimport symbol
    +
    115 
    +
    116 For *nix builds that support visibility attribute, you can define similar behavior by
    +
    117 
    +
    118 setting default visibility to hidden by adding
    +
    119 -fvisibility=hidden (for gcc)
    +
    120 or
    +
    121 -xldscope=hidden (for sun cc)
    +
    122 to CFLAGS
    +
    123 
    +
    124 then using the N_CJSON_API_VISIBILITY flag to "export" the same symbols the way N_CJSON_EXPORT_SYMBOLS does
    +
    125 
    +
    126 */
    +
    127 
    +
    128 /* export symbols by default, this is necessary for copy pasting the C and header file */
    +
    129 #if !defined(N_CJSON_HIDE_SYMBOLS) && !defined(N_CJSON_IMPORT_SYMBOLS) && !defined(N_CJSON_EXPORT_SYMBOLS)
    +
    130 #define N_CJSON_EXPORT_SYMBOLS
    +
    131 #endif
    +
    132 
    +
    133 #if defined(N_CJSON_HIDE_SYMBOLS)
    +
    134 #define N_CJSON_PUBLIC(type) type __stdcall
    +
    135 #elif defined(N_CJSON_EXPORT_SYMBOLS)
    +
    136 #define N_CJSON_PUBLIC(type) __declspec(dllexport) type __stdcall
    +
    137 #elif defined(N_CJSON_IMPORT_SYMBOLS)
    +
    138 #define N_CJSON_PUBLIC(type) __declspec(dllimport) type __stdcall
    +
    139 #endif
    +
    140 #else /* !WIN32 */
    +
    141 #if (defined(__GNUC__) || defined(__SUNPRO_CC) || defined (__SUNPRO_C)) && defined(N_CJSON_API_VISIBILITY)
    +
    142 #define N_CJSON_PUBLIC(type) __attribute__((visibility("default"))) type
    +
    143 #else
    +
    144 #define N_CJSON_PUBLIC(type) type
    +
    145 #endif
    +
    146 #endif
    +
    147 
    +
    175 #ifndef N_CJSON_NESTING_LIMIT
    +
    176 #define N_CJSON_NESTING_LIMIT 100
    +
    177 #endif
    +
    178 
    +
    179 /* returns the version of J as a string */
    +
    180 N_CJSON_PUBLIC(const char*) JVersion(void);
    +
    181 
    +
    182 /* Supply malloc, realloc and free functions to J */
    + +
    184 
    +
    185 /* Memory Management: the caller is always responsible to free the results from all variants of JParse (with JDelete) and JPrint (with stdlib free, JHooks.free_fn, or JFree as appropriate). The exception is JPrintPreallocated, where the caller has full responsibility of the buffer. */
    +
    186 /* Supply a block of JSON, and this returns a J object you can interrogate. */
    +
    187 N_CJSON_PUBLIC(J *) JParse(const char *value);
    +
    188 /* ParseWithOpts allows you to require (and check) that the JSON is null terminated, and to retrieve the pointer to the final byte parsed. */
    +
    189 /* If you supply a ptr in return_parse_end and parsing fails, then return_parse_end will contain a pointer to the error so will match JGetErrorPtr(). */
    +
    190 N_CJSON_PUBLIC(J *) JParseWithOpts(const char *value, const char **return_parse_end, Jbool require_null_terminated);
    +
    191 
    +
    192 /* Render a J entity to text for transfer/storage. */
    +
    193 N_CJSON_PUBLIC(char *) JPrint(const J *item);
    +
    194 /* Render a J entity to text for transfer/storage without any formatting. */
    +
    195 N_CJSON_PUBLIC(char *) JPrintUnformatted(const J *item);
    +
    196 /* Render a J entity to text for transfer/storage without any formatting and without fields that are false, 0, or "". */
    +
    197 N_CJSON_PUBLIC(char *) JPrintUnformattedOmitEmpty(const J *item);
    +
    198 /* Render a J entity to text using a buffered strategy. prebuffer is a guess at the final size. guessing well reduces reallocation. fmt=0 gives unformatted, =1 gives formatted */
    +
    199 N_CJSON_PUBLIC(char *) JPrintBuffered(const J *item, int prebuffer, Jbool fmt);
    +
    200 /* Render a J entity to text using a buffer already allocated in memory with given length. Returns 1 on success and 0 on failure. */
    +
    201 /* NOTE: J is not always 100% accurate in estimating how much memory it will use, so to be safe allocate 5 bytes more than you actually need */
    +
    202 N_CJSON_PUBLIC(Jbool) JPrintPreallocated(J *item, char *buffer, const int length, const Jbool format);
    +
    203 N_CJSON_PUBLIC(Jbool) JPrintPreallocatedOmitEmpty(J *item, char *buffer, const int length, const Jbool format);
    +
    204 /* Delete a J entity and all subentities. */
    +
    205 N_CJSON_PUBLIC(void) JDelete(J *c);
    +
    206 
    +
    207 /* Returns the number of items in an array (or object). */
    +
    208 N_CJSON_PUBLIC(int) JGetArraySize(const J *array);
    +
    209 #define JGetObjectItems JGetArraySize
    +
    210 /* Retrieve item number "index" from array "array". Returns NULL if unsuccessful. */
    +
    211 N_CJSON_PUBLIC(J *) JGetArrayItem(const J *array, int index);
    +
    212 /* Get item "string" from object. Case insensitive. */
    +
    213 N_CJSON_PUBLIC(J *) JGetObjectItem(const J * const object, const char * const string);
    +
    214 N_CJSON_PUBLIC(J *) JGetObjectItemCaseSensitive(const J * const object, const char * const string);
    +
    215 N_CJSON_PUBLIC(Jbool) JHasObjectItem(const J *object, const char *string);
    +
    216 /* For analysing failed parses. This returns a pointer to the parse error. You'll probably need to look a few chars back to make sense of it. Defined when JParse() returns 0. 0 when JParse() succeeds. */
    +
    217 N_CJSON_PUBLIC(const char *) JGetErrorPtr(void);
    +
    218 
    +
    219 /* Check if the item is a string and return its valuestring */
    +
    220 N_CJSON_PUBLIC(char *) JGetStringValue(J *item);
    +
    221 
    +
    222 /* These functions check the type of an item */
    +
    223 N_CJSON_PUBLIC(Jbool) JIsInvalid(const J * const item);
    +
    224 N_CJSON_PUBLIC(Jbool) JIsFalse(const J * const item);
    +
    225 N_CJSON_PUBLIC(Jbool) JIsTrue(const J * const item);
    +
    226 N_CJSON_PUBLIC(Jbool) JIsBool(const J * const item);
    +
    227 N_CJSON_PUBLIC(Jbool) JIsNull(const J * const item);
    +
    228 N_CJSON_PUBLIC(Jbool) JIsNumber(const J * const item);
    +
    229 N_CJSON_PUBLIC(Jbool) JIsString(const J * const item);
    +
    230 N_CJSON_PUBLIC(Jbool) JIsArray(const J * const item);
    +
    231 N_CJSON_PUBLIC(Jbool) JIsObject(const J * const item);
    +
    232 N_CJSON_PUBLIC(Jbool) JIsRaw(const J * const item);
    +
    233 
    +
    234 /* These calls create a J item of the appropriate type. */
    +
    235 N_CJSON_PUBLIC(J *) JCreateTrue(void);
    +
    236 N_CJSON_PUBLIC(J *) JCreateFalse(void);
    +
    237 N_CJSON_PUBLIC(J *) JCreateBool(Jbool boolean);
    + + +
    240 N_CJSON_PUBLIC(J *) JCreateString(const char *string);
    +
    241 /* raw json */
    +
    242 N_CJSON_PUBLIC(J *) JCreateRaw(const char *raw);
    +
    243 N_CJSON_PUBLIC(J *) JCreateArray(void);
    + +
    245 
    +
    246 /* Create a string where valuestring references a string so
    +
    247  * it will not be freed by JDelete */
    +
    248 N_CJSON_PUBLIC(J *) JCreateStringValue(const char *string);
    +
    249 N_CJSON_PUBLIC(J *) JCreateStringReference(const char *string);
    +
    250 /* Create an object/arrray that only references it's elements so
    +
    251  * they will not be freed by JDelete */
    +
    252 N_CJSON_PUBLIC(J *) JCreateObjectReference(const J *child);
    +
    253 N_CJSON_PUBLIC(J *) JCreateArrayReference(const J *child);
    +
    254 
    +
    255 /* These utilities create an Array of count items. */
    +
    256 N_CJSON_PUBLIC(J *) JCreateIntArray(const long int *numbers, int count);
    +
    257 N_CJSON_PUBLIC(J *) JCreateNumberArray(const JNUMBER *numbers, int count);
    +
    258 N_CJSON_PUBLIC(J *) JCreateStringArray(const char **strings, int count);
    +
    259 
    +
    260 /* Append item to the specified array/object. */
    +
    261 N_CJSON_PUBLIC(void) JAddItemToArray(J *array, J *item);
    +
    262 N_CJSON_PUBLIC(void) JAddItemToObject(J *object, const char *string, J *item);
    +
    263 /* Use this when string is definitely const (i.e. a literal, or as good as), and will definitely survive the J object.
    +
    264  * WARNING: When this function was used, make sure to always check that (item->type & JStringIsConst) is zero before
    +
    265  * writing to `item->string` */
    +
    266 N_CJSON_PUBLIC(void) JAddItemToObjectCS(J *object, const char *string, J *item);
    +
    267 /* Append reference to item to the specified array/object. Use this when you want to add an existing J to a new J, but don't want to corrupt your existing J. */
    +
    268 N_CJSON_PUBLIC(void) JAddItemReferenceToArray(J *array, J *item);
    +
    269 N_CJSON_PUBLIC(void) JAddItemReferenceToObject(J *object, const char *string, J *item);
    +
    270 
    +
    271 /* Remove/Detatch items from Arrays/Objects. */
    +
    272 N_CJSON_PUBLIC(J *) JDetachItemViaPointer(J *parent, J * const item);
    +
    273 N_CJSON_PUBLIC(J *) JDetachItemFromArray(J *array, int which);
    +
    274 N_CJSON_PUBLIC(void) JDeleteItemFromArray(J *array, int which);
    +
    275 N_CJSON_PUBLIC(J *) JDetachItemFromObject(J *object, const char *string);
    +
    276 N_CJSON_PUBLIC(J *) JDetachItemFromObjectCaseSensitive(J *object, const char *string);
    +
    277 N_CJSON_PUBLIC(void) JDeleteItemFromObject(J *object, const char *string);
    +
    278 N_CJSON_PUBLIC(void) JDeleteItemFromObjectCaseSensitive(J *object, const char *string);
    +
    279 
    +
    280 /* Update array items. */
    +
    281 N_CJSON_PUBLIC(void) JInsertItemInArray(J *array, int which, J *newitem); /* Shifts pre-existing items to the right. */
    +
    282 N_CJSON_PUBLIC(Jbool) JReplaceItemViaPointer(J * const parent, J * const item, J * replacement);
    +
    283 N_CJSON_PUBLIC(void) JReplaceItemInArray(J *array, int which, J *newitem);
    +
    284 N_CJSON_PUBLIC(void) JReplaceItemInObject(J *object,const char *string,J *newitem);
    +
    285 N_CJSON_PUBLIC(void) JReplaceItemInObjectCaseSensitive(J *object,const char *string,J *newitem);
    +
    286 
    +
    287 /* Duplicate a J item */
    +
    288 N_CJSON_PUBLIC(J *) JDuplicate(const J *item, Jbool recurse);
    +
    289 /* Duplicate will create a new, identical J item to the one you pass, in new memory that will
    +
    290 need to be released. With recurse!=0, it will duplicate any children connected to the item.
    +
    291 The item->next and ->prev pointers are always zero on return from Duplicate. */
    +
    292 /* Recursively compare two J items for equality. If either a or b is NULL or invalid, they will be considered unequal.
    +
    293  * case_sensitive determines if object keys are treated case sensitive (1) or case insensitive (0) */
    +
    294 N_CJSON_PUBLIC(Jbool) JCompare(const J * const a, const J * const b, const Jbool case_sensitive);
    +
    295 
    +
    296 
    +
    297 N_CJSON_PUBLIC(void) JMinify(char *json);
    +
    298 
    +
    299 /* Helper functions for creating and adding items to an object at the same time.
    +
    300  * They return the added item or NULL on failure. */
    +
    301 N_CJSON_PUBLIC(J*) JAddTrueToObject(J * const object, const char * const name);
    +
    302 N_CJSON_PUBLIC(J*) JAddFalseToObject(J * const object, const char * const name);
    +
    303 N_CJSON_PUBLIC(J*) JAddBoolToObject(J * const object, const char * const name, const Jbool boolean);
    +
    304 N_CJSON_PUBLIC(J*) JAddNumberToObject(J * const object, const char * const name, const JNUMBER number);
    +
    305 N_CJSON_PUBLIC(J*) JAddIntToObject(J * const object, const char * const name, const JINTEGER integer);
    +
    306 N_CJSON_PUBLIC(J*) JAddStringToObject(J * const object, const char * const name, const char * const string);
    +
    307 N_CJSON_PUBLIC(J*) JAddRawToObject(J * const object, const char * const name, const char * const raw);
    +
    308 N_CJSON_PUBLIC(J*) JAddObjectToObject(J * const object, const char * const name);
    +
    309 N_CJSON_PUBLIC(J*) JAddArrayToObject(J * const object, const char * const name);
    +
    310 #define JConvertToJSONString JPrintUnformatted
    +
    311 #define JConvertFromJSONString JParse
    +
    312 
    +
    313 /* When assigning an integer value, it needs to be propagated to valuenumber too. */
    +
    314 #define JSetIntValue(object, number) ((object) ? (object)->valueint = (object)->valuenumber = (number) : (number))
    +
    315 /* helper for the JSetNumberValue macro */
    + +
    317 #define JSetNumberValue(object, number) ((object != NULL) ? JSetNumberHelper(object, (JNUMBER)number) : (number))
    +
    318 
    +
    319 /* Macro for iterating over an array or object */
    +
    320 #define JArrayForEach(element, array) for(element = (array != NULL) ? (array)->child : NULL; element != NULL; element = element->next)
    +
    321 // Iterate over the fields of an object
    +
    322 #define JObjectForEach(element, array) JArrayForEach(element, array)
    +
    323 
    +
    324 /* malloc/free objects using the malloc/free functions that have been set with JInitHooks */
    +
    325 N_CJSON_PUBLIC(void *) JMalloc(size_t size);
    +
    326 N_CJSON_PUBLIC(void) JFree(void *object);
    +
    327 
    +
    328 #ifdef __cplusplus
    +
    329 }
    +
    330 #endif
    +
    331 
    +
    332 #endif
    +
    struct J J
    The core JSON object type used by note-c.
    +
    J * JParseWithOpts(const char *value, const char **return_parse_end, Jbool require_null_terminated)
    Definition: n_cjson.c:910
    +
    Jbool JReplaceItemViaPointer(J *const parent, J *const item, J *replacement)
    Definition: n_cjson.c:2162
    +
    char * JPrintBuffered(const J *item, int prebuffer, Jbool fmt)
    Definition: n_cjson.c:1075
    +
    char * JPrintUnformattedOmitEmpty(const J *item)
    Definition: n_cjson.c:1067
    +
    J * JCreateInteger(JINTEGER integer)
    Definition: n_cjson.c:2285
    +
    J * JDetachItemFromObject(J *object, const char *string)
    Definition: n_cjson.c:2095
    +
    void JDelete(J *c)
    Free a J object.
    Definition: n_cjson.c:215
    +
    J * JGetObjectItem(const J *const object, const char *const string)
    Definition: n_cjson.c:1707
    +
    J * JCreateRaw(const char *raw)
    Definition: n_cjson.c:2356
    +
    Jbool JCompare(const J *const a, const J *const b, const Jbool case_sensitive)
    Definition: n_cjson.c:2681
    +
    J * JAddTrueToObject(J *const object, const char *const name)
    Definition: n_cjson.c:1871
    +
    J * JGetObjectItemCaseSensitive(const J *const object, const char *const string)
    Definition: n_cjson.c:1715
    +
    J * JCreateString(const char *string)
    Definition: n_cjson.c:2296
    +
    void JReplaceItemInArray(J *array, int which, J *newitem)
    Definition: n_cjson.c:2192
    +
    void JAddItemToObject(J *object, const char *string, J *item)
    Definition: n_cjson.c:1838
    +
    void JMinify(char *json)
    Definition: n_cjson.c:2552
    +
    Jbool JIsString(const J *const item)
    Definition: n_cjson.c:2649
    +
    void JAddItemToArray(J *array, J *item)
    Definition: n_cjson.c:1783
    +
    Jbool JIsRaw(const J *const item)
    Definition: n_cjson.c:2673
    +
    void JInitHooks(JHooks *hooks)
    +
    const char * JVersion(void)
    Definition: n_cjson.c:116
    +
    Jbool JIsFalse(const J *const item)
    Definition: n_cjson.c:2609
    +
    char * JPrintUnformatted(const J *item)
    Get the unformatted string representation of a J object.
    Definition: n_cjson.c:1059
    +
    void JDeleteItemFromObject(J *object, const char *string)
    Definition: n_cjson.c:2117
    +
    Jbool JIsObject(const J *const item)
    Definition: n_cjson.c:2665
    +
    J * JCreateObjectReference(const J *child)
    Definition: n_cjson.c:2330
    +
    void JDeleteItemFromObjectCaseSensitive(J *object, const char *string)
    Definition: n_cjson.c:2125
    +
    J * JAddNumberToObject(J *const object, const char *const name, const JNUMBER number)
    Add a number field to a J object.
    Definition: n_cjson.c:1934
    +
    Jbool JIsNull(const J *const item)
    Definition: n_cjson.c:2633
    +
    J * JCreateStringArray(const char **strings, int count)
    Definition: n_cjson.c:2455
    +
    const char * JGetErrorPtr(void)
    Definition: n_cjson.c:97
    +
    #define N_CJSON_PUBLIC(type)
    Definition: n_cjson.h:144
    +
    J * JCreateBool(Jbool boolean)
    Definition: n_cjson.c:2257
    +
    void JFree(void *object)
    Free a block of dynamically allocated memory.
    Definition: n_cjson.c:194
    +
    void JInsertItemInArray(J *array, int which, J *newitem)
    Definition: n_cjson.c:2134
    +
    J * JAddIntToObject(J *const object, const char *const name, const JINTEGER integer)
    Definition: n_cjson.c:1949
    +
    Jbool JIsBool(const J *const item)
    Definition: n_cjson.c:2626
    +
    Jbool JHasObjectItem(const J *object, const char *string)
    Definition: n_cjson.c:1723
    +
    J * JCreateArrayReference(const J *child)
    Definition: n_cjson.c:2343
    +
    J * JAddArrayToObject(J *const object, const char *const name)
    Add an array field to a J object.
    Definition: n_cjson.c:2034
    +
    J * JCreateNumber(JNUMBER num)
    Definition: n_cjson.c:2266
    +
    J * JDetachItemFromObjectCaseSensitive(J *object, const char *string)
    Definition: n_cjson.c:2106
    +
    void * JMalloc(size_t size)
    Dynamically allocate a block of memory of the given size.
    Definition: n_cjson.c:181
    +
    Jbool JIsInvalid(const J *const item)
    Definition: n_cjson.c:2601
    +
    void JReplaceItemInObject(J *object, const char *string, J *newitem)
    Definition: n_cjson.c:2223
    +
    Jbool JIsNumber(const J *const item)
    Definition: n_cjson.c:2641
    +
    Jbool JPrintPreallocated(J *item, char *buffer, const int length, const Jbool format)
    Definition: n_cjson.c:1131
    +
    J * JCreateStringReference(const char *string)
    Definition: n_cjson.c:2320
    +
    J * JCreateIntArray(const long int *numbers, int count)
    Definition: n_cjson.c:2396
    +
    char * JPrint(const J *item)
    Definition: n_cjson.c:1040
    +
    void JAddItemReferenceToObject(J *object, const char *string, J *item)
    Definition: n_cjson.c:1863
    +
    int Jbool
    Definition: n_cjson.h:103
    +
    J * JCreateTrue(void)
    Definition: n_cjson.c:2239
    +
    J * JCreateNumberArray(const JNUMBER *numbers, int count)
    Definition: n_cjson.c:2425
    +
    J * JDetachItemFromArray(J *array, int which)
    Definition: n_cjson.c:2075
    +
    void JAddItemReferenceToArray(J *array, J *item)
    Definition: n_cjson.c:1855
    +
    struct JHooks JHooks
    +
    J * JCreateStringValue(const char *string)
    Definition: n_cjson.c:2310
    +
    J * JParse(const char *value)
    Parse the passed in C-string as JSON and return a J object representing it.
    Definition: n_cjson.c:984
    +
    Jbool JIsArray(const J *const item)
    Definition: n_cjson.c:2657
    +
    J * JAddFalseToObject(J *const object, const char *const name)
    Definition: n_cjson.c:1886
    +
    int JGetArraySize(const J *array)
    Definition: n_cjson.c:1635
    +
    J * JCreateArray(void)
    Definition: n_cjson.c:2370
    +
    J * JAddBoolToObject(J *const object, const char *const name, const Jbool boolean)
    Add a boolean field to a J object.
    Definition: n_cjson.c:1910
    +
    J * JAddRawToObject(J *const object, const char *const name, const char *const raw)
    Definition: n_cjson.c:1988
    +
    J * JDuplicate(const J *item, Jbool recurse)
    Definition: n_cjson.c:2486
    +
    J * JAddStringToObject(J *const object, const char *const name, const char *const string)
    Add a string field to a J object.
    Definition: n_cjson.c:1973
    +
    void JReplaceItemInObjectCaseSensitive(J *object, const char *string, J *newitem)
    Definition: n_cjson.c:2231
    +
    JNUMBER JSetNumberHelper(J *object, JNUMBER number)
    Definition: n_cjson.c:328
    +
    J * JCreateObject(void)
    Create a new J object.
    Definition: n_cjson.c:2386
    +
    void JAddItemToObjectCS(J *object, const char *string, J *item)
    Definition: n_cjson.c:1847
    +
    char * JGetStringValue(J *item)
    Definition: n_cjson.c:102
    +
    Jbool JPrintPreallocatedOmitEmpty(J *item, char *buffer, const int length, const Jbool format)
    Definition: n_cjson.c:1126
    +
    Jbool JIsTrue(const J *const item)
    Definition: n_cjson.c:2617
    +
    J * JGetArrayItem(const J *array, int index)
    Definition: n_cjson.c:1673
    +
    J * JCreateFalse(void)
    Definition: n_cjson.c:2248
    +
    void JDeleteItemFromArray(J *array, int which)
    Definition: n_cjson.c:2087
    +
    J * JAddObjectToObject(J *const object, const char *const name)
    Add an object field to another J object.
    Definition: n_cjson.c:2011
    +
    J * JDetachItemViaPointer(J *parent, J *const item)
    Definition: n_cjson.c:2049
    +
    double JNUMBER
    The floating point type used for JSON handling in note-c.
    Definition: note.h:68
    +
    int64_t JINTEGER
    The signed integer type used for JSON handling in note-c.
    Definition: note.h:74
    +
    Definition: n_cjson.h:98
    +
    void(* free_fn)(void *ptr)
    Definition: n_cjson.h:100
    +
    The core JSON object type used by note-c.
    Definition: n_cjson.h:78
    +
    int type
    Definition: n_cjson.h:86
    +
    char * valuestring
    Definition: n_cjson.h:89
    +
    JINTEGER valueint
    Definition: n_cjson.h:91
    +
    struct J * prev
    Definition: n_cjson.h:81
    +
    struct J * next
    Definition: n_cjson.h:80
    +
    struct J * child
    Definition: n_cjson.h:83
    +
    JNUMBER valuenumber
    Definition: n_cjson.h:93
    +
    char * string
    Definition: n_cjson.h:95
    +
    + + + + diff --git a/doxygen/html/n__cjson__helpers_8c.html b/doxygen/html/n__cjson__helpers_8c.html new file mode 100644 index 00000000..9552886a --- /dev/null +++ b/doxygen/html/n__cjson__helpers_8c.html @@ -0,0 +1,1015 @@ + + + + + + + +note-c: /home/runner/work/note-c/note-c/n_cjson_helpers.c File Reference + + + + + + + + + +
    +
    + + + + + + + +
    +
    note-c +  1.0 +
    +
    An easy to use Notecard Library for C/C++
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + +
    +
    + +
    +
    /home/runner/work/note-c/note-c/n_cjson_helpers.c File Reference
    +
    +
    +
    #include <stdlib.h>
    +#include <string.h>
    +#include <time.h>
    +#include "n_lib.h"
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

    +Functions

    bool JIsPresent (J *json, const char *field)
     Determine if a field is present in a JSON object. More...
     
    char * JGetString (J *json, const char *field)
     Get the value of a string field from a JSON object. More...
     
    JJGetArray (J *json, const char *field)
     Get the value of an array field from a JSON object. More...
     
    JJGetObject (J *json, const char *field)
     Get the value of an object field from a JSON object. More...
     
    bool JBoolValue (J *item)
     Return the boolean representation of an item. More...
     
    char * JStringValue (J *item)
     Return the string representation of an item. More...
     
    JNUMBER JNumberValue (J *item)
     Return the number representation of an item. More...
     
    JNUMBER JGetNumber (J *json, const char *field)
     Get the floating point value of a number field from a JSON object. More...
     
    JINTEGER JIntValue (J *item)
     Return the integer representation of an item. More...
     
    JINTEGER JGetInt (J *json, const char *field)
     Get the integer value of a number field from a JSON object. More...
     
    bool JGetBool (J *json, const char *field)
     Get the value of a boolean field from a JSON object. More...
     
    bool JIsNullString (J *json, const char *field)
     Determine if a JSON object is valid and if a field is not present, or null. More...
     
    bool JIsExactString (J *json, const char *field, const char *teststr)
     Determine if a field exists, is a string and matches a provided value. More...
     
    bool JContainsString (J *json, const char *field, const char *substr)
     Determine if a field exists, is a string and contains a provided value. More...
     
    bool JAddBinaryToObject (J *json, const char *fieldName, const void *binaryData, uint32_t binaryDataLen)
     Add binary data as a Base64-encoded string field to a JSON object. More...
     
    bool JGetBinaryFromObject (J *json, const char *fieldName, uint8_t **retBinaryData, uint32_t *retBinaryDataLen)
     Decode a Base64-encoded string field in a JSON object and return the decoded bytes. More...
     
    const char * JGetItemName (const J *item)
     Get the object name. More...
     
    void JItoA (JINTEGER n, char *s)
     Convert an integer to text. More...
     
    JINTEGER JAtoI (const char *string)
     Convert text to an integer. More...
     
    char * JAllocString (uint8_t *buffer, uint32_t len)
     Convert a buffer/len to a null-terminated c-string. More...
     
    const char * JType (J *item)
     Return the type of an item, as a string. More...
     
    int JGetType (J *json, const char *field)
     Get the type of a field, as an int usable in a switch statement. More...
     
    int JGetItemType (J *item)
     
    int JBaseItemType (int type)
     
    +

    Detailed Description

    +

    Written by Ray Ozzie and Blues Inc. team.

    +

    Copyright (c) 2019 Blues Inc. MIT License. Use of this source code is governed by licenses granted by the copyright holder including that found in the LICENSE file.

    +

    Function Documentation

    + +

    ◆ JAddBinaryToObject()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    bool JAddBinaryToObject (Jjson,
    const char * fieldName,
    const void * binaryData,
    uint32_t binaryDataLen 
    )
    +
    + +

    Add binary data as a Base64-encoded string field to a JSON object.

    +
    Parameters
    + + + + + +
    jsonThe JSON object.
    fieldNameThe name to use for the field.
    binaryDataA buffer of binary data to encode.
    binaryDataLenThe length of the binary data in bytes.
    +
    +
    +
    Returns
    True if the string was successfully encoded and added to the object, otherwise false.
    + +
    +
    + +

    ◆ JAllocString()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    char* JAllocString (uint8_t * buffer,
    uint32_t len 
    )
    +
    + +

    Convert a buffer/len to a null-terminated c-string.

    +
    Parameters
    + + + +
    bufferA buffer containing the bytes to convert.
    lenThe length of buffer in bytes.
    +
    +
    +
    Returns
    If buffer is NULL or length 0, the empty string. If allocation fails, NULL. On success, the converted c-string. The returned string must be freed with NoteFree.
    + +
    +
    + +

    ◆ JAtoI()

    + +
    +
    + + + + + + + + +
    JINTEGER JAtoI (const char * string)
    +
    + +

    Convert text to an integer.

    +
    Parameters
    + + +
    stringA null-terminated text buffer
    +
    +
    +
    Returns
    An integer, or 0 if invalid
    + +
    +
    + +

    ◆ JBaseItemType()

    + +
    +
    + + + + + + + + +
    int JBaseItemType (int type)
    +
    + +
    +
    + +

    ◆ JBoolValue()

    + +
    +
    + + + + + + + + +
    bool JBoolValue (Jitem)
    +
    + +

    Return the boolean representation of an item.

    +
    Parameters
    + + +
    itemThe JSON item.
    +
    +
    +
    Returns
    The boolean value.
    + +
    +
    + +

    ◆ JContainsString()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    bool JContainsString (Jjson,
    const char * field,
    const char * substr 
    )
    +
    + +

    Determine if a field exists, is a string and contains a provided value.

    +
    Parameters
    + + + + +
    jsonThe JSON response object.
    fieldThe field to check.
    substrThe string to test against the returned value.
    +
    +
    +
    Returns
    bol. Whether the provided string is found within the field.
    + +
    +
    + +

    ◆ JGetArray()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    J* JGetArray (Jjson,
    const char * field 
    )
    +
    + +

    Get the value of an array field from a JSON object.

    +
    Parameters
    + + + +
    jsonThe JSON object.
    fieldThe array field to query.
    +
    +
    +
    Returns
    A pointer to the array, which is itself a JSON object (J *), if the field exists and is an array, otherwise NULL.
    +
    Note
    The returned JSON object is a pointer to the array contained in the parent JSON object. It is not a copy, so once the parent JSON object is freed, the pointer is no longer valid.
    + +
    +
    + +

    ◆ JGetBinaryFromObject()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    bool JGetBinaryFromObject (Jjson,
    const char * fieldName,
    uint8_t ** retBinaryData,
    uint32_t * retBinaryDataLen 
    )
    +
    + +

    Decode a Base64-encoded string field in a JSON object and return the decoded bytes.

    +
    Parameters
    + + + + + +
    jsonThe JSON object.
    fieldNameThe name of the field.
    retBinaryDataA pointer to a pointer, used to hold the pointer to the decoded bytes.
    retBinaryDataLenA pointer to an unsigned integer, used to hold the length of the decoded bytes.
    +
    +
    +
    Returns
    True if the string was successfully decoded and returned, otherwise false.
    +
    Note
    The returned binary buffer must be freed by the user with JFree when it is no longer needed.
    +
    +On error, the returned binary buffer and data length shall be set to NULL and zero (0), respectively.
    + +
    +
    + +

    ◆ JGetBool()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    bool JGetBool (Jjson,
    const char * field 
    )
    +
    + +

    Get the value of a boolean field from a JSON object.

    +
    Parameters
    + + + +
    jsonThe JSON object.
    fieldThe boolean field to query.
    +
    +
    +
    Returns
    The value of the boolean field if it exists and is a boolean, otherwise false.
    +
    See also
    JGetInt
    +
    +JGetNumber
    + +
    +
    + +

    ◆ JGetInt()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    JINTEGER JGetInt (Jjson,
    const char * field 
    )
    +
    + +

    Get the integer value of a number field from a JSON object.

    +
    Parameters
    + + + +
    jsonThe JSON object.
    fieldThe number field to query.
    +
    +
    +
    Returns
    The value of the number field if the field exists and is a number, otherwise 0.
    +
    Note
    The returned value is the integer representation of the number.
    +
    See also
    JGetBool
    +
    +JGetNumber
    + +
    +
    + +

    ◆ JGetItemName()

    + +
    +
    + + + + + + + + +
    const char* JGetItemName (const Jitem)
    +
    + +

    Get the object name.

    +
    Parameters
    + + +
    itemThe JSON object.
    +
    +
    +
    Returns
    The name, or the empty string, if NULL.
    + +
    +
    + +

    ◆ JGetItemType()

    + +
    +
    + + + + + + + + +
    int JGetItemType (Jitem)
    +
    + +
    +
    + +

    ◆ JGetNumber()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    JNUMBER JGetNumber (Jjson,
    const char * field 
    )
    +
    + +

    Get the floating point value of a number field from a JSON object.

    +
    Parameters
    + + + +
    jsonThe JSON object.
    fieldThe number field to query.
    +
    +
    +
    Returns
    The value of the number field if the field exists and is a number, otherwise 0.0.
    +
    Note
    The returned value is the floating point representation of the number.
    +
    See also
    JGetInt
    +
    +JGetBool
    + +
    +
    + +

    ◆ JGetObject()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    J* JGetObject (Jjson,
    const char * field 
    )
    +
    + +

    Get the value of an object field from a JSON object.

    +
    Parameters
    + + + +
    jsonThe JSON object.
    fieldThe object field to query.
    +
    +
    +
    Returns
    A pointer to the object, which is itself a JSON object (J *), if the field exists and is an object, otherwise NULL.
    +
    Note
    The returned JSON object is a pointer to the object contained in the parent JSON object. It is not a copy, so once the parent JSON object is freed, the pointer is no longer valid.
    + +
    +
    + +

    ◆ JGetString()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    char* JGetString (Jjson,
    const char * field 
    )
    +
    + +

    Get the value of a string field from a JSON object.

    +
    Parameters
    + + + +
    jsonThe JSON object.
    fieldThe string field to query.
    +
    +
    +
    Returns
    A pointer to the string if the field exists and is a string, otherwise the empty string ("").
    +
    Note
    The returned string is a pointer to the string contained in the JSON object. It is not a copy of the string, so once the JSON object is freed, the pointer is no longer valid.
    + +
    +
    + +

    ◆ JGetType()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    int JGetType (Jjson,
    const char * field 
    )
    +
    + +

    Get the type of a field, as an int usable in a switch statement.

    +
    Parameters
    + + + +
    jsonThe JSON object containing the field.
    fieldThe field's name.
    +
    +
    +
    Returns
    The type of the field on success. JTYPE_NOT_PRESENT on error or if the field doesn't exist.
    + +
    +
    + +

    ◆ JIntValue()

    + +
    +
    + + + + + + + + +
    JINTEGER JIntValue (Jitem)
    +
    + +

    Return the integer representation of an item.

    +
    Parameters
    + + +
    itemThe JSON item.
    +
    +
    +
    Returns
    The number, or 0, if NULL.
    + +
    +
    + +

    ◆ JIsExactString()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    bool JIsExactString (Jjson,
    const char * field,
    const char * teststr 
    )
    +
    + +

    Determine if a field exists, is a string and matches a provided value.

    +
    Parameters
    + + + + +
    jsonThe JSON response object.
    fieldThe field to check.
    teststrThe string to test against the returned value.
    +
    +
    +
    Returns
    bol. Whether the fields match exactly.
    + +
    +
    + +

    ◆ JIsNullString()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    bool JIsNullString (Jjson,
    const char * field 
    )
    +
    + +

    Determine if a JSON object is valid and if a field is not present, or null.

    +
    Parameters
    + + + +
    jsonThe JSON response object.
    fieldThe field to return.
    +
    +
    +
    Returns
    bool. False if the field is not present, or NULL.
    + +
    +
    + +

    ◆ JIsPresent()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    bool JIsPresent (Jjson,
    const char * field 
    )
    +
    + +

    Determine if a field is present in a JSON object.

    +
    Parameters
    + + + +
    jsonThe JSON object.
    fieldThe field to find.
    +
    +
    +
    Returns
    True if the field is present, or false if the field is not present or the JSON object is NULL.
    + +
    +
    + +

    ◆ JItoA()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    void JItoA (JINTEGER n,
    char * s 
    )
    +
    + +

    Convert an integer to text.

    +
    Parameters
    + + + +
    nThe integer to convert.
    sThe buffer to hold the text.
    +
    +
    +
    Note
    The buffer must be large enough because no bounds checking is done.
    + +
    +
    + +

    ◆ JNumberValue()

    + +
    +
    + + + + + + + + +
    JNUMBER JNumberValue (Jitem)
    +
    + +

    Return the number representation of an item.

    +
    Parameters
    + + +
    itemThe JSON item.
    +
    +
    +
    Returns
    The number, or 0.0, if NULL.
    + +
    +
    + +

    ◆ JStringValue()

    + +
    +
    + + + + + + + + +
    char* JStringValue (Jitem)
    +
    + +

    Return the string representation of an item.

    +
    Parameters
    + + +
    itemThe JSON item.
    +
    +
    +
    Returns
    The string value, or empty string, if NULL.
    + +
    +
    + +

    ◆ JType()

    + +
    +
    + + + + + + + + +
    const char* JType (Jitem)
    +
    + +

    Return the type of an item, as a string.

    +
    Parameters
    + + +
    itemThe JSON item.
    +
    +
    +
    Returns
    The type
    + +
    +
    +
    + + + + diff --git a/doxygen/html/n__hooks_8c.html b/doxygen/html/n__hooks_8c.html new file mode 100644 index 00000000..197648c9 --- /dev/null +++ b/doxygen/html/n__hooks_8c.html @@ -0,0 +1,2127 @@ + + + + + + + +note-c: /home/runner/work/note-c/note-c/n_hooks.c File Reference + + + + + + + + + +
    +
    + + + + + + + +
    +
    note-c +  1.0 +
    +
    An easy to use Notecard Library for C/C++
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + +
    +
    + +
    +
    /home/runner/work/note-c/note-c/n_hooks.c File Reference
    +
    +
    +
    #include <stdio.h>
    +#include <stdarg.h>
    +#include <stdlib.h>
    +#include "n_lib.h"
    +
    + + + + + + + + + + +

    +Macros

    #define NOTE_SHOW_MALLOC   false
     Show malloc operations for debugging in very low mem environments. More...
     
    #define interfaceNone   0
     
    #define interfaceSerial   1
     
    #define interfaceI2C   2
     
    + + + + + + + + + +

    +Typedefs

    typedef bool(* nNoteResetFn) (void)
     
    typedef const char *(* nTransactionFn) (const char *, size_t, char **, uint32_t)
     
    typedef const char *(* nReceiveFn) (uint8_t *, uint32_t *, bool, uint32_t, uint32_t *)
     
    typedef const char *(* nTransmitFn) (uint8_t *, uint32_t, bool)
     
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

    +Functions

    void NoteSetFnDefault (mallocFn mallocfn, freeFn freefn, delayMsFn delayfn, getMsFn millisfn)
     Set the default memory and timing hooks if they aren't already set. More...
     
    void NoteSetFn (mallocFn mallocHook, freeFn freeHook, delayMsFn delayMsHook, getMsFn getMsHook)
     Set the platform-specific memory and timing hooks. More...
     
    void NoteSetFnDebugOutput (debugOutputFn fn)
     Set the platform-specific debug output function. More...
     
    bool noteIsDebugOutputActive (void)
     Determine if a debug output function has been set. More...
     
    void NoteSetFnTransaction (txnStartFn startFn, txnStopFn stopFn)
     Set the platform-specific transaction initiation/completion fn's. More...
     
    void NoteSetFnMutex (mutexFn lockI2Cfn, mutexFn unlockI2Cfn, mutexFn lockNotefn, mutexFn unlockNotefn)
     Set the platform-specific mutex functions for I2C and the Notecard. More...
     
    void NoteSetFnI2CMutex (mutexFn lockI2Cfn, mutexFn unlockI2Cfn)
     Set the platform-specific mutex functions for I2C. More...
     
    void NoteSetFnNoteMutex (mutexFn lockFn, mutexFn unlockFn)
     Set the platform-specific mutex functions for the Notecard. More...
     
    void NoteSetFnSerial (serialResetFn resetFn, serialTransmitFn transmitFn, serialAvailableFn availFn, serialReceiveFn receiveFn)
     Set the platform-specific hooks for communicating with the Notecard over serial. More...
     
    void NoteSetFnI2C (uint32_t notecardAddr, uint32_t maxTransmitSize, i2cResetFn resetFn, i2cTransmitFn transmitFn, i2cReceiveFn receiveFn)
     Set the platform-specific hooks for communicating with the Notecard over I2C, as well as the I2C address of the Notecard and maximum transmission size. More...
     
    void NoteSetFnDisabled (void)
     Set the platform-specific communications method to be disabled. More...
     
    void NoteDebugIntln (const char *line, int n)
     Write a number to the debug stream and output a newline. More...
     
    void NoteDebugln (const char *line)
     Write text to the debug stream and output a newline. More...
     
    void NoteDebug (const char *line)
     Write to the debug stream. More...
     
    void NoteDebugWithLevel (uint8_t level, const char *msg)
     Write the message to the debug stream, if the level is less than or equal to NOTE_C_LOG_LEVEL. Otherwise, the message is dropped. More...
     
    void NoteDebugWithLevelLn (uint8_t level, const char *msg)
     Same as NoteDebugWithLevel, but add a newline at the end. More...
     
    uint32_t NoteGetMs (void)
     Get the current milliseconds value from the platform-specific hook. More...
     
    void NoteDelayMs (uint32_t ms)
     Delay milliseconds using the platform-specific hook. More...
     
    void n_htoa32 (uint32_t n, char *p)
     Convert number to a hex string. More...
     
    void * NoteMalloc (size_t size)
     Allocate a memory chunk using the platform-specific hook. More...
     
    void NoteFree (void *p)
     Free memory using the platform-specific hook. More...
     
    void NoteLockI2C (void)
     Lock the I2C bus using the platform-specific hook. More...
     
    void NoteUnlockI2C (void)
     Unlock the I2C bus using the platform-specific hook. More...
     
    void noteLockNote (void)
     Lock the Notecard using the platform-specific hook. More...
     
    void noteUnlockNote (void)
     Unlock the Notecard using the platform-specific hook. More...
     
    bool noteTransactionStart (uint32_t timeoutMs)
     Indicate that we're initiating a transaction using the platform-specific hook. More...
     
    void noteTransactionStop (void)
     Indicate that we've completed a transaction using the platform-specific hook. More...
     
    const char * noteActiveInterface (void)
     Get the active interface's name. More...
     
    bool noteSerialReset (void)
     Reset the Serial bus using the platform-specific hook. More...
     
    void noteSerialTransmit (uint8_t *text, size_t len, bool flush)
     Transmit bytes over Serial using the platform-specific hook. More...
     
    bool noteSerialAvailable (void)
     Determine if Serial bus is available using the platform-specific hook. More...
     
    char noteSerialReceive (void)
     Obtain a character from the Serial bus using the platform-specific hook. More...
     
    bool noteI2CReset (uint16_t DevAddress)
     Reset the I2C bus using the platform-specific hook. More...
     
    const char * noteI2CTransmit (uint16_t DevAddress, uint8_t *pBuffer, uint16_t Size)
     Transmit bytes over I2C using the platform-specific hook. More...
     
    const char * noteI2CReceive (uint16_t DevAddress, uint8_t *pBuffer, uint16_t Size, uint32_t *available)
     Receive bytes from I2C using the platform-specific hook. More...
     
    uint32_t NoteI2CAddress (void)
     Get the I2C address of the Notecard. More...
     
    void NoteSetI2CAddress (uint32_t i2caddress)
     Set the I2C address for communication with the Notecard. More...
     
    uint32_t NoteI2CMax (void)
     Determine the maximum number of bytes for each segment of data sent to the Notecard over I2C. More...
     
    bool noteHardReset (void)
     Perform a hard reset on the Notecard using the platform-specific hook. More...
     
    const char * noteJSONTransaction (const char *request, size_t reqLen, char **response, uint32_t timeoutMs)
     Perform a JSON request to the Notecard using the currently-set platform hook. More...
     
    const char * noteChunkedReceive (uint8_t *buffer, uint32_t *size, bool delay, uint32_t timeoutMs, uint32_t *available)
     Receive bytes over from the Notecard using the currently-set platform hook. More...
     
    const char * noteChunkedTransmit (uint8_t *buffer, uint32_t size, bool delay)
     Transmit bytes over to the Notecard using the currently-set platform hook. More...
     
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

    +Variables

    debugOutputFn hookDebugOutput = NULL
     Hook for the calling platform's debug interface, if any. More...
     
    mutexFn hookLockI2C = NULL
     Hook for the calling platform's I2C lock function. More...
     
    mutexFn hookUnlockI2C = NULL
     Hook for the calling platform's I2C unlock function. More...
     
    mutexFn hookLockNote = NULL
     Hook for the calling platform's Notecard lock function. More...
     
    mutexFn hookUnlockNote = NULL
     Hook for the calling platform's Notecard lock function. More...
     
    txnStartFn hookTransactionStart = NULL
     Hook for the calling platform's transaction initiation function. More...
     
    txnStopFn hookTransactionStop = NULL
     Hook for the calling platform's transaction completion function. More...
     
    mallocFn hookMalloc = NULL
     Hook for the calling platform's memory allocation function. More...
     
    freeFn hookFree = NULL
     Hook for the calling platform's memory free function. More...
     
    delayMsFn hookDelayMs = NULL
     Hook for the calling platform's delay function. More...
     
    getMsFn hookGetMs = NULL
     Hook for the calling platform's millis timing function. More...
     
    uint32_t hookActiveInterface = interfaceNone
     Hook for the calling platform's current active interface. Value is one of: More...
     
    serialResetFn hookSerialReset = NULL
     Hook for the calling platform's Serial reset function. More...
     
    serialTransmitFn hookSerialTransmit = NULL
     Hook for the calling platform's Serial transmit function. More...
     
    serialAvailableFn hookSerialAvailable = NULL
     Hook for the calling platform's Serial data available function. More...
     
    serialReceiveFn hookSerialReceive = NULL
     Hook for the calling platform's Serial receive function. More...
     
    uint32_t i2cAddress = 0
     Hook for the calling platform's I2C address. More...
     
    uint32_t i2cMax = 0
     Hook for the calling platform's I2C maximum segment size, in bytes. More...
     
    i2cResetFn hookI2CReset = NULL
     Hook for the calling platform's I2C reset function. More...
     
    i2cTransmitFn hookI2CTransmit = NULL
     Hook for the calling platform's transmit function. More...
     
    i2cReceiveFn hookI2CReceive = NULL
     Hook for the calling platform's I2C receive function. More...
     
    +

    Detailed Description

    +

    Hooks allow libraries dependent on note-c to provide platform- or MCU-specific functions for common functions like I2C locking/unlocking, memory allocation and freeing, delays, and communicating with the Notecard over I2C and Serial. Using these hooks, note-c is able to manage Notecard transaction logic, and defer to platform functionality, when needed.

    +

    Written by Ray Ozzie and Blues Inc. team.

    +

    Copyright (c) 2019 Blues Inc. MIT License. Use of this source code is governed by licenses granted by the copyright holder including that found in the LICENSE file.

    +

    Macro Definition Documentation

    + +

    ◆ interfaceI2C

    + +
    +
    + + + + +
    #define interfaceI2C   2
    +
    + +
    +
    + +

    ◆ interfaceNone

    + +
    +
    + + + + +
    #define interfaceNone   0
    +
    + +
    +
    + +

    ◆ interfaceSerial

    + +
    +
    + + + + +
    #define interfaceSerial   1
    +
    + +
    +
    + +

    ◆ NOTE_SHOW_MALLOC

    + +
    +
    + + + + +
    #define NOTE_SHOW_MALLOC   false
    +
    + +

    Show malloc operations for debugging in very low mem environments.

    + +
    +
    +

    Typedef Documentation

    + +

    ◆ nNoteResetFn

    + +
    +
    + + + + +
    typedef bool(* nNoteResetFn) (void)
    +
    + +
    +
    + +

    ◆ nReceiveFn

    + +
    +
    + + + + +
    typedef const char*(* nReceiveFn) (uint8_t *, uint32_t *, bool, uint32_t, uint32_t *)
    +
    + +
    +
    + +

    ◆ nTransactionFn

    + +
    +
    + + + + +
    typedef const char*(* nTransactionFn) (const char *, size_t, char **, uint32_t)
    +
    + +
    +
    + +

    ◆ nTransmitFn

    + +
    +
    + + + + +
    typedef const char*(* nTransmitFn) (uint8_t *, uint32_t, bool)
    +
    + +
    +
    +

    Function Documentation

    + +

    ◆ n_htoa32()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    void n_htoa32 (uint32_t n,
    char * p 
    )
    +
    + +

    Convert number to a hex string.

    +
    Parameters
    + + + +
    nthe number
    pthe buffer to return it into
    +
    +
    + +
    +
    + +

    ◆ noteActiveInterface()

    + +
    +
    + + + + + + + + +
    const char* noteActiveInterface (void )
    +
    + +

    Get the active interface's name.

    +
    Returns
    A string
    + +
    +
    + +

    ◆ noteChunkedReceive()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    const char* noteChunkedReceive (uint8_t * buffer,
    uint32_t * size,
    bool delay,
    uint32_t timeoutMs,
    uint32_t * available 
    )
    +
    + +

    Receive bytes over from the Notecard using the currently-set platform hook.

    +
    Parameters
    + + + + + + +
    bufferA buffer to receive bytes into.
    size(in/out)
      +
    • (in) The size of the buffer in bytes.
    • +
    • (out) The length of the received data in bytes.
    • +
    +
    delayRespect standard processing delays.
    timeoutMsThe maximum amount of time, in milliseconds, to wait for data to arrive. Passing zero (0) disables the timeout.
    available(in/out)
      +
    • (in) The amount of bytes to request. Sending zero (0) will initiate a priming query when using the I2C interface.
    • +
    • (out) The amount of bytes unable to fit into the provided buffer.
    • +
    +
    +
    +
    +
    Returns
    A c-string with an error, or NULL if no error ocurred.
    + +
    +
    + +

    ◆ noteChunkedTransmit()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    const char* noteChunkedTransmit (uint8_t * buffer,
    uint32_t size,
    bool delay 
    )
    +
    + +

    Transmit bytes over to the Notecard using the currently-set platform hook.

    +
    Parameters
    + + + + +
    bufferA buffer of bytes to transmit.
    sizeThe count of bytes in the buffer to send
    delayRespect standard processing delays.
    +
    +
    +
    Returns
    A c-string with an error, or NULL if no error ocurred.
    + +
    +
    + +

    ◆ NoteDebug()

    + +
    +
    + + + + + + + + +
    void NoteDebug (const char * line)
    +
    + +

    Write to the debug stream.

    +
    Parameters
    + + +
    lineA debug string for output.
    +
    +
    + +
    +
    + +

    ◆ NoteDebugIntln()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    void NoteDebugIntln (const char * line,
    int n 
    )
    +
    + +

    Write a number to the debug stream and output a newline.

    +
    Parameters
    + + + +
    lineA debug string for output.
    nThe number to write.
    +
    +
    + +
    +
    + +

    ◆ NoteDebugln()

    + +
    +
    + + + + + + + + +
    void NoteDebugln (const char * line)
    +
    + +

    Write text to the debug stream and output a newline.

    +
    Parameters
    + + +
    lineA debug string for output.
    +
    +
    + +
    +
    + +

    ◆ NoteDebugWithLevel()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    void NoteDebugWithLevel (uint8_t level,
    const char * msg 
    )
    +
    + +

    Write the message to the debug stream, if the level is less than or equal to NOTE_C_LOG_LEVEL. Otherwise, the message is dropped.

    +
    Parameters
    + + + +
    levelThe log level of the message. See the NOTE_C_LOG_LEVEL_* macros in note.h for possible values.
    msgThe debug message.
    +
    +
    + +
    +
    + +

    ◆ NoteDebugWithLevelLn()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    void NoteDebugWithLevelLn (uint8_t level,
    const char * msg 
    )
    +
    + +

    Same as NoteDebugWithLevel, but add a newline at the end.

    +
    Parameters
    + + + +
    levelThe log level of the message. See the NOTE_C_LOG_LEVEL_* macros in note.h for possible values.
    msgThe debug message.
    +
    +
    + +
    +
    + +

    ◆ NoteDelayMs()

    + +
    +
    + + + + + + + + +
    void NoteDelayMs (uint32_t ms)
    +
    + +

    Delay milliseconds using the platform-specific hook.

    +
    Parameters
    + + +
    msthe milliseconds delay value.
    +
    +
    + +
    +
    + +

    ◆ NoteFree()

    + +
    +
    + + + + + + + + +
    void NoteFree (void * p)
    +
    + +

    Free memory using the platform-specific hook.

    +
    Parameters
    + + +
    pA pointer to the memory address to free.
    +
    +
    + +
    +
    + +

    ◆ NoteGetMs()

    + +
    +
    + + + + + + + + +
    uint32_t NoteGetMs (void )
    +
    + +

    Get the current milliseconds value from the platform-specific hook.

    +
    Returns
    The current milliseconds value.
    + +
    +
    + +

    ◆ noteHardReset()

    + +
    +
    + + + + + + + + +
    bool noteHardReset (void )
    +
    + +

    Perform a hard reset on the Notecard using the platform-specific hook.

    +
    Returns
    A boolean indicating whether the Notecard has been reset successfully.
    + +
    +
    + +

    ◆ NoteI2CAddress()

    + +
    +
    + + + + + + + + +
    uint32_t NoteI2CAddress (void )
    +
    + +

    Get the I2C address of the Notecard.

    +
    Returns
    The current I2C address.
    + +
    +
    + +

    ◆ NoteI2CMax()

    + +
    +
    + + + + + + + + +
    uint32_t NoteI2CMax (void )
    +
    + +

    Determine the maximum number of bytes for each segment of data sent to the Notecard over I2C.

    +
    Returns
    A 32-bit integer of the maximum number of bytes per I2C segment.
    + +
    +
    + +

    ◆ noteI2CReceive()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    const char* noteI2CReceive (uint16_t DevAddress,
    uint8_t * pBuffer,
    uint16_t Size,
    uint32_t * available 
    )
    +
    + +

    Receive bytes from I2C using the platform-specific hook.

    +
    Parameters
    + + + + + +
    DevAddressthe I2C address for transmission.
    pBuffer(out) A buffer in which to place received bytes.
    SizeThe length of bytes.
    available(out) The number of bytes left to read.
    +
    +
    +
    Returns
    A c-string from the platform-specific hook, or an error string if the bus is not active.
    + +
    +
    + +

    ◆ noteI2CReset()

    + +
    +
    + + + + + + + + +
    bool noteI2CReset (uint16_t DevAddress)
    +
    + +

    Reset the I2C bus using the platform-specific hook.

    +
    Returns
    A boolean indicating whether the I2C bus was reset successfully.
    + +
    +
    + +

    ◆ noteI2CTransmit()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    const char* noteI2CTransmit (uint16_t DevAddress,
    uint8_t * pBuffer,
    uint16_t Size 
    )
    +
    + +

    Transmit bytes over I2C using the platform-specific hook.

    +
    Parameters
    + + + + +
    DevAddressthe I2C address for transmission.
    pBufferThe bytes to transmit.
    SizeThe length of bytes.
    +
    +
    +
    Returns
    A c-string from the platform-specific hook, or an error string if the bus is not active.
    + +
    +
    + +

    ◆ noteIsDebugOutputActive()

    + +
    +
    + + + + + + + + +
    bool noteIsDebugOutputActive (void )
    +
    + +

    Determine if a debug output function has been set.

    +
    Returns
    A boolean indicating whether a debug ouput function was provided.
    + +
    +
    + +

    ◆ noteJSONTransaction()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    const char* noteJSONTransaction (const char * request,
    size_t reqLen,
    char ** response,
    uint32_t timeoutMs 
    )
    +
    + +

    Perform a JSON request to the Notecard using the currently-set platform hook.

    +
    Parameters
    + + + + + +
    requestA string containing the JSON request object, which MUST BE terminated with a newline character.
    reqLenthe string length of the JSON request.
    response[out] A c-string buffer that will contain the newline ('
    +') terminated JSON response from the Notercard. If NULL, no response will be captured.
    timeoutMsThe maximum amount of time, in milliseconds, to wait for data to arrive. Passing zero (0) disables the timeout.
    +
    +
    +
    Returns
    NULL if successful, or an error string if the transaction failed or the hook has not been set.
    + +
    +
    + +

    ◆ NoteLockI2C()

    + +
    +
    + + + + + + + + +
    void NoteLockI2C (void )
    +
    + +

    Lock the I2C bus using the platform-specific hook.

    + +
    +
    + +

    ◆ noteLockNote()

    + +
    +
    + + + + + + + + +
    void noteLockNote (void )
    +
    + +

    Lock the Notecard using the platform-specific hook.

    + +
    +
    + +

    ◆ NoteMalloc()

    + +
    +
    + + + + + + + + +
    void* NoteMalloc (size_t size)
    +
    + +

    Allocate a memory chunk using the platform-specific hook.

    +
    Parameters
    + + +
    sizethe number of bytes to allocate.
    +
    +
    + +
    +
    + +

    ◆ noteSerialAvailable()

    + +
    +
    + + + + + + + + +
    bool noteSerialAvailable (void )
    +
    + +

    Determine if Serial bus is available using the platform-specific hook.

    +
    Returns
    A boolean indicating whether the Serial bus is available to read.
    + +
    +
    + +

    ◆ noteSerialReceive()

    + +
    +
    + + + + + + + + +
    char noteSerialReceive (void )
    +
    + +

    Obtain a character from the Serial bus using the platform-specific hook.

    +
    Returns
    A character from the Serial bus.
    + +
    +
    + +

    ◆ noteSerialReset()

    + +
    +
    + + + + + + + + +
    bool noteSerialReset (void )
    +
    + +

    Reset the Serial bus using the platform-specific hook.

    +
    Returns
    A boolean indicating whether the Serial bus was reset successfully.
    + +
    +
    + +

    ◆ noteSerialTransmit()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    void noteSerialTransmit (uint8_t * text,
    size_t len,
    bool flush 
    )
    +
    + +

    Transmit bytes over Serial using the platform-specific hook.

    +
    Parameters
    + + + + +
    textThe bytes to transmit.
    lenThe length of bytes.
    flushtrue to flush the bytes upon transmit.
    +
    +
    + +
    +
    + +

    ◆ NoteSetFn()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    void NoteSetFn (mallocFn mallocHook,
    freeFn freeHook,
    delayMsFn delayMsHook,
    getMsFn getMsHook 
    )
    +
    + +

    Set the platform-specific memory and timing hooks.

    +
    Parameters
    + + + + + +
    mallocHookThe platform-specific memory allocation function (i.e. malloc).
    freeHookThe platform-specific memory free function (i.e. free).
    delayMsHookThe platform-specific millisecond delay function.
    getMsHookThe platform-specific millisecond counter function.
    +
    +
    + +
    +
    + +

    ◆ NoteSetFnDebugOutput()

    + +
    +
    + + + + + + + + +
    void NoteSetFnDebugOutput (debugOutputFn fn)
    +
    + +

    Set the platform-specific debug output function.

    +
    Parameters
    + + +
    fnA function pointer to call for debug output.
    +
    +
    + +
    +
    + +

    ◆ NoteSetFnDefault()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    void NoteSetFnDefault (mallocFn mallocfn,
    freeFn freefn,
    delayMsFn delayfn,
    getMsFn millisfn 
    )
    +
    + +

    Set the default memory and timing hooks if they aren't already set.

    +
    Parameters
    + + + + + +
    mallocfnThe default memory allocation malloc function to use.
    freefnThe default memory free function to use.
    delayfnThe default delay function to use.
    millisfnThe default 'millis' function to use.
    +
    +
    + +
    +
    + +

    ◆ NoteSetFnDisabled()

    + +
    +
    + + + + + + + + +
    void NoteSetFnDisabled (void )
    +
    + +

    Set the platform-specific communications method to be disabled.

    + +
    +
    + +

    ◆ NoteSetFnI2C()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    void NoteSetFnI2C (uint32_t notecardAddr,
    uint32_t maxTransmitSize,
    i2cResetFn resetFn,
    i2cTransmitFn transmitFn,
    i2cReceiveFn receiveFn 
    )
    +
    + +

    Set the platform-specific hooks for communicating with the Notecard over I2C, as well as the I2C address of the Notecard and maximum transmission size.

    +
    Parameters
    + + + + + + +
    notecardAddrThe I2C address of the Notecard. Pass 0 to use the default address.
    maxTransmitSizeThe max number of bytes to send to the Notecard in a single I2C segment. Pass 0 to use the default maximum transmission size.
    resetFnThe platform-specific I2C reset function.
    transmitFnThe platform-specific I2C transmit function.
    receiveFnThe platform-specific I2C receive function.
    +
    +
    + +
    +
    + +

    ◆ NoteSetFnI2CMutex()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    void NoteSetFnI2CMutex (mutexFn lockI2Cfn,
    mutexFn unlockI2Cfn 
    )
    +
    + +

    Set the platform-specific mutex functions for I2C.

    +
    Parameters
    + + + +
    lockI2CfnThe platform-specific I2C lock function.
    unlockI2CfnThe platform-specific I2C unlock function.
    +
    +
    + +
    +
    + +

    ◆ NoteSetFnMutex()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    void NoteSetFnMutex (mutexFn lockI2Cfn,
    mutexFn unlockI2Cfn,
    mutexFn lockNotefn,
    mutexFn unlockNotefn 
    )
    +
    + +

    Set the platform-specific mutex functions for I2C and the Notecard.

    +
    Parameters
    + + + + + +
    lockI2CfnThe platform-specific I2C lock function to use.
    unlockI2CfnThe platform-specific I2C unlock function to use.
    lockNotefnThe platform-specific Notecard lock function to use.
    unlockNotefnThe platform-specific Notecard unlock function to use.
    +
    +
    + +
    +
    + +

    ◆ NoteSetFnNoteMutex()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    void NoteSetFnNoteMutex (mutexFn lockFn,
    mutexFn unlockFn 
    )
    +
    + +

    Set the platform-specific mutex functions for the Notecard.

    +
    Parameters
    + + + +
    lockFnThe platform-specific Notecard lock function.
    unlockFnThe platform-specific Notecard unlock function.
    +
    +
    + +
    +
    + +

    ◆ NoteSetFnSerial()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    void NoteSetFnSerial (serialResetFn resetFn,
    serialTransmitFn transmitFn,
    serialAvailableFn availFn,
    serialReceiveFn receiveFn 
    )
    +
    + +

    Set the platform-specific hooks for communicating with the Notecard over serial.

    +
    Parameters
    + + + + + +
    resetFnThe platform-specific serial reset function.
    transmitFnThe platform-specific serial transmit function.
    availFnThe platform-specific serial available function.
    receiveFnThe platform-specific serial receive function.
    +
    +
    + +
    +
    + +

    ◆ NoteSetFnTransaction()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    void NoteSetFnTransaction (txnStartFn startFn,
    txnStopFn stopFn 
    )
    +
    + +

    Set the platform-specific transaction initiation/completion fn's.

    +
    Parameters
    + + + +
    startFnThe platform-specific transaction initiation function to use.
    stopFnThe platform-specific transaction completion function to use. to use.
    +
    +
    + +
    +
    + +

    ◆ NoteSetI2CAddress()

    + +
    +
    + + + + + + + + +
    void NoteSetI2CAddress (uint32_t i2caddress)
    +
    + +

    Set the I2C address for communication with the Notecard.

    +
    Parameters
    + + +
    i2caddressthe I2C address to use for the Notecard.
    +
    +
    + +
    +
    + +

    ◆ noteTransactionStart()

    + +
    +
    + + + + + + + + +
    bool noteTransactionStart (uint32_t timeoutMs)
    +
    + +

    Indicate that we're initiating a transaction using the platform-specific hook.

    + +
    +
    + +

    ◆ noteTransactionStop()

    + +
    +
    + + + + + + + + +
    void noteTransactionStop (void )
    +
    + +

    Indicate that we've completed a transaction using the platform-specific hook.

    + +
    +
    + +

    ◆ NoteUnlockI2C()

    + +
    +
    + + + + + + + + +
    void NoteUnlockI2C (void )
    +
    + +

    Unlock the I2C bus using the platform-specific hook.

    + +
    +
    + +

    ◆ noteUnlockNote()

    + +
    +
    + + + + + + + + +
    void noteUnlockNote (void )
    +
    + +

    Unlock the Notecard using the platform-specific hook.

    + +
    +
    +

    Variable Documentation

    + +

    ◆ hookActiveInterface

    + +
    +
    + + + + +
    uint32_t hookActiveInterface = interfaceNone
    +
    + +

    Hook for the calling platform's current active interface. Value is one of:

    +
      +
    • interfaceNone = 0 (default)
    • +
    • interfaceSerial = 1
    • +
    • interfaceI2C = 2
    • +
    + +
    +
    + +

    ◆ hookDebugOutput

    + +
    +
    + + + + +
    debugOutputFn hookDebugOutput = NULL
    +
    + +

    Hook for the calling platform's debug interface, if any.

    + +
    +
    + +

    ◆ hookDelayMs

    + +
    +
    + + + + +
    delayMsFn hookDelayMs = NULL
    +
    + +

    Hook for the calling platform's delay function.

    + +
    +
    + +

    ◆ hookFree

    + +
    +
    + + + + +
    freeFn hookFree = NULL
    +
    + +

    Hook for the calling platform's memory free function.

    + +
    +
    + +

    ◆ hookGetMs

    + +
    +
    + + + + +
    getMsFn hookGetMs = NULL
    +
    + +

    Hook for the calling platform's millis timing function.

    + +
    +
    + +

    ◆ hookI2CReceive

    + +
    +
    + + + + +
    i2cReceiveFn hookI2CReceive = NULL
    +
    + +

    Hook for the calling platform's I2C receive function.

    + +
    +
    + +

    ◆ hookI2CReset

    + +
    +
    + + + + +
    i2cResetFn hookI2CReset = NULL
    +
    + +

    Hook for the calling platform's I2C reset function.

    + +
    +
    + +

    ◆ hookI2CTransmit

    + +
    +
    + + + + +
    i2cTransmitFn hookI2CTransmit = NULL
    +
    + +

    Hook for the calling platform's transmit function.

    + +
    +
    + +

    ◆ hookLockI2C

    + +
    +
    + + + + +
    mutexFn hookLockI2C = NULL
    +
    + +

    Hook for the calling platform's I2C lock function.

    + +
    +
    + +

    ◆ hookLockNote

    + +
    +
    + + + + +
    mutexFn hookLockNote = NULL
    +
    + +

    Hook for the calling platform's Notecard lock function.

    + +
    +
    + +

    ◆ hookMalloc

    + +
    +
    + + + + +
    mallocFn hookMalloc = NULL
    +
    + +

    Hook for the calling platform's memory allocation function.

    + +
    +
    + +

    ◆ hookSerialAvailable

    + +
    +
    + + + + +
    serialAvailableFn hookSerialAvailable = NULL
    +
    + +

    Hook for the calling platform's Serial data available function.

    + +
    +
    + +

    ◆ hookSerialReceive

    + +
    +
    + + + + +
    serialReceiveFn hookSerialReceive = NULL
    +
    + +

    Hook for the calling platform's Serial receive function.

    + +
    +
    + +

    ◆ hookSerialReset

    + +
    +
    + + + + +
    serialResetFn hookSerialReset = NULL
    +
    + +

    Hook for the calling platform's Serial reset function.

    + +
    +
    + +

    ◆ hookSerialTransmit

    + +
    +
    + + + + +
    serialTransmitFn hookSerialTransmit = NULL
    +
    + +

    Hook for the calling platform's Serial transmit function.

    + +
    +
    + +

    ◆ hookTransactionStart

    + +
    +
    + + + + +
    txnStartFn hookTransactionStart = NULL
    +
    + +

    Hook for the calling platform's transaction initiation function.

    + +
    +
    + +

    ◆ hookTransactionStop

    + +
    +
    + + + + +
    txnStopFn hookTransactionStop = NULL
    +
    + +

    Hook for the calling platform's transaction completion function.

    + +
    +
    + +

    ◆ hookUnlockI2C

    + +
    +
    + + + + +
    mutexFn hookUnlockI2C = NULL
    +
    + +

    Hook for the calling platform's I2C unlock function.

    + +
    +
    + +

    ◆ hookUnlockNote

    + +
    +
    + + + + +
    mutexFn hookUnlockNote = NULL
    +
    + +

    Hook for the calling platform's Notecard lock function.

    + +
    +
    + +

    ◆ i2cAddress

    + +
    +
    + + + + +
    uint32_t i2cAddress = 0
    +
    + +

    Hook for the calling platform's I2C address.

    + +
    +
    + +

    ◆ i2cMax

    + +
    +
    + + + + +
    uint32_t i2cMax = 0
    +
    + +

    Hook for the calling platform's I2C maximum segment size, in bytes.

    + +
    +
    +
    + + + + diff --git a/doxygen/html/n__request_8c.html b/doxygen/html/n__request_8c.html new file mode 100644 index 00000000..efb5688b --- /dev/null +++ b/doxygen/html/n__request_8c.html @@ -0,0 +1,680 @@ + + + + + + + +note-c: /home/runner/work/note-c/note-c/n_request.c File Reference + + + + + + + + + +
    +
    + + + + + + + +
    +
    note-c +  1.0 +
    +
    An easy to use Notecard Library for C/C++
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + +
    +
    + +
    +
    /home/runner/work/note-c/note-c/n_request.c File Reference
    +
    +
    +
    #include "n_lib.h"
    +
    + + + + + + + + + +

    +Macros

    #define NOTE_C_STATIC   static
     
    #define CRC_FIELD_LENGTH   22
     
    #define CRC_FIELD_NAME_OFFSET   1
     
    #define CRC_FIELD_NAME_TEST   "\"crc\":\""
     
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

    +Functions

    void NoteSuspendTransactionDebug (void)
     Suppress showing transaction details. More...
     
    void NoteResumeTransactionDebug (void)
     Resume showing transaction details. More...
     
    JNoteNewRequest (const char *request)
     Create a new JSON request. More...
     
    JNoteNewCommand (const char *request)
     Create a new JSON command. More...
     
    bool NoteRequest (J *req)
     Send a request to the Notecard. More...
     
    bool NoteRequestWithRetry (J *req, uint32_t timeoutSeconds)
     Send a request to the Notecard, retrying it until it succeeds or it times out. More...
     
    JNoteRequestResponse (J *req)
     Send a request to the Notecard and return the response. More...
     
    JNoteRequestResponseWithRetry (J *req, uint32_t timeoutSeconds)
     Send a request to the Notecard, retrying it until it succeeds or it times out, and return the response. More...
     
    char * NoteRequestResponseJSON (const char *reqJSON)
     Send a request to the Notecard and return the response. More...
     
    JNoteTransaction (J *req)
     Send a request to the Notecard and return the response. More...
     
    JnoteTransactionShouldLock (J *req, bool lockNotecard)
     Same as NoteTransaction, but takes an additional parameter that indicates if the Notecard should be locked. More...
     
    void NoteResetRequired (void)
     Mark that a reset will be required before doing further I/O on a given port. More...
     
    bool NoteReset (void)
     Initialize or re-initialize the module. More...
     
    bool NoteErrorContains (const char *errstr, const char *errtype)
     Check to see if a Notecard error is present in a JSON string. More...
     
    void NoteErrorClean (char *begin)
     Clean error strings out of the specified buffer. More...
     
    uint64_t n_atoh (char *p, int maxLen)
     Convert a hex string to a 64-bit unsigned integer. More...
     
    +

    Detailed Description

    +

    Written by Ray Ozzie and Blues Inc. team.

    +

    Copyright (c) 2019 Blues Inc. MIT License. Use of this source code is governed by licenses granted by the copyright holder including that found in the LICENSE file.

    +

    Macro Definition Documentation

    + +

    ◆ CRC_FIELD_LENGTH

    + +
    +
    + + + + +
    #define CRC_FIELD_LENGTH   22
    +
    + +
    +
    + +

    ◆ CRC_FIELD_NAME_OFFSET

    + +
    +
    + + + + +
    #define CRC_FIELD_NAME_OFFSET   1
    +
    + +
    +
    + +

    ◆ CRC_FIELD_NAME_TEST

    + +
    +
    + + + + +
    #define CRC_FIELD_NAME_TEST   "\"crc\":\""
    +
    + +
    +
    + +

    ◆ NOTE_C_STATIC

    + +
    +
    + + + + +
    #define NOTE_C_STATIC   static
    +
    + +
    +
    +

    Function Documentation

    + +

    ◆ n_atoh()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    uint64_t n_atoh (char * p,
    int maxLen 
    )
    +
    + +

    Convert a hex string to a 64-bit unsigned integer.

    +
    Parameters
    + + + +
    pThe hex string to convert.
    maxLenThe length of the hex string.
    +
    +
    +
    Returns
    The converted number.
    + +
    +
    + +

    ◆ NoteErrorClean()

    + +
    +
    + + + + + + + + +
    void NoteErrorClean (char * begin)
    +
    + +

    Clean error strings out of the specified buffer.

    +

    Notecard errors are enclosed in {} (e.g. {io} for an I/O error). This function takes the input string and removes all errors from it, meaning it removes any substrings matching the pattern {some error string}, including the braces.

    +
    Parameters
    + + +
    beginA C-string to to clean of errors.
    +
    +
    + +
    +
    + +

    ◆ NoteErrorContains()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    bool NoteErrorContains (const char * errstr,
    const char * errtype 
    )
    +
    + +

    Check to see if a Notecard error is present in a JSON string.

    +

    Only Notecard errors enclosed in {} (e.g. {io} for an I/O error) are guaranteed by the API.

    +
    Parameters
    + + + +
    errstrThe string to check for errors.
    errtypeThe error substring to search for in errstr.
    +
    +
    +
    Returns
    true if errstr contains errtype and false otherwise.
    + +
    +
    + +

    ◆ NoteNewCommand()

    + +
    +
    + + + + + + + + +
    J* NoteNewCommand (const char * request)
    +
    + +

    Create a new JSON command.

    +

    Create a dynamically allocated J object with one field "cmd" whose value is the passed in request string. The difference between a command and a request is that the Notecard does not send a response to commands, only to requests.

    +
    Parameters
    + + +
    requestThe name of the command (e.g. card.attn).
    +
    +
    +
    Returns
    A J object with the "cmd" field populated.
    + +
    +
    + +

    ◆ NoteNewRequest()

    + +
    +
    + + + + + + + + +
    J* NoteNewRequest (const char * request)
    +
    + +

    Create a new JSON request.

    +

    Creates a dynamically allocated J object with one field "req" whose value is the passed in request string.

    +
    Parameters
    + + +
    requestThe name of the request, for example hub.set.
    +
    +
    +
    Returns
    A J object with the "req" field populated.
    + +
    +
    + +

    ◆ NoteRequest()

    + +
    +
    + + + + + + + + +
    bool NoteRequest (Jreq)
    +
    + +

    Send a request to the Notecard.

    +

    The passed in request object is always freed, regardless of if the request was successful or not. The response from the Notecard, if any, is freed and not returned to the caller.

    +
    Parameters
    + + +
    reqPointer to a J request object.
    +
    +
    +
    Returns
    true if successful and false if an error occurs (e.g. out of memory or the response from the Notecard has an "err" field). If req is a command rather than a request, a true return value indicates that the command was sent without error. However, since the Notecard sends no response to commands, it does not guarantee that the command was received and processed by the Notecard.
    +
    See also
    NoteRequestResponse if you need to work with the response.
    + +
    +
    + +

    ◆ NoteRequestResponse()

    + +
    +
    + + + + + + + + +
    J* NoteRequestResponse (Jreq)
    +
    + +

    Send a request to the Notecard and return the response.

    +

    The passed in request object is always freed, regardless of if the request was successful or not.

    +
    Parameters
    + + +
    reqPointer to a J request object.
    +
    +
    +
    Returns
    A J object with the response or NULL if there was an error sending the request.
    +
    See also
    NoteResponseError to check the response for errors.
    + +
    +
    + +

    ◆ NoteRequestResponseJSON()

    + +
    +
    + + + + + + + + +
    char* NoteRequestResponseJSON (const char * reqJSON)
    +
    + +

    Send a request to the Notecard and return the response.

    +

    Unlike NoteRequestResponse, this function expects the request to be a valid JSON C-string, rather than a J object. The string is expected to be newline-terminated, otherwise the call produces undefined behavior. The response is returned as a dynamically allocated JSON C-string. The response string is verbatim what was sent by the Notecard, which IS newline-terminated. The caller is responsible for freeing the response string. If the request was a command (i.e. it uses "cmd" instead of "req"), this function returns NULL, because the Notecard does not send a response to commands.

    +
    Parameters
    + + +
    reqJSONA valid newline-terminated JSON C-string containing the request.
    +
    +
    +
    Returns
    A newline-terminated JSON C-string with the response, or NULL if there was no response or if there was an error.
    +
    Note
    When a "cmd" is sent, it is not possible to determine if an error occurred.
    + +
    +
    + +

    ◆ NoteRequestResponseWithRetry()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    J* NoteRequestResponseWithRetry (Jreq,
    uint32_t timeoutSeconds 
    )
    +
    + +

    Send a request to the Notecard, retrying it until it succeeds or it times out, and return the response.

    +

    The passed in request object is always freed, regardless of if the request was successful or not.

    +
    Parameters
    + + + +
    reqPointer to a J request object.
    timeoutSecondsTime limit for retires, in seconds, if there is no response, or if the response contains an I/O error.
    +
    +
    +
    Returns
    A J object with the response or NULL if there was an error sending the request.
    +
    See also
    NoteResponseError to check the response for errors.
    + +
    +
    + +

    ◆ NoteRequestWithRetry()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    bool NoteRequestWithRetry (Jreq,
    uint32_t timeoutSeconds 
    )
    +
    + +

    Send a request to the Notecard, retrying it until it succeeds or it times out.

    +

    The passed in request object is always freed, regardless of if the request was successful or not. The response from the Notecard, if any, is freed and not returned to the caller.

    +
    Parameters
    + + + +
    reqPointer to a J request object.
    timeoutSecondsTime limit for retires, in seconds, if there is no response, or if the response contains an I/O error.
    +
    +
    +
    Returns
    true if successful and false if an error occurs (e.g. out of memory or the response from the Notecard has an "err" field).
    +
    See also
    NoteRequestResponseWithRetry if you need to work with the response.
    + +
    +
    + +

    ◆ NoteReset()

    + +
    +
    + + + + + + + + +
    bool NoteReset (void )
    +
    + +

    Initialize or re-initialize the module.

    +
    Returns
    True if the reset was successful and false if not.
    + +
    +
    + +

    ◆ NoteResetRequired()

    + +
    +
    + + + + + + + + +
    void NoteResetRequired (void )
    +
    + +

    Mark that a reset will be required before doing further I/O on a given port.

    + +
    +
    + +

    ◆ NoteResumeTransactionDebug()

    + +
    +
    + + + + + + + + +
    void NoteResumeTransactionDebug (void )
    +
    + +

    Resume showing transaction details.

    + +
    +
    + +

    ◆ NoteSuspendTransactionDebug()

    + +
    +
    + + + + + + + + +
    void NoteSuspendTransactionDebug (void )
    +
    + +

    Suppress showing transaction details.

    + +
    +
    + +

    ◆ NoteTransaction()

    + +
    +
    + + + + + + + + +
    J* NoteTransaction (Jreq)
    +
    + +

    Send a request to the Notecard and return the response.

    +

    This function doesn't free the passed in request object. The caller is responsible for freeing it.

    +
    Parameters
    + + +
    reqPointer to a J request object.
    +
    +
    +
    Returns
    A J object with the response or NULL if there was an error sending the request.
    +
    See also
    NoteResponseError to check the response for errors.
    + +
    +
    + +

    ◆ noteTransactionShouldLock()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    J* noteTransactionShouldLock (Jreq,
    bool lockNotecard 
    )
    +
    + +

    Same as NoteTransaction, but takes an additional parameter that indicates if the Notecard should be locked.

    +
    Parameters
    + + + +
    reqThe J cJSON request object.
    lockNotecardSet to true if the Notecard should be locked and false otherwise.
    +
    +
    +
    Returns
    a J cJSON object with the response, or NULL if there is insufficient memory.
    + +
    +
    +
    + + + + diff --git a/doxygen/html/nav_f.png b/doxygen/html/nav_f.png new file mode 100644 index 00000000..72a58a52 Binary files /dev/null and b/doxygen/html/nav_f.png differ diff --git a/doxygen/html/nav_g.png b/doxygen/html/nav_g.png new file mode 100644 index 00000000..2093a237 Binary files /dev/null and b/doxygen/html/nav_g.png differ diff --git a/doxygen/html/nav_h.png b/doxygen/html/nav_h.png new file mode 100644 index 00000000..33389b10 Binary files /dev/null and b/doxygen/html/nav_h.png differ diff --git a/doxygen/html/note_8h.html b/doxygen/html/note_8h.html new file mode 100644 index 00000000..d7dc02f2 --- /dev/null +++ b/doxygen/html/note_8h.html @@ -0,0 +1,6875 @@ + + + + + + + +note-c: /home/runner/work/note-c/note-c/note.h File Reference + + + + + + + + + +
    +
    + + + + + + + +
    +
    note-c +  1.0 +
    +
    An easy to use Notecard Library for C/C++
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + +
    +
    + +
    +
    /home/runner/work/note-c/note-c/note.h File Reference
    +
    +
    +
    #include <float.h>
    +#include <limits.h>
    +#include <stdbool.h>
    +#include <stdint.h>
    +#include "n_cjson.h"
    +
    +

    Go to the source code of this file.

    + + + + + + +

    +Data Structures

    struct  NoteMD5Context
     
    struct  NotePayloadDesc
     
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

    +Macros

    #define _NOTE_C_STRINGIZE(x)   #x
     
    #define NOTE_C_STRINGIZE(x)   _NOTE_C_STRINGIZE(x)
     
    #define NOTE_C_VERSION_MAJOR   2
     
    #define NOTE_C_VERSION_MINOR   2
     
    #define NOTE_C_VERSION_PATCH   1
     
    #define NOTE_C_VERSION   NOTE_C_STRINGIZE(NOTE_C_VERSION_MAJOR) "." NOTE_C_STRINGIZE(NOTE_C_VERSION_MINOR) "." NOTE_C_STRINGIZE(NOTE_C_VERSION_PATCH)
     
    #define ERRSTR(x, y)   (x)
     
    #define JINTEGER_MIN   INT64_MIN
     
    #define JINTEGER_MAX   INT64_MAX
     
    #define NoteNewBody   JCreateObject
     
    #define NoteAddBodyToObject(a, b)   JAddItemToObject(a, "body", b)
     
    #define NoteGetBody(a)   JGetObject(a, "body")
     
    #define SYNCSTATUS_LEVEL_MAJOR   0
     
    #define SYNCSTATUS_LEVEL_MINOR   1
     
    #define SYNCSTATUS_LEVEL_DETAILED   2
     
    #define SYNCSTATUS_LEVEL_ALGORITHMIC   3
     
    #define SYNCSTATUS_LEVEL_ALL   -1
     
    #define NoteResponseError(rsp)   (!JIsNullString(rsp, "err"))
     Check if the Notecard response contains an error. More...
     
    #define NoteResponseErrorContains(rsp, errstr)   (JContainsString(rsp, "err", errstr))
     
    #define NoteDeleteResponse(rsp)   JDelete(rsp)
     Free a response from the Notecard. More...
     
    #define NOTE_I2C_ADDR_DEFAULT   0x17
     The default I2C address of the Notecard. More...
     
    #define NOTE_I2C_HEADER_SIZE   2
     
    #define NOTE_I2C_MAX_MAX   (UCHAR_MAX - NOTE_I2C_HEADER_SIZE)
     
    #define NOTE_I2C_MAX_DEFAULT   30
     The maximum number of bytes to request from or transmit to the Notecard in a single chunk. More...
     
    #define NOTE_C_LOG_LEVEL_ERROR   0
     
    #define NOTE_C_LOG_LEVEL_WARN   1
     
    #define NOTE_C_LOG_LEVEL_INFO   2
     
    #define NOTE_C_LOG_LEVEL_DEBUG   3
     
    #define NOTE_C_LOG_FILE_AND_LINE(lvl)
     
    #define NOTE_C_LOG_ERROR(msg)
     
    #define NOTE_C_LOG_WARN(msg)
     
    #define NOTE_C_LOG_INFO(msg)
     
    #define NOTE_C_LOG_DEBUG(msg)
     
    #define NOTE_C_LOG_LEVEL   NOTE_C_LOG_LEVEL_INFO
     
    #define JTYPE_NOT_PRESENT   0
     
    #define JTYPE_BOOL_TRUE   1
     
    #define JTYPE_BOOL_FALSE   2
     
    #define JTYPE_BOOL   JTYPE_BOOL_TRUE
     
    #define JTYPE_NULL   3
     
    #define JTYPE_NUMBER_ZERO   4
     
    #define JTYPE_NUMBER   5
     
    #define JTYPE_STRING_BLANK   6
     
    #define JTYPE_STRING_ZERO   7
     
    #define JTYPE_STRING_NUMBER   8
     
    #define JTYPE_STRING_BOOL_TRUE   9
     
    #define JTYPE_STRING_BOOL_FALSE   10
     
    #define JTYPE_STRING   11
     
    #define JTYPE_OBJECT   12
     
    #define JTYPE_ARRAY   13
     
    #define JGetObjectItemName(j)   (j->string)
     
    #define JNTOA_PRECISION   (16)
     
    #define JNTOA_MAX   (44)
     
    #define NOTE_MD5_HASH_SIZE   16
     
    #define NOTE_MD5_HASH_STRING_SIZE   (((NOTE_MD5_HASH_SIZE)*2)+1)
     
    #define NoteSend   NoteAdd
     
    #define NP_SEGTYPE_LEN   4
     
    #define NP_SEGLEN_LEN   sizeof(uint32_t)
     
    #define NP_SEGHDR_LEN   (NP_SEGTYPE_LEN + NP_SEGLEN_LEN)
     
    #define TBOOL   true
     
    #define TINT8   11
     
    #define TINT16   12
     
    #define TINT24   13
     
    #define TINT32   14
     
    #define TINT64   18
     
    #define TUINT8   21
     
    #define TUINT16   22
     
    #define TUINT24   23
     
    #define TUINT32   24
     
    #define TFLOAT16   12.1
     
    #define TFLOAT32   14.1
     
    #define TFLOAT64   18.1
     
    #define TSTRING(N)   _NOTE_C_STRINGIZE(N)
     
    #define TSTRINGV   _NOTE_C_STRINGIZE(0)
     
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

    +Typedefs

    typedef double JNUMBER
     The floating point type used for JSON handling in note-c. More...
     
    typedef int64_t JINTEGER
     The signed integer type used for JSON handling in note-c. More...
     
    typedef uint64_t JUINTEGER
     The unsigned integer type used for JSON handling in note-c. More...
     
    typedef JUINTEGER JTIME
     
    typedef void(* mutexFn) (void)
     The type for the various mutex (i.e. lock/unlock) hooks. More...
     
    typedef void *(* mallocFn) (size_t size)
     The type for the memory allocation hook. More...
     
    typedef void(* freeFn) (void *mem)
     The type for the memory freeing hook. More...
     
    typedef void(* delayMsFn) (uint32_t ms)
     The type for the millisecond delay hook. More...
     
    typedef uint32_t(* getMsFn) (void)
     The type for the millisecond counter hook. More...
     
    typedef size_t(* debugOutputFn) (const char *text)
     
    typedef bool(* serialResetFn) (void)
     The type for the serial reset hook. More...
     
    typedef void(* serialTransmitFn) (uint8_t *txBuf, size_t txBufSize, bool flush)
     The type for the serial transmit hook. More...
     
    typedef bool(* serialAvailableFn) (void)
     The type for the serial available hook. More...
     
    typedef char(* serialReceiveFn) (void)
     The type for the serial receive hook. More...
     
    typedef bool(* i2cResetFn) (uint16_t address)
     The type for the I2C reset hook. More...
     
    typedef const char *(* i2cTransmitFn) (uint16_t address, uint8_t *txBuf, uint16_t txBufSize)
     The type for the I2C transmit hook. More...
     
    typedef const char *(* i2cReceiveFn) (uint16_t address, uint8_t *rxBuf, uint16_t rxBufSize, uint32_t *available)
     The type for the I2C receive hook. More...
     
    typedef bool(* txnStartFn) (uint32_t timeoutMs)
     
    typedef void(* txnStopFn) (void)
     
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

    +Functions

    bool NoteReset (void)
     Initialize or re-initialize the module. More...
     
    void NoteResetRequired (void)
     Mark that a reset will be required before doing further I/O on a given port. More...
     
    JNoteNewRequest (const char *request)
     Create a new JSON request. More...
     
    JNoteNewCommand (const char *request)
     Create a new JSON command. More...
     
    JNoteRequestResponse (J *req)
     Send a request to the Notecard and return the response. More...
     
    JNoteRequestResponseWithRetry (J *req, uint32_t timeoutSeconds)
     Send a request to the Notecard, retrying it until it succeeds or it times out, and return the response. More...
     
    char * NoteRequestResponseJSON (const char *reqJSON)
     Send a request to the Notecard and return the response. More...
     
    void NoteSuspendTransactionDebug (void)
     Suppress showing transaction details. More...
     
    void NoteResumeTransactionDebug (void)
     Resume showing transaction details. More...
     
    bool NoteDebugSyncStatus (int pollFrequencyMs, int maxLevel)
     
    bool NoteRequest (J *req)
     Send a request to the Notecard. More...
     
    bool NoteRequestWithRetry (J *req, uint32_t timeoutSeconds)
     Send a request to the Notecard, retrying it until it succeeds or it times out. More...
     
    JNoteTransaction (J *req)
     Send a request to the Notecard and return the response. More...
     
    bool NoteErrorContains (const char *errstr, const char *errtype)
     Check to see if a Notecard error is present in a JSON string. More...
     
    void NoteErrorClean (char *errbuf)
     Clean error strings out of the specified buffer. More...
     
    void NoteSetFnDebugOutput (debugOutputFn fn)
     Set the platform-specific debug output function. More...
     
    void NoteSetFnTransaction (txnStartFn startFn, txnStopFn stopFn)
     Set the platform-specific transaction initiation/completion fn's. More...
     
    void NoteSetFnMutex (mutexFn lockI2Cfn, mutexFn unlockI2Cfn, mutexFn lockNotefn, mutexFn unlockNotefn)
     Set the platform-specific mutex functions for I2C and the Notecard. More...
     
    void NoteSetFnI2CMutex (mutexFn lockI2Cfn, mutexFn unlockI2Cfn)
     Set the platform-specific mutex functions for I2C. More...
     
    void NoteSetFnNoteMutex (mutexFn lockFn, mutexFn unlockFn)
     Set the platform-specific mutex functions for the Notecard. More...
     
    void NoteSetFnDefault (mallocFn mallocfn, freeFn freefn, delayMsFn delayfn, getMsFn millisfn)
     Set the default memory and timing hooks if they aren't already set. More...
     
    void NoteSetFn (mallocFn mallocHook, freeFn freeHook, delayMsFn delayMsHook, getMsFn getMsHook)
     Set the platform-specific memory and timing hooks. More...
     
    void NoteSetFnSerial (serialResetFn resetFn, serialTransmitFn transmitFn, serialAvailableFn availFn, serialReceiveFn receiveFn)
     Set the platform-specific hooks for communicating with the Notecard over serial. More...
     
    void NoteSetFnI2C (uint32_t notecardAddr, uint32_t maxTransmitSize, i2cResetFn resetFn, i2cTransmitFn transmitFn, i2cReceiveFn receiveFn)
     Set the platform-specific hooks for communicating with the Notecard over I2C, as well as the I2C address of the Notecard and maximum transmission size. More...
     
    void NoteSetFnDisabled (void)
     Set the platform-specific communications method to be disabled. More...
     
    void NoteSetI2CAddress (uint32_t i2caddress)
     Set the I2C address for communication with the Notecard. More...
     
    JNoteUserAgent (void)
     
    void NoteUserAgentUpdate (J *ua)
     
    void NoteSetUserAgent (char *agent)
     
    void NoteSetUserAgentOS (char *os_name, char *os_platform, char *os_family, char *os_version)
     
    void NoteSetUserAgentCPU (int cpu_mem, int cpu_mhz, int cpu_cores, char *cpu_vendor, char *cpu_name)
     
    void NoteDebug (const char *message)
     Write to the debug stream. More...
     
    void NoteDebugln (const char *message)
     Write text to the debug stream and output a newline. More...
     
    void NoteDebugIntln (const char *message, int n)
     Write a number to the debug stream and output a newline. More...
     
    void NoteDebugf (const char *format,...)
     
    void NoteDebugWithLevel (uint8_t level, const char *msg)
     Write the message to the debug stream, if the level is less than or equal to NOTE_C_LOG_LEVEL. Otherwise, the message is dropped. More...
     
    void NoteDebugWithLevelLn (uint8_t level, const char *msg)
     Same as NoteDebugWithLevel, but add a newline at the end. More...
     
    void * NoteMalloc (size_t size)
     Allocate a memory chunk using the platform-specific hook. More...
     
    void NoteFree (void *)
     Free memory using the platform-specific hook. More...
     
    uint32_t NoteGetMs (void)
     Get the current milliseconds value from the platform-specific hook. More...
     
    void NoteDelayMs (uint32_t ms)
     Delay milliseconds using the platform-specific hook. More...
     
    void NoteLockI2C (void)
     Lock the I2C bus using the platform-specific hook. More...
     
    void NoteUnlockI2C (void)
     Unlock the I2C bus using the platform-specific hook. More...
     
    uint32_t NoteI2CAddress (void)
     Get the I2C address of the Notecard. More...
     
    uint32_t NoteI2CMax (void)
     Determine the maximum number of bytes for each segment of data sent to the Notecard over I2C. More...
     
    uint32_t NoteMemAvailable (void)
     
    bool NotePrint (const char *text)
     
    void NotePrintln (const char *line)
     
    bool NotePrintf (const char *format,...)
     
    size_t strlcpy (char *dst, const char *src, size_t siz)
     
    size_t strlcat (char *dst, const char *src, size_t siz)
     
    void JInit (void)
     
    void JCheck (void)
     
    bool JIsPresent (J *json, const char *field)
     Determine if a field is present in a JSON object. More...
     
    char * JGetString (J *json, const char *field)
     Get the value of a string field from a JSON object. More...
     
    JNUMBER JGetNumber (J *json, const char *field)
     Get the floating point value of a number field from a JSON object. More...
     
    JJGetArray (J *json, const char *field)
     Get the value of an array field from a JSON object. More...
     
    JJGetObject (J *json, const char *field)
     Get the value of an object field from a JSON object. More...
     
    JINTEGER JGetInt (J *json, const char *field)
     Get the integer value of a number field from a JSON object. More...
     
    bool JGetBool (J *json, const char *field)
     Get the value of a boolean field from a JSON object. More...
     
    JNUMBER JNumberValue (J *item)
     Return the number representation of an item. More...
     
    char * JStringValue (J *item)
     Return the string representation of an item. More...
     
    bool JBoolValue (J *item)
     Return the boolean representation of an item. More...
     
    JINTEGER JIntValue (J *item)
     Return the integer representation of an item. More...
     
    bool JIsNullString (J *json, const char *field)
     Determine if a JSON object is valid and if a field is not present, or null. More...
     
    bool JIsExactString (J *json, const char *field, const char *teststr)
     Determine if a field exists, is a string and matches a provided value. More...
     
    bool JContainsString (J *json, const char *field, const char *substr)
     Determine if a field exists, is a string and contains a provided value. More...
     
    bool JAddBinaryToObject (J *json, const char *fieldName, const void *binaryData, uint32_t binaryDataLen)
     Add binary data as a Base64-encoded string field to a JSON object. More...
     
    bool JGetBinaryFromObject (J *json, const char *fieldName, uint8_t **retBinaryData, uint32_t *retBinaryDataLen)
     Decode a Base64-encoded string field in a JSON object and return the decoded bytes. More...
     
    const char * JGetItemName (const J *item)
     Get the object name. More...
     
    char * JAllocString (uint8_t *buffer, uint32_t len)
     Convert a buffer/len to a null-terminated c-string. More...
     
    const char * JType (J *item)
     Return the type of an item, as a string. More...
     
    int JGetType (J *json, const char *field)
     Get the type of a field, as an int usable in a switch statement. More...
     
    int JGetItemType (J *item)
     
    int JBaseItemType (int type)
     
    char * JNtoA (JNUMBER f, char *buf, int precision)
     
    JNUMBER JAtoN (const char *string, char **endPtr)
     
    void JItoA (JINTEGER n, char *s)
     Convert an integer to text. More...
     
    JINTEGER JAtoI (const char *s)
     Convert text to an integer. More...
     
    int JB64EncodeLen (int len)
     
    int JB64Encode (char *coded_dst, const char *plain_src, int len_plain_src)
     
    int JB64DecodeLen (const char *coded_src)
     
    int JB64Decode (char *plain_dst, const char *coded_src)
     
    void NoteMD5Init (NoteMD5Context *ctx)
     
    void NoteMD5Update (NoteMD5Context *ctx, unsigned char const *buf, unsigned long len)
     
    void NoteMD5Final (unsigned char *digest, NoteMD5Context *ctx)
     
    void NoteMD5Transform (unsigned long buf[4], const unsigned char inraw[64])
     
    void NoteMD5Hash (unsigned char *data, unsigned long len, unsigned char *retHash)
     
    void NoteMD5HashString (unsigned char *data, unsigned long len, char *strbuf, unsigned long buflen)
     
    void NoteMD5HashToString (unsigned char *hash, char *strbuf, unsigned long buflen)
     
    uint32_t NoteBinaryCodecDecode (const uint8_t *encData, uint32_t encDataLen, uint8_t *decBuf, uint32_t decBufSize)
     
    uint32_t NoteBinaryCodecEncode (const uint8_t *decData, uint32_t decDataLen, uint8_t *encBuf, uint32_t encBufSize)
     
    uint32_t NoteBinaryCodecMaxDecodedLength (uint32_t bufferSize)
     
    uint32_t NoteBinaryCodecMaxEncodedLength (uint32_t unencodedLength)
     
    const char * NoteBinaryStoreDecodedLength (uint32_t *len)
     
    const char * NoteBinaryStoreEncodedLength (uint32_t *len)
     
    const char * NoteBinaryStoreReceive (uint8_t *buffer, uint32_t bufLen, uint32_t decodedOffset, uint32_t decodedLen)
     
    const char * NoteBinaryStoreReset (void)
     
    const char * NoteBinaryStoreTransmit (uint8_t *unencodedData, uint32_t unencodedLen, uint32_t bufLen, uint32_t notecardOffset)
     
    uint32_t NoteSetSTSecs (uint32_t secs)
     
    bool NoteTimeValid (void)
     
    bool NoteTimeValidST (void)
     
    JTIME NoteTime (void)
     
    JTIME NoteTimeST (void)
     
    void NoteTimeRefreshMins (uint32_t mins)
     
    void NoteTimeSet (JTIME secondsUTC, int offset, char *zone, char *country, char *area)
     
    bool NoteLocalTimeST (uint16_t *retYear, uint8_t *retMonth, uint8_t *retDay, uint8_t *retHour, uint8_t *retMinute, uint8_t *retSecond, char **retWeekday, char **retZone)
     
    bool NoteRegion (char **retCountry, char **retArea, char **retZone, int *retZoneOffset)
     
    bool NoteLocationValid (char *errbuf, uint32_t errbuflen)
     
    bool NoteLocationValidST (char *errbuf, uint32_t errbuflen)
     
    void NoteTurboIO (bool enable)
     
    JINTEGER NoteGetEnvInt (const char *variable, JINTEGER defaultVal)
     
    JNUMBER NoteGetEnvNumber (const char *variable, JNUMBER defaultVal)
     
    bool NoteGetEnv (const char *variable, const char *defaultVal, char *buf, uint32_t buflen)
     
    bool NoteSetEnvDefault (const char *variable, char *buf)
     
    bool NoteSetEnvDefaultNumber (const char *variable, JNUMBER defaultVal)
     
    bool NoteSetEnvDefaultInt (const char *variable, JINTEGER defaultVal)
     
    bool NoteIsConnected (void)
     
    bool NoteIsConnectedST (void)
     
    bool NoteGetNetStatus (char *statusBuf, int statusBufLen)
     
    bool NoteGetVersion (char *versionBuf, int versionBufLen)
     
    bool NoteGetLocation (JNUMBER *retLat, JNUMBER *retLon, JTIME *time, char *statusBuf, int statusBufLen)
     
    bool NoteSetLocation (JNUMBER lat, JNUMBER lon)
     
    bool NoteClearLocation (void)
     
    bool NoteGetLocationMode (char *modeBuf, int modeBufLen)
     
    bool NoteSetLocationMode (const char *mode, uint32_t seconds)
     
    bool NoteGetServiceConfig (char *productBuf, int productBufLen, char *serviceBuf, int serviceBufLen, char *deviceBuf, int deviceBufLen, char *snBuf, int snBufLen)
     
    bool NoteGetServiceConfigST (char *productBuf, int productBufLen, char *serviceBuf, int serviceBufLen, char *deviceBuf, int deviceBufLen, char *snBuf, int snBufLen)
     
    bool NoteGetStatus (char *statusBuf, int statusBufLen, JTIME *bootTime, bool *retUSB, bool *retSignals)
     
    bool NoteGetStatusST (char *statusBuf, int statusBufLen, JTIME *bootTime, bool *retUSB, bool *retSignals)
     
    bool NoteSleep (char *stateb64, uint32_t seconds, const char *modes)
     
    bool NoteWake (int stateLen, void *state)
     
    bool NoteFactoryReset (bool deleteConfigSettings)
     
    bool NoteSetSerialNumber (const char *sn)
     
    bool NoteSetProductID (const char *productID)
     
    bool NoteSetUploadMode (const char *uploadMode, int uploadMinutes, bool align)
     
    bool NoteSetSyncMode (const char *uploadMode, int uploadMinutes, int downloadMinutes, bool align, bool sync)
     
    bool NoteAdd (const char *target, J *body, bool urgent)
     
    bool NoteSendToRoute (const char *method, const char *routeAlias, char *notefile, J *body)
     
    bool NoteGetVoltage (JNUMBER *voltage)
     
    bool NoteGetTemperature (JNUMBER *temp)
     
    bool NoteGetContact (char *nameBuf, int nameBufLen, char *orgBuf, int orgBufLen, char *roleBuf, int roleBufLen, char *emailBuf, int emailBufLen)
     
    bool NoteSetContact (char *nameBuf, char *orgBuf, char *roleBuf, char *emailBuf)
     
    bool NotePayloadSaveAndSleep (NotePayloadDesc *desc, uint32_t seconds, const char *modes)
     
    bool NotePayloadRetrieveAfterSleep (NotePayloadDesc *desc)
     
    void NotePayloadSet (NotePayloadDesc *desc, uint8_t *buf, uint32_t buflen)
     
    void NotePayloadFree (NotePayloadDesc *desc)
     
    bool NotePayloadAddSegment (NotePayloadDesc *desc, const char segtype[NP_SEGTYPE_LEN], void *pdata, uint32_t plen)
     
    bool NotePayloadFindSegment (NotePayloadDesc *desc, const char segtype[NP_SEGTYPE_LEN], void *pdata, uint32_t *plen)
     
    bool NotePayloadGetSegment (NotePayloadDesc *desc, const char segtype[NP_SEGTYPE_LEN], void *pdata, uint32_t len)
     
    bool NoteTemplate (const char *notefileID, J *templateBody)
     
    +

    Detailed Description

    +

    Written by Ray Ozzie and Blues Inc. team.

    +

    Copyright (c) 2019 Blues Inc. MIT License. Use of this source code is governed by licenses granted by the copyright holder including that found in the LICENSE file.

    +

    This library bundles the cJSON JSON parser library.

    +

    Macro Definition Documentation

    + +

    ◆ _NOTE_C_STRINGIZE

    + +
    +
    + + + + + + + + +
    #define _NOTE_C_STRINGIZE( x)   #x
    +
    + +
    +
    + +

    ◆ ERRSTR

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    #define ERRSTR( x,
     
    )   (x)
    +
    + +
    +
    + +

    ◆ JGetObjectItemName

    + +
    +
    + + + + + + + + +
    #define JGetObjectItemName( j)   (j->string)
    +
    + +
    +
    + +

    ◆ JINTEGER_MAX

    + +
    +
    + + + + +
    #define JINTEGER_MAX   INT64_MAX
    +
    + +
    +
    + +

    ◆ JINTEGER_MIN

    + +
    +
    + + + + +
    #define JINTEGER_MIN   INT64_MIN
    +
    + +
    +
    + +

    ◆ JNTOA_MAX

    + +
    +
    + + + + +
    #define JNTOA_MAX   (44)
    +
    + +
    +
    + +

    ◆ JNTOA_PRECISION

    + +
    +
    + + + + +
    #define JNTOA_PRECISION   (16)
    +
    + +
    +
    + +

    ◆ JTYPE_ARRAY

    + +
    +
    + + + + +
    #define JTYPE_ARRAY   13
    +
    + +
    +
    + +

    ◆ JTYPE_BOOL

    + +
    +
    + + + + +
    #define JTYPE_BOOL   JTYPE_BOOL_TRUE
    +
    + +
    +
    + +

    ◆ JTYPE_BOOL_FALSE

    + +
    +
    + + + + +
    #define JTYPE_BOOL_FALSE   2
    +
    + +
    +
    + +

    ◆ JTYPE_BOOL_TRUE

    + +
    +
    + + + + +
    #define JTYPE_BOOL_TRUE   1
    +
    + +
    +
    + +

    ◆ JTYPE_NOT_PRESENT

    + +
    +
    + + + + +
    #define JTYPE_NOT_PRESENT   0
    +
    + +
    +
    + +

    ◆ JTYPE_NULL

    + +
    +
    + + + + +
    #define JTYPE_NULL   3
    +
    + +
    +
    + +

    ◆ JTYPE_NUMBER

    + +
    +
    + + + + +
    #define JTYPE_NUMBER   5
    +
    + +
    +
    + +

    ◆ JTYPE_NUMBER_ZERO

    + +
    +
    + + + + +
    #define JTYPE_NUMBER_ZERO   4
    +
    + +
    +
    + +

    ◆ JTYPE_OBJECT

    + +
    +
    + + + + +
    #define JTYPE_OBJECT   12
    +
    + +
    +
    + +

    ◆ JTYPE_STRING

    + +
    +
    + + + + +
    #define JTYPE_STRING   11
    +
    + +
    +
    + +

    ◆ JTYPE_STRING_BLANK

    + +
    +
    + + + + +
    #define JTYPE_STRING_BLANK   6
    +
    + +
    +
    + +

    ◆ JTYPE_STRING_BOOL_FALSE

    + +
    +
    + + + + +
    #define JTYPE_STRING_BOOL_FALSE   10
    +
    + +
    +
    + +

    ◆ JTYPE_STRING_BOOL_TRUE

    + +
    +
    + + + + +
    #define JTYPE_STRING_BOOL_TRUE   9
    +
    + +
    +
    + +

    ◆ JTYPE_STRING_NUMBER

    + +
    +
    + + + + +
    #define JTYPE_STRING_NUMBER   8
    +
    + +
    +
    + +

    ◆ JTYPE_STRING_ZERO

    + +
    +
    + + + + +
    #define JTYPE_STRING_ZERO   7
    +
    + +
    +
    + +

    ◆ NOTE_C_LOG_DEBUG

    + +
    +
    + + + + + + + + +
    #define NOTE_C_LOG_DEBUG( msg)
    +
    +Value:
    do { \
    +
    NOTE_C_LOG_FILE_AND_LINE(NOTE_C_LOG_LEVEL_DEBUG); \
    +
    NoteDebugWithLevel(NOTE_C_LOG_LEVEL_DEBUG, "[DEBUG] "); \
    +
    NoteDebugWithLevelLn(NOTE_C_LOG_LEVEL_DEBUG, msg); \
    +
    } while (0);
    +
    #define NOTE_C_LOG_LEVEL_DEBUG
    Definition: note.h:336
    +
    +
    +
    + +

    ◆ NOTE_C_LOG_ERROR

    + +
    +
    + + + + + + + + +
    #define NOTE_C_LOG_ERROR( msg)
    +
    +Value:
    do { \
    +
    NOTE_C_LOG_FILE_AND_LINE(NOTE_C_LOG_LEVEL_ERROR); \
    +
    NoteDebugWithLevel(NOTE_C_LOG_LEVEL_ERROR, "[ERROR] "); \
    +
    NoteDebugWithLevelLn(NOTE_C_LOG_LEVEL_ERROR, msg); \
    +
    } while (0);
    +
    #define NOTE_C_LOG_LEVEL_ERROR
    Definition: note.h:333
    +
    +
    +
    + +

    ◆ NOTE_C_LOG_FILE_AND_LINE

    + +
    +
    + + + + + + + + +
    #define NOTE_C_LOG_FILE_AND_LINE( lvl)
    +
    + +
    +
    + +

    ◆ NOTE_C_LOG_INFO

    + +
    +
    + + + + + + + + +
    #define NOTE_C_LOG_INFO( msg)
    +
    +Value:
    do { \
    +
    NOTE_C_LOG_FILE_AND_LINE(NOTE_C_LOG_LEVEL_INFO); \
    +
    NoteDebugWithLevel(NOTE_C_LOG_LEVEL_INFO, "[INFO] "); \
    +
    NoteDebugWithLevelLn(NOTE_C_LOG_LEVEL_INFO, msg); \
    +
    } while (0);
    +
    #define NOTE_C_LOG_LEVEL_INFO
    Definition: note.h:335
    +
    +
    +
    + +

    ◆ NOTE_C_LOG_LEVEL

    + +
    +
    + + + + +
    #define NOTE_C_LOG_LEVEL   NOTE_C_LOG_LEVEL_INFO
    +
    + +
    +
    + +

    ◆ NOTE_C_LOG_LEVEL_DEBUG

    + +
    +
    + + + + +
    #define NOTE_C_LOG_LEVEL_DEBUG   3
    +
    + +
    +
    + +

    ◆ NOTE_C_LOG_LEVEL_ERROR

    + +
    +
    + + + + +
    #define NOTE_C_LOG_LEVEL_ERROR   0
    +
    + +
    +
    + +

    ◆ NOTE_C_LOG_LEVEL_INFO

    + +
    +
    + + + + +
    #define NOTE_C_LOG_LEVEL_INFO   2
    +
    + +
    +
    + +

    ◆ NOTE_C_LOG_LEVEL_WARN

    + +
    +
    + + + + +
    #define NOTE_C_LOG_LEVEL_WARN   1
    +
    + +
    +
    + +

    ◆ NOTE_C_LOG_WARN

    + +
    +
    + + + + + + + + +
    #define NOTE_C_LOG_WARN( msg)
    +
    +Value:
    do { \
    +
    NOTE_C_LOG_FILE_AND_LINE(NOTE_C_LOG_LEVEL_WARN); \
    +
    NoteDebugWithLevel(NOTE_C_LOG_LEVEL_WARN, "[WARN] "); \
    +
    NoteDebugWithLevelLn(NOTE_C_LOG_LEVEL_WARN, msg); \
    +
    } while (0);
    +
    #define NOTE_C_LOG_LEVEL_WARN
    Definition: note.h:334
    +
    +
    +
    + +

    ◆ NOTE_C_STRINGIZE

    + +
    +
    + + + + + + + + +
    #define NOTE_C_STRINGIZE( x)   _NOTE_C_STRINGIZE(x)
    +
    + +
    +
    + +

    ◆ NOTE_C_VERSION

    + + + +

    ◆ NOTE_C_VERSION_MAJOR

    + +
    +
    + + + + +
    #define NOTE_C_VERSION_MAJOR   2
    +
    + +
    +
    + +

    ◆ NOTE_C_VERSION_MINOR

    + +
    +
    + + + + +
    #define NOTE_C_VERSION_MINOR   2
    +
    + +
    +
    + +

    ◆ NOTE_C_VERSION_PATCH

    + +
    +
    + + + + +
    #define NOTE_C_VERSION_PATCH   1
    +
    + +
    +
    + +

    ◆ NOTE_I2C_ADDR_DEFAULT

    + +
    +
    + + + + +
    #define NOTE_I2C_ADDR_DEFAULT   0x17
    +
    + +

    The default I2C address of the Notecard.

    + +
    +
    + +

    ◆ NOTE_I2C_HEADER_SIZE

    + +
    +
    + + + + +
    #define NOTE_I2C_HEADER_SIZE   2
    +
    + +
    +
    + +

    ◆ NOTE_I2C_MAX_DEFAULT

    + +
    +
    + + + + +
    #define NOTE_I2C_MAX_DEFAULT   30
    +
    + +

    The maximum number of bytes to request from or transmit to the Notecard in a single chunk.

    + +
    +
    + +

    ◆ NOTE_I2C_MAX_MAX

    + +
    +
    + + + + +
    #define NOTE_I2C_MAX_MAX   (UCHAR_MAX - NOTE_I2C_HEADER_SIZE)
    +
    + +
    +
    + +

    ◆ NOTE_MD5_HASH_SIZE

    + +
    +
    + + + + +
    #define NOTE_MD5_HASH_SIZE   16
    +
    + +
    +
    + +

    ◆ NOTE_MD5_HASH_STRING_SIZE

    + +
    +
    + + + + +
    #define NOTE_MD5_HASH_STRING_SIZE   (((NOTE_MD5_HASH_SIZE)*2)+1)
    +
    + +
    +
    + +

    ◆ NoteAddBodyToObject

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    #define NoteAddBodyToObject( a,
     
    )   JAddItemToObject(a, "body", b)
    +
    + +
    +
    + +

    ◆ NoteDeleteResponse

    + +
    +
    + + + + + + + + +
    #define NoteDeleteResponse( rsp)   JDelete(rsp)
    +
    + +

    Free a response from the Notecard.

    +
    Parameters
    + + +
    rspThe response to free.
    +
    +
    + +
    +
    + +

    ◆ NoteGetBody

    + +
    +
    + + + + + + + + +
    #define NoteGetBody( a)   JGetObject(a, "body")
    +
    + +
    +
    + +

    ◆ NoteNewBody

    + +
    +
    + + + + +
    #define NoteNewBody   JCreateObject
    +
    + +
    +
    + +

    ◆ NoteResponseError

    + +
    +
    + + + + + + + + +
    #define NoteResponseError( rsp)   (!JIsNullString(rsp, "err"))
    +
    + +

    Check if the Notecard response contains an error.

    +
    Parameters
    + + +
    rspThe response to check.
    +
    +
    +
    Returns
    true if there's an error and false if there's not.
    + +
    +
    + +

    ◆ NoteResponseErrorContains

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    #define NoteResponseErrorContains( rsp,
     errstr 
    )   (JContainsString(rsp, "err", errstr))
    +
    + +
    +
    + +

    ◆ NoteSend

    + +
    +
    + + + + +
    #define NoteSend   NoteAdd
    +
    + +
    +
    + +

    ◆ NP_SEGHDR_LEN

    + +
    +
    + + + + +
    #define NP_SEGHDR_LEN   (NP_SEGTYPE_LEN + NP_SEGLEN_LEN)
    +
    + +
    +
    + +

    ◆ NP_SEGLEN_LEN

    + +
    +
    + + + + +
    #define NP_SEGLEN_LEN   sizeof(uint32_t)
    +
    + +
    +
    + +

    ◆ NP_SEGTYPE_LEN

    + +
    +
    + + + + +
    #define NP_SEGTYPE_LEN   4
    +
    + +
    +
    + +

    ◆ SYNCSTATUS_LEVEL_ALGORITHMIC

    + +
    +
    + + + + +
    #define SYNCSTATUS_LEVEL_ALGORITHMIC   3
    +
    + +
    +
    + +

    ◆ SYNCSTATUS_LEVEL_ALL

    + +
    +
    + + + + +
    #define SYNCSTATUS_LEVEL_ALL   -1
    +
    + +
    +
    + +

    ◆ SYNCSTATUS_LEVEL_DETAILED

    + +
    +
    + + + + +
    #define SYNCSTATUS_LEVEL_DETAILED   2
    +
    + +
    +
    + +

    ◆ SYNCSTATUS_LEVEL_MAJOR

    + +
    +
    + + + + +
    #define SYNCSTATUS_LEVEL_MAJOR   0
    +
    + +
    +
    + +

    ◆ SYNCSTATUS_LEVEL_MINOR

    + +
    +
    + + + + +
    #define SYNCSTATUS_LEVEL_MINOR   1
    +
    + +
    +
    + +

    ◆ TBOOL

    + +
    +
    + + + + +
    #define TBOOL   true
    +
    + +
    +
    + +

    ◆ TFLOAT16

    + +
    +
    + + + + +
    #define TFLOAT16   12.1
    +
    + +
    +
    + +

    ◆ TFLOAT32

    + +
    +
    + + + + +
    #define TFLOAT32   14.1
    +
    + +
    +
    + +

    ◆ TFLOAT64

    + +
    +
    + + + + +
    #define TFLOAT64   18.1
    +
    + +
    +
    + +

    ◆ TINT16

    + +
    +
    + + + + +
    #define TINT16   12
    +
    + +
    +
    + +

    ◆ TINT24

    + +
    +
    + + + + +
    #define TINT24   13
    +
    + +
    +
    + +

    ◆ TINT32

    + +
    +
    + + + + +
    #define TINT32   14
    +
    + +
    +
    + +

    ◆ TINT64

    + +
    +
    + + + + +
    #define TINT64   18
    +
    + +
    +
    + +

    ◆ TINT8

    + +
    +
    + + + + +
    #define TINT8   11
    +
    + +
    +
    + +

    ◆ TSTRING

    + +
    +
    + + + + + + + + +
    #define TSTRING( N)   _NOTE_C_STRINGIZE(N)
    +
    + +
    +
    + +

    ◆ TSTRINGV

    + +
    +
    + + + + +
    #define TSTRINGV   _NOTE_C_STRINGIZE(0)
    +
    + +
    +
    + +

    ◆ TUINT16

    + +
    +
    + + + + +
    #define TUINT16   22
    +
    + +
    +
    + +

    ◆ TUINT24

    + +
    +
    + + + + +
    #define TUINT24   23
    +
    + +
    +
    + +

    ◆ TUINT32

    + +
    +
    + + + + +
    #define TUINT32   24
    +
    + +
    +
    + +

    ◆ TUINT8

    + +
    +
    + + + + +
    #define TUINT8   21
    +
    + +
    +
    +

    Typedef Documentation

    + +

    ◆ debugOutputFn

    + +
    +
    + + + + +
    typedef size_t(* debugOutputFn) (const char *text)
    +
    + +
    +
    + +

    ◆ delayMsFn

    + +
    +
    + + + + +
    delayMsFn
    +
    + +

    The type for the millisecond delay hook.

    +
    Parameters
    + + +
    msThe number of milliseconds to delay for.
    +
    +
    + +
    +
    + +

    ◆ freeFn

    + +
    +
    + + + + +
    freeFn
    +
    + +

    The type for the memory freeing hook.

    +
    Parameters
    + + +
    memPointer to the memory to free.
    +
    +
    + +
    +
    + +

    ◆ getMsFn

    + +
    +
    + + + + +
    getMsFn
    +
    + +

    The type for the millisecond counter hook.

    +
    Returns
    The value of the millisecond counter.
    + +
    +
    + +

    ◆ i2cReceiveFn

    + +
    +
    + + + + +
    i2cReceiveFn
    +
    + +

    The type for the I2C receive hook.

    +

    This hook is used to receive a buffer of bytes from the Notecard.

    +
    Parameters
    + + + + + +
    addressThe I2C address of the Notecard sending the data to receive.
    rxBufA buffer to hold the data received from the Notecard.
    rxBufSizeThe size, in bytes, of rxBuf.
    availableThe number of bytes remaining to be received, if any.
    +
    +
    +
    Returns
    NULL on success and an error string on failure.
    + +
    +
    + +

    ◆ i2cResetFn

    + +
    +
    + + + + +
    i2cResetFn
    +
    + +

    The type for the I2C reset hook.

    +

    This hook is used to reset the I2C peripheral used to communicate with the Notecard.

    +
    Parameters
    + + +
    addressThe I2C address of the Notecard.
    +
    +
    + +
    +
    + +

    ◆ i2cTransmitFn

    + +
    +
    + + + + +
    i2cTransmitFn
    +
    + +

    The type for the I2C transmit hook.

    +

    This hook is used to send a buffer of bytes to the Notecard.

    +
    Parameters
    + + + + +
    addressThe I2C address of the Notecard to transmit the data to.
    txBufA buffer of bytes to transmit to the Notecard.
    txBufSizeThe size, in bytes, of txBuf.
    +
    +
    +
    Returns
    NULL on success and an error string on failure.
    + +
    +
    + +

    ◆ JINTEGER

    + +
    +
    + + + + +
    typedef int64_t JINTEGER
    +
    + +

    The signed integer type used for JSON handling in note-c.

    + +
    +
    + +

    ◆ JNUMBER

    + +
    +
    + + + + +
    typedef double JNUMBER
    +
    + +

    The floating point type used for JSON handling in note-c.

    + +
    +
    + +

    ◆ JTIME

    + +
    +
    + + + + +
    typedef JUINTEGER JTIME
    +
    + +
    +
    + +

    ◆ JUINTEGER

    + +
    +
    + + + + +
    typedef uint64_t JUINTEGER
    +
    + +

    The unsigned integer type used for JSON handling in note-c.

    + +
    +
    + +

    ◆ mallocFn

    + +
    +
    + + + + +
    mallocFn
    +
    + +

    The type for the memory allocation hook.

    +
    Parameters
    + + +
    sizeThe number of bytes to allocate.
    +
    +
    +
    Returns
    A pointer to the newly allocated memory or NULL on failure.
    + +
    +
    + +

    ◆ mutexFn

    + +
    +
    + + + + +
    mutexFn
    +
    + +

    The type for the various mutex (i.e. lock/unlock) hooks.

    + +
    +
    + +

    ◆ serialAvailableFn

    + +
    +
    + + + + +
    serialAvailableFn
    +
    + +

    The type for the serial available hook.

    +
    Returns
    true if there's data to read and false otherwise.
    + +
    +
    + +

    ◆ serialReceiveFn

    + +
    +
    + + + + +
    serialReceiveFn
    +
    + +

    The type for the serial receive hook.

    +
    Returns
    The received byte.
    + +
    +
    + +

    ◆ serialResetFn

    + +
    +
    + + + + +
    serialResetFn
    +
    + +

    The type for the serial reset hook.

    +

    This hook is used to reset the serial peripheral used to communicate with the Notecard.

    +
    Returns
    true on success and false on failure.
    + +
    +
    + +

    ◆ serialTransmitFn

    + +
    +
    + + + + +
    serialTransmitFn
    +
    + +

    The type for the serial transmit hook.

    +
    Parameters
    + + + + +
    txBufA buffer of bytes to transmit to the Notecard.
    txBufSizeThe size, in bytes, of txBuf.
    flushIf true, flush the serial peripheral's transmit buffer.
    +
    +
    + +
    +
    + +

    ◆ txnStartFn

    + +
    +
    + + + + +
    typedef bool(* txnStartFn) (uint32_t timeoutMs)
    +
    + +
    +
    + +

    ◆ txnStopFn

    + +
    +
    + + + + +
    typedef void(* txnStopFn) (void)
    +
    + +
    +
    +

    Function Documentation

    + +

    ◆ JAddBinaryToObject()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    bool JAddBinaryToObject (Jjson,
    const char * fieldName,
    const void * binaryData,
    uint32_t binaryDataLen 
    )
    +
    + +

    Add binary data as a Base64-encoded string field to a JSON object.

    +
    Parameters
    + + + + + +
    jsonThe JSON object.
    fieldNameThe name to use for the field.
    binaryDataA buffer of binary data to encode.
    binaryDataLenThe length of the binary data in bytes.
    +
    +
    +
    Returns
    True if the string was successfully encoded and added to the object, otherwise false.
    + +
    +
    + +

    ◆ JAllocString()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    char* JAllocString (uint8_t * buffer,
    uint32_t len 
    )
    +
    + +

    Convert a buffer/len to a null-terminated c-string.

    +
    Parameters
    + + + +
    bufferA buffer containing the bytes to convert.
    lenThe length of buffer in bytes.
    +
    +
    +
    Returns
    If buffer is NULL or length 0, the empty string. If allocation fails, NULL. On success, the converted c-string. The returned string must be freed with NoteFree.
    + +
    +
    + +

    ◆ JAtoI()

    + +
    +
    + + + + + + + + +
    JINTEGER JAtoI (const char * string)
    +
    + +

    Convert text to an integer.

    +
    Parameters
    + + +
    stringA null-terminated text buffer
    +
    +
    +
    Returns
    An integer, or 0 if invalid
    + +
    +
    + +

    ◆ JAtoN()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    JNUMBER JAtoN (const char * string,
    char ** endPtr 
    )
    +
    + +
    +
    + +

    ◆ JB64Decode()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    int JB64Decode (char * plain_dst,
    const char * coded_src 
    )
    +
    + +
    +
    + +

    ◆ JB64DecodeLen()

    + +
    +
    + + + + + + + + +
    int JB64DecodeLen (const char * coded_src)
    +
    + +
    +
    + +

    ◆ JB64Encode()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    int JB64Encode (char * coded_dst,
    const char * plain_src,
    int len_plain_src 
    )
    +
    + +
    +
    + +

    ◆ JB64EncodeLen()

    + +
    +
    + + + + + + + + +
    int JB64EncodeLen (int len)
    +
    + +
    +
    + +

    ◆ JBaseItemType()

    + +
    +
    + + + + + + + + +
    int JBaseItemType (int type)
    +
    + +
    +
    + +

    ◆ JBoolValue()

    + +
    +
    + + + + + + + + +
    bool JBoolValue (Jitem)
    +
    + +

    Return the boolean representation of an item.

    +
    Parameters
    + + +
    itemThe JSON item.
    +
    +
    +
    Returns
    The boolean value.
    + +
    +
    + +

    ◆ JCheck()

    + +
    +
    + + + + + + + + +
    void JCheck (void )
    +
    + +
    +
    + +

    ◆ JContainsString()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    bool JContainsString (Jjson,
    const char * field,
    const char * substr 
    )
    +
    + +

    Determine if a field exists, is a string and contains a provided value.

    +
    Parameters
    + + + + +
    jsonThe JSON response object.
    fieldThe field to check.
    substrThe string to test against the returned value.
    +
    +
    +
    Returns
    bol. Whether the provided string is found within the field.
    + +
    +
    + +

    ◆ JGetArray()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    J* JGetArray (Jjson,
    const char * field 
    )
    +
    + +

    Get the value of an array field from a JSON object.

    +
    Parameters
    + + + +
    jsonThe JSON object.
    fieldThe array field to query.
    +
    +
    +
    Returns
    A pointer to the array, which is itself a JSON object (J *), if the field exists and is an array, otherwise NULL.
    +
    Note
    The returned JSON object is a pointer to the array contained in the parent JSON object. It is not a copy, so once the parent JSON object is freed, the pointer is no longer valid.
    + +
    +
    + +

    ◆ JGetBinaryFromObject()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    bool JGetBinaryFromObject (Jjson,
    const char * fieldName,
    uint8_t ** retBinaryData,
    uint32_t * retBinaryDataLen 
    )
    +
    + +

    Decode a Base64-encoded string field in a JSON object and return the decoded bytes.

    +
    Parameters
    + + + + + +
    jsonThe JSON object.
    fieldNameThe name of the field.
    retBinaryDataA pointer to a pointer, used to hold the pointer to the decoded bytes.
    retBinaryDataLenA pointer to an unsigned integer, used to hold the length of the decoded bytes.
    +
    +
    +
    Returns
    True if the string was successfully decoded and returned, otherwise false.
    +
    Note
    The returned binary buffer must be freed by the user with JFree when it is no longer needed.
    +
    +On error, the returned binary buffer and data length shall be set to NULL and zero (0), respectively.
    + +
    +
    + +

    ◆ JGetBool()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    bool JGetBool (Jjson,
    const char * field 
    )
    +
    + +

    Get the value of a boolean field from a JSON object.

    +
    Parameters
    + + + +
    jsonThe JSON object.
    fieldThe boolean field to query.
    +
    +
    +
    Returns
    The value of the boolean field if it exists and is a boolean, otherwise false.
    +
    See also
    JGetInt
    +
    +JGetNumber
    + +
    +
    + +

    ◆ JGetInt()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    JINTEGER JGetInt (Jjson,
    const char * field 
    )
    +
    + +

    Get the integer value of a number field from a JSON object.

    +
    Parameters
    + + + +
    jsonThe JSON object.
    fieldThe number field to query.
    +
    +
    +
    Returns
    The value of the number field if the field exists and is a number, otherwise 0.
    +
    Note
    The returned value is the integer representation of the number.
    +
    See also
    JGetBool
    +
    +JGetNumber
    + +
    +
    + +

    ◆ JGetItemName()

    + +
    +
    + + + + + + + + +
    const char* JGetItemName (const Jitem)
    +
    + +

    Get the object name.

    +
    Parameters
    + + +
    itemThe JSON object.
    +
    +
    +
    Returns
    The name, or the empty string, if NULL.
    + +
    +
    + +

    ◆ JGetItemType()

    + +
    +
    + + + + + + + + +
    int JGetItemType (Jitem)
    +
    + +
    +
    + +

    ◆ JGetNumber()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    JNUMBER JGetNumber (Jjson,
    const char * field 
    )
    +
    + +

    Get the floating point value of a number field from a JSON object.

    +
    Parameters
    + + + +
    jsonThe JSON object.
    fieldThe number field to query.
    +
    +
    +
    Returns
    The value of the number field if the field exists and is a number, otherwise 0.0.
    +
    Note
    The returned value is the floating point representation of the number.
    +
    See also
    JGetInt
    +
    +JGetBool
    + +
    +
    + +

    ◆ JGetObject()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    J* JGetObject (Jjson,
    const char * field 
    )
    +
    + +

    Get the value of an object field from a JSON object.

    +
    Parameters
    + + + +
    jsonThe JSON object.
    fieldThe object field to query.
    +
    +
    +
    Returns
    A pointer to the object, which is itself a JSON object (J *), if the field exists and is an object, otherwise NULL.
    +
    Note
    The returned JSON object is a pointer to the object contained in the parent JSON object. It is not a copy, so once the parent JSON object is freed, the pointer is no longer valid.
    + +
    +
    + +

    ◆ JGetString()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    char* JGetString (Jjson,
    const char * field 
    )
    +
    + +

    Get the value of a string field from a JSON object.

    +
    Parameters
    + + + +
    jsonThe JSON object.
    fieldThe string field to query.
    +
    +
    +
    Returns
    A pointer to the string if the field exists and is a string, otherwise the empty string ("").
    +
    Note
    The returned string is a pointer to the string contained in the JSON object. It is not a copy of the string, so once the JSON object is freed, the pointer is no longer valid.
    + +
    +
    + +

    ◆ JGetType()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    int JGetType (Jjson,
    const char * field 
    )
    +
    + +

    Get the type of a field, as an int usable in a switch statement.

    +
    Parameters
    + + + +
    jsonThe JSON object containing the field.
    fieldThe field's name.
    +
    +
    +
    Returns
    The type of the field on success. JTYPE_NOT_PRESENT on error or if the field doesn't exist.
    + +
    +
    + +

    ◆ JInit()

    + +
    +
    + + + + + + + + +
    void JInit (void )
    +
    + +
    +
    + +

    ◆ JIntValue()

    + +
    +
    + + + + + + + + +
    JINTEGER JIntValue (Jitem)
    +
    + +

    Return the integer representation of an item.

    +
    Parameters
    + + +
    itemThe JSON item.
    +
    +
    +
    Returns
    The number, or 0, if NULL.
    + +
    +
    + +

    ◆ JIsExactString()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    bool JIsExactString (Jjson,
    const char * field,
    const char * teststr 
    )
    +
    + +

    Determine if a field exists, is a string and matches a provided value.

    +
    Parameters
    + + + + +
    jsonThe JSON response object.
    fieldThe field to check.
    teststrThe string to test against the returned value.
    +
    +
    +
    Returns
    bol. Whether the fields match exactly.
    + +
    +
    + +

    ◆ JIsNullString()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    bool JIsNullString (Jjson,
    const char * field 
    )
    +
    + +

    Determine if a JSON object is valid and if a field is not present, or null.

    +
    Parameters
    + + + +
    jsonThe JSON response object.
    fieldThe field to return.
    +
    +
    +
    Returns
    bool. False if the field is not present, or NULL.
    + +
    +
    + +

    ◆ JIsPresent()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    bool JIsPresent (Jjson,
    const char * field 
    )
    +
    + +

    Determine if a field is present in a JSON object.

    +
    Parameters
    + + + +
    jsonThe JSON object.
    fieldThe field to find.
    +
    +
    +
    Returns
    True if the field is present, or false if the field is not present or the JSON object is NULL.
    + +
    +
    + +

    ◆ JItoA()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    void JItoA (JINTEGER n,
    char * s 
    )
    +
    + +

    Convert an integer to text.

    +
    Parameters
    + + + +
    nThe integer to convert.
    sThe buffer to hold the text.
    +
    +
    +
    Note
    The buffer must be large enough because no bounds checking is done.
    + +
    +
    + +

    ◆ JNtoA()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    char* JNtoA (JNUMBER f,
    char * buf,
    int precision 
    )
    +
    + +
    +
    + +

    ◆ JNumberValue()

    + +
    +
    + + + + + + + + +
    JNUMBER JNumberValue (Jitem)
    +
    + +

    Return the number representation of an item.

    +
    Parameters
    + + +
    itemThe JSON item.
    +
    +
    +
    Returns
    The number, or 0.0, if NULL.
    + +
    +
    + +

    ◆ JStringValue()

    + +
    +
    + + + + + + + + +
    char* JStringValue (Jitem)
    +
    + +

    Return the string representation of an item.

    +
    Parameters
    + + +
    itemThe JSON item.
    +
    +
    +
    Returns
    The string value, or empty string, if NULL.
    + +
    +
    + +

    ◆ JType()

    + +
    +
    + + + + + + + + +
    const char* JType (Jitem)
    +
    + +

    Return the type of an item, as a string.

    +
    Parameters
    + + +
    itemThe JSON item.
    +
    +
    +
    Returns
    The type
    + +
    +
    + +

    ◆ NoteAdd()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    bool NoteAdd (const char * target,
    Jbody,
    bool urgent 
    )
    +
    + +
    +
    + +

    ◆ NoteBinaryCodecDecode()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    uint32_t NoteBinaryCodecDecode (const uint8_t * encData,
    uint32_t encDataLen,
    uint8_t * decBuf,
    uint32_t decBufSize 
    )
    +
    + +
    +
    + +

    ◆ NoteBinaryCodecEncode()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    uint32_t NoteBinaryCodecEncode (const uint8_t * decData,
    uint32_t decDataLen,
    uint8_t * encBuf,
    uint32_t encBufSize 
    )
    +
    + +
    +
    + +

    ◆ NoteBinaryCodecMaxDecodedLength()

    + +
    +
    + + + + + + + + +
    uint32_t NoteBinaryCodecMaxDecodedLength (uint32_t bufferSize)
    +
    + +
    +
    + +

    ◆ NoteBinaryCodecMaxEncodedLength()

    + +
    +
    + + + + + + + + +
    uint32_t NoteBinaryCodecMaxEncodedLength (uint32_t unencodedLength)
    +
    + +
    +
    + +

    ◆ NoteBinaryStoreDecodedLength()

    + +
    +
    + + + + + + + + +
    const char* NoteBinaryStoreDecodedLength (uint32_t * len)
    +
    + +
    +
    + +

    ◆ NoteBinaryStoreEncodedLength()

    + +
    +
    + + + + + + + + +
    const char* NoteBinaryStoreEncodedLength (uint32_t * len)
    +
    + +
    +
    + +

    ◆ NoteBinaryStoreReceive()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    const char* NoteBinaryStoreReceive (uint8_t * buffer,
    uint32_t bufLen,
    uint32_t decodedOffset,
    uint32_t decodedLen 
    )
    +
    + +
    +
    + +

    ◆ NoteBinaryStoreReset()

    + +
    +
    + + + + + + + + +
    const char* NoteBinaryStoreReset (void )
    +
    + +
    +
    + +

    ◆ NoteBinaryStoreTransmit()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    const char* NoteBinaryStoreTransmit (uint8_t * unencodedData,
    uint32_t unencodedLen,
    uint32_t bufLen,
    uint32_t notecardOffset 
    )
    +
    + +
    +
    + +

    ◆ NoteClearLocation()

    + +
    +
    + + + + + + + + +
    bool NoteClearLocation (void )
    +
    + +
    +
    + +

    ◆ NoteDebug()

    + +
    +
    + + + + + + + + +
    void NoteDebug (const char * line)
    +
    + +

    Write to the debug stream.

    +
    Parameters
    + + +
    lineA debug string for output.
    +
    +
    + +
    +
    + +

    ◆ NoteDebugf()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    void NoteDebugf (const char * format,
     ... 
    )
    +
    + +
    +
    + +

    ◆ NoteDebugIntln()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    void NoteDebugIntln (const char * line,
    int n 
    )
    +
    + +

    Write a number to the debug stream and output a newline.

    +
    Parameters
    + + + +
    lineA debug string for output.
    nThe number to write.
    +
    +
    + +
    +
    + +

    ◆ NoteDebugln()

    + +
    +
    + + + + + + + + +
    void NoteDebugln (const char * line)
    +
    + +

    Write text to the debug stream and output a newline.

    +
    Parameters
    + + +
    lineA debug string for output.
    +
    +
    + +
    +
    + +

    ◆ NoteDebugSyncStatus()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    bool NoteDebugSyncStatus (int pollFrequencyMs,
    int maxLevel 
    )
    +
    + +
    +
    + +

    ◆ NoteDebugWithLevel()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    void NoteDebugWithLevel (uint8_t level,
    const char * msg 
    )
    +
    + +

    Write the message to the debug stream, if the level is less than or equal to NOTE_C_LOG_LEVEL. Otherwise, the message is dropped.

    +
    Parameters
    + + + +
    levelThe log level of the message. See the NOTE_C_LOG_LEVEL_* macros in note.h for possible values.
    msgThe debug message.
    +
    +
    + +
    +
    + +

    ◆ NoteDebugWithLevelLn()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    void NoteDebugWithLevelLn (uint8_t level,
    const char * msg 
    )
    +
    + +

    Same as NoteDebugWithLevel, but add a newline at the end.

    +
    Parameters
    + + + +
    levelThe log level of the message. See the NOTE_C_LOG_LEVEL_* macros in note.h for possible values.
    msgThe debug message.
    +
    +
    + +
    +
    + +

    ◆ NoteDelayMs()

    + +
    +
    + + + + + + + + +
    void NoteDelayMs (uint32_t ms)
    +
    + +

    Delay milliseconds using the platform-specific hook.

    +
    Parameters
    + + +
    msthe milliseconds delay value.
    +
    +
    + +
    +
    + +

    ◆ NoteErrorClean()

    + +
    +
    + + + + + + + + +
    void NoteErrorClean (char * begin)
    +
    + +

    Clean error strings out of the specified buffer.

    +

    Notecard errors are enclosed in {} (e.g. {io} for an I/O error). This function takes the input string and removes all errors from it, meaning it removes any substrings matching the pattern {some error string}, including the braces.

    +
    Parameters
    + + +
    beginA C-string to to clean of errors.
    +
    +
    + +
    +
    + +

    ◆ NoteErrorContains()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    bool NoteErrorContains (const char * errstr,
    const char * errtype 
    )
    +
    + +

    Check to see if a Notecard error is present in a JSON string.

    +

    Only Notecard errors enclosed in {} (e.g. {io} for an I/O error) are guaranteed by the API.

    +
    Parameters
    + + + +
    errstrThe string to check for errors.
    errtypeThe error substring to search for in errstr.
    +
    +
    +
    Returns
    true if errstr contains errtype and false otherwise.
    + +
    +
    + +

    ◆ NoteFactoryReset()

    + +
    +
    + + + + + + + + +
    bool NoteFactoryReset (bool deleteConfigSettings)
    +
    + +
    +
    + +

    ◆ NoteFree()

    + +
    +
    + + + + + + + + +
    void NoteFree (void * p)
    +
    + +

    Free memory using the platform-specific hook.

    +
    Parameters
    + + +
    pA pointer to the memory address to free.
    +
    +
    + +
    +
    + +

    ◆ NoteGetContact()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    bool NoteGetContact (char * nameBuf,
    int nameBufLen,
    char * orgBuf,
    int orgBufLen,
    char * roleBuf,
    int roleBufLen,
    char * emailBuf,
    int emailBufLen 
    )
    +
    + +
    +
    + +

    ◆ NoteGetEnv()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    bool NoteGetEnv (const char * variable,
    const char * defaultVal,
    char * buf,
    uint32_t buflen 
    )
    +
    + +
    +
    + +

    ◆ NoteGetEnvInt()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    JINTEGER NoteGetEnvInt (const char * variable,
    JINTEGER defaultVal 
    )
    +
    + +
    +
    + +

    ◆ NoteGetEnvNumber()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    JNUMBER NoteGetEnvNumber (const char * variable,
    JNUMBER defaultVal 
    )
    +
    + +
    +
    + +

    ◆ NoteGetLocation()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    bool NoteGetLocation (JNUMBERretLat,
    JNUMBERretLon,
    JTIMEtime,
    char * statusBuf,
    int statusBufLen 
    )
    +
    + +
    +
    + +

    ◆ NoteGetLocationMode()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    bool NoteGetLocationMode (char * modeBuf,
    int modeBufLen 
    )
    +
    + +
    +
    + +

    ◆ NoteGetMs()

    + +
    +
    + + + + + + + + +
    uint32_t NoteGetMs (void )
    +
    + +

    Get the current milliseconds value from the platform-specific hook.

    +
    Returns
    The current milliseconds value.
    + +
    +
    + +

    ◆ NoteGetNetStatus()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    bool NoteGetNetStatus (char * statusBuf,
    int statusBufLen 
    )
    +
    + +
    +
    + +

    ◆ NoteGetServiceConfig()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    bool NoteGetServiceConfig (char * productBuf,
    int productBufLen,
    char * serviceBuf,
    int serviceBufLen,
    char * deviceBuf,
    int deviceBufLen,
    char * snBuf,
    int snBufLen 
    )
    +
    + +
    +
    + +

    ◆ NoteGetServiceConfigST()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    bool NoteGetServiceConfigST (char * productBuf,
    int productBufLen,
    char * serviceBuf,
    int serviceBufLen,
    char * deviceBuf,
    int deviceBufLen,
    char * snBuf,
    int snBufLen 
    )
    +
    + +
    +
    + +

    ◆ NoteGetStatus()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    bool NoteGetStatus (char * statusBuf,
    int statusBufLen,
    JTIMEbootTime,
    bool * retUSB,
    bool * retSignals 
    )
    +
    + +
    +
    + +

    ◆ NoteGetStatusST()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    bool NoteGetStatusST (char * statusBuf,
    int statusBufLen,
    JTIMEbootTime,
    bool * retUSB,
    bool * retSignals 
    )
    +
    + +
    +
    + +

    ◆ NoteGetTemperature()

    + +
    +
    + + + + + + + + +
    bool NoteGetTemperature (JNUMBERtemp)
    +
    + +
    +
    + +

    ◆ NoteGetVersion()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    bool NoteGetVersion (char * versionBuf,
    int versionBufLen 
    )
    +
    + +
    +
    + +

    ◆ NoteGetVoltage()

    + +
    +
    + + + + + + + + +
    bool NoteGetVoltage (JNUMBERvoltage)
    +
    + +
    +
    + +

    ◆ NoteI2CAddress()

    + +
    +
    + + + + + + + + +
    uint32_t NoteI2CAddress (void )
    +
    + +

    Get the I2C address of the Notecard.

    +
    Returns
    The current I2C address.
    + +
    +
    + +

    ◆ NoteI2CMax()

    + +
    +
    + + + + + + + + +
    uint32_t NoteI2CMax (void )
    +
    + +

    Determine the maximum number of bytes for each segment of data sent to the Notecard over I2C.

    +
    Returns
    A 32-bit integer of the maximum number of bytes per I2C segment.
    + +
    +
    + +

    ◆ NoteIsConnected()

    + +
    +
    + + + + + + + + +
    bool NoteIsConnected (void )
    +
    + +
    +
    + +

    ◆ NoteIsConnectedST()

    + +
    +
    + + + + + + + + +
    bool NoteIsConnectedST (void )
    +
    + +
    +
    + +

    ◆ NoteLocalTimeST()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    bool NoteLocalTimeST (uint16_t * retYear,
    uint8_t * retMonth,
    uint8_t * retDay,
    uint8_t * retHour,
    uint8_t * retMinute,
    uint8_t * retSecond,
    char ** retWeekday,
    char ** retZone 
    )
    +
    + +
    +
    + +

    ◆ NoteLocationValid()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    bool NoteLocationValid (char * errbuf,
    uint32_t errbuflen 
    )
    +
    + +
    +
    + +

    ◆ NoteLocationValidST()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    bool NoteLocationValidST (char * errbuf,
    uint32_t errbuflen 
    )
    +
    + +
    +
    + +

    ◆ NoteLockI2C()

    + +
    +
    + + + + + + + + +
    void NoteLockI2C (void )
    +
    + +

    Lock the I2C bus using the platform-specific hook.

    + +
    +
    + +

    ◆ NoteMalloc()

    + +
    +
    + + + + + + + + +
    void* NoteMalloc (size_t size)
    +
    + +

    Allocate a memory chunk using the platform-specific hook.

    +
    Parameters
    + + +
    sizethe number of bytes to allocate.
    +
    +
    + +
    +
    + +

    ◆ NoteMD5Final()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    void NoteMD5Final (unsigned char * digest,
    NoteMD5Contextctx 
    )
    +
    + +
    +
    + +

    ◆ NoteMD5Hash()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    void NoteMD5Hash (unsigned char * data,
    unsigned long len,
    unsigned char * retHash 
    )
    +
    + +
    +
    + +

    ◆ NoteMD5HashString()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    void NoteMD5HashString (unsigned char * data,
    unsigned long len,
    char * strbuf,
    unsigned long buflen 
    )
    +
    + +
    +
    + +

    ◆ NoteMD5HashToString()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    void NoteMD5HashToString (unsigned char * hash,
    char * strbuf,
    unsigned long buflen 
    )
    +
    + +
    +
    + +

    ◆ NoteMD5Init()

    + +
    +
    + + + + + + + + +
    void NoteMD5Init (NoteMD5Contextctx)
    +
    + +
    +
    + +

    ◆ NoteMD5Transform()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    void NoteMD5Transform (unsigned long buf[4],
    const unsigned char inraw[64] 
    )
    +
    + +
    +
    + +

    ◆ NoteMD5Update()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    void NoteMD5Update (NoteMD5Contextctx,
    unsigned char const * buf,
    unsigned long len 
    )
    +
    + +
    +
    + +

    ◆ NoteMemAvailable()

    + +
    +
    + + + + + + + + +
    uint32_t NoteMemAvailable (void )
    +
    + +
    +
    + +

    ◆ NoteNewCommand()

    + +
    +
    + + + + + + + + +
    J* NoteNewCommand (const char * request)
    +
    + +

    Create a new JSON command.

    +

    Create a dynamically allocated J object with one field "cmd" whose value is the passed in request string. The difference between a command and a request is that the Notecard does not send a response to commands, only to requests.

    +
    Parameters
    + + +
    requestThe name of the command (e.g. card.attn).
    +
    +
    +
    Returns
    A J object with the "cmd" field populated.
    + +
    +
    + +

    ◆ NoteNewRequest()

    + +
    +
    + + + + + + + + +
    J* NoteNewRequest (const char * request)
    +
    + +

    Create a new JSON request.

    +

    Creates a dynamically allocated J object with one field "req" whose value is the passed in request string.

    +
    Parameters
    + + +
    requestThe name of the request, for example hub.set.
    +
    +
    +
    Returns
    A J object with the "req" field populated.
    + +
    +
    + +

    ◆ NotePayloadAddSegment()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    bool NotePayloadAddSegment (NotePayloadDescdesc,
    const char segtype[NP_SEGTYPE_LEN],
    void * pdata,
    uint32_t plen 
    )
    +
    + +
    +
    + +

    ◆ NotePayloadFindSegment()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    bool NotePayloadFindSegment (NotePayloadDescdesc,
    const char segtype[NP_SEGTYPE_LEN],
    void * pdata,
    uint32_t * plen 
    )
    +
    + +
    +
    + +

    ◆ NotePayloadFree()

    + +
    +
    + + + + + + + + +
    void NotePayloadFree (NotePayloadDescdesc)
    +
    + +
    +
    + +

    ◆ NotePayloadGetSegment()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    bool NotePayloadGetSegment (NotePayloadDescdesc,
    const char segtype[NP_SEGTYPE_LEN],
    void * pdata,
    uint32_t len 
    )
    +
    + +
    +
    + +

    ◆ NotePayloadRetrieveAfterSleep()

    + +
    +
    + + + + + + + + +
    bool NotePayloadRetrieveAfterSleep (NotePayloadDescdesc)
    +
    + +
    +
    + +

    ◆ NotePayloadSaveAndSleep()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    bool NotePayloadSaveAndSleep (NotePayloadDescdesc,
    uint32_t seconds,
    const char * modes 
    )
    +
    + +
    +
    + +

    ◆ NotePayloadSet()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    void NotePayloadSet (NotePayloadDescdesc,
    uint8_t * buf,
    uint32_t buflen 
    )
    +
    + +
    +
    + +

    ◆ NotePrint()

    + +
    +
    + + + + + + + + +
    bool NotePrint (const char * text)
    +
    + +
    +
    + +

    ◆ NotePrintf()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    bool NotePrintf (const char * format,
     ... 
    )
    +
    + +
    +
    + +

    ◆ NotePrintln()

    + +
    +
    + + + + + + + + +
    void NotePrintln (const char * line)
    +
    + +
    +
    + +

    ◆ NoteRegion()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    bool NoteRegion (char ** retCountry,
    char ** retArea,
    char ** retZone,
    int * retZoneOffset 
    )
    +
    + +
    +
    + +

    ◆ NoteRequest()

    + +
    +
    + + + + + + + + +
    bool NoteRequest (Jreq)
    +
    + +

    Send a request to the Notecard.

    +

    The passed in request object is always freed, regardless of if the request was successful or not. The response from the Notecard, if any, is freed and not returned to the caller.

    +
    Parameters
    + + +
    reqPointer to a J request object.
    +
    +
    +
    Returns
    true if successful and false if an error occurs (e.g. out of memory or the response from the Notecard has an "err" field). If req is a command rather than a request, a true return value indicates that the command was sent without error. However, since the Notecard sends no response to commands, it does not guarantee that the command was received and processed by the Notecard.
    +
    See also
    NoteRequestResponse if you need to work with the response.
    + +
    +
    + +

    ◆ NoteRequestResponse()

    + +
    +
    + + + + + + + + +
    J* NoteRequestResponse (Jreq)
    +
    + +

    Send a request to the Notecard and return the response.

    +

    The passed in request object is always freed, regardless of if the request was successful or not.

    +
    Parameters
    + + +
    reqPointer to a J request object.
    +
    +
    +
    Returns
    A J object with the response or NULL if there was an error sending the request.
    +
    See also
    NoteResponseError to check the response for errors.
    + +
    +
    + +

    ◆ NoteRequestResponseJSON()

    + +
    +
    + + + + + + + + +
    char* NoteRequestResponseJSON (const char * reqJSON)
    +
    + +

    Send a request to the Notecard and return the response.

    +

    Unlike NoteRequestResponse, this function expects the request to be a valid JSON C-string, rather than a J object. The string is expected to be newline-terminated, otherwise the call produces undefined behavior. The response is returned as a dynamically allocated JSON C-string. The response string is verbatim what was sent by the Notecard, which IS newline-terminated. The caller is responsible for freeing the response string. If the request was a command (i.e. it uses "cmd" instead of "req"), this function returns NULL, because the Notecard does not send a response to commands.

    +
    Parameters
    + + +
    reqJSONA valid newline-terminated JSON C-string containing the request.
    +
    +
    +
    Returns
    A newline-terminated JSON C-string with the response, or NULL if there was no response or if there was an error.
    +
    Note
    When a "cmd" is sent, it is not possible to determine if an error occurred.
    + +
    +
    + +

    ◆ NoteRequestResponseWithRetry()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    J* NoteRequestResponseWithRetry (Jreq,
    uint32_t timeoutSeconds 
    )
    +
    + +

    Send a request to the Notecard, retrying it until it succeeds or it times out, and return the response.

    +

    The passed in request object is always freed, regardless of if the request was successful or not.

    +
    Parameters
    + + + +
    reqPointer to a J request object.
    timeoutSecondsTime limit for retires, in seconds, if there is no response, or if the response contains an I/O error.
    +
    +
    +
    Returns
    A J object with the response or NULL if there was an error sending the request.
    +
    See also
    NoteResponseError to check the response for errors.
    + +
    +
    + +

    ◆ NoteRequestWithRetry()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    bool NoteRequestWithRetry (Jreq,
    uint32_t timeoutSeconds 
    )
    +
    + +

    Send a request to the Notecard, retrying it until it succeeds or it times out.

    +

    The passed in request object is always freed, regardless of if the request was successful or not. The response from the Notecard, if any, is freed and not returned to the caller.

    +
    Parameters
    + + + +
    reqPointer to a J request object.
    timeoutSecondsTime limit for retires, in seconds, if there is no response, or if the response contains an I/O error.
    +
    +
    +
    Returns
    true if successful and false if an error occurs (e.g. out of memory or the response from the Notecard has an "err" field).
    +
    See also
    NoteRequestResponseWithRetry if you need to work with the response.
    + +
    +
    + +

    ◆ NoteReset()

    + +
    +
    + + + + + + + + +
    bool NoteReset (void )
    +
    + +

    Initialize or re-initialize the module.

    +
    Returns
    True if the reset was successful and false if not.
    + +
    +
    + +

    ◆ NoteResetRequired()

    + +
    +
    + + + + + + + + +
    void NoteResetRequired (void )
    +
    + +

    Mark that a reset will be required before doing further I/O on a given port.

    + +
    +
    + +

    ◆ NoteResumeTransactionDebug()

    + +
    +
    + + + + + + + + +
    void NoteResumeTransactionDebug (void )
    +
    + +

    Resume showing transaction details.

    + +
    +
    + +

    ◆ NoteSendToRoute()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    bool NoteSendToRoute (const char * method,
    const char * routeAlias,
    char * notefile,
    Jbody 
    )
    +
    + +
    +
    + +

    ◆ NoteSetContact()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    bool NoteSetContact (char * nameBuf,
    char * orgBuf,
    char * roleBuf,
    char * emailBuf 
    )
    +
    + +
    +
    + +

    ◆ NoteSetEnvDefault()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    bool NoteSetEnvDefault (const char * variable,
    char * buf 
    )
    +
    + +
    +
    + +

    ◆ NoteSetEnvDefaultInt()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    bool NoteSetEnvDefaultInt (const char * variable,
    JINTEGER defaultVal 
    )
    +
    + +
    +
    + +

    ◆ NoteSetEnvDefaultNumber()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    bool NoteSetEnvDefaultNumber (const char * variable,
    JNUMBER defaultVal 
    )
    +
    + +
    +
    + +

    ◆ NoteSetFn()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    void NoteSetFn (mallocFn mallocHook,
    freeFn freeHook,
    delayMsFn delayMsHook,
    getMsFn getMsHook 
    )
    +
    + +

    Set the platform-specific memory and timing hooks.

    +
    Parameters
    + + + + + +
    mallocHookThe platform-specific memory allocation function (i.e. malloc).
    freeHookThe platform-specific memory free function (i.e. free).
    delayMsHookThe platform-specific millisecond delay function.
    getMsHookThe platform-specific millisecond counter function.
    +
    +
    + +
    +
    + +

    ◆ NoteSetFnDebugOutput()

    + +
    +
    + + + + + + + + +
    void NoteSetFnDebugOutput (debugOutputFn fn)
    +
    + +

    Set the platform-specific debug output function.

    +
    Parameters
    + + +
    fnA function pointer to call for debug output.
    +
    +
    + +
    +
    + +

    ◆ NoteSetFnDefault()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    void NoteSetFnDefault (mallocFn mallocfn,
    freeFn freefn,
    delayMsFn delayfn,
    getMsFn millisfn 
    )
    +
    + +

    Set the default memory and timing hooks if they aren't already set.

    +
    Parameters
    + + + + + +
    mallocfnThe default memory allocation malloc function to use.
    freefnThe default memory free function to use.
    delayfnThe default delay function to use.
    millisfnThe default 'millis' function to use.
    +
    +
    + +
    +
    + +

    ◆ NoteSetFnDisabled()

    + +
    +
    + + + + + + + + +
    void NoteSetFnDisabled (void )
    +
    + +

    Set the platform-specific communications method to be disabled.

    + +
    +
    + +

    ◆ NoteSetFnI2C()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    void NoteSetFnI2C (uint32_t notecardAddr,
    uint32_t maxTransmitSize,
    i2cResetFn resetFn,
    i2cTransmitFn transmitFn,
    i2cReceiveFn receiveFn 
    )
    +
    + +

    Set the platform-specific hooks for communicating with the Notecard over I2C, as well as the I2C address of the Notecard and maximum transmission size.

    +
    Parameters
    + + + + + + +
    notecardAddrThe I2C address of the Notecard. Pass 0 to use the default address.
    maxTransmitSizeThe max number of bytes to send to the Notecard in a single I2C segment. Pass 0 to use the default maximum transmission size.
    resetFnThe platform-specific I2C reset function.
    transmitFnThe platform-specific I2C transmit function.
    receiveFnThe platform-specific I2C receive function.
    +
    +
    + +
    +
    + +

    ◆ NoteSetFnI2CMutex()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    void NoteSetFnI2CMutex (mutexFn lockI2Cfn,
    mutexFn unlockI2Cfn 
    )
    +
    + +

    Set the platform-specific mutex functions for I2C.

    +
    Parameters
    + + + +
    lockI2CfnThe platform-specific I2C lock function.
    unlockI2CfnThe platform-specific I2C unlock function.
    +
    +
    + +
    +
    + +

    ◆ NoteSetFnMutex()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    void NoteSetFnMutex (mutexFn lockI2Cfn,
    mutexFn unlockI2Cfn,
    mutexFn lockNotefn,
    mutexFn unlockNotefn 
    )
    +
    + +

    Set the platform-specific mutex functions for I2C and the Notecard.

    +
    Parameters
    + + + + + +
    lockI2CfnThe platform-specific I2C lock function to use.
    unlockI2CfnThe platform-specific I2C unlock function to use.
    lockNotefnThe platform-specific Notecard lock function to use.
    unlockNotefnThe platform-specific Notecard unlock function to use.
    +
    +
    + +
    +
    + +

    ◆ NoteSetFnNoteMutex()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    void NoteSetFnNoteMutex (mutexFn lockFn,
    mutexFn unlockFn 
    )
    +
    + +

    Set the platform-specific mutex functions for the Notecard.

    +
    Parameters
    + + + +
    lockFnThe platform-specific Notecard lock function.
    unlockFnThe platform-specific Notecard unlock function.
    +
    +
    + +
    +
    + +

    ◆ NoteSetFnSerial()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    void NoteSetFnSerial (serialResetFn resetFn,
    serialTransmitFn transmitFn,
    serialAvailableFn availFn,
    serialReceiveFn receiveFn 
    )
    +
    + +

    Set the platform-specific hooks for communicating with the Notecard over serial.

    +
    Parameters
    + + + + + +
    resetFnThe platform-specific serial reset function.
    transmitFnThe platform-specific serial transmit function.
    availFnThe platform-specific serial available function.
    receiveFnThe platform-specific serial receive function.
    +
    +
    + +
    +
    + +

    ◆ NoteSetFnTransaction()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    void NoteSetFnTransaction (txnStartFn startFn,
    txnStopFn stopFn 
    )
    +
    + +

    Set the platform-specific transaction initiation/completion fn's.

    +
    Parameters
    + + + +
    startFnThe platform-specific transaction initiation function to use.
    stopFnThe platform-specific transaction completion function to use. to use.
    +
    +
    + +
    +
    + +

    ◆ NoteSetI2CAddress()

    + +
    +
    + + + + + + + + +
    void NoteSetI2CAddress (uint32_t i2caddress)
    +
    + +

    Set the I2C address for communication with the Notecard.

    +
    Parameters
    + + +
    i2caddressthe I2C address to use for the Notecard.
    +
    +
    + +
    +
    + +

    ◆ NoteSetLocation()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    bool NoteSetLocation (JNUMBER lat,
    JNUMBER lon 
    )
    +
    + +
    +
    + +

    ◆ NoteSetLocationMode()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    bool NoteSetLocationMode (const char * mode,
    uint32_t seconds 
    )
    +
    + +
    +
    + +

    ◆ NoteSetProductID()

    + +
    +
    + + + + + + + + +
    bool NoteSetProductID (const char * productID)
    +
    + +
    +
    + +

    ◆ NoteSetSerialNumber()

    + +
    +
    + + + + + + + + +
    bool NoteSetSerialNumber (const char * sn)
    +
    + +
    +
    + +

    ◆ NoteSetSTSecs()

    + +
    +
    + + + + + + + + +
    uint32_t NoteSetSTSecs (uint32_t secs)
    +
    + +
    +
    + +

    ◆ NoteSetSyncMode()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    bool NoteSetSyncMode (const char * uploadMode,
    int uploadMinutes,
    int downloadMinutes,
    bool align,
    bool sync 
    )
    +
    + +
    +
    + +

    ◆ NoteSetUploadMode()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    bool NoteSetUploadMode (const char * uploadMode,
    int uploadMinutes,
    bool align 
    )
    +
    + +
    +
    + +

    ◆ NoteSetUserAgent()

    + +
    +
    + + + + + + + + +
    void NoteSetUserAgent (char * agent)
    +
    + +
    +
    + +

    ◆ NoteSetUserAgentCPU()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    void NoteSetUserAgentCPU (int cpu_mem,
    int cpu_mhz,
    int cpu_cores,
    char * cpu_vendor,
    char * cpu_name 
    )
    +
    + +
    +
    + +

    ◆ NoteSetUserAgentOS()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    void NoteSetUserAgentOS (char * os_name,
    char * os_platform,
    char * os_family,
    char * os_version 
    )
    +
    + +
    +
    + +

    ◆ NoteSleep()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    bool NoteSleep (char * stateb64,
    uint32_t seconds,
    const char * modes 
    )
    +
    + +
    +
    + +

    ◆ NoteSuspendTransactionDebug()

    + +
    +
    + + + + + + + + +
    void NoteSuspendTransactionDebug (void )
    +
    + +

    Suppress showing transaction details.

    + +
    +
    + +

    ◆ NoteTemplate()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    bool NoteTemplate (const char * notefileID,
    JtemplateBody 
    )
    +
    + +
    +
    + +

    ◆ NoteTime()

    + +
    +
    + + + + + + + + +
    JTIME NoteTime (void )
    +
    + +
    +
    + +

    ◆ NoteTimeRefreshMins()

    + +
    +
    + + + + + + + + +
    void NoteTimeRefreshMins (uint32_t mins)
    +
    + +
    +
    + +

    ◆ NoteTimeSet()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
    void NoteTimeSet (JTIME secondsUTC,
    int offset,
    char * zone,
    char * country,
    char * area 
    )
    +
    + +
    +
    + +

    ◆ NoteTimeST()

    + +
    +
    + + + + + + + + +
    JTIME NoteTimeST (void )
    +
    + +
    +
    + +

    ◆ NoteTimeValid()

    + +
    +
    + + + + + + + + +
    bool NoteTimeValid (void )
    +
    + +
    +
    + +

    ◆ NoteTimeValidST()

    + +
    +
    + + + + + + + + +
    bool NoteTimeValidST (void )
    +
    + +
    +
    + +

    ◆ NoteTransaction()

    + +
    +
    + + + + + + + + +
    J* NoteTransaction (Jreq)
    +
    + +

    Send a request to the Notecard and return the response.

    +

    This function doesn't free the passed in request object. The caller is responsible for freeing it.

    +
    Parameters
    + + +
    reqPointer to a J request object.
    +
    +
    +
    Returns
    A J object with the response or NULL if there was an error sending the request.
    +
    See also
    NoteResponseError to check the response for errors.
    + +
    +
    + +

    ◆ NoteTurboIO()

    + +
    +
    + + + + + + + + +
    void NoteTurboIO (bool enable)
    +
    + +
    +
    + +

    ◆ NoteUnlockI2C()

    + +
    +
    + + + + + + + + +
    void NoteUnlockI2C (void )
    +
    + +

    Unlock the I2C bus using the platform-specific hook.

    + +
    +
    + +

    ◆ NoteUserAgent()

    + +
    +
    + + + + + + + + +
    J* NoteUserAgent (void )
    +
    + +
    +
    + +

    ◆ NoteUserAgentUpdate()

    + +
    +
    + + + + + + + + +
    void NoteUserAgentUpdate (Jua)
    +
    + +
    +
    + +

    ◆ NoteWake()

    + +
    +
    + + + + + + + + + + + + + + + + + + +
    bool NoteWake (int stateLen,
    void * state 
    )
    +
    + +
    +
    + +

    ◆ strlcat()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    size_t strlcat (char * dst,
    const char * src,
    size_t siz 
    )
    +
    + +
    +
    + +

    ◆ strlcpy()

    + +
    +
    + + + + + + + + + + + + + + + + + + + + + + + + +
    size_t strlcpy (char * dst,
    const char * src,
    size_t siz 
    )
    +
    + +
    +
    +
    + + + + diff --git a/doxygen/html/note_8h_source.html b/doxygen/html/note_8h_source.html new file mode 100644 index 00000000..d3e1e639 --- /dev/null +++ b/doxygen/html/note_8h_source.html @@ -0,0 +1,674 @@ + + + + + + + +note-c: /home/runner/work/note-c/note-c/note.h Source File + + + + + + + + + +
    +
    + + + + + + + +
    +
    note-c +  1.0 +
    +
    An easy to use Notecard Library for C/C++
    +
    +
    + + + + + + + +
    + +
    +
    + + +
    + +
    + +
    +
    +
    /home/runner/work/note-c/note-c/note.h
    +
    +
    +Go to the documentation of this file.
    1 
    +
    16 #pragma once
    +
    17 
    +
    18 // In case they're not yet defined
    +
    19 #include <float.h>
    +
    20 #include <limits.h>
    +
    21 #include <stdbool.h>
    +
    22 #include <stdint.h>
    +
    23 
    +
    24 #define _NOTE_C_STRINGIZE(x) #x
    +
    25 #define NOTE_C_STRINGIZE(x) _NOTE_C_STRINGIZE(x)
    +
    26 
    +
    27 #define NOTE_C_VERSION_MAJOR 2
    +
    28 #define NOTE_C_VERSION_MINOR 2
    +
    29 #define NOTE_C_VERSION_PATCH 1
    +
    30 
    +
    31 #define NOTE_C_VERSION NOTE_C_STRINGIZE(NOTE_C_VERSION_MAJOR) "." NOTE_C_STRINGIZE(NOTE_C_VERSION_MINOR) "." NOTE_C_STRINGIZE(NOTE_C_VERSION_PATCH)
    +
    32 
    +
    33 // If double and float are the same size, then we must be on a small MCU. Turn
    +
    34 // on NOTE_C_LOW_MEM to conserve memory.
    +
    35 #if defined(FLT_MAX_EXP) && defined(DBL_MAX_EXP)
    +
    36 #if (FLT_MAX_EXP == DBL_MAX_EXP)
    +
    37 #define NOTE_C_LOW_MEM
    +
    38 #endif
    +
    39 #elif defined(__FLT_MAX_EXP__) && defined(__DBL_MAX_EXP__)
    +
    40 #if (__FLT_MAX_EXP__ == __DBL_MAX_EXP__)
    +
    41 #define NOTE_C_LOW_MEM
    +
    42 #endif
    +
    43 #else
    +
    44 #error What are floating point exponent length symbols for this compiler?
    +
    45 #endif
    +
    46 
    +
    47 // NOTE_LOWMEM is the old name of NOTE_C_LOW_MEM. If NOTE_LOWMEM is defined,
    +
    48 // we define NOTE_C_LOW_MEM as well, for backwards compatibility. NOTE_FLOAT is
    +
    49 // also no longer used internally, but used to be defined when NOTE_LOWMEM was
    +
    50 // defined. It's also preserved here for backwards compatibility.
    +
    51 #ifdef NOTE_LOWMEM
    +
    52 #define NOTE_C_LOW_MEM
    +
    53 #define NOTE_FLOAT
    +
    54 #endif
    +
    55 
    +
    56 #ifdef NOTE_C_LOW_MEM
    +
    57 #define ERRSTR(x,y) (y)
    +
    58 #else
    +
    59 #define ERRSTR(x,y) (x)
    +
    60 #endif
    +
    61 
    +
    65 #ifdef NOTE_C_TEST_SINGLE_PRECISION
    +
    66 typedef float JNUMBER;
    +
    67 #else
    +
    68 typedef double JNUMBER;
    +
    69 #endif
    +
    70 
    +
    74 typedef int64_t JINTEGER;
    +
    75 #define JINTEGER_MIN INT64_MIN
    +
    76 #define JINTEGER_MAX INT64_MAX
    +
    77 
    +
    81 typedef uint64_t JUINTEGER;
    +
    82 
    +
    83 // UNIX Epoch time (also known as POSIX time) is the number of seconds that have elapsed since
    +
    84 // 00:00:00 Thursday, 1 January 1970, Coordinated Universal Time (UTC). In this project, it always
    +
    85 // originates from the Notecard, which synchronizes the time from both the cell network and GPS.
    +
    86 typedef JUINTEGER JTIME;
    +
    87 
    +
    88 // C-callable functions
    +
    89 #ifdef __cplusplus
    +
    90 extern "C" {
    +
    91 #endif
    +
    92 
    +
    93 // cJSON wrappers
    +
    94 #include "n_cjson.h"
    +
    95 
    +
    96 // Notecard hook functions
    +
    97 
    +
    103 typedef void (*mutexFn) (void);
    +
    113 typedef void * (*mallocFn) (size_t size);
    +
    121 typedef void (*freeFn) (void * mem);
    +
    129 typedef void (*delayMsFn) (uint32_t ms);
    +
    137 typedef uint32_t (*getMsFn) (void);
    +
    138 typedef size_t (*debugOutputFn) (const char *text);
    +
    139 
    +
    150 typedef bool (*serialResetFn) (void);
    +
    160 typedef void (*serialTransmitFn) (uint8_t *txBuf, size_t txBufSize, bool flush);
    +
    168 typedef bool (*serialAvailableFn) (void);
    +
    169 
    +
    177 typedef char (*serialReceiveFn) (void);
    +
    188 typedef bool (*i2cResetFn) (uint16_t address);
    +
    202 typedef const char * (*i2cTransmitFn) (uint16_t address, uint8_t* txBuf,
    +
    203  uint16_t txBufSize);
    +
    218 typedef const char * (*i2cReceiveFn) (uint16_t address, uint8_t* rxBuf,
    +
    219  uint16_t rxBufSize, uint32_t *available);
    +
    220 typedef bool (*txnStartFn) (uint32_t timeoutMs);
    +
    221 typedef void (*txnStopFn) (void);
    +
    222 
    +
    223 // External API
    +
    224 bool NoteReset(void);
    +
    225 void NoteResetRequired(void);
    +
    226 #define NoteNewBody JCreateObject
    +
    227 #define NoteAddBodyToObject(a, b) JAddItemToObject(a, "body", b)
    +
    228 #define NoteGetBody(a) JGetObject(a, "body")
    +
    229 J *NoteNewRequest(const char *request);
    +
    230 J *NoteNewCommand(const char *request);
    +
    231 J *NoteRequestResponse(J *req);
    +
    232 J *NoteRequestResponseWithRetry(J *req, uint32_t timeoutSeconds);
    +
    233 char * NoteRequestResponseJSON(const char *reqJSON);
    +
    234 void NoteSuspendTransactionDebug(void);
    +
    235 void NoteResumeTransactionDebug(void);
    +
    236 #define SYNCSTATUS_LEVEL_MAJOR 0
    +
    237 #define SYNCSTATUS_LEVEL_MINOR 1
    +
    238 #define SYNCSTATUS_LEVEL_DETAILED 2
    +
    239 #define SYNCSTATUS_LEVEL_ALGORITHMIC 3
    +
    240 #define SYNCSTATUS_LEVEL_ALL -1
    +
    241 bool NoteDebugSyncStatus(int pollFrequencyMs, int maxLevel);
    +
    242 bool NoteRequest(J *req);
    +
    243 bool NoteRequestWithRetry(J *req, uint32_t timeoutSeconds);
    +
    251 #define NoteResponseError(rsp) (!JIsNullString(rsp, "err"))
    +
    252 #define NoteResponseErrorContains(rsp, errstr) (JContainsString(rsp, "err", errstr))
    +
    258 #define NoteDeleteResponse(rsp) JDelete(rsp)
    +
    259 J *NoteTransaction(J *req);
    +
    260 bool NoteErrorContains(const char *errstr, const char *errtype);
    +
    261 void NoteErrorClean(char *errbuf);
    + +
    263 void NoteSetFnTransaction(txnStartFn startFn, txnStopFn stopFn);
    +
    264 void NoteSetFnMutex(mutexFn lockI2Cfn, mutexFn unlockI2Cfn, mutexFn lockNotefn,
    +
    265  mutexFn unlockNotefn);
    +
    266 void NoteSetFnI2CMutex(mutexFn lockI2Cfn, mutexFn unlockI2Cfn);
    +
    267 void NoteSetFnNoteMutex(mutexFn lockFn, mutexFn unlockFn);
    +
    268 void NoteSetFnDefault(mallocFn mallocfn, freeFn freefn, delayMsFn delayfn,
    +
    269  getMsFn millisfn);
    +
    270 void NoteSetFn(mallocFn mallocHook, freeFn freeHook, delayMsFn delayMsHook,
    +
    271  getMsFn getMsHook);
    +
    272 void NoteSetFnSerial(serialResetFn resetFn, serialTransmitFn transmitFn,
    +
    273  serialAvailableFn availFn, serialReceiveFn receiveFn);
    +
    274 void NoteSetFnI2C(uint32_t notecardAddr, uint32_t maxTransmitSize,
    +
    275  i2cResetFn resetFn, i2cTransmitFn transmitFn,
    +
    276  i2cReceiveFn receiveFn);
    +
    277 void NoteSetFnDisabled(void);
    +
    278 void NoteSetI2CAddress(uint32_t i2caddress);
    +
    279 
    +
    280 // The Notecard, whose default I2C address is below, uses a serial-to-i2c
    +
    281 // protocol whose "byte count" must fit into a single byte and which must not
    +
    282 // include a 2-byte header field. This is why the maximum that can be
    +
    283 // transmitted by note-c in a single I2C I/O is 255 - 2 = 253 bytes.
    +
    284 
    +
    288 #define NOTE_I2C_ADDR_DEFAULT 0x17
    +
    289 
    +
    290 // Serial-to-i2c protocol header size in bytes
    +
    291 #ifndef NOTE_I2C_HEADER_SIZE
    +
    292 #define NOTE_I2C_HEADER_SIZE 2
    +
    293 #endif
    +
    294 
    +
    295 // Maximum bytes capable of being transmitted in a single read/write operation
    +
    296 #ifndef NOTE_I2C_MAX_MAX
    +
    297 #define NOTE_I2C_MAX_MAX (UCHAR_MAX - NOTE_I2C_HEADER_SIZE)
    +
    298 #endif
    +
    299 
    +
    300 // In ARDUINO implementations, which to date is the largest use of this library,
    +
    301 // the Wire package is implemented in a broad variety of ways by different
    +
    302 // vendors. The default implementation has a mere 32-byte static I2C buffer,
    +
    303 // which means that the maximum to be transmitted in a single I/O (given our
    +
    304 // 2-byte serial-to-i2c protocol header) is 30 bytes. However, if we know
    +
    305 // the specific platform (such as STM32DUINO) we can relax this restriction.
    +
    306 #if defined(NOTE_I2C_MAX_DEFAULT)
    +
    307 // user is overriding it at compile time
    +
    308 #elif defined(ARDUINO_ARCH_STM32)
    +
    309 // we know that stm32duino dynamically allocates I/O buffer
    +
    310 #define NOTE_I2C_MAX_DEFAULT NOTE_I2C_MAX_MAX
    +
    311 #else
    +
    312 // default to what's known to be safe for all Arduino implementations
    +
    317 #define NOTE_I2C_MAX_DEFAULT 30
    +
    318 #endif
    +
    319 
    +
    320 // User agent
    + + +
    323 void NoteSetUserAgent(char *agent);
    +
    324 void NoteSetUserAgentOS(char *os_name, char *os_platform, char *os_family, char *os_version);
    +
    325 void NoteSetUserAgentCPU(int cpu_mem, int cpu_mhz, int cpu_cores, char *cpu_vendor, char *cpu_name);
    +
    326 
    +
    327 // Calls to the functions set above
    +
    328 void NoteDebug(const char *message);
    +
    329 void NoteDebugln(const char *message);
    +
    330 void NoteDebugIntln(const char *message, int n);
    +
    331 void NoteDebugf(const char *format, ...);
    +
    332 
    +
    333 #define NOTE_C_LOG_LEVEL_ERROR 0
    +
    334 #define NOTE_C_LOG_LEVEL_WARN 1
    +
    335 #define NOTE_C_LOG_LEVEL_INFO 2
    +
    336 #define NOTE_C_LOG_LEVEL_DEBUG 3
    +
    337 
    +
    338 void NoteDebugWithLevel(uint8_t level, const char *msg);
    +
    339 void NoteDebugWithLevelLn(uint8_t level, const char *msg);
    +
    340 
    +
    341 #ifdef NOTE_C_LOG_SHOW_FILE_AND_LINE
    +
    342 #define NOTE_C_LOG_FILE_AND_LINE(lvl) do { \
    +
    343  NoteDebugWithLevel(lvl, __FILE__ ":" NOTE_C_STRINGIZE(__LINE__) " "); \
    +
    344 } while (0);
    +
    345 #else
    +
    346 #define NOTE_C_LOG_FILE_AND_LINE(lvl)
    +
    347 #endif
    +
    348 
    +
    349 #define NOTE_C_LOG_ERROR(msg) do { \
    +
    350  NOTE_C_LOG_FILE_AND_LINE(NOTE_C_LOG_LEVEL_ERROR); \
    +
    351  NoteDebugWithLevel(NOTE_C_LOG_LEVEL_ERROR, "[ERROR] "); \
    +
    352  NoteDebugWithLevelLn(NOTE_C_LOG_LEVEL_ERROR, msg); \
    +
    353 } while (0);
    +
    354 
    +
    355 #define NOTE_C_LOG_WARN(msg) do { \
    +
    356  NOTE_C_LOG_FILE_AND_LINE(NOTE_C_LOG_LEVEL_WARN); \
    +
    357  NoteDebugWithLevel(NOTE_C_LOG_LEVEL_WARN, "[WARN] "); \
    +
    358  NoteDebugWithLevelLn(NOTE_C_LOG_LEVEL_WARN, msg); \
    +
    359 } while (0);
    +
    360 
    +
    361 #define NOTE_C_LOG_INFO(msg) do { \
    +
    362  NOTE_C_LOG_FILE_AND_LINE(NOTE_C_LOG_LEVEL_INFO); \
    +
    363  NoteDebugWithLevel(NOTE_C_LOG_LEVEL_INFO, "[INFO] "); \
    +
    364  NoteDebugWithLevelLn(NOTE_C_LOG_LEVEL_INFO, msg); \
    +
    365 } while (0);
    +
    366 
    +
    367 #define NOTE_C_LOG_DEBUG(msg) do { \
    +
    368  NOTE_C_LOG_FILE_AND_LINE(NOTE_C_LOG_LEVEL_DEBUG); \
    +
    369  NoteDebugWithLevel(NOTE_C_LOG_LEVEL_DEBUG, "[DEBUG] "); \
    +
    370  NoteDebugWithLevelLn(NOTE_C_LOG_LEVEL_DEBUG, msg); \
    +
    371 } while (0);
    +
    372 
    +
    373 // The max log level for NoteDebugWithLevel is only configurable at
    +
    374 // compile-time, via NOTE_C_LOG_LEVEL.
    +
    375 #ifndef NOTE_C_LOG_LEVEL
    +
    376 #define NOTE_C_LOG_LEVEL NOTE_C_LOG_LEVEL_INFO
    +
    377 #endif
    +
    378 
    +
    379 void *NoteMalloc(size_t size);
    +
    380 void NoteFree(void *);
    +
    381 uint32_t NoteGetMs(void);
    +
    382 void NoteDelayMs(uint32_t ms);
    +
    383 void NoteLockI2C(void);
    +
    384 void NoteUnlockI2C(void);
    +
    385 uint32_t NoteI2CAddress(void);
    +
    386 uint32_t NoteI2CMax(void);
    +
    387 uint32_t NoteMemAvailable(void);
    +
    388 bool NotePrint(const char *text);
    +
    389 void NotePrintln(const char *line);
    +
    390 bool NotePrintf(const char *format, ...);
    +
    391 
    +
    392 // String helpers to help encourage the world to abandon the horribly-error-prone strn*
    +
    393 size_t strlcpy(char *dst, const char *src, size_t siz);
    +
    394 size_t strlcat(char *dst, const char *src, size_t siz);
    +
    395 
    +
    396 // JSON helpers
    +
    397 void JInit(void);
    +
    398 void JCheck(void);
    +
    399 bool JIsPresent(J *json, const char *field);
    +
    400 char *JGetString(J *json, const char *field);
    +
    401 JNUMBER JGetNumber(J *json, const char *field);
    +
    402 J *JGetArray(J *json, const char *field);
    +
    403 J *JGetObject(J *json, const char *field);
    +
    404 JINTEGER JGetInt(J *json, const char *field);
    +
    405 bool JGetBool(J *json, const char *field);
    +
    406 JNUMBER JNumberValue(J *item);
    +
    407 char *JStringValue(J *item);
    +
    408 bool JBoolValue(J *item);
    +
    409 JINTEGER JIntValue(J *item);
    +
    410 bool JIsNullString(J *json, const char *field);
    +
    411 bool JIsExactString(J *json, const char *field, const char *teststr);
    +
    412 bool JContainsString(J *json, const char *field, const char *substr);
    +
    413 bool JAddBinaryToObject(J *json, const char *fieldName, const void *binaryData, uint32_t binaryDataLen);
    +
    414 bool JGetBinaryFromObject(J *json, const char *fieldName, uint8_t **retBinaryData, uint32_t *retBinaryDataLen);
    +
    415 const char *JGetItemName(const J * item);
    +
    416 char *JAllocString(uint8_t *buffer, uint32_t len);
    +
    417 const char *JType(J *item);
    +
    418 
    +
    419 #define JTYPE_NOT_PRESENT 0
    +
    420 #define JTYPE_BOOL_TRUE 1
    +
    421 #define JTYPE_BOOL_FALSE 2
    +
    422 #define JTYPE_BOOL JTYPE_BOOL_TRUE
    +
    423 #define JTYPE_NULL 3
    +
    424 #define JTYPE_NUMBER_ZERO 4
    +
    425 #define JTYPE_NUMBER 5
    +
    426 #define JTYPE_STRING_BLANK 6
    +
    427 #define JTYPE_STRING_ZERO 7
    +
    428 #define JTYPE_STRING_NUMBER 8
    +
    429 #define JTYPE_STRING_BOOL_TRUE 9
    +
    430 #define JTYPE_STRING_BOOL_FALSE 10
    +
    431 #define JTYPE_STRING 11
    +
    432 #define JTYPE_OBJECT 12
    +
    433 #define JTYPE_ARRAY 13
    +
    434 int JGetType(J *json, const char *field);
    +
    435 int JGetItemType(J *item);
    +
    436 int JBaseItemType(int type);
    +
    437 #define JGetObjectItemName(j) (j->string)
    +
    438 
    +
    439 // Helper functions for apps that wish to limit their C library dependencies
    +
    440 #define JNTOA_PRECISION (16)
    +
    441 #define JNTOA_MAX (44)
    +
    442 char * JNtoA(JNUMBER f, char * buf, int precision);
    +
    443 JNUMBER JAtoN(const char *string, char **endPtr);
    +
    444 void JItoA(JINTEGER n, char *s);
    +
    445 JINTEGER JAtoI(const char *s);
    +
    446 int JB64EncodeLen(int len);
    +
    447 int JB64Encode(char * coded_dst, const char *plain_src,int len_plain_src);
    +
    448 int JB64DecodeLen(const char * coded_src);
    +
    449 int JB64Decode(char * plain_dst, const char *coded_src);
    +
    450 
    +
    451 // MD5 Helper functions
    +
    452 typedef struct {
    +
    453  unsigned long buf[4];
    +
    454  unsigned long bits[2];
    +
    455  unsigned char in[64];
    + +
    457 #define NOTE_MD5_HASH_SIZE 16
    +
    458 #define NOTE_MD5_HASH_STRING_SIZE (((NOTE_MD5_HASH_SIZE)*2)+1)
    + +
    460 void NoteMD5Update(NoteMD5Context *ctx, unsigned char const *buf, unsigned long len);
    +
    461 void NoteMD5Final(unsigned char *digest, NoteMD5Context *ctx);
    +
    462 void NoteMD5Transform(unsigned long buf[4], const unsigned char inraw[64]);
    +
    463 void NoteMD5Hash(unsigned char* data, unsigned long len, unsigned char *retHash);
    +
    464 void NoteMD5HashString(unsigned char *data, unsigned long len, char *strbuf, unsigned long buflen);
    +
    465 void NoteMD5HashToString(unsigned char *hash, char *strbuf, unsigned long buflen);
    +
    466 
    +
    467 // High-level helper functions that are both useful and serve to show developers
    +
    468 // how to call the API
    +
    469 uint32_t NoteBinaryCodecDecode(const uint8_t *encData, uint32_t encDataLen,
    +
    470  uint8_t *decBuf, uint32_t decBufSize);
    +
    471 uint32_t NoteBinaryCodecEncode(const uint8_t *decData, uint32_t decDataLen,
    +
    472  uint8_t *encBuf, uint32_t encBufSize);
    +
    473 uint32_t NoteBinaryCodecMaxDecodedLength(uint32_t bufferSize);
    +
    474 uint32_t NoteBinaryCodecMaxEncodedLength(uint32_t unencodedLength);
    +
    475 const char * NoteBinaryStoreDecodedLength(uint32_t *len);
    +
    476 const char * NoteBinaryStoreEncodedLength(uint32_t *len);
    +
    477 const char * NoteBinaryStoreReceive(uint8_t *buffer, uint32_t bufLen,
    +
    478  uint32_t decodedOffset, uint32_t decodedLen);
    +
    479 const char * NoteBinaryStoreReset(void);
    +
    480 const char * NoteBinaryStoreTransmit(uint8_t *unencodedData, uint32_t unencodedLen,
    +
    481  uint32_t bufLen, uint32_t notecardOffset);
    +
    482 uint32_t NoteSetSTSecs(uint32_t secs);
    +
    483 bool NoteTimeValid(void);
    +
    484 bool NoteTimeValidST(void);
    + + +
    487 void NoteTimeRefreshMins(uint32_t mins);
    +
    488 void NoteTimeSet(JTIME secondsUTC, int offset, char *zone, char *country, char *area);
    +
    489 bool NoteLocalTimeST(uint16_t *retYear, uint8_t *retMonth, uint8_t *retDay, uint8_t *retHour, uint8_t *retMinute, uint8_t *retSecond, char **retWeekday, char **retZone);
    +
    490 bool NoteRegion(char **retCountry, char **retArea, char **retZone, int *retZoneOffset);
    +
    491 bool NoteLocationValid(char *errbuf, uint32_t errbuflen);
    +
    492 bool NoteLocationValidST(char *errbuf, uint32_t errbuflen);
    +
    493 void NoteTurboIO(bool enable);
    +
    494 JINTEGER NoteGetEnvInt(const char *variable, JINTEGER defaultVal);
    +
    495 JNUMBER NoteGetEnvNumber(const char *variable, JNUMBER defaultVal);
    +
    496 bool NoteGetEnv(const char *variable, const char *defaultVal, char *buf, uint32_t buflen);
    +
    497 bool NoteSetEnvDefault(const char *variable, char *buf);
    +
    498 bool NoteSetEnvDefaultNumber(const char *variable, JNUMBER defaultVal);
    +
    499 bool NoteSetEnvDefaultInt(const char *variable, JINTEGER defaultVal);
    +
    500 bool NoteIsConnected(void);
    +
    501 bool NoteIsConnectedST(void);
    +
    502 bool NoteGetNetStatus(char *statusBuf, int statusBufLen);
    +
    503 bool NoteGetVersion(char *versionBuf, int versionBufLen);
    +
    504 bool NoteGetLocation(JNUMBER *retLat, JNUMBER *retLon, JTIME *time, char *statusBuf, int statusBufLen);
    + +
    506 bool NoteClearLocation(void);
    +
    507 bool NoteGetLocationMode(char *modeBuf, int modeBufLen);
    +
    508 bool NoteSetLocationMode(const char *mode, uint32_t seconds);
    +
    509 bool NoteGetServiceConfig(char *productBuf, int productBufLen, char *serviceBuf, int serviceBufLen, char *deviceBuf, int deviceBufLen, char *snBuf, int snBufLen);
    +
    510 bool NoteGetServiceConfigST(char *productBuf, int productBufLen, char *serviceBuf, int serviceBufLen, char *deviceBuf, int deviceBufLen, char *snBuf, int snBufLen);
    +
    511 bool NoteGetStatus(char *statusBuf, int statusBufLen, JTIME *bootTime, bool *retUSB, bool *retSignals);
    +
    512 bool NoteGetStatusST(char *statusBuf, int statusBufLen, JTIME *bootTime, bool *retUSB, bool *retSignals);
    +
    513 bool NoteSleep(char *stateb64, uint32_t seconds, const char *modes);
    +
    514 bool NoteWake(int stateLen, void *state);
    +
    515 bool NoteFactoryReset(bool deleteConfigSettings);
    +
    516 bool NoteSetSerialNumber(const char *sn);
    +
    517 bool NoteSetProductID(const char *productID);
    +
    518 bool NoteSetUploadMode(const char *uploadMode, int uploadMinutes, bool align);
    +
    519 bool NoteSetSyncMode(const char *uploadMode, int uploadMinutes, int downloadMinutes, bool align, bool sync);
    +
    520 #define NoteSend NoteAdd
    +
    521 bool NoteAdd(const char *target, J *body, bool urgent);
    +
    522 bool NoteSendToRoute(const char *method, const char *routeAlias, char *notefile, J *body);
    +
    523 bool NoteGetVoltage(JNUMBER *voltage);
    + +
    525 bool NoteGetContact(char *nameBuf, int nameBufLen, char *orgBuf, int orgBufLen, char *roleBuf, int roleBufLen, char *emailBuf, int emailBufLen);
    +
    526 bool NoteSetContact(char *nameBuf, char *orgBuf, char *roleBuf, char *emailBuf);
    +
    527 
    +
    528 // Definitions necessary for payload descriptor
    +
    529 #define NP_SEGTYPE_LEN 4
    +
    530 #define NP_SEGLEN_LEN sizeof(uint32_t)
    +
    531 #define NP_SEGHDR_LEN (NP_SEGTYPE_LEN + NP_SEGLEN_LEN)
    +
    532 typedef struct {
    +
    533  uint8_t *data;
    +
    534  uint32_t alloc;
    +
    535  uint32_t length;
    + +
    537 bool NotePayloadSaveAndSleep(NotePayloadDesc *desc, uint32_t seconds, const char *modes);
    + +
    539 void NotePayloadSet(NotePayloadDesc *desc, uint8_t *buf, uint32_t buflen);
    + +
    541 bool NotePayloadAddSegment(NotePayloadDesc *desc, const char segtype[NP_SEGTYPE_LEN], void *pdata, uint32_t plen);
    +
    542 bool NotePayloadFindSegment(NotePayloadDesc *desc, const char segtype[NP_SEGTYPE_LEN], void *pdata, uint32_t *plen);
    +
    543 bool NotePayloadGetSegment(NotePayloadDesc *desc, const char segtype[NP_SEGTYPE_LEN], void *pdata, uint32_t len);
    +
    544 
    +
    545 // Hard-wired constants used to specify field types when creating note templates
    +
    546 #define TBOOL true // bool
    +
    547 #define TINT8 11 // 1-byte signed integer
    +
    548 #define TINT16 12 // 2-byte signed integer
    +
    549 #define TINT24 13 // 3-byte signed integer
    +
    550 #define TINT32 14 // 4-byte signed integer
    +
    551 #define TINT64 18 // 8-byte signed integer (note-c support depends upon platform)
    +
    552 #define TUINT8 21 // 1-byte unsigned integer (requires notecard firmware >= build 14444)
    +
    553 #define TUINT16 22 // 2-byte unsigned integer (requires notecard firmware >= build 14444)
    +
    554 #define TUINT24 23 // 3-byte unsigned integer (requires notecard firmware >= build 14444)
    +
    555 #define TUINT32 24 // 4-byte unsigned integer (requires notecard firmware >= build 14444)
    +
    556 #define TFLOAT16 12.1 // 2-byte IEEE 754 floating point
    +
    557 #define TFLOAT32 14.1 // 4-byte IEEE 754 floating point (a.k.a. "float")
    +
    558 #define TFLOAT64 18.1 // 8-byte IEEE 754 floating point (a.k.a. "double")
    +
    559 #define TSTRING(N) _NOTE_C_STRINGIZE(N) // UTF-8 text of N bytes maximum (fixed-length reserved buffer)
    +
    560 #define TSTRINGV _NOTE_C_STRINGIZE(0) // variable-length string
    +
    561 bool NoteTemplate(const char *notefileID, J *templateBody);
    +
    562 
    +
    563 // End of C-callable functions
    +
    564 #ifdef __cplusplus
    +
    565 }
    +
    566 #endif
    + +
    JINTEGER JGetInt(J *json, const char *field)
    Get the integer value of a number field from a JSON object.
    Definition: n_cjson_helpers.c:226
    +
    void(* serialTransmitFn)(uint8_t *txBuf, size_t txBufSize, bool flush)
    The type for the serial transmit hook.
    Definition: note.h:160
    +
    void NoteSetUserAgentCPU(int cpu_mem, int cpu_mhz, int cpu_cores, char *cpu_vendor, char *cpu_name)
    +
    void NoteDebugln(const char *message)
    Write text to the debug stream and output a newline.
    Definition: n_hooks.c:409
    +
    void NoteTimeSet(JTIME secondsUTC, int offset, char *zone, char *country, char *area)
    +
    void NoteMD5HashToString(unsigned char *hash, char *strbuf, unsigned long buflen)
    +
    const char * NoteBinaryStoreReceive(uint8_t *buffer, uint32_t bufLen, uint32_t decodedOffset, uint32_t decodedLen)
    +
    bool NoteFactoryReset(bool deleteConfigSettings)
    +
    int JGetType(J *json, const char *field)
    Get the type of a field, as an int usable in a switch statement.
    Definition: n_cjson_helpers.c:605
    +
    JTIME NoteTime(void)
    +
    bool NotePayloadFindSegment(NotePayloadDesc *desc, const char segtype[NP_SEGTYPE_LEN], void *pdata, uint32_t *plen)
    +
    uint32_t NoteBinaryCodecDecode(const uint8_t *encData, uint32_t encDataLen, uint8_t *decBuf, uint32_t decBufSize)
    +
    uint32_t NoteBinaryCodecMaxEncodedLength(uint32_t unencodedLength)
    +
    bool NoteErrorContains(const char *errstr, const char *errtype)
    Check to see if a Notecard error is present in a JSON string.
    Definition: n_request.c:755
    +
    void NotePrintln(const char *line)
    +
    void NoteLockI2C(void)
    Lock the I2C bus using the platform-specific hook.
    Definition: n_hooks.c:584
    +
    bool NoteGetLocationMode(char *modeBuf, int modeBufLen)
    +
    JTIME NoteTimeST(void)
    +
    size_t(* debugOutputFn)(const char *text)
    Definition: note.h:138
    +
    char * JStringValue(J *item)
    Return the string representation of an item.
    Definition: n_cjson_helpers.c:145
    +
    char * NoteRequestResponseJSON(const char *reqJSON)
    Send a request to the Notecard and return the response.
    Definition: n_request.c:304
    +
    void NoteResumeTransactionDebug(void)
    Resume showing transaction details.
    Definition: n_request.c:84
    +
    bool NoteGetContact(char *nameBuf, int nameBufLen, char *orgBuf, int orgBufLen, char *roleBuf, int roleBufLen, char *emailBuf, int emailBufLen)
    +
    bool(* txnStartFn)(uint32_t timeoutMs)
    Definition: note.h:220
    +
    void NoteUnlockI2C(void)
    Unlock the I2C bus using the platform-specific hook.
    Definition: n_hooks.c:596
    +
    JNUMBER JNumberValue(J *item)
    Return the number representation of an item.
    Definition: n_cjson_helpers.c:160
    +
    JNUMBER JAtoN(const char *string, char **endPtr)
    +
    uint32_t NoteSetSTSecs(uint32_t secs)
    +
    J * NoteNewRequest(const char *request)
    Create a new JSON request.
    Definition: n_request.c:99
    +
    void NoteDelayMs(uint32_t ms)
    Delay milliseconds using the platform-specific hook.
    Definition: n_hooks.c:487
    +
    bool JContainsString(J *json, const char *field, const char *substr)
    Determine if a field exists, is a string and contains a provided value.
    Definition: n_cjson_helpers.c:339
    +
    void NoteTurboIO(bool enable)
    +
    void(* delayMsFn)(uint32_t ms)
    The type for the millisecond delay hook.
    Definition: note.h:129
    +
    bool NoteGetTemperature(JNUMBER *temp)
    +
    void NoteFree(void *)
    Free memory using the platform-specific hook.
    Definition: n_hooks.c:566
    +
    uint32_t NoteI2CMax(void)
    Determine the maximum number of bytes for each segment of data sent to the Notecard over I2C.
    Definition: n_hooks.c:811
    +
    void NoteSetUserAgent(char *agent)
    +
    bool NotePrint(const char *text)
    +
    bool NoteGetNetStatus(char *statusBuf, int statusBufLen)
    +
    bool NoteSetLocationMode(const char *mode, uint32_t seconds)
    +
    int JGetItemType(J *item)
    Definition: n_cjson_helpers.c:614
    +
    void NoteErrorClean(char *errbuf)
    Clean error strings out of the specified buffer.
    Definition: n_request.c:770
    +
    bool NoteSetEnvDefaultInt(const char *variable, JINTEGER defaultVal)
    +
    bool JBoolValue(J *item)
    Return the boolean representation of an item.
    Definition: n_cjson_helpers.c:130
    +
    void JItoA(JINTEGER n, char *s)
    Convert an integer to text.
    Definition: n_cjson_helpers.c:477
    +
    bool NotePayloadSaveAndSleep(NotePayloadDesc *desc, uint32_t seconds, const char *modes)
    +
    bool NoteSetEnvDefaultNumber(const char *variable, JNUMBER defaultVal)
    +
    uint32_t(* getMsFn)(void)
    The type for the millisecond counter hook.
    Definition: note.h:137
    +
    J * NoteNewCommand(const char *request)
    Create a new JSON command.
    Definition: n_request.c:120
    +
    int JB64Decode(char *plain_dst, const char *coded_src)
    +
    const char * NoteBinaryStoreReset(void)
    +
    bool JGetBinaryFromObject(J *json, const char *fieldName, uint8_t **retBinaryData, uint32_t *retBinaryDataLen)
    Decode a Base64-encoded string field in a JSON object and return the decoded bytes.
    Definition: n_cjson_helpers.c:413
    +
    uint32_t NoteGetMs(void)
    Get the current milliseconds value from the platform-specific hook.
    Definition: n_hooks.c:473
    +
    bool JGetBool(J *json, const char *field)
    Get the value of a boolean field from a JSON object.
    Definition: n_cjson_helpers.c:253
    +
    void NotePayloadFree(NotePayloadDesc *desc)
    +
    J * JGetArray(J *json, const char *field)
    Get the value of an array field from a JSON object.
    Definition: n_cjson_helpers.c:80
    +
    J * JGetObject(J *json, const char *field)
    Get the value of an object field from a JSON object.
    Definition: n_cjson_helpers.c:108
    +
    void NoteSetFnNoteMutex(mutexFn lockFn, mutexFn unlockFn)
    Set the platform-specific mutex functions for the Notecard.
    Definition: n_hooks.c:302
    +
    int JB64DecodeLen(const char *coded_src)
    +
    bool NoteLocationValid(char *errbuf, uint32_t errbuflen)
    +
    void(* txnStopFn)(void)
    Definition: note.h:221
    +
    bool NoteSleep(char *stateb64, uint32_t seconds, const char *modes)
    +
    void NoteMD5HashString(unsigned char *data, unsigned long len, char *strbuf, unsigned long buflen)
    +
    bool NoteSetLocation(JNUMBER lat, JNUMBER lon)
    +
    void(* freeFn)(void *mem)
    The type for the memory freeing hook.
    Definition: note.h:121
    +
    bool NotePayloadGetSegment(NotePayloadDesc *desc, const char segtype[NP_SEGTYPE_LEN], void *pdata, uint32_t len)
    +
    bool NoteLocalTimeST(uint16_t *retYear, uint8_t *retMonth, uint8_t *retDay, uint8_t *retHour, uint8_t *retMinute, uint8_t *retSecond, char **retWeekday, char **retZone)
    +
    void NoteSetFnDefault(mallocFn mallocfn, freeFn freefn, delayMsFn delayfn, getMsFn millisfn)
    Set the default memory and timing hooks if they aren't already set.
    Definition: n_hooks.c:194
    +
    uint32_t NoteI2CAddress(void)
    Get the I2C address of the Notecard.
    Definition: n_hooks.c:785
    +
    void NoteSetI2CAddress(uint32_t i2caddress)
    Set the I2C address for communication with the Notecard.
    Definition: n_hooks.c:799
    +
    bool(* serialAvailableFn)(void)
    The type for the serial available hook.
    Definition: note.h:168
    +
    J * NoteRequestResponseWithRetry(J *req, uint32_t timeoutSeconds)
    Send a request to the Notecard, retrying it until it succeeds or it times out, and return the respons...
    Definition: n_request.c:240
    +
    uint32_t NoteBinaryCodecMaxDecodedLength(uint32_t bufferSize)
    +
    bool NoteTemplate(const char *notefileID, J *templateBody)
    +
    bool NotePayloadRetrieveAfterSleep(NotePayloadDesc *desc)
    +
    bool NoteReset(void)
    Initialize or re-initialize the module.
    Definition: n_request.c:736
    +
    void NoteSetUserAgentOS(char *os_name, char *os_platform, char *os_family, char *os_version)
    +
    bool NoteSetSyncMode(const char *uploadMode, int uploadMinutes, int downloadMinutes, bool align, bool sync)
    +
    void NoteSetFnDebugOutput(debugOutputFn fn)
    Set the platform-specific debug output function.
    Definition: n_hooks.c:234
    +
    void NoteSetFnI2CMutex(mutexFn lockI2Cfn, mutexFn unlockI2Cfn)
    Set the platform-specific mutex functions for I2C.
    Definition: n_hooks.c:290
    +
    bool NoteSetProductID(const char *productID)
    +
    void NoteResetRequired(void)
    Mark that a reset will be required before doing further I/O on a given port.
    Definition: n_request.c:726
    +
    bool JIsPresent(J *json, const char *field)
    Determine if a field is present in a JSON object.
    Definition: n_cjson_helpers.c:28
    +
    bool NoteGetLocation(JNUMBER *retLat, JNUMBER *retLon, JTIME *time, char *statusBuf, int statusBufLen)
    +
    bool NoteSendToRoute(const char *method, const char *routeAlias, char *notefile, J *body)
    +
    bool(* serialResetFn)(void)
    The type for the serial reset hook.
    Definition: note.h:150
    +
    void NoteMD5Hash(unsigned char *data, unsigned long len, unsigned char *retHash)
    +
    int JBaseItemType(int type)
    Definition: n_cjson_helpers.c:673
    +
    void NoteMD5Transform(unsigned long buf[4], const unsigned char inraw[64])
    +
    J * NoteUserAgent(void)
    +
    JNUMBER JGetNumber(J *json, const char *field)
    Get the floating point value of a number field from a JSON object.
    Definition: n_cjson_helpers.c:182
    +
    bool NoteRequestWithRetry(J *req, uint32_t timeoutSeconds)
    Send a request to the Notecard, retrying it until it succeeds or it times out.
    Definition: n_request.c:178
    +
    const char * NoteBinaryStoreEncodedLength(uint32_t *len)
    +
    void NoteSetFnMutex(mutexFn lockI2Cfn, mutexFn unlockI2Cfn, mutexFn lockNotefn, mutexFn unlockNotefn)
    Set the platform-specific mutex functions for I2C and the Notecard.
    Definition: n_hooks.c:276
    +
    const char *(* i2cTransmitFn)(uint16_t address, uint8_t *txBuf, uint16_t txBufSize)
    The type for the I2C transmit hook.
    Definition: note.h:202
    +
    bool NoteGetEnv(const char *variable, const char *defaultVal, char *buf, uint32_t buflen)
    +
    bool NoteAdd(const char *target, J *body, bool urgent)
    +
    void NoteSetFnSerial(serialResetFn resetFn, serialTransmitFn transmitFn, serialAvailableFn availFn, serialReceiveFn receiveFn)
    Set the platform-specific hooks for communicating with the Notecard over serial.
    Definition: n_hooks.c:317
    +
    void NoteSetFnDisabled(void)
    Set the platform-specific communications method to be disabled.
    Definition: n_hooks.c:371
    +
    J * NoteTransaction(J *req)
    Send a request to the Notecard and return the response.
    Definition: n_request.c:435
    +
    uint32_t NoteBinaryCodecEncode(const uint8_t *decData, uint32_t decDataLen, uint8_t *encBuf, uint32_t encBufSize)
    +
    bool JAddBinaryToObject(J *json, const char *fieldName, const void *binaryData, uint32_t binaryDataLen)
    Add binary data as a Base64-encoded string field to a JSON object.
    Definition: n_cjson_helpers.c:372
    +
    void NoteSetFnTransaction(txnStartFn startFn, txnStopFn stopFn)
    Set the platform-specific transaction initiation/completion fn's.
    Definition: n_hooks.c:259
    +
    void * NoteMalloc(size_t size)
    Allocate a memory chunk using the platform-specific hook.
    Definition: n_hooks.c:548
    +
    char(* serialReceiveFn)(void)
    The type for the serial receive hook.
    Definition: note.h:177
    +
    int JB64EncodeLen(int len)
    +
    double JNUMBER
    The floating point type used for JSON handling in note-c.
    Definition: note.h:68
    +
    JINTEGER JIntValue(J *item)
    Return the integer representation of an item.
    Definition: n_cjson_helpers.c:204
    +
    bool NoteIsConnectedST(void)
    +
    bool NoteLocationValidST(char *errbuf, uint32_t errbuflen)
    +
    void JCheck(void)
    +
    uint64_t JUINTEGER
    The unsigned integer type used for JSON handling in note-c.
    Definition: note.h:81
    +
    #define NP_SEGTYPE_LEN
    Definition: note.h:529
    +
    char * JGetString(J *json, const char *field)
    Get the value of a string field from a JSON object.
    Definition: n_cjson_helpers.c:49
    +
    JINTEGER NoteGetEnvInt(const char *variable, JINTEGER defaultVal)
    +
    JUINTEGER JTIME
    Definition: note.h:86
    +
    JINTEGER JAtoI(const char *s)
    Convert text to an integer.
    Definition: n_cjson_helpers.c:512
    +
    char * JAllocString(uint8_t *buffer, uint32_t len)
    Convert a buffer/len to a null-terminated c-string.
    Definition: n_cjson_helpers.c:552
    +
    bool NoteSetContact(char *nameBuf, char *orgBuf, char *roleBuf, char *emailBuf)
    +
    bool NoteClearLocation(void)
    +
    bool JIsNullString(J *json, const char *field)
    Determine if a JSON object is valid and if a field is not present, or null.
    Definition: n_cjson_helpers.c:277
    +
    void NoteSuspendTransactionDebug(void)
    Suppress showing transaction details.
    Definition: n_request.c:76
    +
    bool NoteRequest(J *req)
    Send a request to the Notecard.
    Definition: n_request.c:147
    +
    J * NoteRequestResponse(J *req)
    Send a request to the Notecard and return the response.
    Definition: n_request.c:206
    +
    bool(* i2cResetFn)(uint16_t address)
    The type for the I2C reset hook.
    Definition: note.h:188
    +
    void NoteDebugf(const char *format,...)
    +
    void NoteDebug(const char *message)
    Write to the debug stream.
    Definition: n_hooks.c:421
    +
    void JInit(void)
    +
    bool NoteWake(int stateLen, void *state)
    +
    int64_t JINTEGER
    The signed integer type used for JSON handling in note-c.
    Definition: note.h:74
    +
    void NoteDebugIntln(const char *message, int n)
    Write a number to the debug stream and output a newline.
    Definition: n_hooks.c:392
    +
    bool NoteGetVersion(char *versionBuf, int versionBufLen)
    +
    int JB64Encode(char *coded_dst, const char *plain_src, int len_plain_src)
    +
    void NoteSetFnI2C(uint32_t notecardAddr, uint32_t maxTransmitSize, i2cResetFn resetFn, i2cTransmitFn transmitFn, i2cReceiveFn receiveFn)
    Set the platform-specific hooks for communicating with the Notecard over I2C, as well as the I2C addr...
    Definition: n_hooks.c:347
    +
    bool NoteTimeValidST(void)
    +
    bool NoteSetSerialNumber(const char *sn)
    +
    bool NoteGetServiceConfigST(char *productBuf, int productBufLen, char *serviceBuf, int serviceBufLen, char *deviceBuf, int deviceBufLen, char *snBuf, int snBufLen)
    +
    void(* mutexFn)(void)
    The type for the various mutex (i.e. lock/unlock) hooks.
    Definition: note.h:103
    +
    bool NotePrintf(const char *format,...)
    +
    const char * JGetItemName(const J *item)
    Get the object name.
    Definition: n_cjson_helpers.c:461
    +
    bool NoteGetServiceConfig(char *productBuf, int productBufLen, char *serviceBuf, int serviceBufLen, char *deviceBuf, int deviceBufLen, char *snBuf, int snBufLen)
    +
    void NoteUserAgentUpdate(J *ua)
    +
    void NoteMD5Final(unsigned char *digest, NoteMD5Context *ctx)
    +
    bool NoteGetVoltage(JNUMBER *voltage)
    +
    void NoteSetFn(mallocFn mallocHook, freeFn freeHook, delayMsFn delayMsHook, getMsFn getMsHook)
    Set the platform-specific memory and timing hooks.
    Definition: n_hooks.c:219
    +
    bool NoteIsConnected(void)
    +
    bool NotePayloadAddSegment(NotePayloadDesc *desc, const char segtype[NP_SEGTYPE_LEN], void *pdata, uint32_t plen)
    +
    bool NoteGetStatusST(char *statusBuf, int statusBufLen, JTIME *bootTime, bool *retUSB, bool *retSignals)
    +
    void NoteDebugWithLevel(uint8_t level, const char *msg)
    Write the message to the debug stream, if the level is less than or equal to NOTE_C_LOG_LEVEL....
    Definition: n_hooks.c:439
    +
    bool NoteDebugSyncStatus(int pollFrequencyMs, int maxLevel)
    +
    bool NoteRegion(char **retCountry, char **retArea, char **retZone, int *retZoneOffset)
    +
    const char * JType(J *item)
    Return the type of an item, as a string.
    Definition: n_cjson_helpers.c:572
    +
    bool NoteGetStatus(char *statusBuf, int statusBufLen, JTIME *bootTime, bool *retUSB, bool *retSignals)
    +
    char * JNtoA(JNUMBER f, char *buf, int precision)
    +
    void NoteMD5Update(NoteMD5Context *ctx, unsigned char const *buf, unsigned long len)
    +
    uint32_t NoteMemAvailable(void)
    +
    size_t strlcat(char *dst, const char *src, size_t siz)
    +
    void NotePayloadSet(NotePayloadDesc *desc, uint8_t *buf, uint32_t buflen)
    +
    void NoteDebugWithLevelLn(uint8_t level, const char *msg)
    Same as NoteDebugWithLevel, but add a newline at the end.
    Definition: n_hooks.c:460
    +
    size_t strlcpy(char *dst, const char *src, size_t siz)
    +
    bool NoteSetUploadMode(const char *uploadMode, int uploadMinutes, bool align)
    +
    const char *(* i2cReceiveFn)(uint16_t address, uint8_t *rxBuf, uint16_t rxBufSize, uint32_t *available)
    The type for the I2C receive hook.
    Definition: note.h:218
    +
    void NoteMD5Init(NoteMD5Context *ctx)
    +
    bool JIsExactString(J *json, const char *field, const char *teststr)
    Determine if a field exists, is a string and matches a provided value.
    Definition: n_cjson_helpers.c:308
    +
    void NoteTimeRefreshMins(uint32_t mins)
    +
    JNUMBER NoteGetEnvNumber(const char *variable, JNUMBER defaultVal)
    +
    void *(* mallocFn)(size_t size)
    The type for the memory allocation hook.
    Definition: note.h:113
    +
    bool NoteSetEnvDefault(const char *variable, char *buf)
    +
    bool NoteTimeValid(void)
    +
    const char * NoteBinaryStoreTransmit(uint8_t *unencodedData, uint32_t unencodedLen, uint32_t bufLen, uint32_t notecardOffset)
    +
    const char * NoteBinaryStoreDecodedLength(uint32_t *len)
    +
    The core JSON object type used by note-c.
    Definition: n_cjson.h:78
    +
    Definition: note.h:452
    +
    Definition: note.h:532
    +
    uint8_t * data
    Definition: note.h:533
    +
    uint32_t length
    Definition: note.h:535
    +
    uint32_t alloc
    Definition: note.h:534
    +
    + + + + diff --git a/doxygen/html/open.png b/doxygen/html/open.png new file mode 100644 index 00000000..30f75c7e Binary files /dev/null and b/doxygen/html/open.png differ diff --git a/doxygen/html/search/all_0.html b/doxygen/html/search/all_0.html new file mode 100644 index 00000000..1ec5b2d5 --- /dev/null +++ b/doxygen/html/search/all_0.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/all_0.js b/doxygen/html/search/all_0.js new file mode 100644 index 00000000..f22279da --- /dev/null +++ b/doxygen/html/search/all_0.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['_5fnote_5fc_5fstringize_0',['_NOTE_C_STRINGIZE',['../note_8h.html#a9d60cc6621d82d040e56afb6f1607d69',1,'note.h']]] +]; diff --git a/doxygen/html/search/all_1.html b/doxygen/html/search/all_1.html new file mode 100644 index 00000000..9f80e904 --- /dev/null +++ b/doxygen/html/search/all_1.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/all_1.js b/doxygen/html/search/all_1.js new file mode 100644 index 00000000..4406b904 --- /dev/null +++ b/doxygen/html/search/all_1.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['alloc_1',['alloc',['../struct_note_payload_desc.html#afb8e03b00c614d92cde2695938cd8ef1',1,'NotePayloadDesc']]] +]; diff --git a/doxygen/html/search/all_10.html b/doxygen/html/search/all_10.html new file mode 100644 index 00000000..3bf11961 --- /dev/null +++ b/doxygen/html/search/all_10.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/all_10.js b/doxygen/html/search/all_10.js new file mode 100644 index 00000000..8665e291 --- /dev/null +++ b/doxygen/html/search/all_10.js @@ -0,0 +1,15 @@ +var searchData= +[ + ['serialavailablefn_408',['serialAvailableFn',['../note_8h.html#a58f8d48fe891877b7702a013e63e6991',1,'note.h']]], + ['serialreceivefn_409',['serialReceiveFn',['../note_8h.html#a9a014c2bc8e94f611f98415b3d6b9569',1,'note.h']]], + ['serialresetfn_410',['serialResetFn',['../note_8h.html#a75873a7790764116d88f80aaaf23263b',1,'note.h']]], + ['serialtransmitfn_411',['serialTransmitFn',['../note_8h.html#a02dd02c70f8ef01f9ded212d5630f5e0',1,'note.h']]], + ['string_412',['string',['../struct_j.html#aedd40ac50e584c7b93e0046e404ae543',1,'J']]], + ['strlcat_413',['strlcat',['../note_8h.html#ae85b825a7f3d4dcf136b85949b646a46',1,'note.h']]], + ['strlcpy_414',['strlcpy',['../note_8h.html#aeb79f86261de904967d433c1b5e9a1de',1,'note.h']]], + ['syncstatus_5flevel_5falgorithmic_415',['SYNCSTATUS_LEVEL_ALGORITHMIC',['../note_8h.html#a148902b910ba060dac353c3871183403',1,'note.h']]], + ['syncstatus_5flevel_5fall_416',['SYNCSTATUS_LEVEL_ALL',['../note_8h.html#a11bc43f4578ce909ad4403cc3b15e79f',1,'note.h']]], + ['syncstatus_5flevel_5fdetailed_417',['SYNCSTATUS_LEVEL_DETAILED',['../note_8h.html#acdd8348847658b936879035020767bab',1,'note.h']]], + ['syncstatus_5flevel_5fmajor_418',['SYNCSTATUS_LEVEL_MAJOR',['../note_8h.html#a6081d56bf39642758465b3c1d155f853',1,'note.h']]], + ['syncstatus_5flevel_5fminor_419',['SYNCSTATUS_LEVEL_MINOR',['../note_8h.html#a17656ac3ed2c4e6a77b115417bf75a7a',1,'note.h']]] +]; diff --git a/doxygen/html/search/all_11.html b/doxygen/html/search/all_11.html new file mode 100644 index 00000000..c9f79d28 --- /dev/null +++ b/doxygen/html/search/all_11.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/all_11.js b/doxygen/html/search/all_11.js new file mode 100644 index 00000000..bd317cfc --- /dev/null +++ b/doxygen/html/search/all_11.js @@ -0,0 +1,21 @@ +var searchData= +[ + ['tbool_420',['TBOOL',['../note_8h.html#a18eddc8e4f0522a438b6475058e5ad32',1,'note.h']]], + ['tfloat16_421',['TFLOAT16',['../note_8h.html#a154fa3416f08de2b073fe6aef8c0104d',1,'note.h']]], + ['tfloat32_422',['TFLOAT32',['../note_8h.html#a340a46ea4717ab906196ee4ada26c0a0',1,'note.h']]], + ['tfloat64_423',['TFLOAT64',['../note_8h.html#a05a270325382e9d22be6317760dc800a',1,'note.h']]], + ['tint16_424',['TINT16',['../note_8h.html#a91ba007692878e4a02154c04ae390f39',1,'note.h']]], + ['tint24_425',['TINT24',['../note_8h.html#a2011bffb5bae1513306b0615f885ecc3',1,'note.h']]], + ['tint32_426',['TINT32',['../note_8h.html#ab1bbd49f40d8d7722f8ca7347bd83513',1,'note.h']]], + ['tint64_427',['TINT64',['../note_8h.html#a8437f26572687d03e061a0113af0cb0c',1,'note.h']]], + ['tint8_428',['TINT8',['../note_8h.html#a6186fd56a505b415b2ab2f50233c157f',1,'note.h']]], + ['tstring_429',['TSTRING',['../note_8h.html#ad7d1fa7b9a59ec5eba97dd784cbc29e9',1,'note.h']]], + ['tstringv_430',['TSTRINGV',['../note_8h.html#a465bf5c669736c4f4d64d185d736c5bb',1,'note.h']]], + ['tuint16_431',['TUINT16',['../note_8h.html#a1d8690165d7e8509f58efd34fd45041e',1,'note.h']]], + ['tuint24_432',['TUINT24',['../note_8h.html#a5a5e5e167c6cb206ea61d86cf030adb5',1,'note.h']]], + ['tuint32_433',['TUINT32',['../note_8h.html#a7f2af02b4c87ac0d4804ad8b5437d48d',1,'note.h']]], + ['tuint8_434',['TUINT8',['../note_8h.html#ade35b42a310f0bde7e6741c9ee7673b4',1,'note.h']]], + ['txnstartfn_435',['txnStartFn',['../note_8h.html#a294656e8c061b533f96003de5e4687fb',1,'note.h']]], + ['txnstopfn_436',['txnStopFn',['../note_8h.html#a5489831ee66f5f8c29021bfceaffb5ec',1,'note.h']]], + ['type_437',['type',['../struct_j.html#a1bb6f40b6adc8640b4beb11102b21c4b',1,'J']]] +]; diff --git a/doxygen/html/search/all_12.html b/doxygen/html/search/all_12.html new file mode 100644 index 00000000..ab934722 --- /dev/null +++ b/doxygen/html/search/all_12.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/all_12.js b/doxygen/html/search/all_12.js new file mode 100644 index 00000000..62c1060d --- /dev/null +++ b/doxygen/html/search/all_12.js @@ -0,0 +1,6 @@ +var searchData= +[ + ['valueint_438',['valueint',['../struct_j.html#a55e3d5d8de0cc6aff4d92c1b1228f7ea',1,'J']]], + ['valuenumber_439',['valuenumber',['../struct_j.html#ac62cf00a5cadeafc84d8d9fec38cfa50',1,'J']]], + ['valuestring_440',['valuestring',['../struct_j.html#a54f8d507791671d5f5951e8cae540232',1,'J']]] +]; diff --git a/doxygen/html/search/all_2.html b/doxygen/html/search/all_2.html new file mode 100644 index 00000000..02cfffc2 --- /dev/null +++ b/doxygen/html/search/all_2.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/all_2.js b/doxygen/html/search/all_2.js new file mode 100644 index 00000000..928c321c --- /dev/null +++ b/doxygen/html/search/all_2.js @@ -0,0 +1,7 @@ +var searchData= +[ + ['bits_2',['bits',['../struct_note_m_d5_context.html#a79dcc9210c65fe4f31eb4295b2fc9510',1,'NoteMD5Context']]], + ['buf_3',['buf',['../struct_note_m_d5_context.html#ad58666280287db0368333c2f50465f02',1,'NoteMD5Context']]], + ['buffer_4',['buffer',['../structprintbuffer.html#a754f63618e91db99f7ab6cfc4e629013',1,'printbuffer']]], + ['buffer_5fat_5foffset_5',['buffer_at_offset',['../n__cjson_8c.html#ac538057ef78677344d222b763251af5e',1,'n_cjson.c']]] +]; diff --git a/doxygen/html/search/all_3.html b/doxygen/html/search/all_3.html new file mode 100644 index 00000000..39767b85 --- /dev/null +++ b/doxygen/html/search/all_3.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/all_3.js b/doxygen/html/search/all_3.js new file mode 100644 index 00000000..c2eea329 --- /dev/null +++ b/doxygen/html/search/all_3.js @@ -0,0 +1,12 @@ +var searchData= +[ + ['can_5faccess_5fat_5findex_6',['can_access_at_index',['../n__cjson_8c.html#ae210aa01f1afe7510658c392f0f6e128',1,'n_cjson.c']]], + ['can_5fread_7',['can_read',['../n__cjson_8c.html#a2257377f8b81f4f76a16b698f681af34',1,'n_cjson.c']]], + ['cannot_5faccess_5fat_5findex_8',['cannot_access_at_index',['../n__cjson_8c.html#a5c873a43d8a78ce9a6d9e8eb41d65d2d',1,'n_cjson.c']]], + ['child_9',['child',['../struct_j.html#ab4ff5a4f92fa47b521015ef15e6da518',1,'J']]], + ['cjson_5fmin_10',['cjson_min',['../n__cjson_8c.html#a13f540fa846f658531751b5ccb78f303',1,'n_cjson.c']]], + ['content_11',['content',['../structparse__buffer.html#a52ee1184576baa3d5171059ab0e942de',1,'parse_buffer']]], + ['crc_5ffield_5flength_12',['CRC_FIELD_LENGTH',['../n__request_8c.html#a8334a93acebb34e7bc188f767dc42f90',1,'n_request.c']]], + ['crc_5ffield_5fname_5foffset_13',['CRC_FIELD_NAME_OFFSET',['../n__request_8c.html#a370d78366b4c13731108b1afd745b4ce',1,'n_request.c']]], + ['crc_5ffield_5fname_5ftest_14',['CRC_FIELD_NAME_TEST',['../n__request_8c.html#ac5f2372cc25a915c8dccd2924c7c6f19',1,'n_request.c']]] +]; diff --git a/doxygen/html/search/all_4.html b/doxygen/html/search/all_4.html new file mode 100644 index 00000000..fc40463c --- /dev/null +++ b/doxygen/html/search/all_4.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/all_4.js b/doxygen/html/search/all_4.js new file mode 100644 index 00000000..42cc89a6 --- /dev/null +++ b/doxygen/html/search/all_4.js @@ -0,0 +1,7 @@ +var searchData= +[ + ['data_15',['data',['../struct_note_payload_desc.html#a05effe66a8c405ee11e9b1d8758d322a',1,'NotePayloadDesc']]], + ['debugoutputfn_16',['debugOutputFn',['../note_8h.html#a233e9fec868082bb68e23c6e73af67a2',1,'note.h']]], + ['delaymsfn_17',['delayMsFn',['../note_8h.html#a323baf90f21427329bfb7ef9a61c83d7',1,'note.h']]], + ['depth_18',['depth',['../structparse__buffer.html#af613c4ed7d73f76c60c50d1bcf4c67a0',1,'parse_buffer::depth()'],['../structprintbuffer.html#aa7311b5da38ff8d1737824c611b48732',1,'printbuffer::depth()']]] +]; diff --git a/doxygen/html/search/all_5.html b/doxygen/html/search/all_5.html new file mode 100644 index 00000000..9dd9344b --- /dev/null +++ b/doxygen/html/search/all_5.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/all_5.js b/doxygen/html/search/all_5.js new file mode 100644 index 00000000..cdfb55da --- /dev/null +++ b/doxygen/html/search/all_5.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['error_19',['error',['../structerror.html',1,'']]], + ['errstr_20',['ERRSTR',['../note_8h.html#a842e0f5c7170ddfde0164bad199d6fdc',1,'note.h']]] +]; diff --git a/doxygen/html/search/all_6.html b/doxygen/html/search/all_6.html new file mode 100644 index 00000000..f1e516d7 --- /dev/null +++ b/doxygen/html/search/all_6.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/all_6.js b/doxygen/html/search/all_6.js new file mode 100644 index 00000000..1a7698f3 --- /dev/null +++ b/doxygen/html/search/all_6.js @@ -0,0 +1,6 @@ +var searchData= +[ + ['format_21',['format',['../structprintbuffer.html#a38337d25a56957deebce187d9ab089ef',1,'printbuffer']]], + ['free_5ffn_22',['free_fn',['../struct_j_hooks.html#a154d673fa4669abf51f7848c2c299718',1,'JHooks']]], + ['freefn_23',['freeFn',['../note_8h.html#a570f0444ac7f08f8d66bd12cf49b662c',1,'note.h']]] +]; diff --git a/doxygen/html/search/all_7.html b/doxygen/html/search/all_7.html new file mode 100644 index 00000000..8ddbf6c8 --- /dev/null +++ b/doxygen/html/search/all_7.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/all_7.js b/doxygen/html/search/all_7.js new file mode 100644 index 00000000..35c7958a --- /dev/null +++ b/doxygen/html/search/all_7.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['getmsfn_24',['getMsFn',['../note_8h.html#a4717d9986b1e1b5db55590abd6fc9910',1,'note.h']]] +]; diff --git a/doxygen/html/search/all_8.html b/doxygen/html/search/all_8.html new file mode 100644 index 00000000..83c55ae2 --- /dev/null +++ b/doxygen/html/search/all_8.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/all_8.js b/doxygen/html/search/all_8.js new file mode 100644 index 00000000..d59ee7fe --- /dev/null +++ b/doxygen/html/search/all_8.js @@ -0,0 +1,22 @@ +var searchData= +[ + ['hookactiveinterface_25',['hookActiveInterface',['../n__hooks_8c.html#a2e1147a166cf94837f8793746231acce',1,'n_hooks.c']]], + ['hookdebugoutput_26',['hookDebugOutput',['../n__hooks_8c.html#a11663e8bd175750e1e06c8201a5478a8',1,'n_hooks.c']]], + ['hookdelayms_27',['hookDelayMs',['../n__hooks_8c.html#a18e7b68c9f867dcd0818086f602e932f',1,'n_hooks.c']]], + ['hookfree_28',['hookFree',['../n__hooks_8c.html#ac3f19a99b0efcdf65efdb56ab8c83950',1,'n_hooks.c']]], + ['hookgetms_29',['hookGetMs',['../n__hooks_8c.html#a06884d23d5f78279deb3a32a43ef4694',1,'n_hooks.c']]], + ['hooki2creceive_30',['hookI2CReceive',['../n__hooks_8c.html#a263455cdbf1fc17b92a975c7535f1950',1,'n_hooks.c']]], + ['hooki2creset_31',['hookI2CReset',['../n__hooks_8c.html#a57e8dca746e7d85e7eabfb0b7bee4572',1,'n_hooks.c']]], + ['hooki2ctransmit_32',['hookI2CTransmit',['../n__hooks_8c.html#aa0d2d6474eba5963389d55f795968cb6',1,'n_hooks.c']]], + ['hooklocki2c_33',['hookLockI2C',['../n__hooks_8c.html#a3f891ce572bd99b70a8c20f999d5942d',1,'n_hooks.c']]], + ['hooklocknote_34',['hookLockNote',['../n__hooks_8c.html#a37517c21bcce9f3a523beb50838b1126',1,'n_hooks.c']]], + ['hookmalloc_35',['hookMalloc',['../n__hooks_8c.html#a82e929c5ea774f51f743646d088c7067',1,'n_hooks.c']]], + ['hookserialavailable_36',['hookSerialAvailable',['../n__hooks_8c.html#a85a763552201e904319a46d7bbaffb2f',1,'n_hooks.c']]], + ['hookserialreceive_37',['hookSerialReceive',['../n__hooks_8c.html#abb53cb4c8b5875405005a10f8e5dd276',1,'n_hooks.c']]], + ['hookserialreset_38',['hookSerialReset',['../n__hooks_8c.html#a8b924ad75dc42dbb9f55e39bbb383e53',1,'n_hooks.c']]], + ['hookserialtransmit_39',['hookSerialTransmit',['../n__hooks_8c.html#adc5dbf6a449a062dc2ce585b377e01c8',1,'n_hooks.c']]], + ['hooktransactionstart_40',['hookTransactionStart',['../n__hooks_8c.html#a2862300245c7f82df19c4f3a3a79f759',1,'n_hooks.c']]], + ['hooktransactionstop_41',['hookTransactionStop',['../n__hooks_8c.html#aee65145a7f7916880913d039ee9dec70',1,'n_hooks.c']]], + ['hookunlocki2c_42',['hookUnlockI2C',['../n__hooks_8c.html#a0188e2a3e1e67ab47bb31ffaca28c0f1',1,'n_hooks.c']]], + ['hookunlocknote_43',['hookUnlockNote',['../n__hooks_8c.html#a79775290fccd64212d68cf8bf37fce1a',1,'n_hooks.c']]] +]; diff --git a/doxygen/html/search/all_9.html b/doxygen/html/search/all_9.html new file mode 100644 index 00000000..1e263c13 --- /dev/null +++ b/doxygen/html/search/all_9.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/all_9.js b/doxygen/html/search/all_9.js new file mode 100644 index 00000000..d0af2242 --- /dev/null +++ b/doxygen/html/search/all_9.js @@ -0,0 +1,12 @@ +var searchData= +[ + ['i2caddress_44',['i2cAddress',['../n__hooks_8c.html#ad55843178b5a1e1ecfba8e9b53544c57',1,'n_hooks.c']]], + ['i2cmax_45',['i2cMax',['../n__hooks_8c.html#a6b4abd91cf929e64478a77b3cab5c793',1,'n_hooks.c']]], + ['i2creceivefn_46',['i2cReceiveFn',['../note_8h.html#aef5eac1396470d4d872d979aaf95cbb2',1,'note.h']]], + ['i2cresetfn_47',['i2cResetFn',['../note_8h.html#ab18cc9957da000e5a05db53d4543d26b',1,'note.h']]], + ['i2ctransmitfn_48',['i2cTransmitFn',['../note_8h.html#a841b338ac017194680b08ec57c179efc',1,'note.h']]], + ['in_49',['in',['../struct_note_m_d5_context.html#af22373f810c98e50af1890c0a5e8cfa1',1,'NoteMD5Context']]], + ['interfacei2c_50',['interfaceI2C',['../n__hooks_8c.html#a27a151021020827bdb6304575544bb47',1,'n_hooks.c']]], + ['interfacenone_51',['interfaceNone',['../n__hooks_8c.html#ac12390f151d06023c61fbc03ffba5a13',1,'n_hooks.c']]], + ['interfaceserial_52',['interfaceSerial',['../n__hooks_8c.html#a61d64f8102ea568c7ed64584369c1779',1,'n_hooks.c']]] +]; diff --git a/doxygen/html/search/all_a.html b/doxygen/html/search/all_a.html new file mode 100644 index 00000000..3a6cac10 --- /dev/null +++ b/doxygen/html/search/all_a.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/all_a.js b/doxygen/html/search/all_a.js new file mode 100644 index 00000000..3a75d2ec --- /dev/null +++ b/doxygen/html/search/all_a.js @@ -0,0 +1,157 @@ +var searchData= +[ + ['j_53',['J',['../struct_j.html',1,'J'],['../n__cjson_8h.html#a08f69cc109c0024a645dafe4b3cbdeb3',1,'J(): n_cjson.h']]], + ['jaddarraytoobject_54',['JAddArrayToObject',['../n__cjson_8h.html#a7cd4c6c618fcaad6ac3582f09b7937e9',1,'JAddArrayToObject(J *const object, const char *const name): n_cjson.c'],['../n__cjson_8c.html#a7cd4c6c618fcaad6ac3582f09b7937e9',1,'JAddArrayToObject(J *const object, const char *const name): n_cjson.c']]], + ['jaddbinarytoobject_55',['JAddBinaryToObject',['../n__cjson__helpers_8c.html#a9378ea8eddda1f23c815b69591747846',1,'JAddBinaryToObject(J *json, const char *fieldName, const void *binaryData, uint32_t binaryDataLen): n_cjson_helpers.c'],['../note_8h.html#a9378ea8eddda1f23c815b69591747846',1,'JAddBinaryToObject(J *json, const char *fieldName, const void *binaryData, uint32_t binaryDataLen): n_cjson_helpers.c']]], + ['jaddbooltoobject_56',['JAddBoolToObject',['../n__cjson_8h.html#ada94bbdf4ef161ed96a9ad97da05bfcb',1,'JAddBoolToObject(J *const object, const char *const name, const Jbool boolean): n_cjson.c'],['../n__cjson_8c.html#ada94bbdf4ef161ed96a9ad97da05bfcb',1,'JAddBoolToObject(J *const object, const char *const name, const Jbool boolean): n_cjson.c']]], + ['jaddfalsetoobject_57',['JAddFalseToObject',['../n__cjson_8h.html#ad64ecd3c612bcf123846d501b0d5700b',1,'JAddFalseToObject(J *const object, const char *const name): n_cjson.c'],['../n__cjson_8c.html#ad64ecd3c612bcf123846d501b0d5700b',1,'JAddFalseToObject(J *const object, const char *const name): n_cjson.c']]], + ['jaddinttoobject_58',['JAddIntToObject',['../n__cjson_8h.html#a6dd643b7f5ba26a812c4d9cac4482249',1,'JAddIntToObject(J *const object, const char *const name, const JINTEGER integer): n_cjson.c'],['../n__cjson_8c.html#a6dd643b7f5ba26a812c4d9cac4482249',1,'JAddIntToObject(J *const object, const char *const name, const JINTEGER integer): n_cjson.c']]], + ['jadditemreferencetoarray_59',['JAddItemReferenceToArray',['../n__cjson_8h.html#acd1c75541c79aaf01f779286a0ce80d1',1,'JAddItemReferenceToArray(J *array, J *item): n_cjson.c'],['../n__cjson_8c.html#acd1c75541c79aaf01f779286a0ce80d1',1,'JAddItemReferenceToArray(J *array, J *item): n_cjson.c']]], + ['jadditemreferencetoobject_60',['JAddItemReferenceToObject',['../n__cjson_8c.html#ab77e67888463113228be8786a31f48d0',1,'JAddItemReferenceToObject(J *object, const char *string, J *item): n_cjson.c'],['../n__cjson_8h.html#ab77e67888463113228be8786a31f48d0',1,'JAddItemReferenceToObject(J *object, const char *string, J *item): n_cjson.c']]], + ['jadditemtoarray_61',['JAddItemToArray',['../n__cjson_8h.html#a35cec7da03622637f3be481198c7c97d',1,'JAddItemToArray(J *array, J *item): n_cjson.c'],['../n__cjson_8c.html#a35cec7da03622637f3be481198c7c97d',1,'JAddItemToArray(J *array, J *item): n_cjson.c']]], + ['jadditemtoobject_62',['JAddItemToObject',['../n__cjson_8h.html#a3430617fcd905e9d3d997354cb7e23cc',1,'JAddItemToObject(J *object, const char *string, J *item): n_cjson.c'],['../n__cjson_8c.html#a3430617fcd905e9d3d997354cb7e23cc',1,'JAddItemToObject(J *object, const char *string, J *item): n_cjson.c']]], + ['jadditemtoobjectcs_63',['JAddItemToObjectCS',['../n__cjson_8h.html#aedf66bf41048a0cfcb61a3803ed28ba0',1,'JAddItemToObjectCS(J *object, const char *string, J *item): n_cjson.c'],['../n__cjson_8c.html#aedf66bf41048a0cfcb61a3803ed28ba0',1,'JAddItemToObjectCS(J *object, const char *string, J *item): n_cjson.c']]], + ['jaddnumbertoobject_64',['JAddNumberToObject',['../n__cjson_8h.html#a4ec54b4a0b1f546f450ebdffa6a2b180',1,'JAddNumberToObject(J *const object, const char *const name, const JNUMBER number): n_cjson.c'],['../n__cjson_8c.html#a4ec54b4a0b1f546f450ebdffa6a2b180',1,'JAddNumberToObject(J *const object, const char *const name, const JNUMBER number): n_cjson.c']]], + ['jaddobjecttoobject_65',['JAddObjectToObject',['../n__cjson_8h.html#afa68057664156c8be1b1caabdd9ba851',1,'JAddObjectToObject(J *const object, const char *const name): n_cjson.c'],['../n__cjson_8c.html#afa68057664156c8be1b1caabdd9ba851',1,'JAddObjectToObject(J *const object, const char *const name): n_cjson.c']]], + ['jaddrawtoobject_66',['JAddRawToObject',['../n__cjson_8h.html#adc9d093f67cb53eb2b2264b27bfb00e4',1,'JAddRawToObject(J *const object, const char *const name, const char *const raw): n_cjson.c'],['../n__cjson_8c.html#adc9d093f67cb53eb2b2264b27bfb00e4',1,'JAddRawToObject(J *const object, const char *const name, const char *const raw): n_cjson.c']]], + ['jaddstringtoobject_67',['JAddStringToObject',['../n__cjson_8h.html#ae1162e04a1b4a9a2f59d5f98dc79d70c',1,'JAddStringToObject(J *const object, const char *const name, const char *const string): n_cjson.c'],['../n__cjson_8c.html#ae1162e04a1b4a9a2f59d5f98dc79d70c',1,'JAddStringToObject(J *const object, const char *const name, const char *const string): n_cjson.c']]], + ['jaddtruetoobject_68',['JAddTrueToObject',['../n__cjson_8c.html#a29a6911bfbeddb6d995a75aae73963da',1,'JAddTrueToObject(J *const object, const char *const name): n_cjson.c'],['../n__cjson_8h.html#a29a6911bfbeddb6d995a75aae73963da',1,'JAddTrueToObject(J *const object, const char *const name): n_cjson.c']]], + ['jallocstring_69',['JAllocString',['../note_8h.html#aacfb17275b3a24dc751834205db62e79',1,'JAllocString(uint8_t *buffer, uint32_t len): n_cjson_helpers.c'],['../n__cjson__helpers_8c.html#aacfb17275b3a24dc751834205db62e79',1,'JAllocString(uint8_t *buffer, uint32_t len): n_cjson_helpers.c']]], + ['jarray_70',['JArray',['../n__cjson_8h.html#a9948138a2efa4524c27f4381b75edf78',1,'n_cjson.h']]], + ['jarrayforeach_71',['JArrayForEach',['../n__cjson_8h.html#abf5a971e7edd30b9fdc23322cb275e23',1,'n_cjson.h']]], + ['jatoi_72',['JAtoI',['../n__cjson__helpers_8c.html#a308f04aae0351a47e78c6974c0ced6e6',1,'JAtoI(const char *string): n_cjson_helpers.c'],['../note_8h.html#aab6ee0e6d2c3b0836c6ab294c5626d01',1,'JAtoI(const char *s): n_cjson_helpers.c']]], + ['jaton_73',['JAtoN',['../note_8h.html#a2cc99bbc9c2ede0b85f310a775960f3f',1,'note.h']]], + ['jb64decode_74',['JB64Decode',['../note_8h.html#a48c6cad9358d4154567949c192445a9e',1,'note.h']]], + ['jb64decodelen_75',['JB64DecodeLen',['../note_8h.html#a53559c7bc512587f6776794a78fc424f',1,'note.h']]], + ['jb64encode_76',['JB64Encode',['../note_8h.html#abd22cd7117763400021d6653a33f0d94',1,'note.h']]], + ['jb64encodelen_77',['JB64EncodeLen',['../note_8h.html#a9c5d969e2bfd9cbda902e6388285e624',1,'note.h']]], + ['jbaseitemtype_78',['JBaseItemType',['../n__cjson__helpers_8c.html#a791851ed95cd350c24f33af25e7f0af8',1,'JBaseItemType(int type): n_cjson_helpers.c'],['../note_8h.html#a791851ed95cd350c24f33af25e7f0af8',1,'JBaseItemType(int type): n_cjson_helpers.c']]], + ['jbool_79',['Jbool',['../n__cjson_8h.html#abcfad9bdd54f2729b7e1c3891289f8dd',1,'n_cjson.h']]], + ['jboolvalue_80',['JBoolValue',['../n__cjson__helpers_8c.html#a3e836494d9b3a6fc4e4b02dc2767df83',1,'JBoolValue(J *item): n_cjson_helpers.c'],['../note_8h.html#a3e836494d9b3a6fc4e4b02dc2767df83',1,'JBoolValue(J *item): n_cjson_helpers.c']]], + ['jcheck_81',['JCheck',['../note_8h.html#aa2c94029f47ff6dab5fe3087d8efef4f',1,'note.h']]], + ['jcompare_82',['JCompare',['../n__cjson_8c.html#a29a204614c3c8a73a1eed2482f31ab15',1,'JCompare(const J *const a, const J *const b, const Jbool case_sensitive): n_cjson.c'],['../n__cjson_8h.html#a29a204614c3c8a73a1eed2482f31ab15',1,'JCompare(const J *const a, const J *const b, const Jbool case_sensitive): n_cjson.c']]], + ['jcontainsstring_83',['JContainsString',['../n__cjson__helpers_8c.html#a31742b8fc463be8e85fe6f1b269bf9bb',1,'JContainsString(J *json, const char *field, const char *substr): n_cjson_helpers.c'],['../note_8h.html#a31742b8fc463be8e85fe6f1b269bf9bb',1,'JContainsString(J *json, const char *field, const char *substr): n_cjson_helpers.c']]], + ['jconvertfromjsonstring_84',['JConvertFromJSONString',['../n__cjson_8h.html#a4502909a13d0852d700ed45c692804cd',1,'n_cjson.h']]], + ['jconverttojsonstring_85',['JConvertToJSONString',['../n__cjson_8h.html#a5c58c74c07ecf18d0ffff0c989c01d31',1,'n_cjson.h']]], + ['jcreatearray_86',['JCreateArray',['../n__cjson_8h.html#ad75827f86360241ca657ae848d16c243',1,'JCreateArray(void): n_cjson.c'],['../n__cjson_8c.html#ad75827f86360241ca657ae848d16c243',1,'JCreateArray(void): n_cjson.c']]], + ['jcreatearrayreference_87',['JCreateArrayReference',['../n__cjson_8h.html#a748dd4e91fbe2f6ebe288f8299dd1f2c',1,'JCreateArrayReference(const J *child): n_cjson.c'],['../n__cjson_8c.html#a748dd4e91fbe2f6ebe288f8299dd1f2c',1,'JCreateArrayReference(const J *child): n_cjson.c']]], + ['jcreatebool_88',['JCreateBool',['../n__cjson_8h.html#a62626c03b8dad6a17b15dfc2d8909a70',1,'JCreateBool(Jbool boolean): n_cjson.c'],['../n__cjson_8c.html#aafa53ebad89699a6d9569682b938b68b',1,'JCreateBool(Jbool b): n_cjson.c']]], + ['jcreatefalse_89',['JCreateFalse',['../n__cjson_8h.html#af6e5c9bd6c503f8951a38825899ef781',1,'JCreateFalse(void): n_cjson.c'],['../n__cjson_8c.html#af6e5c9bd6c503f8951a38825899ef781',1,'JCreateFalse(void): n_cjson.c']]], + ['jcreateintarray_90',['JCreateIntArray',['../n__cjson_8h.html#aa73ca2d1f034e715996630e10e35bdf8',1,'JCreateIntArray(const long int *numbers, int count): n_cjson.c'],['../n__cjson_8c.html#aa73ca2d1f034e715996630e10e35bdf8',1,'JCreateIntArray(const long int *numbers, int count): n_cjson.c']]], + ['jcreateinteger_91',['JCreateInteger',['../n__cjson_8h.html#a16770eadd67555bc26998098fcadf2ea',1,'JCreateInteger(JINTEGER integer): n_cjson.c'],['../n__cjson_8c.html#a16770eadd67555bc26998098fcadf2ea',1,'JCreateInteger(JINTEGER integer): n_cjson.c']]], + ['jcreatenumber_92',['JCreateNumber',['../n__cjson_8h.html#a7d36cc32deaf942b62cd14edcf14110e',1,'JCreateNumber(JNUMBER num): n_cjson.c'],['../n__cjson_8c.html#a7d36cc32deaf942b62cd14edcf14110e',1,'JCreateNumber(JNUMBER num): n_cjson.c']]], + ['jcreatenumberarray_93',['JCreateNumberArray',['../n__cjson_8h.html#ac72aae948a85f2b04515cb1908a2bdb2',1,'JCreateNumberArray(const JNUMBER *numbers, int count): n_cjson.c'],['../n__cjson_8c.html#ac72aae948a85f2b04515cb1908a2bdb2',1,'JCreateNumberArray(const JNUMBER *numbers, int count): n_cjson.c']]], + ['jcreateobject_94',['JCreateObject',['../n__cjson_8h.html#ae86ee2002e7ae53d7fa6ccfcae55de0e',1,'JCreateObject(void): n_cjson.c'],['../n__cjson_8c.html#ae86ee2002e7ae53d7fa6ccfcae55de0e',1,'JCreateObject(void): n_cjson.c']]], + ['jcreateobjectreference_95',['JCreateObjectReference',['../n__cjson_8h.html#a4ba40c853dd17baed1d1e02025b4b908',1,'JCreateObjectReference(const J *child): n_cjson.c'],['../n__cjson_8c.html#a4ba40c853dd17baed1d1e02025b4b908',1,'JCreateObjectReference(const J *child): n_cjson.c']]], + ['jcreateraw_96',['JCreateRaw',['../n__cjson_8h.html#a253c87633d076994278559b2dca8b326',1,'JCreateRaw(const char *raw): n_cjson.c'],['../n__cjson_8c.html#a253c87633d076994278559b2dca8b326',1,'JCreateRaw(const char *raw): n_cjson.c']]], + ['jcreatestring_97',['JCreateString',['../n__cjson_8c.html#a2f5a9a0a2d094b3a7dcfb2682974adb3',1,'JCreateString(const char *string): n_cjson.c'],['../n__cjson_8h.html#a2f5a9a0a2d094b3a7dcfb2682974adb3',1,'JCreateString(const char *string): n_cjson.c']]], + ['jcreatestringarray_98',['JCreateStringArray',['../n__cjson_8h.html#a593f675d4d3c6880d6342a278f705b45',1,'JCreateStringArray(const char **strings, int count): n_cjson.c'],['../n__cjson_8c.html#a593f675d4d3c6880d6342a278f705b45',1,'JCreateStringArray(const char **strings, int count): n_cjson.c']]], + ['jcreatestringreference_99',['JCreateStringReference',['../n__cjson_8h.html#a9a7bd4cef73e4cd16da0d3596ed8828c',1,'JCreateStringReference(const char *string): n_cjson.c'],['../n__cjson_8c.html#a9a7bd4cef73e4cd16da0d3596ed8828c',1,'JCreateStringReference(const char *string): n_cjson.c']]], + ['jcreatestringvalue_100',['JCreateStringValue',['../n__cjson_8h.html#ad0c31477e03ca9725efdf5c4f23f1b21',1,'JCreateStringValue(const char *string): n_cjson.c'],['../n__cjson_8c.html#ad0c31477e03ca9725efdf5c4f23f1b21',1,'JCreateStringValue(const char *string): n_cjson.c']]], + ['jcreatetrue_101',['JCreateTrue',['../n__cjson_8c.html#ac4239abc5da80657b4ac258ca3441525',1,'JCreateTrue(void): n_cjson.c'],['../n__cjson_8h.html#ac4239abc5da80657b4ac258ca3441525',1,'JCreateTrue(void): n_cjson.c']]], + ['jdelete_102',['JDelete',['../n__cjson_8h.html#a200e39becef910970302806821377a02',1,'JDelete(J *c): n_cjson.c'],['../n__cjson_8c.html#a68aef53f8739bf4a34f9dd73af9a6a4b',1,'JDelete(J *item): n_cjson.c']]], + ['jdeleteitemfromarray_103',['JDeleteItemFromArray',['../n__cjson_8h.html#af895529b28a3a7ee2e65e75ae1703abb',1,'JDeleteItemFromArray(J *array, int which): n_cjson.c'],['../n__cjson_8c.html#af895529b28a3a7ee2e65e75ae1703abb',1,'JDeleteItemFromArray(J *array, int which): n_cjson.c']]], + ['jdeleteitemfromobject_104',['JDeleteItemFromObject',['../n__cjson_8h.html#a469200cf78eb64693c306b8c2bb8fca6',1,'JDeleteItemFromObject(J *object, const char *string): n_cjson.c'],['../n__cjson_8c.html#a469200cf78eb64693c306b8c2bb8fca6',1,'JDeleteItemFromObject(J *object, const char *string): n_cjson.c']]], + ['jdeleteitemfromobjectcasesensitive_105',['JDeleteItemFromObjectCaseSensitive',['../n__cjson_8h.html#a4d2345eb658b861b6be499ae156eb4d5',1,'JDeleteItemFromObjectCaseSensitive(J *object, const char *string): n_cjson.c'],['../n__cjson_8c.html#a4d2345eb658b861b6be499ae156eb4d5',1,'JDeleteItemFromObjectCaseSensitive(J *object, const char *string): n_cjson.c']]], + ['jdetachitemfromarray_106',['JDetachItemFromArray',['../n__cjson_8h.html#ac76b43d7456f0d9b20dfb05afb34de2f',1,'JDetachItemFromArray(J *array, int which): n_cjson.c'],['../n__cjson_8c.html#ac76b43d7456f0d9b20dfb05afb34de2f',1,'JDetachItemFromArray(J *array, int which): n_cjson.c']]], + ['jdetachitemfromobject_107',['JDetachItemFromObject',['../n__cjson_8h.html#a1a32853dd45405ad607a12fc73704060',1,'JDetachItemFromObject(J *object, const char *string): n_cjson.c'],['../n__cjson_8c.html#a1a32853dd45405ad607a12fc73704060',1,'JDetachItemFromObject(J *object, const char *string): n_cjson.c']]], + ['jdetachitemfromobjectcasesensitive_108',['JDetachItemFromObjectCaseSensitive',['../n__cjson_8h.html#a8091581926873615eb209c29281bff96',1,'JDetachItemFromObjectCaseSensitive(J *object, const char *string): n_cjson.c'],['../n__cjson_8c.html#a8091581926873615eb209c29281bff96',1,'JDetachItemFromObjectCaseSensitive(J *object, const char *string): n_cjson.c']]], + ['jdetachitemviapointer_109',['JDetachItemViaPointer',['../n__cjson_8c.html#afe5cf91e0f429c5d419d1107a5337232',1,'JDetachItemViaPointer(J *parent, J *const item): n_cjson.c'],['../n__cjson_8h.html#afe5cf91e0f429c5d419d1107a5337232',1,'JDetachItemViaPointer(J *parent, J *const item): n_cjson.c']]], + ['jduplicate_110',['JDuplicate',['../n__cjson_8h.html#adddee3d8407e149c5e4b77c139a0fcd9',1,'JDuplicate(const J *item, Jbool recurse): n_cjson.c'],['../n__cjson_8c.html#adddee3d8407e149c5e4b77c139a0fcd9',1,'JDuplicate(const J *item, Jbool recurse): n_cjson.c']]], + ['jfalse_111',['JFalse',['../n__cjson_8h.html#a4c4e8a545657ef9148ffb476b0a93074',1,'n_cjson.h']]], + ['jfree_112',['JFree',['../n__cjson_8h.html#a65411d47da558e0084a07a773275218b',1,'JFree(void *object): n_cjson.c'],['../n__cjson_8c.html#abf261bfa6bcacd681e976231d1d974d3',1,'JFree(void *p): n_cjson.c']]], + ['jgetarray_113',['JGetArray',['../n__cjson__helpers_8c.html#a529a0e079866616aa12e4598296e462f',1,'JGetArray(J *json, const char *field): n_cjson_helpers.c'],['../note_8h.html#a529a0e079866616aa12e4598296e462f',1,'JGetArray(J *json, const char *field): n_cjson_helpers.c']]], + ['jgetarrayitem_114',['JGetArrayItem',['../n__cjson_8h.html#af581f6c7ed4c9348939c3c52b043caa9',1,'JGetArrayItem(const J *array, int index): n_cjson.c'],['../n__cjson_8c.html#af581f6c7ed4c9348939c3c52b043caa9',1,'JGetArrayItem(const J *array, int index): n_cjson.c']]], + ['jgetarraysize_115',['JGetArraySize',['../n__cjson_8h.html#ad6c39ba426fee1353a286a35b64a825d',1,'JGetArraySize(const J *array): n_cjson.c'],['../n__cjson_8c.html#ad6c39ba426fee1353a286a35b64a825d',1,'JGetArraySize(const J *array): n_cjson.c']]], + ['jgetbinaryfromobject_116',['JGetBinaryFromObject',['../n__cjson__helpers_8c.html#a4c5ca7aa585e06623f2788b86300538d',1,'JGetBinaryFromObject(J *json, const char *fieldName, uint8_t **retBinaryData, uint32_t *retBinaryDataLen): n_cjson_helpers.c'],['../note_8h.html#a4c5ca7aa585e06623f2788b86300538d',1,'JGetBinaryFromObject(J *json, const char *fieldName, uint8_t **retBinaryData, uint32_t *retBinaryDataLen): n_cjson_helpers.c']]], + ['jgetbool_117',['JGetBool',['../n__cjson__helpers_8c.html#a51518894ee545340a884089f64e34671',1,'JGetBool(J *json, const char *field): n_cjson_helpers.c'],['../note_8h.html#a51518894ee545340a884089f64e34671',1,'JGetBool(J *json, const char *field): n_cjson_helpers.c']]], + ['jgeterrorptr_118',['JGetErrorPtr',['../n__cjson_8h.html#a5dd9a0020f9d8c787390cd5289942b42',1,'JGetErrorPtr(void): n_cjson.c'],['../n__cjson_8c.html#a5dd9a0020f9d8c787390cd5289942b42',1,'JGetErrorPtr(void): n_cjson.c']]], + ['jgetint_119',['JGetInt',['../note_8h.html#a00b1ca83bdb8cc849114b973dd862d65',1,'JGetInt(J *json, const char *field): n_cjson_helpers.c'],['../n__cjson__helpers_8c.html#a00b1ca83bdb8cc849114b973dd862d65',1,'JGetInt(J *json, const char *field): n_cjson_helpers.c']]], + ['jgetitemname_120',['JGetItemName',['../n__cjson__helpers_8c.html#acf30975898c4673472f59eb97d913712',1,'JGetItemName(const J *item): n_cjson_helpers.c'],['../note_8h.html#acf30975898c4673472f59eb97d913712',1,'JGetItemName(const J *item): n_cjson_helpers.c']]], + ['jgetitemtype_121',['JGetItemType',['../n__cjson__helpers_8c.html#a39d4dc978cbd0c5d10d287b4ac57b8d1',1,'JGetItemType(J *item): n_cjson_helpers.c'],['../note_8h.html#a39d4dc978cbd0c5d10d287b4ac57b8d1',1,'JGetItemType(J *item): n_cjson_helpers.c']]], + ['jgetnumber_122',['JGetNumber',['../n__cjson__helpers_8c.html#a7e30c9120dbe63db3fbedd568f76ecf7',1,'JGetNumber(J *json, const char *field): n_cjson_helpers.c'],['../note_8h.html#a7e30c9120dbe63db3fbedd568f76ecf7',1,'JGetNumber(J *json, const char *field): n_cjson_helpers.c']]], + ['jgetobject_123',['JGetObject',['../n__cjson__helpers_8c.html#a5334b2addcaa277c21319d38c17ab74b',1,'JGetObject(J *json, const char *field): n_cjson_helpers.c'],['../note_8h.html#a5334b2addcaa277c21319d38c17ab74b',1,'JGetObject(J *json, const char *field): n_cjson_helpers.c']]], + ['jgetobjectitem_124',['JGetObjectItem',['../n__cjson_8h.html#a22f9286ff894072bef58b39aa5d7223e',1,'JGetObjectItem(const J *const object, const char *const string): n_cjson.c'],['../n__cjson_8c.html#a22f9286ff894072bef58b39aa5d7223e',1,'JGetObjectItem(const J *const object, const char *const string): n_cjson.c']]], + ['jgetobjectitemcasesensitive_125',['JGetObjectItemCaseSensitive',['../n__cjson_8h.html#a2ce90377e181ab0f4dc4c47b6a7a1d30',1,'JGetObjectItemCaseSensitive(const J *const object, const char *const string): n_cjson.c'],['../n__cjson_8c.html#a2ce90377e181ab0f4dc4c47b6a7a1d30',1,'JGetObjectItemCaseSensitive(const J *const object, const char *const string): n_cjson.c']]], + ['jgetobjectitemname_126',['JGetObjectItemName',['../note_8h.html#a5427874049e8ce6e2211214d93f232c7',1,'note.h']]], + ['jgetobjectitems_127',['JGetObjectItems',['../n__cjson_8h.html#a324bbba2b89cd3b9c306edb249452e1a',1,'n_cjson.h']]], + ['jgetstring_128',['JGetString',['../n__cjson__helpers_8c.html#aa8d038212b35b9da6d78100be2c00285',1,'JGetString(J *json, const char *field): n_cjson_helpers.c'],['../note_8h.html#aa8d038212b35b9da6d78100be2c00285',1,'JGetString(J *json, const char *field): n_cjson_helpers.c']]], + ['jgetstringvalue_129',['JGetStringValue',['../n__cjson_8h.html#af0163fae01e99e4d0e6ea6e0c0303e68',1,'JGetStringValue(J *item): n_cjson.c'],['../n__cjson_8c.html#af0163fae01e99e4d0e6ea6e0c0303e68',1,'JGetStringValue(J *item): n_cjson.c']]], + ['jgettype_130',['JGetType',['../n__cjson__helpers_8c.html#a0b63b324fbe5e773ca7c137666687b41',1,'JGetType(J *json, const char *field): n_cjson_helpers.c'],['../note_8h.html#a0b63b324fbe5e773ca7c137666687b41',1,'JGetType(J *json, const char *field): n_cjson_helpers.c']]], + ['jhasobjectitem_131',['JHasObjectItem',['../n__cjson_8h.html#a7469d6cd6aa0d487c5a3a87a102ad3ee',1,'JHasObjectItem(const J *object, const char *string): n_cjson.c'],['../n__cjson_8c.html#a7469d6cd6aa0d487c5a3a87a102ad3ee',1,'JHasObjectItem(const J *object, const char *string): n_cjson.c']]], + ['jhooks_132',['JHooks',['../n__cjson_8h.html#ad0397f28634dba79785c2a66c076bb08',1,'JHooks(): n_cjson.h'],['../struct_j_hooks.html',1,'JHooks']]], + ['jinit_133',['JInit',['../note_8h.html#ab4005e4eb92f95e4430147551c093a82',1,'note.h']]], + ['jinithooks_134',['JInitHooks',['../n__cjson_8h.html#a3acdaa6d3025b4e731284f0c949f32a3',1,'n_cjson.h']]], + ['jinsertiteminarray_135',['JInsertItemInArray',['../n__cjson_8h.html#a67d8128a4a64c4554afcf33c41487633',1,'JInsertItemInArray(J *array, int which, J *newitem): n_cjson.c'],['../n__cjson_8c.html#a67d8128a4a64c4554afcf33c41487633',1,'JInsertItemInArray(J *array, int which, J *newitem): n_cjson.c']]], + ['jinteger_136',['JINTEGER',['../note_8h.html#ab76f50f98a2aef9bf6ea1e6c7a2c8cbb',1,'note.h']]], + ['jinteger_5fmax_137',['JINTEGER_MAX',['../note_8h.html#a445107097b19783483070744407468d9',1,'note.h']]], + ['jinteger_5fmin_138',['JINTEGER_MIN',['../note_8h.html#a882dbbae976880c3bc34c7a6e6ac2f9a',1,'note.h']]], + ['jintvalue_139',['JIntValue',['../n__cjson__helpers_8c.html#a9f5aaa3fbaaee87de2b6119c7428b9dd',1,'JIntValue(J *item): n_cjson_helpers.c'],['../note_8h.html#a9f5aaa3fbaaee87de2b6119c7428b9dd',1,'JIntValue(J *item): n_cjson_helpers.c']]], + ['jinvalid_140',['JInvalid',['../n__cjson_8h.html#add66c6533bb4eb0e8da570a0859fc4e2',1,'n_cjson.h']]], + ['jisarray_141',['JIsArray',['../n__cjson_8h.html#ad2e8fbc0e1b1484f3593d95e32335c12',1,'JIsArray(const J *const item): n_cjson.c'],['../n__cjson_8c.html#ad2e8fbc0e1b1484f3593d95e32335c12',1,'JIsArray(const J *const item): n_cjson.c']]], + ['jisbool_142',['JIsBool',['../n__cjson_8c.html#a7018dd9b9399e168495a42da2ca30c32',1,'JIsBool(const J *const item): n_cjson.c'],['../n__cjson_8h.html#a7018dd9b9399e168495a42da2ca30c32',1,'JIsBool(const J *const item): n_cjson.c']]], + ['jisexactstring_143',['JIsExactString',['../n__cjson__helpers_8c.html#af4e9257e3b88d1b55441f15efd1bf0c3',1,'JIsExactString(J *json, const char *field, const char *teststr): n_cjson_helpers.c'],['../note_8h.html#af4e9257e3b88d1b55441f15efd1bf0c3',1,'JIsExactString(J *json, const char *field, const char *teststr): n_cjson_helpers.c']]], + ['jisfalse_144',['JIsFalse',['../n__cjson_8h.html#a457bc8d0d7e568fd974b36e9d10ec24d',1,'JIsFalse(const J *const item): n_cjson.c'],['../n__cjson_8c.html#a457bc8d0d7e568fd974b36e9d10ec24d',1,'JIsFalse(const J *const item): n_cjson.c']]], + ['jisinvalid_145',['JIsInvalid',['../n__cjson_8h.html#a88cfb9e3b03ac17ba67d037f76037dbc',1,'JIsInvalid(const J *const item): n_cjson.c'],['../n__cjson_8c.html#a88cfb9e3b03ac17ba67d037f76037dbc',1,'JIsInvalid(const J *const item): n_cjson.c']]], + ['jisnull_146',['JIsNull',['../n__cjson_8h.html#a58e9e823e7eb8675b8dd652994816d10',1,'JIsNull(const J *const item): n_cjson.c'],['../n__cjson_8c.html#a58e9e823e7eb8675b8dd652994816d10',1,'JIsNull(const J *const item): n_cjson.c']]], + ['jisnullstring_147',['JIsNullString',['../n__cjson__helpers_8c.html#aafb4b69e85bd5d9c2d1534688fd4176d',1,'JIsNullString(J *json, const char *field): n_cjson_helpers.c'],['../note_8h.html#aafb4b69e85bd5d9c2d1534688fd4176d',1,'JIsNullString(J *json, const char *field): n_cjson_helpers.c']]], + ['jisnumber_148',['JIsNumber',['../n__cjson_8h.html#a90966d05e3d50b9c6f664be5bb0246ec',1,'JIsNumber(const J *const item): n_cjson.c'],['../n__cjson_8c.html#a90966d05e3d50b9c6f664be5bb0246ec',1,'JIsNumber(const J *const item): n_cjson.c']]], + ['jisobject_149',['JIsObject',['../n__cjson_8h.html#a46958f34e3c76bef78fff3e9f78a7af8',1,'JIsObject(const J *const item): n_cjson.c'],['../n__cjson_8c.html#a46958f34e3c76bef78fff3e9f78a7af8',1,'JIsObject(const J *const item): n_cjson.c']]], + ['jispresent_150',['JIsPresent',['../n__cjson__helpers_8c.html#a6cfeede8f787bbfd890ec7deae8aca24',1,'JIsPresent(J *json, const char *field): n_cjson_helpers.c'],['../note_8h.html#a6cfeede8f787bbfd890ec7deae8aca24',1,'JIsPresent(J *json, const char *field): n_cjson_helpers.c']]], + ['jisraw_151',['JIsRaw',['../n__cjson_8h.html#a38fc30cb88e2b0e194eb1b15def5c85d',1,'JIsRaw(const J *const item): n_cjson.c'],['../n__cjson_8c.html#a38fc30cb88e2b0e194eb1b15def5c85d',1,'JIsRaw(const J *const item): n_cjson.c']]], + ['jisreference_152',['JIsReference',['../n__cjson_8h.html#abd6ed1a437e8e4047b403a36bace79b0',1,'n_cjson.h']]], + ['jisstring_153',['JIsString',['../n__cjson_8h.html#a35c8801a08c0fd4de08759c36bd7d8ad',1,'JIsString(const J *const item): n_cjson.c'],['../n__cjson_8c.html#a35c8801a08c0fd4de08759c36bd7d8ad',1,'JIsString(const J *const item): n_cjson.c']]], + ['jistrue_154',['JIsTrue',['../n__cjson_8h.html#af3451fac120016cabb032443098328e1',1,'JIsTrue(const J *const item): n_cjson.c'],['../n__cjson_8c.html#af3451fac120016cabb032443098328e1',1,'JIsTrue(const J *const item): n_cjson.c']]], + ['jitoa_155',['JItoA',['../n__cjson__helpers_8c.html#a3fe8a8eeb1d78a8eb52ed720a36b99c6',1,'JItoA(JINTEGER n, char *s): n_cjson_helpers.c'],['../note_8h.html#a3fe8a8eeb1d78a8eb52ed720a36b99c6',1,'JItoA(JINTEGER n, char *s): n_cjson_helpers.c']]], + ['jmalloc_156',['JMalloc',['../n__cjson_8c.html#a820f2fa3e1ef927ecf7fa31bb8de2002',1,'JMalloc(size_t size): n_cjson.c'],['../n__cjson_8h.html#a820f2fa3e1ef927ecf7fa31bb8de2002',1,'JMalloc(size_t size): n_cjson.c']]], + ['jminify_157',['JMinify',['../n__cjson_8h.html#a34f0eda948e36394026a0c2d927bbed5',1,'JMinify(char *json): n_cjson.c'],['../n__cjson_8c.html#a34f0eda948e36394026a0c2d927bbed5',1,'JMinify(char *json): n_cjson.c']]], + ['jntoa_158',['JNtoA',['../note_8h.html#ae6dda9b360c01c2e654c62a320db56ff',1,'note.h']]], + ['jntoa_5fmax_159',['JNTOA_MAX',['../note_8h.html#a2554bdccd902653258af24e049abaccb',1,'note.h']]], + ['jntoa_5fprecision_160',['JNTOA_PRECISION',['../note_8h.html#a20c36388ecbae9120b19c30118891097',1,'note.h']]], + ['jnull_161',['JNULL',['../n__cjson_8h.html#a8be837cc65db843920c5bb2508208b44',1,'n_cjson.h']]], + ['jnumber_162',['JNumber',['../n__cjson_8h.html#a81a6942a78096063c9de50c2b5f756d6',1,'n_cjson.h']]], + ['jnumber_163',['JNUMBER',['../note_8h.html#a9c9eb17c00d2f5af0a9fd4f3bc43bdc6',1,'note.h']]], + ['jnumbervalue_164',['JNumberValue',['../n__cjson__helpers_8c.html#a2b2a9c92f2833d424d1a7ab66b3533a8',1,'JNumberValue(J *item): n_cjson_helpers.c'],['../note_8h.html#a2b2a9c92f2833d424d1a7ab66b3533a8',1,'JNumberValue(J *item): n_cjson_helpers.c']]], + ['jobject_165',['JObject',['../n__cjson_8h.html#a45e5b1c47300f1543cfaf97606da88b3',1,'n_cjson.h']]], + ['jobjectforeach_166',['JObjectForEach',['../n__cjson_8h.html#ac7d6eb2e58504d324156b25c6c8862b4',1,'n_cjson.h']]], + ['jparse_167',['JParse',['../n__cjson_8h.html#ad286b9ae6d487c082caa7a0fa5764f69',1,'JParse(const char *value): n_cjson.c'],['../n__cjson_8c.html#ad286b9ae6d487c082caa7a0fa5764f69',1,'JParse(const char *value): n_cjson.c']]], + ['jparsewithopts_168',['JParseWithOpts',['../n__cjson_8h.html#a0bb5a98ddeb134fb0f9f9006c50bdf27',1,'JParseWithOpts(const char *value, const char **return_parse_end, Jbool require_null_terminated): n_cjson.c'],['../n__cjson_8c.html#a0bb5a98ddeb134fb0f9f9006c50bdf27',1,'JParseWithOpts(const char *value, const char **return_parse_end, Jbool require_null_terminated): n_cjson.c']]], + ['jprint_169',['JPrint',['../n__cjson_8h.html#aa869125c5b452e2e8d0143eee20c9c92',1,'JPrint(const J *item): n_cjson.c'],['../n__cjson_8c.html#aa869125c5b452e2e8d0143eee20c9c92',1,'JPrint(const J *item): n_cjson.c']]], + ['jprintbuffered_170',['JPrintBuffered',['../n__cjson_8h.html#a14a6a625679d4c4f6a93353874257daf',1,'JPrintBuffered(const J *item, int prebuffer, Jbool fmt): n_cjson.c'],['../n__cjson_8c.html#a14a6a625679d4c4f6a93353874257daf',1,'JPrintBuffered(const J *item, int prebuffer, Jbool fmt): n_cjson.c']]], + ['jprintpreallocated_171',['JPrintPreallocated',['../n__cjson_8h.html#a9662c84586e86ee2e8ef9e8e4e06a7e5',1,'JPrintPreallocated(J *item, char *buffer, const int length, const Jbool format): n_cjson.c'],['../n__cjson_8c.html#aec398b8654e05c3465d069e34deca404',1,'JPrintPreallocated(J *item, char *buf, const int len, const Jbool fmt): n_cjson.c']]], + ['jprintpreallocatedomitempty_172',['JPrintPreallocatedOmitEmpty',['../n__cjson_8h.html#af12b8d583fbab76f68acf6d7ba31a935',1,'JPrintPreallocatedOmitEmpty(J *item, char *buffer, const int length, const Jbool format): n_cjson.c'],['../n__cjson_8c.html#a996461f664592b56a8f76834b0156181',1,'JPrintPreallocatedOmitEmpty(J *item, char *buf, const int len, const Jbool fmt): n_cjson.c']]], + ['jprintunformatted_173',['JPrintUnformatted',['../n__cjson_8h.html#a458985772911635a0d904e575a5c7839',1,'JPrintUnformatted(const J *item): n_cjson.c'],['../n__cjson_8c.html#a458985772911635a0d904e575a5c7839',1,'JPrintUnformatted(const J *item): n_cjson.c']]], + ['jprintunformattedomitempty_174',['JPrintUnformattedOmitEmpty',['../n__cjson_8h.html#a14ac02cf9a117f42de1aae22c6d67bc8',1,'JPrintUnformattedOmitEmpty(const J *item): n_cjson.c'],['../n__cjson_8c.html#a14ac02cf9a117f42de1aae22c6d67bc8',1,'JPrintUnformattedOmitEmpty(const J *item): n_cjson.c']]], + ['jraw_175',['JRaw',['../n__cjson_8h.html#a40980c81dba7b14912dd5643a3a98ce3',1,'n_cjson.h']]], + ['jreplaceiteminarray_176',['JReplaceItemInArray',['../n__cjson_8h.html#a3382107cdb7fbf8bb00d0a59ce8c02f3',1,'JReplaceItemInArray(J *array, int which, J *newitem): n_cjson.c'],['../n__cjson_8c.html#a3382107cdb7fbf8bb00d0a59ce8c02f3',1,'JReplaceItemInArray(J *array, int which, J *newitem): n_cjson.c']]], + ['jreplaceiteminobject_177',['JReplaceItemInObject',['../n__cjson_8h.html#a90435b417a6abdb321c4c300bdf8b75b',1,'JReplaceItemInObject(J *object, const char *string, J *newitem): n_cjson.c'],['../n__cjson_8c.html#a90435b417a6abdb321c4c300bdf8b75b',1,'JReplaceItemInObject(J *object, const char *string, J *newitem): n_cjson.c']]], + ['jreplaceiteminobjectcasesensitive_178',['JReplaceItemInObjectCaseSensitive',['../n__cjson_8h.html#ae3eaa58eeca1eb3a5821e21286dc72bd',1,'JReplaceItemInObjectCaseSensitive(J *object, const char *string, J *newitem): n_cjson.c'],['../n__cjson_8c.html#ae3eaa58eeca1eb3a5821e21286dc72bd',1,'JReplaceItemInObjectCaseSensitive(J *object, const char *string, J *newitem): n_cjson.c']]], + ['jreplaceitemviapointer_179',['JReplaceItemViaPointer',['../n__cjson_8h.html#a0ef15ee7acb72042a7ab2fdcf088b090',1,'JReplaceItemViaPointer(J *const parent, J *const item, J *replacement): n_cjson.c'],['../n__cjson_8c.html#a0ef15ee7acb72042a7ab2fdcf088b090',1,'JReplaceItemViaPointer(J *const parent, J *const item, J *replacement): n_cjson.c']]], + ['jsetintvalue_180',['JSetIntValue',['../n__cjson_8h.html#ae72ad73c813d2307d544d954e48d6c95',1,'n_cjson.h']]], + ['jsetnumberhelper_181',['JSetNumberHelper',['../n__cjson_8h.html#ae69e47e50ef142737771bad7332bd8a1',1,'JSetNumberHelper(J *object, JNUMBER number): n_cjson.c'],['../n__cjson_8c.html#ae69e47e50ef142737771bad7332bd8a1',1,'JSetNumberHelper(J *object, JNUMBER number): n_cjson.c']]], + ['jsetnumbervalue_182',['JSetNumberValue',['../n__cjson_8h.html#a9e2a67c94b8fc6355ac93a824503a036',1,'n_cjson.h']]], + ['json_183',['json',['../structerror.html#a9b123855d5dd48e86de846588462b39f',1,'error']]], + ['jstring_184',['JString',['../n__cjson_8h.html#ab9e8c51828f7f79c9fcf2220d24b03ec',1,'n_cjson.h']]], + ['jstringisconst_185',['JStringIsConst',['../n__cjson_8h.html#ab186903675fdf0b3d22cf3e7a69994bf',1,'n_cjson.h']]], + ['jstringvalue_186',['JStringValue',['../n__cjson__helpers_8c.html#a2499d761e554a80868701a50c2a05f17',1,'JStringValue(J *item): n_cjson_helpers.c'],['../note_8h.html#a2499d761e554a80868701a50c2a05f17',1,'JStringValue(J *item): n_cjson_helpers.c']]], + ['jtime_187',['JTIME',['../note_8h.html#aaa2abe42069f4e8774798f8e3e89264e',1,'note.h']]], + ['jtrue_188',['JTrue',['../n__cjson_8h.html#af3f87fd9d106ef925670d3b0d5303413',1,'n_cjson.h']]], + ['jtype_189',['JType',['../n__cjson__helpers_8c.html#ade41b3ffbdfc99fa8a87ae63cfebb2fa',1,'JType(J *item): n_cjson_helpers.c'],['../note_8h.html#ade41b3ffbdfc99fa8a87ae63cfebb2fa',1,'JType(J *item): n_cjson_helpers.c']]], + ['jtype_5farray_190',['JTYPE_ARRAY',['../note_8h.html#a3029c9e9a021cf404acbc2178b94470f',1,'note.h']]], + ['jtype_5fbool_191',['JTYPE_BOOL',['../note_8h.html#a7fd70bf9265ce886f8370b4fb8eebb92',1,'note.h']]], + ['jtype_5fbool_5ffalse_192',['JTYPE_BOOL_FALSE',['../note_8h.html#a33c56f9e059f017b5f73a7207b5f690a',1,'note.h']]], + ['jtype_5fbool_5ftrue_193',['JTYPE_BOOL_TRUE',['../note_8h.html#a1dde42a8f9d06851b91f73dcadb48067',1,'note.h']]], + ['jtype_5fnot_5fpresent_194',['JTYPE_NOT_PRESENT',['../note_8h.html#abb2f3b5f9047911dfa9ae2249ae4ad58',1,'note.h']]], + ['jtype_5fnull_195',['JTYPE_NULL',['../note_8h.html#ab65facde73aab39c8c078c8f328badb0',1,'note.h']]], + ['jtype_5fnumber_196',['JTYPE_NUMBER',['../note_8h.html#a73cc27bda4c0d44bffca5dbc353e8d65',1,'note.h']]], + ['jtype_5fnumber_5fzero_197',['JTYPE_NUMBER_ZERO',['../note_8h.html#a34cb28204f46e15dc57b5b82181e2e1d',1,'note.h']]], + ['jtype_5fobject_198',['JTYPE_OBJECT',['../note_8h.html#a7f3ba7ec204fbe5e43714b514236a1c7',1,'note.h']]], + ['jtype_5fstring_199',['JTYPE_STRING',['../note_8h.html#aeba8ddb49a982975aff58fbc5a44b37d',1,'note.h']]], + ['jtype_5fstring_5fblank_200',['JTYPE_STRING_BLANK',['../note_8h.html#a88bdd6cb77b65bec7d1a12d512a021a7',1,'note.h']]], + ['jtype_5fstring_5fbool_5ffalse_201',['JTYPE_STRING_BOOL_FALSE',['../note_8h.html#a9db7f1f3c20bfd4aa66d563cde2d3bef',1,'note.h']]], + ['jtype_5fstring_5fbool_5ftrue_202',['JTYPE_STRING_BOOL_TRUE',['../note_8h.html#ad5597cf60a093c2986fb5451e69ea43e',1,'note.h']]], + ['jtype_5fstring_5fnumber_203',['JTYPE_STRING_NUMBER',['../note_8h.html#ab081e08668cdcbaed0bf2506cb666f9b',1,'note.h']]], + ['jtype_5fstring_5fzero_204',['JTYPE_STRING_ZERO',['../note_8h.html#a05967fa1a39c824fce62fe31a645ca08',1,'note.h']]], + ['juinteger_205',['JUINTEGER',['../note_8h.html#aa40439c159fdacb5de8314453a6cc241',1,'note.h']]], + ['jversion_206',['JVersion',['../n__cjson_8h.html#a43aeaea29ca03af0c4aa80556fee3445',1,'JVersion(void): n_cjson.c'],['../n__cjson_8c.html#a43aeaea29ca03af0c4aa80556fee3445',1,'JVersion(void): n_cjson.c']]] +]; diff --git a/doxygen/html/search/all_b.html b/doxygen/html/search/all_b.html new file mode 100644 index 00000000..130deb4e --- /dev/null +++ b/doxygen/html/search/all_b.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/all_b.js b/doxygen/html/search/all_b.js new file mode 100644 index 00000000..21d0ceee --- /dev/null +++ b/doxygen/html/search/all_b.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['length_207',['length',['../structparse__buffer.html#a036970e9335896d3cee8459eda9e2eb9',1,'parse_buffer::length()'],['../structprintbuffer.html#a1a679f8b6fe9b413fb3a87203b0f5bc8',1,'printbuffer::length()'],['../struct_note_payload_desc.html#ad28917f881294856b621632d318f5ea7',1,'NotePayloadDesc::length()']]] +]; diff --git a/doxygen/html/search/all_c.html b/doxygen/html/search/all_c.html new file mode 100644 index 00000000..3dd5af06 --- /dev/null +++ b/doxygen/html/search/all_c.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/all_c.js b/doxygen/html/search/all_c.js new file mode 100644 index 00000000..814d6aa2 --- /dev/null +++ b/doxygen/html/search/all_c.js @@ -0,0 +1,6 @@ +var searchData= +[ + ['malloc_5ffn_208',['malloc_fn',['../struct_j_hooks.html#a2e5e46e7f23c87f9c8681607bd28d05a',1,'JHooks']]], + ['mallocfn_209',['mallocFn',['../note_8h.html#af700faf8575fb2f45c3881786624b4d6',1,'note.h']]], + ['mutexfn_210',['mutexFn',['../note_8h.html#ac9d4324784f851631c22f78099225463',1,'note.h']]] +]; diff --git a/doxygen/html/search/all_d.html b/doxygen/html/search/all_d.html new file mode 100644 index 00000000..af7f2f0f --- /dev/null +++ b/doxygen/html/search/all_d.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/all_d.js b/doxygen/html/search/all_d.js new file mode 100644 index 00000000..ec5898a3 --- /dev/null +++ b/doxygen/html/search/all_d.js @@ -0,0 +1,193 @@ +var searchData= +[ + ['n_5fatoh_211',['n_atoh',['../n__request_8c.html#a56c6c634ffc5ccaa04faf0875c0fe10e',1,'n_request.c']]], + ['n_5fcjson_2ec_212',['n_cjson.c',['../n__cjson_8c.html',1,'']]], + ['n_5fcjson_2eh_213',['n_cjson.h',['../n__cjson_8h.html',1,'']]], + ['n_5fcjson_5fhelpers_2ec_214',['n_cjson_helpers.c',['../n__cjson__helpers_8c.html',1,'']]], + ['n_5fcjson_5fnesting_5flimit_215',['N_CJSON_NESTING_LIMIT',['../n__cjson_8h.html#a4b45cf89b4c917ceca2e2389c4f723e4',1,'n_cjson.h']]], + ['n_5fcjson_5fpublic_216',['N_CJSON_PUBLIC',['../n__cjson_8h.html#a5f460c51c54d1548d58c1ebf4985a347',1,'n_cjson.h']]], + ['n_5fcjson_5fversion_5fmajor_217',['N_CJSON_VERSION_MAJOR',['../n__cjson_8h.html#aab3945fc5ef708e1ad59f44d1a7073d1',1,'n_cjson.h']]], + ['n_5fcjson_5fversion_5fminor_218',['N_CJSON_VERSION_MINOR',['../n__cjson_8h.html#aeeb6bcdd8d62de4450d58ce8b1650f30',1,'n_cjson.h']]], + ['n_5fcjson_5fversion_5fpatch_219',['N_CJSON_VERSION_PATCH',['../n__cjson_8h.html#a921b0ad837d39c9285e36ee17cba3886',1,'n_cjson.h']]], + ['n_5fhooks_2ec_220',['n_hooks.c',['../n__hooks_8c.html',1,'']]], + ['n_5fhtoa16_221',['n_htoa16',['../n__cjson_8c.html#a745406e6582e9e9cd4bc4411d0f91b86',1,'n_cjson.c']]], + ['n_5fhtoa32_222',['n_htoa32',['../n__hooks_8c.html#aac33ee334208aaa53da33809889f0abe',1,'n_hooks.c']]], + ['n_5frequest_2ec_223',['n_request.c',['../n__request_8c.html',1,'']]], + ['next_224',['next',['../struct_j.html#aa07e8b542090fe62bf0469e85d69c37c',1,'J']]], + ['nnoteresetfn_225',['nNoteResetFn',['../n__hooks_8c.html#aea3d0ea7684640d1848d2914996faecd',1,'n_hooks.c']]], + ['noalloc_226',['noalloc',['../structprintbuffer.html#a2055471b46a66241c72beffd81b67e66',1,'printbuffer']]], + ['note_2eh_227',['note.h',['../note_8h.html',1,'']]], + ['note_5fc_5flog_5fdebug_228',['NOTE_C_LOG_DEBUG',['../note_8h.html#a3123fd4930117eb19b75fef8199d6032',1,'note.h']]], + ['note_5fc_5flog_5ferror_229',['NOTE_C_LOG_ERROR',['../note_8h.html#a87c75bac44560f4cbb8573dc0048169a',1,'note.h']]], + ['note_5fc_5flog_5ffile_5fand_5fline_230',['NOTE_C_LOG_FILE_AND_LINE',['../note_8h.html#a073d21669b13a5eff2361fc07c8bbf92',1,'note.h']]], + ['note_5fc_5flog_5finfo_231',['NOTE_C_LOG_INFO',['../note_8h.html#a260d740972b2082c72f77b416713f5a0',1,'note.h']]], + ['note_5fc_5flog_5flevel_232',['NOTE_C_LOG_LEVEL',['../note_8h.html#ac7f821af4d5b209d37104e2f8038f69c',1,'note.h']]], + ['note_5fc_5flog_5flevel_5fdebug_233',['NOTE_C_LOG_LEVEL_DEBUG',['../note_8h.html#ae09134b1efa9ccbc91fc1c1b6af5f4b0',1,'note.h']]], + ['note_5fc_5flog_5flevel_5ferror_234',['NOTE_C_LOG_LEVEL_ERROR',['../note_8h.html#a6c208024da45b2b4150b2f98d951efb4',1,'note.h']]], + ['note_5fc_5flog_5flevel_5finfo_235',['NOTE_C_LOG_LEVEL_INFO',['../note_8h.html#a4b3a37c8c77a3523c47e1efd31e7edc4',1,'note.h']]], + ['note_5fc_5flog_5flevel_5fwarn_236',['NOTE_C_LOG_LEVEL_WARN',['../note_8h.html#afefa6c4eba9dce431adbf9e5183e04e9',1,'note.h']]], + ['note_5fc_5flog_5fwarn_237',['NOTE_C_LOG_WARN',['../note_8h.html#a7ac988c4204339520399f37a04eb4110',1,'note.h']]], + ['note_5fc_5fstatic_238',['NOTE_C_STATIC',['../n__request_8c.html#af118c2aba9040de625bebcf41c49e571',1,'NOTE_C_STATIC(): n_request.c'],['../n__cjson_8c.html#af118c2aba9040de625bebcf41c49e571',1,'NOTE_C_STATIC(): n_cjson.c']]], + ['note_5fc_5fstringize_239',['NOTE_C_STRINGIZE',['../note_8h.html#aa0eaf84658de3c39c7263959f4950e41',1,'note.h']]], + ['note_5fc_5fversion_240',['NOTE_C_VERSION',['../note_8h.html#aa4cdd0eed41940a458709f2034b706e8',1,'note.h']]], + ['note_5fc_5fversion_5fmajor_241',['NOTE_C_VERSION_MAJOR',['../note_8h.html#ad3ef8b1d9585fb28c46942ab96815b20',1,'note.h']]], + ['note_5fc_5fversion_5fminor_242',['NOTE_C_VERSION_MINOR',['../note_8h.html#a15af17c840e4dee0e552124fde744773',1,'note.h']]], + ['note_5fc_5fversion_5fpatch_243',['NOTE_C_VERSION_PATCH',['../note_8h.html#a9a66291724eb8ba8bc651dc90ed441f9',1,'note.h']]], + ['note_5fi2c_5faddr_5fdefault_244',['NOTE_I2C_ADDR_DEFAULT',['../note_8h.html#a3107c5344909029555deedfacb21b43a',1,'note.h']]], + ['note_5fi2c_5fheader_5fsize_245',['NOTE_I2C_HEADER_SIZE',['../note_8h.html#aa043f18c8e0b59eef37008116957dbfa',1,'note.h']]], + ['note_5fi2c_5fmax_5fdefault_246',['NOTE_I2C_MAX_DEFAULT',['../note_8h.html#a029462dd63c2f85402fa69f5466082f2',1,'note.h']]], + ['note_5fi2c_5fmax_5fmax_247',['NOTE_I2C_MAX_MAX',['../note_8h.html#adc8fa90e5c138f5c4a0ac9da3be910d4',1,'note.h']]], + ['note_5fmd5_5fhash_5fsize_248',['NOTE_MD5_HASH_SIZE',['../note_8h.html#ada955eca3890263865a0f8b15afc052d',1,'note.h']]], + ['note_5fmd5_5fhash_5fstring_5fsize_249',['NOTE_MD5_HASH_STRING_SIZE',['../note_8h.html#a1bb87c25941d1a303245efbe489929e7',1,'note.h']]], + ['note_5fshow_5fmalloc_250',['NOTE_SHOW_MALLOC',['../n__hooks_8c.html#ab037e3109a302fc9719fea71f6734b32',1,'n_hooks.c']]], + ['noteactiveinterface_251',['noteActiveInterface',['../n__hooks_8c.html#a70ecd2743be8507da5bd82b1fc94074f',1,'n_hooks.c']]], + ['noteadd_252',['NoteAdd',['../note_8h.html#a859c73fcda95741f545f2996d0d4d50a',1,'note.h']]], + ['noteaddbodytoobject_253',['NoteAddBodyToObject',['../note_8h.html#a09e55e06b045772b4fc105c0329c73a1',1,'note.h']]], + ['notebinarycodecdecode_254',['NoteBinaryCodecDecode',['../note_8h.html#a10c81f1c0470f4b3cd1c877183163815',1,'note.h']]], + ['notebinarycodecencode_255',['NoteBinaryCodecEncode',['../note_8h.html#a91a381b28624b7d7a5b7c59cea31e40f',1,'note.h']]], + ['notebinarycodecmaxdecodedlength_256',['NoteBinaryCodecMaxDecodedLength',['../note_8h.html#a5db0bc71463c613425debfb34fa38794',1,'note.h']]], + ['notebinarycodecmaxencodedlength_257',['NoteBinaryCodecMaxEncodedLength',['../note_8h.html#a126a4cb7f30d49518bd2552902099634',1,'note.h']]], + ['notebinarystoredecodedlength_258',['NoteBinaryStoreDecodedLength',['../note_8h.html#afe6fc60626aff39d8daa732d5cd98acc',1,'note.h']]], + ['notebinarystoreencodedlength_259',['NoteBinaryStoreEncodedLength',['../note_8h.html#a7f645124333a941eccdba3fbc70381f1',1,'note.h']]], + ['notebinarystorereceive_260',['NoteBinaryStoreReceive',['../note_8h.html#a0a6303c68a7d3fec63ed94e540c349b4',1,'note.h']]], + ['notebinarystorereset_261',['NoteBinaryStoreReset',['../note_8h.html#a4b0744fcac784957345f532646a81c10',1,'note.h']]], + ['notebinarystoretransmit_262',['NoteBinaryStoreTransmit',['../note_8h.html#afdad71c4316f98ed2502d632846edf76',1,'note.h']]], + ['notechunkedreceive_263',['noteChunkedReceive',['../n__hooks_8c.html#ae4ccc80c42fc4c2ca310f46452f7008d',1,'n_hooks.c']]], + ['notechunkedtransmit_264',['noteChunkedTransmit',['../n__hooks_8c.html#aeebbd8afc790746f80206493d833a2af',1,'n_hooks.c']]], + ['noteclearlocation_265',['NoteClearLocation',['../note_8h.html#aafa429043e07e78852045017c75392ae',1,'note.h']]], + ['notedebug_266',['NoteDebug',['../n__hooks_8c.html#a2f5d9ab0d7d259363c2b1fc9507968e9',1,'NoteDebug(const char *line): n_hooks.c'],['../note_8h.html#ab3a18d61ebc4df43fad6b0eb8ff327fa',1,'NoteDebug(const char *message): n_hooks.c']]], + ['notedebugf_267',['NoteDebugf',['../note_8h.html#ab239dae9dfc343d2569fe87041ae7d49',1,'note.h']]], + ['notedebugintln_268',['NoteDebugIntln',['../n__hooks_8c.html#a735b443951ae911c98ddb39c54f0ba7a',1,'NoteDebugIntln(const char *line, int n): n_hooks.c'],['../note_8h.html#ab81480d77900e81e466d9010ed57a347',1,'NoteDebugIntln(const char *message, int n): n_hooks.c']]], + ['notedebugln_269',['NoteDebugln',['../n__hooks_8c.html#ad2104215255468930924e4f3c5eac820',1,'NoteDebugln(const char *line): n_hooks.c'],['../note_8h.html#a080a80ba2040187f419af4cafe0042e6',1,'NoteDebugln(const char *message): n_hooks.c']]], + ['notedebugsyncstatus_270',['NoteDebugSyncStatus',['../note_8h.html#adde35249318a7b5cc3f1c2393685b75b',1,'note.h']]], + ['notedebugwithlevel_271',['NoteDebugWithLevel',['../n__hooks_8c.html#adbf027f8ae53aea93f71965a9dbad0d8',1,'NoteDebugWithLevel(uint8_t level, const char *msg): n_hooks.c'],['../note_8h.html#adbf027f8ae53aea93f71965a9dbad0d8',1,'NoteDebugWithLevel(uint8_t level, const char *msg): n_hooks.c']]], + ['notedebugwithlevelln_272',['NoteDebugWithLevelLn',['../n__hooks_8c.html#aea4a872558f91cfdba679dea15e39b9c',1,'NoteDebugWithLevelLn(uint8_t level, const char *msg): n_hooks.c'],['../note_8h.html#aea4a872558f91cfdba679dea15e39b9c',1,'NoteDebugWithLevelLn(uint8_t level, const char *msg): n_hooks.c']]], + ['notedelayms_273',['NoteDelayMs',['../n__hooks_8c.html#a30ebf8f80fc647865819c842adc53816',1,'NoteDelayMs(uint32_t ms): n_hooks.c'],['../note_8h.html#a30ebf8f80fc647865819c842adc53816',1,'NoteDelayMs(uint32_t ms): n_hooks.c']]], + ['notedeleteresponse_274',['NoteDeleteResponse',['../note_8h.html#a5e957ef70b05d1b5173ba34ea7b60588',1,'note.h']]], + ['noteerrorclean_275',['NoteErrorClean',['../n__request_8c.html#a622a74213848c997191e0fceb7d72c64',1,'NoteErrorClean(char *begin): n_request.c'],['../note_8h.html#a3b8d73d3dc3b3315b1be8260e83f10ab',1,'NoteErrorClean(char *errbuf): n_request.c']]], + ['noteerrorcontains_276',['NoteErrorContains',['../n__request_8c.html#a1385294098059d94d366e2fd843358e5',1,'NoteErrorContains(const char *errstr, const char *errtype): n_request.c'],['../note_8h.html#a1385294098059d94d366e2fd843358e5',1,'NoteErrorContains(const char *errstr, const char *errtype): n_request.c']]], + ['notefactoryreset_277',['NoteFactoryReset',['../note_8h.html#a0a6818960d5dc59c9dc15ec12c8eca67',1,'note.h']]], + ['notefree_278',['NoteFree',['../n__hooks_8c.html#a684906dd58e03a139b98f3a342b5c83b',1,'NoteFree(void *p): n_hooks.c'],['../note_8h.html#a34280452b55a2013552227bd6e811fdd',1,'NoteFree(void *): n_hooks.c']]], + ['notegetbody_279',['NoteGetBody',['../note_8h.html#aada0fea556f714e917ac330c87c7c2c1',1,'note.h']]], + ['notegetcontact_280',['NoteGetContact',['../note_8h.html#a289e6d70e17615cf927a9094080139f1',1,'note.h']]], + ['notegetenv_281',['NoteGetEnv',['../note_8h.html#a84b63daf99110b90e0e9cad94df694ff',1,'note.h']]], + ['notegetenvint_282',['NoteGetEnvInt',['../note_8h.html#aa998d7b236f2ff2541a20872f261db60',1,'note.h']]], + ['notegetenvnumber_283',['NoteGetEnvNumber',['../note_8h.html#af6f3d1929a16c26050550f01d69de9a9',1,'note.h']]], + ['notegetlocation_284',['NoteGetLocation',['../note_8h.html#a711d1c4cb256e29e34853959d4f032cc',1,'note.h']]], + ['notegetlocationmode_285',['NoteGetLocationMode',['../note_8h.html#a1f5e4d1d5d4c91ee2409686e59e28e76',1,'note.h']]], + ['notegetms_286',['NoteGetMs',['../n__hooks_8c.html#a4dcd12c5b2ec9d2acd78363a2e41e698',1,'NoteGetMs(void): n_hooks.c'],['../note_8h.html#a4dcd12c5b2ec9d2acd78363a2e41e698',1,'NoteGetMs(void): n_hooks.c']]], + ['notegetnetstatus_287',['NoteGetNetStatus',['../note_8h.html#a387befb0abe72b215645a6650ea7e72f',1,'note.h']]], + ['notegetserviceconfig_288',['NoteGetServiceConfig',['../note_8h.html#acf36d7c23420551e51597554a69f97c3',1,'note.h']]], + ['notegetserviceconfigst_289',['NoteGetServiceConfigST',['../note_8h.html#ac5989f17e99b8f154fe4318bb7bcf73d',1,'note.h']]], + ['notegetstatus_290',['NoteGetStatus',['../note_8h.html#adfe58a53ab4a4de6f6b00092494330ab',1,'note.h']]], + ['notegetstatusst_291',['NoteGetStatusST',['../note_8h.html#ad873ec5c640174f673ceabad89b8f030',1,'note.h']]], + ['notegettemperature_292',['NoteGetTemperature',['../note_8h.html#a33a8a42563cc3dc4d3bda44144d73784',1,'note.h']]], + ['notegetversion_293',['NoteGetVersion',['../note_8h.html#ab9c78d2fef7a116ccc22ced6a9304fb1',1,'note.h']]], + ['notegetvoltage_294',['NoteGetVoltage',['../note_8h.html#ad29039cfe90306e391d8a85a0df1d69f',1,'note.h']]], + ['notehardreset_295',['noteHardReset',['../n__hooks_8c.html#a25a3bc894007c69b27c81bd2093c1457',1,'n_hooks.c']]], + ['notei2caddress_296',['NoteI2CAddress',['../n__hooks_8c.html#a57dcffb142faaef2714839d27afe5be0',1,'NoteI2CAddress(void): n_hooks.c'],['../note_8h.html#a57dcffb142faaef2714839d27afe5be0',1,'NoteI2CAddress(void): n_hooks.c']]], + ['notei2cmax_297',['NoteI2CMax',['../n__hooks_8c.html#a35bbb8179be3a72ab7ec302dcbfad9e7',1,'NoteI2CMax(void): n_hooks.c'],['../note_8h.html#a35bbb8179be3a72ab7ec302dcbfad9e7',1,'NoteI2CMax(void): n_hooks.c']]], + ['notei2creceive_298',['noteI2CReceive',['../n__hooks_8c.html#a99f3a0e0399cb234c4beffb898857460',1,'n_hooks.c']]], + ['notei2creset_299',['noteI2CReset',['../n__hooks_8c.html#ac0f858f36f53326c84d163a9c555face',1,'n_hooks.c']]], + ['notei2ctransmit_300',['noteI2CTransmit',['../n__hooks_8c.html#a5d9df694d590e90ac6be645445cd29c3',1,'n_hooks.c']]], + ['noteisconnected_301',['NoteIsConnected',['../note_8h.html#ad479c8e6d2c17ed58f96b9aa234ad81d',1,'note.h']]], + ['noteisconnectedst_302',['NoteIsConnectedST',['../note_8h.html#aa1cce9855703b1b8a5cc856a84378c45',1,'note.h']]], + ['noteisdebugoutputactive_303',['noteIsDebugOutputActive',['../n__hooks_8c.html#a0d80498206dfae3b9a056b85b88695e9',1,'n_hooks.c']]], + ['notejsontransaction_304',['noteJSONTransaction',['../n__hooks_8c.html#adfb344b8d5cae2be70bd5a06a161e561',1,'n_hooks.c']]], + ['notelocaltimest_305',['NoteLocalTimeST',['../note_8h.html#a57534ae715e262dd91a55bd71de37631',1,'note.h']]], + ['notelocationvalid_306',['NoteLocationValid',['../note_8h.html#a544f2aeaa9bbd229ab173f8e9ba42dc5',1,'note.h']]], + ['notelocationvalidst_307',['NoteLocationValidST',['../note_8h.html#aa1fd37b1100f616b178fc6c0bcd18292',1,'note.h']]], + ['notelocki2c_308',['NoteLockI2C',['../n__hooks_8c.html#a195386217d2b20709846d45780af2013',1,'NoteLockI2C(void): n_hooks.c'],['../note_8h.html#a195386217d2b20709846d45780af2013',1,'NoteLockI2C(void): n_hooks.c']]], + ['notelocknote_309',['noteLockNote',['../n__hooks_8c.html#a91724ed7e398e2ad2954fc7496414ebe',1,'n_hooks.c']]], + ['notemalloc_310',['NoteMalloc',['../n__hooks_8c.html#a97d5a9da7d7d35519c54e90c8bcd9b20',1,'NoteMalloc(size_t size): n_hooks.c'],['../note_8h.html#a97d5a9da7d7d35519c54e90c8bcd9b20',1,'NoteMalloc(size_t size): n_hooks.c']]], + ['notemd5context_311',['NoteMD5Context',['../struct_note_m_d5_context.html',1,'']]], + ['notemd5final_312',['NoteMD5Final',['../note_8h.html#ad1aef239c14e207376fff97a9269b569',1,'note.h']]], + ['notemd5hash_313',['NoteMD5Hash',['../note_8h.html#a789bebabb0a08fe02ccea85aa917488d',1,'note.h']]], + ['notemd5hashstring_314',['NoteMD5HashString',['../note_8h.html#a54de4da750412f3f2192e1ff453810ab',1,'note.h']]], + ['notemd5hashtostring_315',['NoteMD5HashToString',['../note_8h.html#a095d52cf0bc437922a8104cb97445d29',1,'note.h']]], + ['notemd5init_316',['NoteMD5Init',['../note_8h.html#af22f3a3c0071c07b3765df7907301c9f',1,'note.h']]], + ['notemd5transform_317',['NoteMD5Transform',['../note_8h.html#a7a52d858400f4634e7be440a5753967e',1,'note.h']]], + ['notemd5update_318',['NoteMD5Update',['../note_8h.html#ae70580a3b6b7d93590e84a46b4035fa9',1,'note.h']]], + ['notememavailable_319',['NoteMemAvailable',['../note_8h.html#ae7537bf172173234ecb77a6e0af513f8',1,'note.h']]], + ['notenewbody_320',['NoteNewBody',['../note_8h.html#aa4e6f9fe285abae5dec0312c1dda3f06',1,'note.h']]], + ['notenewcommand_321',['NoteNewCommand',['../n__request_8c.html#a48877576f8d94864dedbe663ba68c3f0',1,'NoteNewCommand(const char *request): n_request.c'],['../note_8h.html#a48877576f8d94864dedbe663ba68c3f0',1,'NoteNewCommand(const char *request): n_request.c']]], + ['notenewrequest_322',['NoteNewRequest',['../n__request_8c.html#a2f5fce48cfd817f1bf940ab145f7cc59',1,'NoteNewRequest(const char *request): n_request.c'],['../note_8h.html#a2f5fce48cfd817f1bf940ab145f7cc59',1,'NoteNewRequest(const char *request): n_request.c']]], + ['notepayloadaddsegment_323',['NotePayloadAddSegment',['../note_8h.html#ad7c0fdd390eaf4338117bba38a92cdce',1,'note.h']]], + ['notepayloaddesc_324',['NotePayloadDesc',['../struct_note_payload_desc.html',1,'']]], + ['notepayloadfindsegment_325',['NotePayloadFindSegment',['../note_8h.html#a10bb7e445f9515a2289e9ed2dd4485d1',1,'note.h']]], + ['notepayloadfree_326',['NotePayloadFree',['../note_8h.html#a516e80912a7b5874770888765db7347e',1,'note.h']]], + ['notepayloadgetsegment_327',['NotePayloadGetSegment',['../note_8h.html#a573bc94dabf3f27220685a8c4d7adce9',1,'note.h']]], + ['notepayloadretrieveaftersleep_328',['NotePayloadRetrieveAfterSleep',['../note_8h.html#a62202e752d3e6b75d0beebbc0ebd29e9',1,'note.h']]], + ['notepayloadsaveandsleep_329',['NotePayloadSaveAndSleep',['../note_8h.html#a42f5f4c8090a088fbc0d6b68646e9c0e',1,'note.h']]], + ['notepayloadset_330',['NotePayloadSet',['../note_8h.html#ae8b19866d8b472354b80679fcd03d3bf',1,'note.h']]], + ['noteprint_331',['NotePrint',['../note_8h.html#a36d63199ff85bd480eafc6b547e7f9a0',1,'note.h']]], + ['noteprintf_332',['NotePrintf',['../note_8h.html#aca48731908e450c955c6dc1f6b3381a4',1,'note.h']]], + ['noteprintln_333',['NotePrintln',['../note_8h.html#a17c3fa0521904ce276913ce0bd666fd1',1,'note.h']]], + ['noteregion_334',['NoteRegion',['../note_8h.html#ade2325739300181a0fad13e83f377ac1',1,'note.h']]], + ['noterequest_335',['NoteRequest',['../n__request_8c.html#ab1227db7501f0b979ed894fb764790e3',1,'NoteRequest(J *req): n_request.c'],['../note_8h.html#ab1227db7501f0b979ed894fb764790e3',1,'NoteRequest(J *req): n_request.c']]], + ['noterequestresponse_336',['NoteRequestResponse',['../n__request_8c.html#ab163a75667bef7e74294125d40e15c12',1,'NoteRequestResponse(J *req): n_request.c'],['../note_8h.html#ab163a75667bef7e74294125d40e15c12',1,'NoteRequestResponse(J *req): n_request.c']]], + ['noterequestresponsejson_337',['NoteRequestResponseJSON',['../note_8h.html#a24fcc50f78212b5f7e08ed05b58c0ad1',1,'NoteRequestResponseJSON(const char *reqJSON): n_request.c'],['../n__request_8c.html#a24fcc50f78212b5f7e08ed05b58c0ad1',1,'NoteRequestResponseJSON(const char *reqJSON): n_request.c']]], + ['noterequestresponsewithretry_338',['NoteRequestResponseWithRetry',['../n__request_8c.html#a5d43b857b1bf72f312a2e7ba1825445b',1,'NoteRequestResponseWithRetry(J *req, uint32_t timeoutSeconds): n_request.c'],['../note_8h.html#a5d43b857b1bf72f312a2e7ba1825445b',1,'NoteRequestResponseWithRetry(J *req, uint32_t timeoutSeconds): n_request.c']]], + ['noterequestwithretry_339',['NoteRequestWithRetry',['../n__request_8c.html#a7eef6ff395f1e94934d3f9eb99bbcb9a',1,'NoteRequestWithRetry(J *req, uint32_t timeoutSeconds): n_request.c'],['../note_8h.html#a7eef6ff395f1e94934d3f9eb99bbcb9a',1,'NoteRequestWithRetry(J *req, uint32_t timeoutSeconds): n_request.c']]], + ['notereset_340',['NoteReset',['../n__request_8c.html#a6358096b5a9e5c69a4f56b12e80092fa',1,'NoteReset(void): n_request.c'],['../note_8h.html#a6358096b5a9e5c69a4f56b12e80092fa',1,'NoteReset(void): n_request.c']]], + ['noteresetrequired_341',['NoteResetRequired',['../n__request_8c.html#a6c62afa66443f9dbb0a36bf9f76e9896',1,'NoteResetRequired(void): n_request.c'],['../note_8h.html#a6c62afa66443f9dbb0a36bf9f76e9896',1,'NoteResetRequired(void): n_request.c']]], + ['noteresponseerror_342',['NoteResponseError',['../note_8h.html#acd6f73358d95a8188495babd142c5977',1,'note.h']]], + ['noteresponseerrorcontains_343',['NoteResponseErrorContains',['../note_8h.html#aebc81ad84af23cc172214e6bfae7a00f',1,'note.h']]], + ['noteresumetransactiondebug_344',['NoteResumeTransactionDebug',['../note_8h.html#a27085ec262c1b7e69d4f8998e2a5219c',1,'NoteResumeTransactionDebug(void): n_request.c'],['../n__request_8c.html#a27085ec262c1b7e69d4f8998e2a5219c',1,'NoteResumeTransactionDebug(void): n_request.c']]], + ['notesend_345',['NoteSend',['../note_8h.html#a2468ed01b499ba8fc72fefa3500cad90',1,'note.h']]], + ['notesendtoroute_346',['NoteSendToRoute',['../note_8h.html#a740e04f22326f5f421bf3c86d5fd1ed3',1,'note.h']]], + ['noteserialavailable_347',['noteSerialAvailable',['../n__hooks_8c.html#a4dd1aa50682d8adfcb29900f3af0df7e',1,'n_hooks.c']]], + ['noteserialreceive_348',['noteSerialReceive',['../n__hooks_8c.html#a16710dbd211bf722a2538ca069c1bc39',1,'n_hooks.c']]], + ['noteserialreset_349',['noteSerialReset',['../n__hooks_8c.html#a5648adfefdf583e2cec1807b44544396',1,'n_hooks.c']]], + ['noteserialtransmit_350',['noteSerialTransmit',['../n__hooks_8c.html#a7f13dc9ce8037d8e1728c278fa31f789',1,'n_hooks.c']]], + ['notesetcontact_351',['NoteSetContact',['../note_8h.html#aad1a6d6d04a1cac3339022d1068df201',1,'note.h']]], + ['notesetenvdefault_352',['NoteSetEnvDefault',['../note_8h.html#af7edd00b0a1764be80585ca6b99e8045',1,'note.h']]], + ['notesetenvdefaultint_353',['NoteSetEnvDefaultInt',['../note_8h.html#a3b959828f2723e37f1aa15818122a49c',1,'note.h']]], + ['notesetenvdefaultnumber_354',['NoteSetEnvDefaultNumber',['../note_8h.html#a43932b5cf2ba57357efd5de109c288d3',1,'note.h']]], + ['notesetfn_355',['NoteSetFn',['../n__hooks_8c.html#ad334248744d5387da78ca09c3498f397',1,'NoteSetFn(mallocFn mallocHook, freeFn freeHook, delayMsFn delayMsHook, getMsFn getMsHook): n_hooks.c'],['../note_8h.html#ad334248744d5387da78ca09c3498f397',1,'NoteSetFn(mallocFn mallocHook, freeFn freeHook, delayMsFn delayMsHook, getMsFn getMsHook): n_hooks.c']]], + ['notesetfndebugoutput_356',['NoteSetFnDebugOutput',['../n__hooks_8c.html#a6844f5cd4d6e38d65c090dba954321b4',1,'NoteSetFnDebugOutput(debugOutputFn fn): n_hooks.c'],['../note_8h.html#a6844f5cd4d6e38d65c090dba954321b4',1,'NoteSetFnDebugOutput(debugOutputFn fn): n_hooks.c']]], + ['notesetfndefault_357',['NoteSetFnDefault',['../n__hooks_8c.html#a57a711029fed4148da73679ff2c8a154',1,'NoteSetFnDefault(mallocFn mallocfn, freeFn freefn, delayMsFn delayfn, getMsFn millisfn): n_hooks.c'],['../note_8h.html#a57a711029fed4148da73679ff2c8a154',1,'NoteSetFnDefault(mallocFn mallocfn, freeFn freefn, delayMsFn delayfn, getMsFn millisfn): n_hooks.c']]], + ['notesetfndisabled_358',['NoteSetFnDisabled',['../n__hooks_8c.html#a8648db242df0d5ac68334ab93ee5fa0e',1,'NoteSetFnDisabled(void): n_hooks.c'],['../note_8h.html#a8648db242df0d5ac68334ab93ee5fa0e',1,'NoteSetFnDisabled(void): n_hooks.c']]], + ['notesetfni2c_359',['NoteSetFnI2C',['../n__hooks_8c.html#abeb555883ff039880048164763c3b9f0',1,'NoteSetFnI2C(uint32_t notecardAddr, uint32_t maxTransmitSize, i2cResetFn resetFn, i2cTransmitFn transmitFn, i2cReceiveFn receiveFn): n_hooks.c'],['../note_8h.html#abeb555883ff039880048164763c3b9f0',1,'NoteSetFnI2C(uint32_t notecardAddr, uint32_t maxTransmitSize, i2cResetFn resetFn, i2cTransmitFn transmitFn, i2cReceiveFn receiveFn): n_hooks.c']]], + ['notesetfni2cmutex_360',['NoteSetFnI2CMutex',['../note_8h.html#a6879f42e34e075aec82b499fd5ddd12a',1,'NoteSetFnI2CMutex(mutexFn lockI2Cfn, mutexFn unlockI2Cfn): n_hooks.c'],['../n__hooks_8c.html#a6879f42e34e075aec82b499fd5ddd12a',1,'NoteSetFnI2CMutex(mutexFn lockI2Cfn, mutexFn unlockI2Cfn): n_hooks.c']]], + ['notesetfnmutex_361',['NoteSetFnMutex',['../n__hooks_8c.html#a81210c0d43535f1945083f7b3fcad67a',1,'NoteSetFnMutex(mutexFn lockI2Cfn, mutexFn unlockI2Cfn, mutexFn lockNotefn, mutexFn unlockNotefn): n_hooks.c'],['../note_8h.html#a81210c0d43535f1945083f7b3fcad67a',1,'NoteSetFnMutex(mutexFn lockI2Cfn, mutexFn unlockI2Cfn, mutexFn lockNotefn, mutexFn unlockNotefn): n_hooks.c']]], + ['notesetfnnotemutex_362',['NoteSetFnNoteMutex',['../n__hooks_8c.html#a534aa37f7e753dd06a847f429f8e743f',1,'NoteSetFnNoteMutex(mutexFn lockFn, mutexFn unlockFn): n_hooks.c'],['../note_8h.html#a534aa37f7e753dd06a847f429f8e743f',1,'NoteSetFnNoteMutex(mutexFn lockFn, mutexFn unlockFn): n_hooks.c']]], + ['notesetfnserial_363',['NoteSetFnSerial',['../n__hooks_8c.html#a85c66fdcef6d9ea044a9adc37af5afa7',1,'NoteSetFnSerial(serialResetFn resetFn, serialTransmitFn transmitFn, serialAvailableFn availFn, serialReceiveFn receiveFn): n_hooks.c'],['../note_8h.html#a85c66fdcef6d9ea044a9adc37af5afa7',1,'NoteSetFnSerial(serialResetFn resetFn, serialTransmitFn transmitFn, serialAvailableFn availFn, serialReceiveFn receiveFn): n_hooks.c']]], + ['notesetfntransaction_364',['NoteSetFnTransaction',['../n__hooks_8c.html#a946facc30c7f3b5f1820db01fde9fa4d',1,'NoteSetFnTransaction(txnStartFn startFn, txnStopFn stopFn): n_hooks.c'],['../note_8h.html#a946facc30c7f3b5f1820db01fde9fa4d',1,'NoteSetFnTransaction(txnStartFn startFn, txnStopFn stopFn): n_hooks.c']]], + ['noteseti2caddress_365',['NoteSetI2CAddress',['../n__hooks_8c.html#a58d7607711312253b402749133e2933a',1,'NoteSetI2CAddress(uint32_t i2caddress): n_hooks.c'],['../note_8h.html#a58d7607711312253b402749133e2933a',1,'NoteSetI2CAddress(uint32_t i2caddress): n_hooks.c']]], + ['notesetlocation_366',['NoteSetLocation',['../note_8h.html#a54f0c0ac25d91cdff09d4c374f4b9393',1,'note.h']]], + ['notesetlocationmode_367',['NoteSetLocationMode',['../note_8h.html#a38ab54badbef76dd436d557889eaaf83',1,'note.h']]], + ['notesetproductid_368',['NoteSetProductID',['../note_8h.html#a68e1b388237b6d156f07299c8fdea24b',1,'note.h']]], + ['notesetserialnumber_369',['NoteSetSerialNumber',['../note_8h.html#ac4e9ce3c9b56c05603c3a87377abfdda',1,'note.h']]], + ['notesetstsecs_370',['NoteSetSTSecs',['../note_8h.html#a2e8d519c15479dfaf09566ed97ec3711',1,'note.h']]], + ['notesetsyncmode_371',['NoteSetSyncMode',['../note_8h.html#a65b9120ff5b755405d76a3ba992197ac',1,'note.h']]], + ['notesetuploadmode_372',['NoteSetUploadMode',['../note_8h.html#aedfe8eec797fa14b80c9a836a3267a69',1,'note.h']]], + ['notesetuseragent_373',['NoteSetUserAgent',['../note_8h.html#a35ebbb9e71fc6822ec7848df598b1b6f',1,'note.h']]], + ['notesetuseragentcpu_374',['NoteSetUserAgentCPU',['../note_8h.html#a06db056eec95b5d3bce80a00d87720d1',1,'note.h']]], + ['notesetuseragentos_375',['NoteSetUserAgentOS',['../note_8h.html#a6586f487873db10a6cca9f4f2812f2e1',1,'note.h']]], + ['notesleep_376',['NoteSleep',['../note_8h.html#a5495b9b5807536807987af253ee2b918',1,'note.h']]], + ['notesuspendtransactiondebug_377',['NoteSuspendTransactionDebug',['../n__request_8c.html#ab0427f0cd3e286d8020309ea88687d09',1,'NoteSuspendTransactionDebug(void): n_request.c'],['../note_8h.html#ab0427f0cd3e286d8020309ea88687d09',1,'NoteSuspendTransactionDebug(void): n_request.c']]], + ['notetemplate_378',['NoteTemplate',['../note_8h.html#a5de0a3a1b648b9d5c2d0a7c608264f6a',1,'note.h']]], + ['notetime_379',['NoteTime',['../note_8h.html#a0d930f1361f45030bc3638197b329bcb',1,'note.h']]], + ['notetimerefreshmins_380',['NoteTimeRefreshMins',['../note_8h.html#af5568df79a7d26a8807b54853a56b921',1,'note.h']]], + ['notetimeset_381',['NoteTimeSet',['../note_8h.html#a09596cfe3e377e92f4ebf6700e3ac990',1,'note.h']]], + ['notetimest_382',['NoteTimeST',['../note_8h.html#a1f834110044f5d4586ad98bde88084d6',1,'note.h']]], + ['notetimevalid_383',['NoteTimeValid',['../note_8h.html#afc76a1b0c6b4dfa1ab2e7c3d6286583e',1,'note.h']]], + ['notetimevalidst_384',['NoteTimeValidST',['../note_8h.html#abf11915def4e2d9b1e54cb63d13e95e2',1,'note.h']]], + ['notetransaction_385',['NoteTransaction',['../n__request_8c.html#a8b5e380054a80026a80c531a734f025c',1,'NoteTransaction(J *req): n_request.c'],['../note_8h.html#a8b5e380054a80026a80c531a734f025c',1,'NoteTransaction(J *req): n_request.c']]], + ['notetransactionshouldlock_386',['noteTransactionShouldLock',['../n__request_8c.html#ad807b7de69820e7c5f308f8caba96562',1,'n_request.c']]], + ['notetransactionstart_387',['noteTransactionStart',['../n__hooks_8c.html#a31026968acce3c29d9bed1a16606955c',1,'n_hooks.c']]], + ['notetransactionstop_388',['noteTransactionStop',['../n__hooks_8c.html#a710038819ac8776ba26c05b912380182',1,'n_hooks.c']]], + ['noteturboio_389',['NoteTurboIO',['../note_8h.html#a3188b2609ac87faadfb0ec5cb9b158bf',1,'note.h']]], + ['noteunlocki2c_390',['NoteUnlockI2C',['../n__hooks_8c.html#a2a4589fef84a01f2a1bee1c5a7053fc6',1,'NoteUnlockI2C(void): n_hooks.c'],['../note_8h.html#a2a4589fef84a01f2a1bee1c5a7053fc6',1,'NoteUnlockI2C(void): n_hooks.c']]], + ['noteunlocknote_391',['noteUnlockNote',['../n__hooks_8c.html#aeaef70aca07305e46c41c6091afae506',1,'n_hooks.c']]], + ['noteuseragent_392',['NoteUserAgent',['../note_8h.html#a7df3b564875a8975cf524851a4f83ff9',1,'note.h']]], + ['noteuseragentupdate_393',['NoteUserAgentUpdate',['../note_8h.html#ad09beb502758c3c20ea01d0b5940a751',1,'note.h']]], + ['notewake_394',['NoteWake',['../note_8h.html#ab6689989662882c9140822e67d0ae84d',1,'note.h']]], + ['np_5fseghdr_5flen_395',['NP_SEGHDR_LEN',['../note_8h.html#a6bd262ffa71c6e153f70b1fcbfbe9150',1,'note.h']]], + ['np_5fseglen_5flen_396',['NP_SEGLEN_LEN',['../note_8h.html#a21ad183750f7d93528d707af3339b200',1,'note.h']]], + ['np_5fsegtype_5flen_397',['NP_SEGTYPE_LEN',['../note_8h.html#aa77f7c6fe5afd314bc6948e167a8d040',1,'note.h']]], + ['nreceivefn_398',['nReceiveFn',['../n__hooks_8c.html#ab573aa22885384520bb3080189f246b3',1,'n_hooks.c']]], + ['ntransactionfn_399',['nTransactionFn',['../n__hooks_8c.html#a3af2856f787f9707f6f3cb25d2c28860',1,'n_hooks.c']]], + ['ntransmitfn_400',['nTransmitFn',['../n__hooks_8c.html#a4adc8af3e4ea403988d458615cf6f845',1,'n_hooks.c']]] +]; diff --git a/doxygen/html/search/all_e.html b/doxygen/html/search/all_e.html new file mode 100644 index 00000000..e25df423 --- /dev/null +++ b/doxygen/html/search/all_e.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/all_e.js b/doxygen/html/search/all_e.js new file mode 100644 index 00000000..6d1f6f10 --- /dev/null +++ b/doxygen/html/search/all_e.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['offset_401',['offset',['../structparse__buffer.html#af727920073077579942a79de519bb31a',1,'parse_buffer::offset()'],['../structprintbuffer.html#a3ed6f9d24d6591047680492a962dc7c9',1,'printbuffer::offset()']]], + ['omitempty_402',['omitempty',['../structprintbuffer.html#af746da3857d83e6c7cba29cc5bd7a123',1,'printbuffer']]] +]; diff --git a/doxygen/html/search/all_f.html b/doxygen/html/search/all_f.html new file mode 100644 index 00000000..b23da6ce --- /dev/null +++ b/doxygen/html/search/all_f.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/all_f.js b/doxygen/html/search/all_f.js new file mode 100644 index 00000000..8107c68c --- /dev/null +++ b/doxygen/html/search/all_f.js @@ -0,0 +1,8 @@ +var searchData= +[ + ['parse_5fbuffer_403',['parse_buffer',['../structparse__buffer.html',1,'']]], + ['position_404',['position',['../structerror.html#a24de70a4d517ab351d80c18582cadb66',1,'error']]], + ['prev_405',['prev',['../struct_j.html#a970543539919061d72e5973433964bee',1,'J']]], + ['print_5ftab_5fchars_406',['PRINT_TAB_CHARS',['../n__cjson_8c.html#a3a77fd438cec9e807b5dfc440010d2fe',1,'n_cjson.c']]], + ['printbuffer_407',['printbuffer',['../structprintbuffer.html',1,'']]] +]; diff --git a/doxygen/html/search/classes_0.html b/doxygen/html/search/classes_0.html new file mode 100644 index 00000000..af8159ee --- /dev/null +++ b/doxygen/html/search/classes_0.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/classes_0.js b/doxygen/html/search/classes_0.js new file mode 100644 index 00000000..bba9de9f --- /dev/null +++ b/doxygen/html/search/classes_0.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['error_441',['error',['../structerror.html',1,'']]] +]; diff --git a/doxygen/html/search/classes_1.html b/doxygen/html/search/classes_1.html new file mode 100644 index 00000000..576e9168 --- /dev/null +++ b/doxygen/html/search/classes_1.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/classes_1.js b/doxygen/html/search/classes_1.js new file mode 100644 index 00000000..20758ec8 --- /dev/null +++ b/doxygen/html/search/classes_1.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['j_442',['J',['../struct_j.html',1,'']]], + ['jhooks_443',['JHooks',['../struct_j_hooks.html',1,'']]] +]; diff --git a/doxygen/html/search/classes_2.html b/doxygen/html/search/classes_2.html new file mode 100644 index 00000000..956405e5 --- /dev/null +++ b/doxygen/html/search/classes_2.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/classes_2.js b/doxygen/html/search/classes_2.js new file mode 100644 index 00000000..438d8a6a --- /dev/null +++ b/doxygen/html/search/classes_2.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['notemd5context_444',['NoteMD5Context',['../struct_note_m_d5_context.html',1,'']]], + ['notepayloaddesc_445',['NotePayloadDesc',['../struct_note_payload_desc.html',1,'']]] +]; diff --git a/doxygen/html/search/classes_3.html b/doxygen/html/search/classes_3.html new file mode 100644 index 00000000..d33343bc --- /dev/null +++ b/doxygen/html/search/classes_3.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/classes_3.js b/doxygen/html/search/classes_3.js new file mode 100644 index 00000000..8749c190 --- /dev/null +++ b/doxygen/html/search/classes_3.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['parse_5fbuffer_446',['parse_buffer',['../structparse__buffer.html',1,'']]], + ['printbuffer_447',['printbuffer',['../structprintbuffer.html',1,'']]] +]; diff --git a/doxygen/html/search/close.svg b/doxygen/html/search/close.svg new file mode 100644 index 00000000..a933eea1 --- /dev/null +++ b/doxygen/html/search/close.svg @@ -0,0 +1,31 @@ + + + + + + image/svg+xml + + + + + + + + diff --git a/doxygen/html/search/defines_0.html b/doxygen/html/search/defines_0.html new file mode 100644 index 00000000..15cc3de3 --- /dev/null +++ b/doxygen/html/search/defines_0.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/defines_0.js b/doxygen/html/search/defines_0.js new file mode 100644 index 00000000..6f670646 --- /dev/null +++ b/doxygen/html/search/defines_0.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['_5fnote_5fc_5fstringize_774',['_NOTE_C_STRINGIZE',['../note_8h.html#a9d60cc6621d82d040e56afb6f1607d69',1,'note.h']]] +]; diff --git a/doxygen/html/search/defines_1.html b/doxygen/html/search/defines_1.html new file mode 100644 index 00000000..c49009c7 --- /dev/null +++ b/doxygen/html/search/defines_1.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/defines_1.js b/doxygen/html/search/defines_1.js new file mode 100644 index 00000000..d70bba85 --- /dev/null +++ b/doxygen/html/search/defines_1.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['buffer_5fat_5foffset_775',['buffer_at_offset',['../n__cjson_8c.html#ac538057ef78677344d222b763251af5e',1,'n_cjson.c']]] +]; diff --git a/doxygen/html/search/defines_2.html b/doxygen/html/search/defines_2.html new file mode 100644 index 00000000..c5510111 --- /dev/null +++ b/doxygen/html/search/defines_2.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/defines_2.js b/doxygen/html/search/defines_2.js new file mode 100644 index 00000000..6fa7d36c --- /dev/null +++ b/doxygen/html/search/defines_2.js @@ -0,0 +1,10 @@ +var searchData= +[ + ['can_5faccess_5fat_5findex_776',['can_access_at_index',['../n__cjson_8c.html#ae210aa01f1afe7510658c392f0f6e128',1,'n_cjson.c']]], + ['can_5fread_777',['can_read',['../n__cjson_8c.html#a2257377f8b81f4f76a16b698f681af34',1,'n_cjson.c']]], + ['cannot_5faccess_5fat_5findex_778',['cannot_access_at_index',['../n__cjson_8c.html#a5c873a43d8a78ce9a6d9e8eb41d65d2d',1,'n_cjson.c']]], + ['cjson_5fmin_779',['cjson_min',['../n__cjson_8c.html#a13f540fa846f658531751b5ccb78f303',1,'n_cjson.c']]], + ['crc_5ffield_5flength_780',['CRC_FIELD_LENGTH',['../n__request_8c.html#a8334a93acebb34e7bc188f767dc42f90',1,'n_request.c']]], + ['crc_5ffield_5fname_5foffset_781',['CRC_FIELD_NAME_OFFSET',['../n__request_8c.html#a370d78366b4c13731108b1afd745b4ce',1,'n_request.c']]], + ['crc_5ffield_5fname_5ftest_782',['CRC_FIELD_NAME_TEST',['../n__request_8c.html#ac5f2372cc25a915c8dccd2924c7c6f19',1,'n_request.c']]] +]; diff --git a/doxygen/html/search/defines_3.html b/doxygen/html/search/defines_3.html new file mode 100644 index 00000000..8c6d2153 --- /dev/null +++ b/doxygen/html/search/defines_3.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/defines_3.js b/doxygen/html/search/defines_3.js new file mode 100644 index 00000000..05a8bc69 --- /dev/null +++ b/doxygen/html/search/defines_3.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['errstr_783',['ERRSTR',['../note_8h.html#a842e0f5c7170ddfde0164bad199d6fdc',1,'note.h']]] +]; diff --git a/doxygen/html/search/defines_4.html b/doxygen/html/search/defines_4.html new file mode 100644 index 00000000..f4afac12 --- /dev/null +++ b/doxygen/html/search/defines_4.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/defines_4.js b/doxygen/html/search/defines_4.js new file mode 100644 index 00000000..446e135f --- /dev/null +++ b/doxygen/html/search/defines_4.js @@ -0,0 +1,6 @@ +var searchData= +[ + ['interfacei2c_784',['interfaceI2C',['../n__hooks_8c.html#a27a151021020827bdb6304575544bb47',1,'n_hooks.c']]], + ['interfacenone_785',['interfaceNone',['../n__hooks_8c.html#ac12390f151d06023c61fbc03ffba5a13',1,'n_hooks.c']]], + ['interfaceserial_786',['interfaceSerial',['../n__hooks_8c.html#a61d64f8102ea568c7ed64584369c1779',1,'n_hooks.c']]] +]; diff --git a/doxygen/html/search/defines_5.html b/doxygen/html/search/defines_5.html new file mode 100644 index 00000000..8c40d123 --- /dev/null +++ b/doxygen/html/search/defines_5.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/defines_5.js b/doxygen/html/search/defines_5.js new file mode 100644 index 00000000..e12dd341 --- /dev/null +++ b/doxygen/html/search/defines_5.js @@ -0,0 +1,41 @@ +var searchData= +[ + ['jarray_787',['JArray',['../n__cjson_8h.html#a9948138a2efa4524c27f4381b75edf78',1,'n_cjson.h']]], + ['jarrayforeach_788',['JArrayForEach',['../n__cjson_8h.html#abf5a971e7edd30b9fdc23322cb275e23',1,'n_cjson.h']]], + ['jconvertfromjsonstring_789',['JConvertFromJSONString',['../n__cjson_8h.html#a4502909a13d0852d700ed45c692804cd',1,'n_cjson.h']]], + ['jconverttojsonstring_790',['JConvertToJSONString',['../n__cjson_8h.html#a5c58c74c07ecf18d0ffff0c989c01d31',1,'n_cjson.h']]], + ['jfalse_791',['JFalse',['../n__cjson_8h.html#a4c4e8a545657ef9148ffb476b0a93074',1,'n_cjson.h']]], + ['jgetobjectitemname_792',['JGetObjectItemName',['../note_8h.html#a5427874049e8ce6e2211214d93f232c7',1,'note.h']]], + ['jgetobjectitems_793',['JGetObjectItems',['../n__cjson_8h.html#a324bbba2b89cd3b9c306edb249452e1a',1,'n_cjson.h']]], + ['jinteger_5fmax_794',['JINTEGER_MAX',['../note_8h.html#a445107097b19783483070744407468d9',1,'note.h']]], + ['jinteger_5fmin_795',['JINTEGER_MIN',['../note_8h.html#a882dbbae976880c3bc34c7a6e6ac2f9a',1,'note.h']]], + ['jinvalid_796',['JInvalid',['../n__cjson_8h.html#add66c6533bb4eb0e8da570a0859fc4e2',1,'n_cjson.h']]], + ['jisreference_797',['JIsReference',['../n__cjson_8h.html#abd6ed1a437e8e4047b403a36bace79b0',1,'n_cjson.h']]], + ['jntoa_5fmax_798',['JNTOA_MAX',['../note_8h.html#a2554bdccd902653258af24e049abaccb',1,'note.h']]], + ['jntoa_5fprecision_799',['JNTOA_PRECISION',['../note_8h.html#a20c36388ecbae9120b19c30118891097',1,'note.h']]], + ['jnull_800',['JNULL',['../n__cjson_8h.html#a8be837cc65db843920c5bb2508208b44',1,'n_cjson.h']]], + ['jnumber_801',['JNumber',['../n__cjson_8h.html#a81a6942a78096063c9de50c2b5f756d6',1,'n_cjson.h']]], + ['jobject_802',['JObject',['../n__cjson_8h.html#a45e5b1c47300f1543cfaf97606da88b3',1,'n_cjson.h']]], + ['jobjectforeach_803',['JObjectForEach',['../n__cjson_8h.html#ac7d6eb2e58504d324156b25c6c8862b4',1,'n_cjson.h']]], + ['jraw_804',['JRaw',['../n__cjson_8h.html#a40980c81dba7b14912dd5643a3a98ce3',1,'n_cjson.h']]], + ['jsetintvalue_805',['JSetIntValue',['../n__cjson_8h.html#ae72ad73c813d2307d544d954e48d6c95',1,'n_cjson.h']]], + ['jsetnumbervalue_806',['JSetNumberValue',['../n__cjson_8h.html#a9e2a67c94b8fc6355ac93a824503a036',1,'n_cjson.h']]], + ['jstring_807',['JString',['../n__cjson_8h.html#ab9e8c51828f7f79c9fcf2220d24b03ec',1,'n_cjson.h']]], + ['jstringisconst_808',['JStringIsConst',['../n__cjson_8h.html#ab186903675fdf0b3d22cf3e7a69994bf',1,'n_cjson.h']]], + ['jtrue_809',['JTrue',['../n__cjson_8h.html#af3f87fd9d106ef925670d3b0d5303413',1,'n_cjson.h']]], + ['jtype_5farray_810',['JTYPE_ARRAY',['../note_8h.html#a3029c9e9a021cf404acbc2178b94470f',1,'note.h']]], + ['jtype_5fbool_811',['JTYPE_BOOL',['../note_8h.html#a7fd70bf9265ce886f8370b4fb8eebb92',1,'note.h']]], + ['jtype_5fbool_5ffalse_812',['JTYPE_BOOL_FALSE',['../note_8h.html#a33c56f9e059f017b5f73a7207b5f690a',1,'note.h']]], + ['jtype_5fbool_5ftrue_813',['JTYPE_BOOL_TRUE',['../note_8h.html#a1dde42a8f9d06851b91f73dcadb48067',1,'note.h']]], + ['jtype_5fnot_5fpresent_814',['JTYPE_NOT_PRESENT',['../note_8h.html#abb2f3b5f9047911dfa9ae2249ae4ad58',1,'note.h']]], + ['jtype_5fnull_815',['JTYPE_NULL',['../note_8h.html#ab65facde73aab39c8c078c8f328badb0',1,'note.h']]], + ['jtype_5fnumber_816',['JTYPE_NUMBER',['../note_8h.html#a73cc27bda4c0d44bffca5dbc353e8d65',1,'note.h']]], + ['jtype_5fnumber_5fzero_817',['JTYPE_NUMBER_ZERO',['../note_8h.html#a34cb28204f46e15dc57b5b82181e2e1d',1,'note.h']]], + ['jtype_5fobject_818',['JTYPE_OBJECT',['../note_8h.html#a7f3ba7ec204fbe5e43714b514236a1c7',1,'note.h']]], + ['jtype_5fstring_819',['JTYPE_STRING',['../note_8h.html#aeba8ddb49a982975aff58fbc5a44b37d',1,'note.h']]], + ['jtype_5fstring_5fblank_820',['JTYPE_STRING_BLANK',['../note_8h.html#a88bdd6cb77b65bec7d1a12d512a021a7',1,'note.h']]], + ['jtype_5fstring_5fbool_5ffalse_821',['JTYPE_STRING_BOOL_FALSE',['../note_8h.html#a9db7f1f3c20bfd4aa66d563cde2d3bef',1,'note.h']]], + ['jtype_5fstring_5fbool_5ftrue_822',['JTYPE_STRING_BOOL_TRUE',['../note_8h.html#ad5597cf60a093c2986fb5451e69ea43e',1,'note.h']]], + ['jtype_5fstring_5fnumber_823',['JTYPE_STRING_NUMBER',['../note_8h.html#ab081e08668cdcbaed0bf2506cb666f9b',1,'note.h']]], + ['jtype_5fstring_5fzero_824',['JTYPE_STRING_ZERO',['../note_8h.html#a05967fa1a39c824fce62fe31a645ca08',1,'note.h']]] +]; diff --git a/doxygen/html/search/defines_6.html b/doxygen/html/search/defines_6.html new file mode 100644 index 00000000..c6c0f489 --- /dev/null +++ b/doxygen/html/search/defines_6.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/defines_6.js b/doxygen/html/search/defines_6.js new file mode 100644 index 00000000..ea23c6af --- /dev/null +++ b/doxygen/html/search/defines_6.js @@ -0,0 +1,41 @@ +var searchData= +[ + ['n_5fcjson_5fnesting_5flimit_825',['N_CJSON_NESTING_LIMIT',['../n__cjson_8h.html#a4b45cf89b4c917ceca2e2389c4f723e4',1,'n_cjson.h']]], + ['n_5fcjson_5fpublic_826',['N_CJSON_PUBLIC',['../n__cjson_8h.html#a5f460c51c54d1548d58c1ebf4985a347',1,'n_cjson.h']]], + ['n_5fcjson_5fversion_5fmajor_827',['N_CJSON_VERSION_MAJOR',['../n__cjson_8h.html#aab3945fc5ef708e1ad59f44d1a7073d1',1,'n_cjson.h']]], + ['n_5fcjson_5fversion_5fminor_828',['N_CJSON_VERSION_MINOR',['../n__cjson_8h.html#aeeb6bcdd8d62de4450d58ce8b1650f30',1,'n_cjson.h']]], + ['n_5fcjson_5fversion_5fpatch_829',['N_CJSON_VERSION_PATCH',['../n__cjson_8h.html#a921b0ad837d39c9285e36ee17cba3886',1,'n_cjson.h']]], + ['note_5fc_5flog_5fdebug_830',['NOTE_C_LOG_DEBUG',['../note_8h.html#a3123fd4930117eb19b75fef8199d6032',1,'note.h']]], + ['note_5fc_5flog_5ferror_831',['NOTE_C_LOG_ERROR',['../note_8h.html#a87c75bac44560f4cbb8573dc0048169a',1,'note.h']]], + ['note_5fc_5flog_5ffile_5fand_5fline_832',['NOTE_C_LOG_FILE_AND_LINE',['../note_8h.html#a073d21669b13a5eff2361fc07c8bbf92',1,'note.h']]], + ['note_5fc_5flog_5finfo_833',['NOTE_C_LOG_INFO',['../note_8h.html#a260d740972b2082c72f77b416713f5a0',1,'note.h']]], + ['note_5fc_5flog_5flevel_834',['NOTE_C_LOG_LEVEL',['../note_8h.html#ac7f821af4d5b209d37104e2f8038f69c',1,'note.h']]], + ['note_5fc_5flog_5flevel_5fdebug_835',['NOTE_C_LOG_LEVEL_DEBUG',['../note_8h.html#ae09134b1efa9ccbc91fc1c1b6af5f4b0',1,'note.h']]], + ['note_5fc_5flog_5flevel_5ferror_836',['NOTE_C_LOG_LEVEL_ERROR',['../note_8h.html#a6c208024da45b2b4150b2f98d951efb4',1,'note.h']]], + ['note_5fc_5flog_5flevel_5finfo_837',['NOTE_C_LOG_LEVEL_INFO',['../note_8h.html#a4b3a37c8c77a3523c47e1efd31e7edc4',1,'note.h']]], + ['note_5fc_5flog_5flevel_5fwarn_838',['NOTE_C_LOG_LEVEL_WARN',['../note_8h.html#afefa6c4eba9dce431adbf9e5183e04e9',1,'note.h']]], + ['note_5fc_5flog_5fwarn_839',['NOTE_C_LOG_WARN',['../note_8h.html#a7ac988c4204339520399f37a04eb4110',1,'note.h']]], + ['note_5fc_5fstatic_840',['NOTE_C_STATIC',['../n__request_8c.html#af118c2aba9040de625bebcf41c49e571',1,'NOTE_C_STATIC(): n_request.c'],['../n__cjson_8c.html#af118c2aba9040de625bebcf41c49e571',1,'NOTE_C_STATIC(): n_cjson.c']]], + ['note_5fc_5fstringize_841',['NOTE_C_STRINGIZE',['../note_8h.html#aa0eaf84658de3c39c7263959f4950e41',1,'note.h']]], + ['note_5fc_5fversion_842',['NOTE_C_VERSION',['../note_8h.html#aa4cdd0eed41940a458709f2034b706e8',1,'note.h']]], + ['note_5fc_5fversion_5fmajor_843',['NOTE_C_VERSION_MAJOR',['../note_8h.html#ad3ef8b1d9585fb28c46942ab96815b20',1,'note.h']]], + ['note_5fc_5fversion_5fminor_844',['NOTE_C_VERSION_MINOR',['../note_8h.html#a15af17c840e4dee0e552124fde744773',1,'note.h']]], + ['note_5fc_5fversion_5fpatch_845',['NOTE_C_VERSION_PATCH',['../note_8h.html#a9a66291724eb8ba8bc651dc90ed441f9',1,'note.h']]], + ['note_5fi2c_5faddr_5fdefault_846',['NOTE_I2C_ADDR_DEFAULT',['../note_8h.html#a3107c5344909029555deedfacb21b43a',1,'note.h']]], + ['note_5fi2c_5fheader_5fsize_847',['NOTE_I2C_HEADER_SIZE',['../note_8h.html#aa043f18c8e0b59eef37008116957dbfa',1,'note.h']]], + ['note_5fi2c_5fmax_5fdefault_848',['NOTE_I2C_MAX_DEFAULT',['../note_8h.html#a029462dd63c2f85402fa69f5466082f2',1,'note.h']]], + ['note_5fi2c_5fmax_5fmax_849',['NOTE_I2C_MAX_MAX',['../note_8h.html#adc8fa90e5c138f5c4a0ac9da3be910d4',1,'note.h']]], + ['note_5fmd5_5fhash_5fsize_850',['NOTE_MD5_HASH_SIZE',['../note_8h.html#ada955eca3890263865a0f8b15afc052d',1,'note.h']]], + ['note_5fmd5_5fhash_5fstring_5fsize_851',['NOTE_MD5_HASH_STRING_SIZE',['../note_8h.html#a1bb87c25941d1a303245efbe489929e7',1,'note.h']]], + ['note_5fshow_5fmalloc_852',['NOTE_SHOW_MALLOC',['../n__hooks_8c.html#ab037e3109a302fc9719fea71f6734b32',1,'n_hooks.c']]], + ['noteaddbodytoobject_853',['NoteAddBodyToObject',['../note_8h.html#a09e55e06b045772b4fc105c0329c73a1',1,'note.h']]], + ['notedeleteresponse_854',['NoteDeleteResponse',['../note_8h.html#a5e957ef70b05d1b5173ba34ea7b60588',1,'note.h']]], + ['notegetbody_855',['NoteGetBody',['../note_8h.html#aada0fea556f714e917ac330c87c7c2c1',1,'note.h']]], + ['notenewbody_856',['NoteNewBody',['../note_8h.html#aa4e6f9fe285abae5dec0312c1dda3f06',1,'note.h']]], + ['noteresponseerror_857',['NoteResponseError',['../note_8h.html#acd6f73358d95a8188495babd142c5977',1,'note.h']]], + ['noteresponseerrorcontains_858',['NoteResponseErrorContains',['../note_8h.html#aebc81ad84af23cc172214e6bfae7a00f',1,'note.h']]], + ['notesend_859',['NoteSend',['../note_8h.html#a2468ed01b499ba8fc72fefa3500cad90',1,'note.h']]], + ['np_5fseghdr_5flen_860',['NP_SEGHDR_LEN',['../note_8h.html#a6bd262ffa71c6e153f70b1fcbfbe9150',1,'note.h']]], + ['np_5fseglen_5flen_861',['NP_SEGLEN_LEN',['../note_8h.html#a21ad183750f7d93528d707af3339b200',1,'note.h']]], + ['np_5fsegtype_5flen_862',['NP_SEGTYPE_LEN',['../note_8h.html#aa77f7c6fe5afd314bc6948e167a8d040',1,'note.h']]] +]; diff --git a/doxygen/html/search/defines_7.html b/doxygen/html/search/defines_7.html new file mode 100644 index 00000000..81d23049 --- /dev/null +++ b/doxygen/html/search/defines_7.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/defines_7.js b/doxygen/html/search/defines_7.js new file mode 100644 index 00000000..dd26db3c --- /dev/null +++ b/doxygen/html/search/defines_7.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['print_5ftab_5fchars_863',['PRINT_TAB_CHARS',['../n__cjson_8c.html#a3a77fd438cec9e807b5dfc440010d2fe',1,'n_cjson.c']]] +]; diff --git a/doxygen/html/search/defines_8.html b/doxygen/html/search/defines_8.html new file mode 100644 index 00000000..7e7e3dc9 --- /dev/null +++ b/doxygen/html/search/defines_8.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/defines_8.js b/doxygen/html/search/defines_8.js new file mode 100644 index 00000000..01abb9c6 --- /dev/null +++ b/doxygen/html/search/defines_8.js @@ -0,0 +1,8 @@ +var searchData= +[ + ['syncstatus_5flevel_5falgorithmic_864',['SYNCSTATUS_LEVEL_ALGORITHMIC',['../note_8h.html#a148902b910ba060dac353c3871183403',1,'note.h']]], + ['syncstatus_5flevel_5fall_865',['SYNCSTATUS_LEVEL_ALL',['../note_8h.html#a11bc43f4578ce909ad4403cc3b15e79f',1,'note.h']]], + ['syncstatus_5flevel_5fdetailed_866',['SYNCSTATUS_LEVEL_DETAILED',['../note_8h.html#acdd8348847658b936879035020767bab',1,'note.h']]], + ['syncstatus_5flevel_5fmajor_867',['SYNCSTATUS_LEVEL_MAJOR',['../note_8h.html#a6081d56bf39642758465b3c1d155f853',1,'note.h']]], + ['syncstatus_5flevel_5fminor_868',['SYNCSTATUS_LEVEL_MINOR',['../note_8h.html#a17656ac3ed2c4e6a77b115417bf75a7a',1,'note.h']]] +]; diff --git a/doxygen/html/search/defines_9.html b/doxygen/html/search/defines_9.html new file mode 100644 index 00000000..596c26f3 --- /dev/null +++ b/doxygen/html/search/defines_9.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/defines_9.js b/doxygen/html/search/defines_9.js new file mode 100644 index 00000000..ad30d505 --- /dev/null +++ b/doxygen/html/search/defines_9.js @@ -0,0 +1,18 @@ +var searchData= +[ + ['tbool_869',['TBOOL',['../note_8h.html#a18eddc8e4f0522a438b6475058e5ad32',1,'note.h']]], + ['tfloat16_870',['TFLOAT16',['../note_8h.html#a154fa3416f08de2b073fe6aef8c0104d',1,'note.h']]], + ['tfloat32_871',['TFLOAT32',['../note_8h.html#a340a46ea4717ab906196ee4ada26c0a0',1,'note.h']]], + ['tfloat64_872',['TFLOAT64',['../note_8h.html#a05a270325382e9d22be6317760dc800a',1,'note.h']]], + ['tint16_873',['TINT16',['../note_8h.html#a91ba007692878e4a02154c04ae390f39',1,'note.h']]], + ['tint24_874',['TINT24',['../note_8h.html#a2011bffb5bae1513306b0615f885ecc3',1,'note.h']]], + ['tint32_875',['TINT32',['../note_8h.html#ab1bbd49f40d8d7722f8ca7347bd83513',1,'note.h']]], + ['tint64_876',['TINT64',['../note_8h.html#a8437f26572687d03e061a0113af0cb0c',1,'note.h']]], + ['tint8_877',['TINT8',['../note_8h.html#a6186fd56a505b415b2ab2f50233c157f',1,'note.h']]], + ['tstring_878',['TSTRING',['../note_8h.html#ad7d1fa7b9a59ec5eba97dd784cbc29e9',1,'note.h']]], + ['tstringv_879',['TSTRINGV',['../note_8h.html#a465bf5c669736c4f4d64d185d736c5bb',1,'note.h']]], + ['tuint16_880',['TUINT16',['../note_8h.html#a1d8690165d7e8509f58efd34fd45041e',1,'note.h']]], + ['tuint24_881',['TUINT24',['../note_8h.html#a5a5e5e167c6cb206ea61d86cf030adb5',1,'note.h']]], + ['tuint32_882',['TUINT32',['../note_8h.html#a7f2af02b4c87ac0d4804ad8b5437d48d',1,'note.h']]], + ['tuint8_883',['TUINT8',['../note_8h.html#ade35b42a310f0bde7e6741c9ee7673b4',1,'note.h']]] +]; diff --git a/doxygen/html/search/files_0.html b/doxygen/html/search/files_0.html new file mode 100644 index 00000000..9498842a --- /dev/null +++ b/doxygen/html/search/files_0.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/files_0.js b/doxygen/html/search/files_0.js new file mode 100644 index 00000000..251e854d --- /dev/null +++ b/doxygen/html/search/files_0.js @@ -0,0 +1,9 @@ +var searchData= +[ + ['n_5fcjson_2ec_448',['n_cjson.c',['../n__cjson_8c.html',1,'']]], + ['n_5fcjson_2eh_449',['n_cjson.h',['../n__cjson_8h.html',1,'']]], + ['n_5fcjson_5fhelpers_2ec_450',['n_cjson_helpers.c',['../n__cjson__helpers_8c.html',1,'']]], + ['n_5fhooks_2ec_451',['n_hooks.c',['../n__hooks_8c.html',1,'']]], + ['n_5frequest_2ec_452',['n_request.c',['../n__request_8c.html',1,'']]], + ['note_2eh_453',['note.h',['../note_8h.html',1,'']]] +]; diff --git a/doxygen/html/search/functions_0.html b/doxygen/html/search/functions_0.html new file mode 100644 index 00000000..eb4c5014 --- /dev/null +++ b/doxygen/html/search/functions_0.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/functions_0.js b/doxygen/html/search/functions_0.js new file mode 100644 index 00000000..eba71534 --- /dev/null +++ b/doxygen/html/search/functions_0.js @@ -0,0 +1,111 @@ +var searchData= +[ + ['jaddarraytoobject_454',['JAddArrayToObject',['../n__cjson_8c.html#a7cd4c6c618fcaad6ac3582f09b7937e9',1,'JAddArrayToObject(J *const object, const char *const name): n_cjson.c'],['../n__cjson_8h.html#a7cd4c6c618fcaad6ac3582f09b7937e9',1,'JAddArrayToObject(J *const object, const char *const name): n_cjson.c']]], + ['jaddbinarytoobject_455',['JAddBinaryToObject',['../note_8h.html#a9378ea8eddda1f23c815b69591747846',1,'JAddBinaryToObject(J *json, const char *fieldName, const void *binaryData, uint32_t binaryDataLen): n_cjson_helpers.c'],['../n__cjson__helpers_8c.html#a9378ea8eddda1f23c815b69591747846',1,'JAddBinaryToObject(J *json, const char *fieldName, const void *binaryData, uint32_t binaryDataLen): n_cjson_helpers.c']]], + ['jaddbooltoobject_456',['JAddBoolToObject',['../n__cjson_8c.html#ada94bbdf4ef161ed96a9ad97da05bfcb',1,'JAddBoolToObject(J *const object, const char *const name, const Jbool boolean): n_cjson.c'],['../n__cjson_8h.html#ada94bbdf4ef161ed96a9ad97da05bfcb',1,'JAddBoolToObject(J *const object, const char *const name, const Jbool boolean): n_cjson.c']]], + ['jaddfalsetoobject_457',['JAddFalseToObject',['../n__cjson_8c.html#ad64ecd3c612bcf123846d501b0d5700b',1,'JAddFalseToObject(J *const object, const char *const name): n_cjson.c'],['../n__cjson_8h.html#ad64ecd3c612bcf123846d501b0d5700b',1,'JAddFalseToObject(J *const object, const char *const name): n_cjson.c']]], + ['jaddinttoobject_458',['JAddIntToObject',['../n__cjson_8h.html#a6dd643b7f5ba26a812c4d9cac4482249',1,'JAddIntToObject(J *const object, const char *const name, const JINTEGER integer): n_cjson.c'],['../n__cjson_8c.html#a6dd643b7f5ba26a812c4d9cac4482249',1,'JAddIntToObject(J *const object, const char *const name, const JINTEGER integer): n_cjson.c']]], + ['jadditemreferencetoarray_459',['JAddItemReferenceToArray',['../n__cjson_8h.html#acd1c75541c79aaf01f779286a0ce80d1',1,'JAddItemReferenceToArray(J *array, J *item): n_cjson.c'],['../n__cjson_8c.html#acd1c75541c79aaf01f779286a0ce80d1',1,'JAddItemReferenceToArray(J *array, J *item): n_cjson.c']]], + ['jadditemreferencetoobject_460',['JAddItemReferenceToObject',['../n__cjson_8h.html#ab77e67888463113228be8786a31f48d0',1,'JAddItemReferenceToObject(J *object, const char *string, J *item): n_cjson.c'],['../n__cjson_8c.html#ab77e67888463113228be8786a31f48d0',1,'JAddItemReferenceToObject(J *object, const char *string, J *item): n_cjson.c']]], + ['jadditemtoarray_461',['JAddItemToArray',['../n__cjson_8h.html#a35cec7da03622637f3be481198c7c97d',1,'JAddItemToArray(J *array, J *item): n_cjson.c'],['../n__cjson_8c.html#a35cec7da03622637f3be481198c7c97d',1,'JAddItemToArray(J *array, J *item): n_cjson.c']]], + ['jadditemtoobject_462',['JAddItemToObject',['../n__cjson_8c.html#a3430617fcd905e9d3d997354cb7e23cc',1,'JAddItemToObject(J *object, const char *string, J *item): n_cjson.c'],['../n__cjson_8h.html#a3430617fcd905e9d3d997354cb7e23cc',1,'JAddItemToObject(J *object, const char *string, J *item): n_cjson.c']]], + ['jadditemtoobjectcs_463',['JAddItemToObjectCS',['../n__cjson_8h.html#aedf66bf41048a0cfcb61a3803ed28ba0',1,'JAddItemToObjectCS(J *object, const char *string, J *item): n_cjson.c'],['../n__cjson_8c.html#aedf66bf41048a0cfcb61a3803ed28ba0',1,'JAddItemToObjectCS(J *object, const char *string, J *item): n_cjson.c']]], + ['jaddnumbertoobject_464',['JAddNumberToObject',['../n__cjson_8h.html#a4ec54b4a0b1f546f450ebdffa6a2b180',1,'JAddNumberToObject(J *const object, const char *const name, const JNUMBER number): n_cjson.c'],['../n__cjson_8c.html#a4ec54b4a0b1f546f450ebdffa6a2b180',1,'JAddNumberToObject(J *const object, const char *const name, const JNUMBER number): n_cjson.c']]], + ['jaddobjecttoobject_465',['JAddObjectToObject',['../n__cjson_8h.html#afa68057664156c8be1b1caabdd9ba851',1,'JAddObjectToObject(J *const object, const char *const name): n_cjson.c'],['../n__cjson_8c.html#afa68057664156c8be1b1caabdd9ba851',1,'JAddObjectToObject(J *const object, const char *const name): n_cjson.c']]], + ['jaddrawtoobject_466',['JAddRawToObject',['../n__cjson_8h.html#adc9d093f67cb53eb2b2264b27bfb00e4',1,'JAddRawToObject(J *const object, const char *const name, const char *const raw): n_cjson.c'],['../n__cjson_8c.html#adc9d093f67cb53eb2b2264b27bfb00e4',1,'JAddRawToObject(J *const object, const char *const name, const char *const raw): n_cjson.c']]], + ['jaddstringtoobject_467',['JAddStringToObject',['../n__cjson_8h.html#ae1162e04a1b4a9a2f59d5f98dc79d70c',1,'JAddStringToObject(J *const object, const char *const name, const char *const string): n_cjson.c'],['../n__cjson_8c.html#ae1162e04a1b4a9a2f59d5f98dc79d70c',1,'JAddStringToObject(J *const object, const char *const name, const char *const string): n_cjson.c']]], + ['jaddtruetoobject_468',['JAddTrueToObject',['../n__cjson_8h.html#a29a6911bfbeddb6d995a75aae73963da',1,'JAddTrueToObject(J *const object, const char *const name): n_cjson.c'],['../n__cjson_8c.html#a29a6911bfbeddb6d995a75aae73963da',1,'JAddTrueToObject(J *const object, const char *const name): n_cjson.c']]], + ['jallocstring_469',['JAllocString',['../n__cjson__helpers_8c.html#aacfb17275b3a24dc751834205db62e79',1,'JAllocString(uint8_t *buffer, uint32_t len): n_cjson_helpers.c'],['../note_8h.html#aacfb17275b3a24dc751834205db62e79',1,'JAllocString(uint8_t *buffer, uint32_t len): n_cjson_helpers.c']]], + ['jatoi_470',['JAtoI',['../n__cjson__helpers_8c.html#a308f04aae0351a47e78c6974c0ced6e6',1,'JAtoI(const char *string): n_cjson_helpers.c'],['../note_8h.html#aab6ee0e6d2c3b0836c6ab294c5626d01',1,'JAtoI(const char *s): n_cjson_helpers.c']]], + ['jaton_471',['JAtoN',['../note_8h.html#a2cc99bbc9c2ede0b85f310a775960f3f',1,'note.h']]], + ['jb64decode_472',['JB64Decode',['../note_8h.html#a48c6cad9358d4154567949c192445a9e',1,'note.h']]], + ['jb64decodelen_473',['JB64DecodeLen',['../note_8h.html#a53559c7bc512587f6776794a78fc424f',1,'note.h']]], + ['jb64encode_474',['JB64Encode',['../note_8h.html#abd22cd7117763400021d6653a33f0d94',1,'note.h']]], + ['jb64encodelen_475',['JB64EncodeLen',['../note_8h.html#a9c5d969e2bfd9cbda902e6388285e624',1,'note.h']]], + ['jbaseitemtype_476',['JBaseItemType',['../n__cjson__helpers_8c.html#a791851ed95cd350c24f33af25e7f0af8',1,'JBaseItemType(int type): n_cjson_helpers.c'],['../note_8h.html#a791851ed95cd350c24f33af25e7f0af8',1,'JBaseItemType(int type): n_cjson_helpers.c']]], + ['jboolvalue_477',['JBoolValue',['../n__cjson__helpers_8c.html#a3e836494d9b3a6fc4e4b02dc2767df83',1,'JBoolValue(J *item): n_cjson_helpers.c'],['../note_8h.html#a3e836494d9b3a6fc4e4b02dc2767df83',1,'JBoolValue(J *item): n_cjson_helpers.c']]], + ['jcheck_478',['JCheck',['../note_8h.html#aa2c94029f47ff6dab5fe3087d8efef4f',1,'note.h']]], + ['jcompare_479',['JCompare',['../n__cjson_8h.html#a29a204614c3c8a73a1eed2482f31ab15',1,'JCompare(const J *const a, const J *const b, const Jbool case_sensitive): n_cjson.c'],['../n__cjson_8c.html#a29a204614c3c8a73a1eed2482f31ab15',1,'JCompare(const J *const a, const J *const b, const Jbool case_sensitive): n_cjson.c']]], + ['jcontainsstring_480',['JContainsString',['../n__cjson__helpers_8c.html#a31742b8fc463be8e85fe6f1b269bf9bb',1,'JContainsString(J *json, const char *field, const char *substr): n_cjson_helpers.c'],['../note_8h.html#a31742b8fc463be8e85fe6f1b269bf9bb',1,'JContainsString(J *json, const char *field, const char *substr): n_cjson_helpers.c']]], + ['jcreatearray_481',['JCreateArray',['../n__cjson_8h.html#ad75827f86360241ca657ae848d16c243',1,'JCreateArray(void): n_cjson.c'],['../n__cjson_8c.html#ad75827f86360241ca657ae848d16c243',1,'JCreateArray(void): n_cjson.c']]], + ['jcreatearrayreference_482',['JCreateArrayReference',['../n__cjson_8h.html#a748dd4e91fbe2f6ebe288f8299dd1f2c',1,'JCreateArrayReference(const J *child): n_cjson.c'],['../n__cjson_8c.html#a748dd4e91fbe2f6ebe288f8299dd1f2c',1,'JCreateArrayReference(const J *child): n_cjson.c']]], + ['jcreatebool_483',['JCreateBool',['../n__cjson_8h.html#a62626c03b8dad6a17b15dfc2d8909a70',1,'JCreateBool(Jbool boolean): n_cjson.c'],['../n__cjson_8c.html#aafa53ebad89699a6d9569682b938b68b',1,'JCreateBool(Jbool b): n_cjson.c']]], + ['jcreatefalse_484',['JCreateFalse',['../n__cjson_8h.html#af6e5c9bd6c503f8951a38825899ef781',1,'JCreateFalse(void): n_cjson.c'],['../n__cjson_8c.html#af6e5c9bd6c503f8951a38825899ef781',1,'JCreateFalse(void): n_cjson.c']]], + ['jcreateintarray_485',['JCreateIntArray',['../n__cjson_8h.html#aa73ca2d1f034e715996630e10e35bdf8',1,'JCreateIntArray(const long int *numbers, int count): n_cjson.c'],['../n__cjson_8c.html#aa73ca2d1f034e715996630e10e35bdf8',1,'JCreateIntArray(const long int *numbers, int count): n_cjson.c']]], + ['jcreateinteger_486',['JCreateInteger',['../n__cjson_8h.html#a16770eadd67555bc26998098fcadf2ea',1,'JCreateInteger(JINTEGER integer): n_cjson.c'],['../n__cjson_8c.html#a16770eadd67555bc26998098fcadf2ea',1,'JCreateInteger(JINTEGER integer): n_cjson.c']]], + ['jcreatenumber_487',['JCreateNumber',['../n__cjson_8h.html#a7d36cc32deaf942b62cd14edcf14110e',1,'JCreateNumber(JNUMBER num): n_cjson.c'],['../n__cjson_8c.html#a7d36cc32deaf942b62cd14edcf14110e',1,'JCreateNumber(JNUMBER num): n_cjson.c']]], + ['jcreatenumberarray_488',['JCreateNumberArray',['../n__cjson_8h.html#ac72aae948a85f2b04515cb1908a2bdb2',1,'JCreateNumberArray(const JNUMBER *numbers, int count): n_cjson.c'],['../n__cjson_8c.html#ac72aae948a85f2b04515cb1908a2bdb2',1,'JCreateNumberArray(const JNUMBER *numbers, int count): n_cjson.c']]], + ['jcreateobject_489',['JCreateObject',['../n__cjson_8h.html#ae86ee2002e7ae53d7fa6ccfcae55de0e',1,'JCreateObject(void): n_cjson.c'],['../n__cjson_8c.html#ae86ee2002e7ae53d7fa6ccfcae55de0e',1,'JCreateObject(void): n_cjson.c']]], + ['jcreateobjectreference_490',['JCreateObjectReference',['../n__cjson_8c.html#a4ba40c853dd17baed1d1e02025b4b908',1,'JCreateObjectReference(const J *child): n_cjson.c'],['../n__cjson_8h.html#a4ba40c853dd17baed1d1e02025b4b908',1,'JCreateObjectReference(const J *child): n_cjson.c']]], + ['jcreateraw_491',['JCreateRaw',['../n__cjson_8h.html#a253c87633d076994278559b2dca8b326',1,'JCreateRaw(const char *raw): n_cjson.c'],['../n__cjson_8c.html#a253c87633d076994278559b2dca8b326',1,'JCreateRaw(const char *raw): n_cjson.c']]], + ['jcreatestring_492',['JCreateString',['../n__cjson_8h.html#a2f5a9a0a2d094b3a7dcfb2682974adb3',1,'JCreateString(const char *string): n_cjson.c'],['../n__cjson_8c.html#a2f5a9a0a2d094b3a7dcfb2682974adb3',1,'JCreateString(const char *string): n_cjson.c']]], + ['jcreatestringarray_493',['JCreateStringArray',['../n__cjson_8h.html#a593f675d4d3c6880d6342a278f705b45',1,'JCreateStringArray(const char **strings, int count): n_cjson.c'],['../n__cjson_8c.html#a593f675d4d3c6880d6342a278f705b45',1,'JCreateStringArray(const char **strings, int count): n_cjson.c']]], + ['jcreatestringreference_494',['JCreateStringReference',['../n__cjson_8h.html#a9a7bd4cef73e4cd16da0d3596ed8828c',1,'JCreateStringReference(const char *string): n_cjson.c'],['../n__cjson_8c.html#a9a7bd4cef73e4cd16da0d3596ed8828c',1,'JCreateStringReference(const char *string): n_cjson.c']]], + ['jcreatestringvalue_495',['JCreateStringValue',['../n__cjson_8h.html#ad0c31477e03ca9725efdf5c4f23f1b21',1,'JCreateStringValue(const char *string): n_cjson.c'],['../n__cjson_8c.html#ad0c31477e03ca9725efdf5c4f23f1b21',1,'JCreateStringValue(const char *string): n_cjson.c']]], + ['jcreatetrue_496',['JCreateTrue',['../n__cjson_8h.html#ac4239abc5da80657b4ac258ca3441525',1,'JCreateTrue(void): n_cjson.c'],['../n__cjson_8c.html#ac4239abc5da80657b4ac258ca3441525',1,'JCreateTrue(void): n_cjson.c']]], + ['jdelete_497',['JDelete',['../n__cjson_8h.html#a200e39becef910970302806821377a02',1,'JDelete(J *c): n_cjson.c'],['../n__cjson_8c.html#a68aef53f8739bf4a34f9dd73af9a6a4b',1,'JDelete(J *item): n_cjson.c']]], + ['jdeleteitemfromarray_498',['JDeleteItemFromArray',['../n__cjson_8h.html#af895529b28a3a7ee2e65e75ae1703abb',1,'JDeleteItemFromArray(J *array, int which): n_cjson.c'],['../n__cjson_8c.html#af895529b28a3a7ee2e65e75ae1703abb',1,'JDeleteItemFromArray(J *array, int which): n_cjson.c']]], + ['jdeleteitemfromobject_499',['JDeleteItemFromObject',['../n__cjson_8h.html#a469200cf78eb64693c306b8c2bb8fca6',1,'JDeleteItemFromObject(J *object, const char *string): n_cjson.c'],['../n__cjson_8c.html#a469200cf78eb64693c306b8c2bb8fca6',1,'JDeleteItemFromObject(J *object, const char *string): n_cjson.c']]], + ['jdeleteitemfromobjectcasesensitive_500',['JDeleteItemFromObjectCaseSensitive',['../n__cjson_8h.html#a4d2345eb658b861b6be499ae156eb4d5',1,'JDeleteItemFromObjectCaseSensitive(J *object, const char *string): n_cjson.c'],['../n__cjson_8c.html#a4d2345eb658b861b6be499ae156eb4d5',1,'JDeleteItemFromObjectCaseSensitive(J *object, const char *string): n_cjson.c']]], + ['jdetachitemfromarray_501',['JDetachItemFromArray',['../n__cjson_8h.html#ac76b43d7456f0d9b20dfb05afb34de2f',1,'JDetachItemFromArray(J *array, int which): n_cjson.c'],['../n__cjson_8c.html#ac76b43d7456f0d9b20dfb05afb34de2f',1,'JDetachItemFromArray(J *array, int which): n_cjson.c']]], + ['jdetachitemfromobject_502',['JDetachItemFromObject',['../n__cjson_8c.html#a1a32853dd45405ad607a12fc73704060',1,'JDetachItemFromObject(J *object, const char *string): n_cjson.c'],['../n__cjson_8h.html#a1a32853dd45405ad607a12fc73704060',1,'JDetachItemFromObject(J *object, const char *string): n_cjson.c']]], + ['jdetachitemfromobjectcasesensitive_503',['JDetachItemFromObjectCaseSensitive',['../n__cjson_8h.html#a8091581926873615eb209c29281bff96',1,'JDetachItemFromObjectCaseSensitive(J *object, const char *string): n_cjson.c'],['../n__cjson_8c.html#a8091581926873615eb209c29281bff96',1,'JDetachItemFromObjectCaseSensitive(J *object, const char *string): n_cjson.c']]], + ['jdetachitemviapointer_504',['JDetachItemViaPointer',['../n__cjson_8h.html#afe5cf91e0f429c5d419d1107a5337232',1,'JDetachItemViaPointer(J *parent, J *const item): n_cjson.c'],['../n__cjson_8c.html#afe5cf91e0f429c5d419d1107a5337232',1,'JDetachItemViaPointer(J *parent, J *const item): n_cjson.c']]], + ['jduplicate_505',['JDuplicate',['../n__cjson_8h.html#adddee3d8407e149c5e4b77c139a0fcd9',1,'JDuplicate(const J *item, Jbool recurse): n_cjson.c'],['../n__cjson_8c.html#adddee3d8407e149c5e4b77c139a0fcd9',1,'JDuplicate(const J *item, Jbool recurse): n_cjson.c']]], + ['jfree_506',['JFree',['../n__cjson_8h.html#a65411d47da558e0084a07a773275218b',1,'JFree(void *object): n_cjson.c'],['../n__cjson_8c.html#abf261bfa6bcacd681e976231d1d974d3',1,'JFree(void *p): n_cjson.c']]], + ['jgetarray_507',['JGetArray',['../n__cjson__helpers_8c.html#a529a0e079866616aa12e4598296e462f',1,'JGetArray(J *json, const char *field): n_cjson_helpers.c'],['../note_8h.html#a529a0e079866616aa12e4598296e462f',1,'JGetArray(J *json, const char *field): n_cjson_helpers.c']]], + ['jgetarrayitem_508',['JGetArrayItem',['../n__cjson_8c.html#af581f6c7ed4c9348939c3c52b043caa9',1,'JGetArrayItem(const J *array, int index): n_cjson.c'],['../n__cjson_8h.html#af581f6c7ed4c9348939c3c52b043caa9',1,'JGetArrayItem(const J *array, int index): n_cjson.c']]], + ['jgetarraysize_509',['JGetArraySize',['../n__cjson_8h.html#ad6c39ba426fee1353a286a35b64a825d',1,'JGetArraySize(const J *array): n_cjson.c'],['../n__cjson_8c.html#ad6c39ba426fee1353a286a35b64a825d',1,'JGetArraySize(const J *array): n_cjson.c']]], + ['jgetbinaryfromobject_510',['JGetBinaryFromObject',['../n__cjson__helpers_8c.html#a4c5ca7aa585e06623f2788b86300538d',1,'JGetBinaryFromObject(J *json, const char *fieldName, uint8_t **retBinaryData, uint32_t *retBinaryDataLen): n_cjson_helpers.c'],['../note_8h.html#a4c5ca7aa585e06623f2788b86300538d',1,'JGetBinaryFromObject(J *json, const char *fieldName, uint8_t **retBinaryData, uint32_t *retBinaryDataLen): n_cjson_helpers.c']]], + ['jgetbool_511',['JGetBool',['../n__cjson__helpers_8c.html#a51518894ee545340a884089f64e34671',1,'JGetBool(J *json, const char *field): n_cjson_helpers.c'],['../note_8h.html#a51518894ee545340a884089f64e34671',1,'JGetBool(J *json, const char *field): n_cjson_helpers.c']]], + ['jgeterrorptr_512',['JGetErrorPtr',['../n__cjson_8h.html#a5dd9a0020f9d8c787390cd5289942b42',1,'JGetErrorPtr(void): n_cjson.c'],['../n__cjson_8c.html#a5dd9a0020f9d8c787390cd5289942b42',1,'JGetErrorPtr(void): n_cjson.c']]], + ['jgetint_513',['JGetInt',['../n__cjson__helpers_8c.html#a00b1ca83bdb8cc849114b973dd862d65',1,'JGetInt(J *json, const char *field): n_cjson_helpers.c'],['../note_8h.html#a00b1ca83bdb8cc849114b973dd862d65',1,'JGetInt(J *json, const char *field): n_cjson_helpers.c']]], + ['jgetitemname_514',['JGetItemName',['../n__cjson__helpers_8c.html#acf30975898c4673472f59eb97d913712',1,'JGetItemName(const J *item): n_cjson_helpers.c'],['../note_8h.html#acf30975898c4673472f59eb97d913712',1,'JGetItemName(const J *item): n_cjson_helpers.c']]], + ['jgetitemtype_515',['JGetItemType',['../n__cjson__helpers_8c.html#a39d4dc978cbd0c5d10d287b4ac57b8d1',1,'JGetItemType(J *item): n_cjson_helpers.c'],['../note_8h.html#a39d4dc978cbd0c5d10d287b4ac57b8d1',1,'JGetItemType(J *item): n_cjson_helpers.c']]], + ['jgetnumber_516',['JGetNumber',['../note_8h.html#a7e30c9120dbe63db3fbedd568f76ecf7',1,'JGetNumber(J *json, const char *field): n_cjson_helpers.c'],['../n__cjson__helpers_8c.html#a7e30c9120dbe63db3fbedd568f76ecf7',1,'JGetNumber(J *json, const char *field): n_cjson_helpers.c']]], + ['jgetobject_517',['JGetObject',['../n__cjson__helpers_8c.html#a5334b2addcaa277c21319d38c17ab74b',1,'JGetObject(J *json, const char *field): n_cjson_helpers.c'],['../note_8h.html#a5334b2addcaa277c21319d38c17ab74b',1,'JGetObject(J *json, const char *field): n_cjson_helpers.c']]], + ['jgetobjectitem_518',['JGetObjectItem',['../n__cjson_8h.html#a22f9286ff894072bef58b39aa5d7223e',1,'JGetObjectItem(const J *const object, const char *const string): n_cjson.c'],['../n__cjson_8c.html#a22f9286ff894072bef58b39aa5d7223e',1,'JGetObjectItem(const J *const object, const char *const string): n_cjson.c']]], + ['jgetobjectitemcasesensitive_519',['JGetObjectItemCaseSensitive',['../n__cjson_8h.html#a2ce90377e181ab0f4dc4c47b6a7a1d30',1,'JGetObjectItemCaseSensitive(const J *const object, const char *const string): n_cjson.c'],['../n__cjson_8c.html#a2ce90377e181ab0f4dc4c47b6a7a1d30',1,'JGetObjectItemCaseSensitive(const J *const object, const char *const string): n_cjson.c']]], + ['jgetstring_520',['JGetString',['../n__cjson__helpers_8c.html#aa8d038212b35b9da6d78100be2c00285',1,'JGetString(J *json, const char *field): n_cjson_helpers.c'],['../note_8h.html#aa8d038212b35b9da6d78100be2c00285',1,'JGetString(J *json, const char *field): n_cjson_helpers.c']]], + ['jgetstringvalue_521',['JGetStringValue',['../n__cjson_8h.html#af0163fae01e99e4d0e6ea6e0c0303e68',1,'JGetStringValue(J *item): n_cjson.c'],['../n__cjson_8c.html#af0163fae01e99e4d0e6ea6e0c0303e68',1,'JGetStringValue(J *item): n_cjson.c']]], + ['jgettype_522',['JGetType',['../n__cjson__helpers_8c.html#a0b63b324fbe5e773ca7c137666687b41',1,'JGetType(J *json, const char *field): n_cjson_helpers.c'],['../note_8h.html#a0b63b324fbe5e773ca7c137666687b41',1,'JGetType(J *json, const char *field): n_cjson_helpers.c']]], + ['jhasobjectitem_523',['JHasObjectItem',['../n__cjson_8h.html#a7469d6cd6aa0d487c5a3a87a102ad3ee',1,'JHasObjectItem(const J *object, const char *string): n_cjson.c'],['../n__cjson_8c.html#a7469d6cd6aa0d487c5a3a87a102ad3ee',1,'JHasObjectItem(const J *object, const char *string): n_cjson.c']]], + ['jinit_524',['JInit',['../note_8h.html#ab4005e4eb92f95e4430147551c093a82',1,'note.h']]], + ['jinithooks_525',['JInitHooks',['../n__cjson_8h.html#a3acdaa6d3025b4e731284f0c949f32a3',1,'n_cjson.h']]], + ['jinsertiteminarray_526',['JInsertItemInArray',['../n__cjson_8h.html#a67d8128a4a64c4554afcf33c41487633',1,'JInsertItemInArray(J *array, int which, J *newitem): n_cjson.c'],['../n__cjson_8c.html#a67d8128a4a64c4554afcf33c41487633',1,'JInsertItemInArray(J *array, int which, J *newitem): n_cjson.c']]], + ['jintvalue_527',['JIntValue',['../n__cjson__helpers_8c.html#a9f5aaa3fbaaee87de2b6119c7428b9dd',1,'JIntValue(J *item): n_cjson_helpers.c'],['../note_8h.html#a9f5aaa3fbaaee87de2b6119c7428b9dd',1,'JIntValue(J *item): n_cjson_helpers.c']]], + ['jisarray_528',['JIsArray',['../n__cjson_8h.html#ad2e8fbc0e1b1484f3593d95e32335c12',1,'JIsArray(const J *const item): n_cjson.c'],['../n__cjson_8c.html#ad2e8fbc0e1b1484f3593d95e32335c12',1,'JIsArray(const J *const item): n_cjson.c']]], + ['jisbool_529',['JIsBool',['../n__cjson_8c.html#a7018dd9b9399e168495a42da2ca30c32',1,'JIsBool(const J *const item): n_cjson.c'],['../n__cjson_8h.html#a7018dd9b9399e168495a42da2ca30c32',1,'JIsBool(const J *const item): n_cjson.c']]], + ['jisexactstring_530',['JIsExactString',['../n__cjson__helpers_8c.html#af4e9257e3b88d1b55441f15efd1bf0c3',1,'JIsExactString(J *json, const char *field, const char *teststr): n_cjson_helpers.c'],['../note_8h.html#af4e9257e3b88d1b55441f15efd1bf0c3',1,'JIsExactString(J *json, const char *field, const char *teststr): n_cjson_helpers.c']]], + ['jisfalse_531',['JIsFalse',['../n__cjson_8h.html#a457bc8d0d7e568fd974b36e9d10ec24d',1,'JIsFalse(const J *const item): n_cjson.c'],['../n__cjson_8c.html#a457bc8d0d7e568fd974b36e9d10ec24d',1,'JIsFalse(const J *const item): n_cjson.c']]], + ['jisinvalid_532',['JIsInvalid',['../n__cjson_8h.html#a88cfb9e3b03ac17ba67d037f76037dbc',1,'JIsInvalid(const J *const item): n_cjson.c'],['../n__cjson_8c.html#a88cfb9e3b03ac17ba67d037f76037dbc',1,'JIsInvalid(const J *const item): n_cjson.c']]], + ['jisnull_533',['JIsNull',['../n__cjson_8h.html#a58e9e823e7eb8675b8dd652994816d10',1,'JIsNull(const J *const item): n_cjson.c'],['../n__cjson_8c.html#a58e9e823e7eb8675b8dd652994816d10',1,'JIsNull(const J *const item): n_cjson.c']]], + ['jisnullstring_534',['JIsNullString',['../n__cjson__helpers_8c.html#aafb4b69e85bd5d9c2d1534688fd4176d',1,'JIsNullString(J *json, const char *field): n_cjson_helpers.c'],['../note_8h.html#aafb4b69e85bd5d9c2d1534688fd4176d',1,'JIsNullString(J *json, const char *field): n_cjson_helpers.c']]], + ['jisnumber_535',['JIsNumber',['../n__cjson_8c.html#a90966d05e3d50b9c6f664be5bb0246ec',1,'JIsNumber(const J *const item): n_cjson.c'],['../n__cjson_8h.html#a90966d05e3d50b9c6f664be5bb0246ec',1,'JIsNumber(const J *const item): n_cjson.c']]], + ['jisobject_536',['JIsObject',['../n__cjson_8h.html#a46958f34e3c76bef78fff3e9f78a7af8',1,'JIsObject(const J *const item): n_cjson.c'],['../n__cjson_8c.html#a46958f34e3c76bef78fff3e9f78a7af8',1,'JIsObject(const J *const item): n_cjson.c']]], + ['jispresent_537',['JIsPresent',['../n__cjson__helpers_8c.html#a6cfeede8f787bbfd890ec7deae8aca24',1,'JIsPresent(J *json, const char *field): n_cjson_helpers.c'],['../note_8h.html#a6cfeede8f787bbfd890ec7deae8aca24',1,'JIsPresent(J *json, const char *field): n_cjson_helpers.c']]], + ['jisraw_538',['JIsRaw',['../n__cjson_8h.html#a38fc30cb88e2b0e194eb1b15def5c85d',1,'JIsRaw(const J *const item): n_cjson.c'],['../n__cjson_8c.html#a38fc30cb88e2b0e194eb1b15def5c85d',1,'JIsRaw(const J *const item): n_cjson.c']]], + ['jisstring_539',['JIsString',['../n__cjson_8h.html#a35c8801a08c0fd4de08759c36bd7d8ad',1,'JIsString(const J *const item): n_cjson.c'],['../n__cjson_8c.html#a35c8801a08c0fd4de08759c36bd7d8ad',1,'JIsString(const J *const item): n_cjson.c']]], + ['jistrue_540',['JIsTrue',['../n__cjson_8h.html#af3451fac120016cabb032443098328e1',1,'JIsTrue(const J *const item): n_cjson.c'],['../n__cjson_8c.html#af3451fac120016cabb032443098328e1',1,'JIsTrue(const J *const item): n_cjson.c']]], + ['jitoa_541',['JItoA',['../n__cjson__helpers_8c.html#a3fe8a8eeb1d78a8eb52ed720a36b99c6',1,'JItoA(JINTEGER n, char *s): n_cjson_helpers.c'],['../note_8h.html#a3fe8a8eeb1d78a8eb52ed720a36b99c6',1,'JItoA(JINTEGER n, char *s): n_cjson_helpers.c']]], + ['jmalloc_542',['JMalloc',['../n__cjson_8c.html#a820f2fa3e1ef927ecf7fa31bb8de2002',1,'JMalloc(size_t size): n_cjson.c'],['../n__cjson_8h.html#a820f2fa3e1ef927ecf7fa31bb8de2002',1,'JMalloc(size_t size): n_cjson.c']]], + ['jminify_543',['JMinify',['../n__cjson_8h.html#a34f0eda948e36394026a0c2d927bbed5',1,'JMinify(char *json): n_cjson.c'],['../n__cjson_8c.html#a34f0eda948e36394026a0c2d927bbed5',1,'JMinify(char *json): n_cjson.c']]], + ['jntoa_544',['JNtoA',['../note_8h.html#ae6dda9b360c01c2e654c62a320db56ff',1,'note.h']]], + ['jnumbervalue_545',['JNumberValue',['../n__cjson__helpers_8c.html#a2b2a9c92f2833d424d1a7ab66b3533a8',1,'JNumberValue(J *item): n_cjson_helpers.c'],['../note_8h.html#a2b2a9c92f2833d424d1a7ab66b3533a8',1,'JNumberValue(J *item): n_cjson_helpers.c']]], + ['jparse_546',['JParse',['../n__cjson_8h.html#ad286b9ae6d487c082caa7a0fa5764f69',1,'JParse(const char *value): n_cjson.c'],['../n__cjson_8c.html#ad286b9ae6d487c082caa7a0fa5764f69',1,'JParse(const char *value): n_cjson.c']]], + ['jparsewithopts_547',['JParseWithOpts',['../n__cjson_8h.html#a0bb5a98ddeb134fb0f9f9006c50bdf27',1,'JParseWithOpts(const char *value, const char **return_parse_end, Jbool require_null_terminated): n_cjson.c'],['../n__cjson_8c.html#a0bb5a98ddeb134fb0f9f9006c50bdf27',1,'JParseWithOpts(const char *value, const char **return_parse_end, Jbool require_null_terminated): n_cjson.c']]], + ['jprint_548',['JPrint',['../n__cjson_8h.html#aa869125c5b452e2e8d0143eee20c9c92',1,'JPrint(const J *item): n_cjson.c'],['../n__cjson_8c.html#aa869125c5b452e2e8d0143eee20c9c92',1,'JPrint(const J *item): n_cjson.c']]], + ['jprintbuffered_549',['JPrintBuffered',['../n__cjson_8h.html#a14a6a625679d4c4f6a93353874257daf',1,'JPrintBuffered(const J *item, int prebuffer, Jbool fmt): n_cjson.c'],['../n__cjson_8c.html#a14a6a625679d4c4f6a93353874257daf',1,'JPrintBuffered(const J *item, int prebuffer, Jbool fmt): n_cjson.c']]], + ['jprintpreallocated_550',['JPrintPreallocated',['../n__cjson_8h.html#a9662c84586e86ee2e8ef9e8e4e06a7e5',1,'JPrintPreallocated(J *item, char *buffer, const int length, const Jbool format): n_cjson.c'],['../n__cjson_8c.html#aec398b8654e05c3465d069e34deca404',1,'JPrintPreallocated(J *item, char *buf, const int len, const Jbool fmt): n_cjson.c']]], + ['jprintpreallocatedomitempty_551',['JPrintPreallocatedOmitEmpty',['../n__cjson_8h.html#af12b8d583fbab76f68acf6d7ba31a935',1,'JPrintPreallocatedOmitEmpty(J *item, char *buffer, const int length, const Jbool format): n_cjson.c'],['../n__cjson_8c.html#a996461f664592b56a8f76834b0156181',1,'JPrintPreallocatedOmitEmpty(J *item, char *buf, const int len, const Jbool fmt): n_cjson.c']]], + ['jprintunformatted_552',['JPrintUnformatted',['../n__cjson_8h.html#a458985772911635a0d904e575a5c7839',1,'JPrintUnformatted(const J *item): n_cjson.c'],['../n__cjson_8c.html#a458985772911635a0d904e575a5c7839',1,'JPrintUnformatted(const J *item): n_cjson.c']]], + ['jprintunformattedomitempty_553',['JPrintUnformattedOmitEmpty',['../n__cjson_8h.html#a14ac02cf9a117f42de1aae22c6d67bc8',1,'JPrintUnformattedOmitEmpty(const J *item): n_cjson.c'],['../n__cjson_8c.html#a14ac02cf9a117f42de1aae22c6d67bc8',1,'JPrintUnformattedOmitEmpty(const J *item): n_cjson.c']]], + ['jreplaceiteminarray_554',['JReplaceItemInArray',['../n__cjson_8h.html#a3382107cdb7fbf8bb00d0a59ce8c02f3',1,'JReplaceItemInArray(J *array, int which, J *newitem): n_cjson.c'],['../n__cjson_8c.html#a3382107cdb7fbf8bb00d0a59ce8c02f3',1,'JReplaceItemInArray(J *array, int which, J *newitem): n_cjson.c']]], + ['jreplaceiteminobject_555',['JReplaceItemInObject',['../n__cjson_8c.html#a90435b417a6abdb321c4c300bdf8b75b',1,'JReplaceItemInObject(J *object, const char *string, J *newitem): n_cjson.c'],['../n__cjson_8h.html#a90435b417a6abdb321c4c300bdf8b75b',1,'JReplaceItemInObject(J *object, const char *string, J *newitem): n_cjson.c']]], + ['jreplaceiteminobjectcasesensitive_556',['JReplaceItemInObjectCaseSensitive',['../n__cjson_8h.html#ae3eaa58eeca1eb3a5821e21286dc72bd',1,'JReplaceItemInObjectCaseSensitive(J *object, const char *string, J *newitem): n_cjson.c'],['../n__cjson_8c.html#ae3eaa58eeca1eb3a5821e21286dc72bd',1,'JReplaceItemInObjectCaseSensitive(J *object, const char *string, J *newitem): n_cjson.c']]], + ['jreplaceitemviapointer_557',['JReplaceItemViaPointer',['../n__cjson_8h.html#a0ef15ee7acb72042a7ab2fdcf088b090',1,'JReplaceItemViaPointer(J *const parent, J *const item, J *replacement): n_cjson.c'],['../n__cjson_8c.html#a0ef15ee7acb72042a7ab2fdcf088b090',1,'JReplaceItemViaPointer(J *const parent, J *const item, J *replacement): n_cjson.c']]], + ['jsetnumberhelper_558',['JSetNumberHelper',['../n__cjson_8h.html#ae69e47e50ef142737771bad7332bd8a1',1,'JSetNumberHelper(J *object, JNUMBER number): n_cjson.c'],['../n__cjson_8c.html#ae69e47e50ef142737771bad7332bd8a1',1,'JSetNumberHelper(J *object, JNUMBER number): n_cjson.c']]], + ['jstringvalue_559',['JStringValue',['../n__cjson__helpers_8c.html#a2499d761e554a80868701a50c2a05f17',1,'JStringValue(J *item): n_cjson_helpers.c'],['../note_8h.html#a2499d761e554a80868701a50c2a05f17',1,'JStringValue(J *item): n_cjson_helpers.c']]], + ['jtype_560',['JType',['../n__cjson__helpers_8c.html#ade41b3ffbdfc99fa8a87ae63cfebb2fa',1,'JType(J *item): n_cjson_helpers.c'],['../note_8h.html#ade41b3ffbdfc99fa8a87ae63cfebb2fa',1,'JType(J *item): n_cjson_helpers.c']]], + ['jversion_561',['JVersion',['../n__cjson_8h.html#a43aeaea29ca03af0c4aa80556fee3445',1,'JVersion(void): n_cjson.c'],['../n__cjson_8c.html#a43aeaea29ca03af0c4aa80556fee3445',1,'JVersion(void): n_cjson.c']]] +]; diff --git a/doxygen/html/search/functions_1.html b/doxygen/html/search/functions_1.html new file mode 100644 index 00000000..ef4088b8 --- /dev/null +++ b/doxygen/html/search/functions_1.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/functions_1.js b/doxygen/html/search/functions_1.js new file mode 100644 index 00000000..901d21f1 --- /dev/null +++ b/doxygen/html/search/functions_1.js @@ -0,0 +1,141 @@ +var searchData= +[ + ['n_5fatoh_562',['n_atoh',['../n__request_8c.html#a56c6c634ffc5ccaa04faf0875c0fe10e',1,'n_request.c']]], + ['n_5fhtoa16_563',['n_htoa16',['../n__cjson_8c.html#a745406e6582e9e9cd4bc4411d0f91b86',1,'n_cjson.c']]], + ['n_5fhtoa32_564',['n_htoa32',['../n__hooks_8c.html#aac33ee334208aaa53da33809889f0abe',1,'n_hooks.c']]], + ['noteactiveinterface_565',['noteActiveInterface',['../n__hooks_8c.html#a70ecd2743be8507da5bd82b1fc94074f',1,'n_hooks.c']]], + ['noteadd_566',['NoteAdd',['../note_8h.html#a859c73fcda95741f545f2996d0d4d50a',1,'note.h']]], + ['notebinarycodecdecode_567',['NoteBinaryCodecDecode',['../note_8h.html#a10c81f1c0470f4b3cd1c877183163815',1,'note.h']]], + ['notebinarycodecencode_568',['NoteBinaryCodecEncode',['../note_8h.html#a91a381b28624b7d7a5b7c59cea31e40f',1,'note.h']]], + ['notebinarycodecmaxdecodedlength_569',['NoteBinaryCodecMaxDecodedLength',['../note_8h.html#a5db0bc71463c613425debfb34fa38794',1,'note.h']]], + ['notebinarycodecmaxencodedlength_570',['NoteBinaryCodecMaxEncodedLength',['../note_8h.html#a126a4cb7f30d49518bd2552902099634',1,'note.h']]], + ['notebinarystoredecodedlength_571',['NoteBinaryStoreDecodedLength',['../note_8h.html#afe6fc60626aff39d8daa732d5cd98acc',1,'note.h']]], + ['notebinarystoreencodedlength_572',['NoteBinaryStoreEncodedLength',['../note_8h.html#a7f645124333a941eccdba3fbc70381f1',1,'note.h']]], + ['notebinarystorereceive_573',['NoteBinaryStoreReceive',['../note_8h.html#a0a6303c68a7d3fec63ed94e540c349b4',1,'note.h']]], + ['notebinarystorereset_574',['NoteBinaryStoreReset',['../note_8h.html#a4b0744fcac784957345f532646a81c10',1,'note.h']]], + ['notebinarystoretransmit_575',['NoteBinaryStoreTransmit',['../note_8h.html#afdad71c4316f98ed2502d632846edf76',1,'note.h']]], + ['notechunkedreceive_576',['noteChunkedReceive',['../n__hooks_8c.html#ae4ccc80c42fc4c2ca310f46452f7008d',1,'n_hooks.c']]], + ['notechunkedtransmit_577',['noteChunkedTransmit',['../n__hooks_8c.html#aeebbd8afc790746f80206493d833a2af',1,'n_hooks.c']]], + ['noteclearlocation_578',['NoteClearLocation',['../note_8h.html#aafa429043e07e78852045017c75392ae',1,'note.h']]], + ['notedebug_579',['NoteDebug',['../n__hooks_8c.html#a2f5d9ab0d7d259363c2b1fc9507968e9',1,'NoteDebug(const char *line): n_hooks.c'],['../note_8h.html#ab3a18d61ebc4df43fad6b0eb8ff327fa',1,'NoteDebug(const char *message): n_hooks.c']]], + ['notedebugf_580',['NoteDebugf',['../note_8h.html#ab239dae9dfc343d2569fe87041ae7d49',1,'note.h']]], + ['notedebugintln_581',['NoteDebugIntln',['../n__hooks_8c.html#a735b443951ae911c98ddb39c54f0ba7a',1,'NoteDebugIntln(const char *line, int n): n_hooks.c'],['../note_8h.html#ab81480d77900e81e466d9010ed57a347',1,'NoteDebugIntln(const char *message, int n): n_hooks.c']]], + ['notedebugln_582',['NoteDebugln',['../n__hooks_8c.html#ad2104215255468930924e4f3c5eac820',1,'NoteDebugln(const char *line): n_hooks.c'],['../note_8h.html#a080a80ba2040187f419af4cafe0042e6',1,'NoteDebugln(const char *message): n_hooks.c']]], + ['notedebugsyncstatus_583',['NoteDebugSyncStatus',['../note_8h.html#adde35249318a7b5cc3f1c2393685b75b',1,'note.h']]], + ['notedebugwithlevel_584',['NoteDebugWithLevel',['../note_8h.html#adbf027f8ae53aea93f71965a9dbad0d8',1,'NoteDebugWithLevel(uint8_t level, const char *msg): n_hooks.c'],['../n__hooks_8c.html#adbf027f8ae53aea93f71965a9dbad0d8',1,'NoteDebugWithLevel(uint8_t level, const char *msg): n_hooks.c']]], + ['notedebugwithlevelln_585',['NoteDebugWithLevelLn',['../n__hooks_8c.html#aea4a872558f91cfdba679dea15e39b9c',1,'NoteDebugWithLevelLn(uint8_t level, const char *msg): n_hooks.c'],['../note_8h.html#aea4a872558f91cfdba679dea15e39b9c',1,'NoteDebugWithLevelLn(uint8_t level, const char *msg): n_hooks.c']]], + ['notedelayms_586',['NoteDelayMs',['../n__hooks_8c.html#a30ebf8f80fc647865819c842adc53816',1,'NoteDelayMs(uint32_t ms): n_hooks.c'],['../note_8h.html#a30ebf8f80fc647865819c842adc53816',1,'NoteDelayMs(uint32_t ms): n_hooks.c']]], + ['noteerrorclean_587',['NoteErrorClean',['../n__request_8c.html#a622a74213848c997191e0fceb7d72c64',1,'NoteErrorClean(char *begin): n_request.c'],['../note_8h.html#a3b8d73d3dc3b3315b1be8260e83f10ab',1,'NoteErrorClean(char *errbuf): n_request.c']]], + ['noteerrorcontains_588',['NoteErrorContains',['../n__request_8c.html#a1385294098059d94d366e2fd843358e5',1,'NoteErrorContains(const char *errstr, const char *errtype): n_request.c'],['../note_8h.html#a1385294098059d94d366e2fd843358e5',1,'NoteErrorContains(const char *errstr, const char *errtype): n_request.c']]], + ['notefactoryreset_589',['NoteFactoryReset',['../note_8h.html#a0a6818960d5dc59c9dc15ec12c8eca67',1,'note.h']]], + ['notefree_590',['NoteFree',['../n__hooks_8c.html#a684906dd58e03a139b98f3a342b5c83b',1,'NoteFree(void *p): n_hooks.c'],['../note_8h.html#a34280452b55a2013552227bd6e811fdd',1,'NoteFree(void *): n_hooks.c']]], + ['notegetcontact_591',['NoteGetContact',['../note_8h.html#a289e6d70e17615cf927a9094080139f1',1,'note.h']]], + ['notegetenv_592',['NoteGetEnv',['../note_8h.html#a84b63daf99110b90e0e9cad94df694ff',1,'note.h']]], + ['notegetenvint_593',['NoteGetEnvInt',['../note_8h.html#aa998d7b236f2ff2541a20872f261db60',1,'note.h']]], + ['notegetenvnumber_594',['NoteGetEnvNumber',['../note_8h.html#af6f3d1929a16c26050550f01d69de9a9',1,'note.h']]], + ['notegetlocation_595',['NoteGetLocation',['../note_8h.html#a711d1c4cb256e29e34853959d4f032cc',1,'note.h']]], + ['notegetlocationmode_596',['NoteGetLocationMode',['../note_8h.html#a1f5e4d1d5d4c91ee2409686e59e28e76',1,'note.h']]], + ['notegetms_597',['NoteGetMs',['../note_8h.html#a4dcd12c5b2ec9d2acd78363a2e41e698',1,'NoteGetMs(void): n_hooks.c'],['../n__hooks_8c.html#a4dcd12c5b2ec9d2acd78363a2e41e698',1,'NoteGetMs(void): n_hooks.c']]], + ['notegetnetstatus_598',['NoteGetNetStatus',['../note_8h.html#a387befb0abe72b215645a6650ea7e72f',1,'note.h']]], + ['notegetserviceconfig_599',['NoteGetServiceConfig',['../note_8h.html#acf36d7c23420551e51597554a69f97c3',1,'note.h']]], + ['notegetserviceconfigst_600',['NoteGetServiceConfigST',['../note_8h.html#ac5989f17e99b8f154fe4318bb7bcf73d',1,'note.h']]], + ['notegetstatus_601',['NoteGetStatus',['../note_8h.html#adfe58a53ab4a4de6f6b00092494330ab',1,'note.h']]], + ['notegetstatusst_602',['NoteGetStatusST',['../note_8h.html#ad873ec5c640174f673ceabad89b8f030',1,'note.h']]], + ['notegettemperature_603',['NoteGetTemperature',['../note_8h.html#a33a8a42563cc3dc4d3bda44144d73784',1,'note.h']]], + ['notegetversion_604',['NoteGetVersion',['../note_8h.html#ab9c78d2fef7a116ccc22ced6a9304fb1',1,'note.h']]], + ['notegetvoltage_605',['NoteGetVoltage',['../note_8h.html#ad29039cfe90306e391d8a85a0df1d69f',1,'note.h']]], + ['notehardreset_606',['noteHardReset',['../n__hooks_8c.html#a25a3bc894007c69b27c81bd2093c1457',1,'n_hooks.c']]], + ['notei2caddress_607',['NoteI2CAddress',['../n__hooks_8c.html#a57dcffb142faaef2714839d27afe5be0',1,'NoteI2CAddress(void): n_hooks.c'],['../note_8h.html#a57dcffb142faaef2714839d27afe5be0',1,'NoteI2CAddress(void): n_hooks.c']]], + ['notei2cmax_608',['NoteI2CMax',['../n__hooks_8c.html#a35bbb8179be3a72ab7ec302dcbfad9e7',1,'NoteI2CMax(void): n_hooks.c'],['../note_8h.html#a35bbb8179be3a72ab7ec302dcbfad9e7',1,'NoteI2CMax(void): n_hooks.c']]], + ['notei2creceive_609',['noteI2CReceive',['../n__hooks_8c.html#a99f3a0e0399cb234c4beffb898857460',1,'n_hooks.c']]], + ['notei2creset_610',['noteI2CReset',['../n__hooks_8c.html#ac0f858f36f53326c84d163a9c555face',1,'n_hooks.c']]], + ['notei2ctransmit_611',['noteI2CTransmit',['../n__hooks_8c.html#a5d9df694d590e90ac6be645445cd29c3',1,'n_hooks.c']]], + ['noteisconnected_612',['NoteIsConnected',['../note_8h.html#ad479c8e6d2c17ed58f96b9aa234ad81d',1,'note.h']]], + ['noteisconnectedst_613',['NoteIsConnectedST',['../note_8h.html#aa1cce9855703b1b8a5cc856a84378c45',1,'note.h']]], + ['noteisdebugoutputactive_614',['noteIsDebugOutputActive',['../n__hooks_8c.html#a0d80498206dfae3b9a056b85b88695e9',1,'n_hooks.c']]], + ['notejsontransaction_615',['noteJSONTransaction',['../n__hooks_8c.html#adfb344b8d5cae2be70bd5a06a161e561',1,'n_hooks.c']]], + ['notelocaltimest_616',['NoteLocalTimeST',['../note_8h.html#a57534ae715e262dd91a55bd71de37631',1,'note.h']]], + ['notelocationvalid_617',['NoteLocationValid',['../note_8h.html#a544f2aeaa9bbd229ab173f8e9ba42dc5',1,'note.h']]], + ['notelocationvalidst_618',['NoteLocationValidST',['../note_8h.html#aa1fd37b1100f616b178fc6c0bcd18292',1,'note.h']]], + ['notelocki2c_619',['NoteLockI2C',['../n__hooks_8c.html#a195386217d2b20709846d45780af2013',1,'NoteLockI2C(void): n_hooks.c'],['../note_8h.html#a195386217d2b20709846d45780af2013',1,'NoteLockI2C(void): n_hooks.c']]], + ['notelocknote_620',['noteLockNote',['../n__hooks_8c.html#a91724ed7e398e2ad2954fc7496414ebe',1,'n_hooks.c']]], + ['notemalloc_621',['NoteMalloc',['../n__hooks_8c.html#a97d5a9da7d7d35519c54e90c8bcd9b20',1,'NoteMalloc(size_t size): n_hooks.c'],['../note_8h.html#a97d5a9da7d7d35519c54e90c8bcd9b20',1,'NoteMalloc(size_t size): n_hooks.c']]], + ['notemd5final_622',['NoteMD5Final',['../note_8h.html#ad1aef239c14e207376fff97a9269b569',1,'note.h']]], + ['notemd5hash_623',['NoteMD5Hash',['../note_8h.html#a789bebabb0a08fe02ccea85aa917488d',1,'note.h']]], + ['notemd5hashstring_624',['NoteMD5HashString',['../note_8h.html#a54de4da750412f3f2192e1ff453810ab',1,'note.h']]], + ['notemd5hashtostring_625',['NoteMD5HashToString',['../note_8h.html#a095d52cf0bc437922a8104cb97445d29',1,'note.h']]], + ['notemd5init_626',['NoteMD5Init',['../note_8h.html#af22f3a3c0071c07b3765df7907301c9f',1,'note.h']]], + ['notemd5transform_627',['NoteMD5Transform',['../note_8h.html#a7a52d858400f4634e7be440a5753967e',1,'note.h']]], + ['notemd5update_628',['NoteMD5Update',['../note_8h.html#ae70580a3b6b7d93590e84a46b4035fa9',1,'note.h']]], + ['notememavailable_629',['NoteMemAvailable',['../note_8h.html#ae7537bf172173234ecb77a6e0af513f8',1,'note.h']]], + ['notenewcommand_630',['NoteNewCommand',['../n__request_8c.html#a48877576f8d94864dedbe663ba68c3f0',1,'NoteNewCommand(const char *request): n_request.c'],['../note_8h.html#a48877576f8d94864dedbe663ba68c3f0',1,'NoteNewCommand(const char *request): n_request.c']]], + ['notenewrequest_631',['NoteNewRequest',['../n__request_8c.html#a2f5fce48cfd817f1bf940ab145f7cc59',1,'NoteNewRequest(const char *request): n_request.c'],['../note_8h.html#a2f5fce48cfd817f1bf940ab145f7cc59',1,'NoteNewRequest(const char *request): n_request.c']]], + ['notepayloadaddsegment_632',['NotePayloadAddSegment',['../note_8h.html#ad7c0fdd390eaf4338117bba38a92cdce',1,'note.h']]], + ['notepayloadfindsegment_633',['NotePayloadFindSegment',['../note_8h.html#a10bb7e445f9515a2289e9ed2dd4485d1',1,'note.h']]], + ['notepayloadfree_634',['NotePayloadFree',['../note_8h.html#a516e80912a7b5874770888765db7347e',1,'note.h']]], + ['notepayloadgetsegment_635',['NotePayloadGetSegment',['../note_8h.html#a573bc94dabf3f27220685a8c4d7adce9',1,'note.h']]], + ['notepayloadretrieveaftersleep_636',['NotePayloadRetrieveAfterSleep',['../note_8h.html#a62202e752d3e6b75d0beebbc0ebd29e9',1,'note.h']]], + ['notepayloadsaveandsleep_637',['NotePayloadSaveAndSleep',['../note_8h.html#a42f5f4c8090a088fbc0d6b68646e9c0e',1,'note.h']]], + ['notepayloadset_638',['NotePayloadSet',['../note_8h.html#ae8b19866d8b472354b80679fcd03d3bf',1,'note.h']]], + ['noteprint_639',['NotePrint',['../note_8h.html#a36d63199ff85bd480eafc6b547e7f9a0',1,'note.h']]], + ['noteprintf_640',['NotePrintf',['../note_8h.html#aca48731908e450c955c6dc1f6b3381a4',1,'note.h']]], + ['noteprintln_641',['NotePrintln',['../note_8h.html#a17c3fa0521904ce276913ce0bd666fd1',1,'note.h']]], + ['noteregion_642',['NoteRegion',['../note_8h.html#ade2325739300181a0fad13e83f377ac1',1,'note.h']]], + ['noterequest_643',['NoteRequest',['../n__request_8c.html#ab1227db7501f0b979ed894fb764790e3',1,'NoteRequest(J *req): n_request.c'],['../note_8h.html#ab1227db7501f0b979ed894fb764790e3',1,'NoteRequest(J *req): n_request.c']]], + ['noterequestresponse_644',['NoteRequestResponse',['../n__request_8c.html#ab163a75667bef7e74294125d40e15c12',1,'NoteRequestResponse(J *req): n_request.c'],['../note_8h.html#ab163a75667bef7e74294125d40e15c12',1,'NoteRequestResponse(J *req): n_request.c']]], + ['noterequestresponsejson_645',['NoteRequestResponseJSON',['../note_8h.html#a24fcc50f78212b5f7e08ed05b58c0ad1',1,'NoteRequestResponseJSON(const char *reqJSON): n_request.c'],['../n__request_8c.html#a24fcc50f78212b5f7e08ed05b58c0ad1',1,'NoteRequestResponseJSON(const char *reqJSON): n_request.c']]], + ['noterequestresponsewithretry_646',['NoteRequestResponseWithRetry',['../n__request_8c.html#a5d43b857b1bf72f312a2e7ba1825445b',1,'NoteRequestResponseWithRetry(J *req, uint32_t timeoutSeconds): n_request.c'],['../note_8h.html#a5d43b857b1bf72f312a2e7ba1825445b',1,'NoteRequestResponseWithRetry(J *req, uint32_t timeoutSeconds): n_request.c']]], + ['noterequestwithretry_647',['NoteRequestWithRetry',['../n__request_8c.html#a7eef6ff395f1e94934d3f9eb99bbcb9a',1,'NoteRequestWithRetry(J *req, uint32_t timeoutSeconds): n_request.c'],['../note_8h.html#a7eef6ff395f1e94934d3f9eb99bbcb9a',1,'NoteRequestWithRetry(J *req, uint32_t timeoutSeconds): n_request.c']]], + ['notereset_648',['NoteReset',['../n__request_8c.html#a6358096b5a9e5c69a4f56b12e80092fa',1,'NoteReset(void): n_request.c'],['../note_8h.html#a6358096b5a9e5c69a4f56b12e80092fa',1,'NoteReset(void): n_request.c']]], + ['noteresetrequired_649',['NoteResetRequired',['../n__request_8c.html#a6c62afa66443f9dbb0a36bf9f76e9896',1,'NoteResetRequired(void): n_request.c'],['../note_8h.html#a6c62afa66443f9dbb0a36bf9f76e9896',1,'NoteResetRequired(void): n_request.c']]], + ['noteresumetransactiondebug_650',['NoteResumeTransactionDebug',['../note_8h.html#a27085ec262c1b7e69d4f8998e2a5219c',1,'NoteResumeTransactionDebug(void): n_request.c'],['../n__request_8c.html#a27085ec262c1b7e69d4f8998e2a5219c',1,'NoteResumeTransactionDebug(void): n_request.c']]], + ['notesendtoroute_651',['NoteSendToRoute',['../note_8h.html#a740e04f22326f5f421bf3c86d5fd1ed3',1,'note.h']]], + ['noteserialavailable_652',['noteSerialAvailable',['../n__hooks_8c.html#a4dd1aa50682d8adfcb29900f3af0df7e',1,'n_hooks.c']]], + ['noteserialreceive_653',['noteSerialReceive',['../n__hooks_8c.html#a16710dbd211bf722a2538ca069c1bc39',1,'n_hooks.c']]], + ['noteserialreset_654',['noteSerialReset',['../n__hooks_8c.html#a5648adfefdf583e2cec1807b44544396',1,'n_hooks.c']]], + ['noteserialtransmit_655',['noteSerialTransmit',['../n__hooks_8c.html#a7f13dc9ce8037d8e1728c278fa31f789',1,'n_hooks.c']]], + ['notesetcontact_656',['NoteSetContact',['../note_8h.html#aad1a6d6d04a1cac3339022d1068df201',1,'note.h']]], + ['notesetenvdefault_657',['NoteSetEnvDefault',['../note_8h.html#af7edd00b0a1764be80585ca6b99e8045',1,'note.h']]], + ['notesetenvdefaultint_658',['NoteSetEnvDefaultInt',['../note_8h.html#a3b959828f2723e37f1aa15818122a49c',1,'note.h']]], + ['notesetenvdefaultnumber_659',['NoteSetEnvDefaultNumber',['../note_8h.html#a43932b5cf2ba57357efd5de109c288d3',1,'note.h']]], + ['notesetfn_660',['NoteSetFn',['../n__hooks_8c.html#ad334248744d5387da78ca09c3498f397',1,'NoteSetFn(mallocFn mallocHook, freeFn freeHook, delayMsFn delayMsHook, getMsFn getMsHook): n_hooks.c'],['../note_8h.html#ad334248744d5387da78ca09c3498f397',1,'NoteSetFn(mallocFn mallocHook, freeFn freeHook, delayMsFn delayMsHook, getMsFn getMsHook): n_hooks.c']]], + ['notesetfndebugoutput_661',['NoteSetFnDebugOutput',['../n__hooks_8c.html#a6844f5cd4d6e38d65c090dba954321b4',1,'NoteSetFnDebugOutput(debugOutputFn fn): n_hooks.c'],['../note_8h.html#a6844f5cd4d6e38d65c090dba954321b4',1,'NoteSetFnDebugOutput(debugOutputFn fn): n_hooks.c']]], + ['notesetfndefault_662',['NoteSetFnDefault',['../n__hooks_8c.html#a57a711029fed4148da73679ff2c8a154',1,'NoteSetFnDefault(mallocFn mallocfn, freeFn freefn, delayMsFn delayfn, getMsFn millisfn): n_hooks.c'],['../note_8h.html#a57a711029fed4148da73679ff2c8a154',1,'NoteSetFnDefault(mallocFn mallocfn, freeFn freefn, delayMsFn delayfn, getMsFn millisfn): n_hooks.c']]], + ['notesetfndisabled_663',['NoteSetFnDisabled',['../n__hooks_8c.html#a8648db242df0d5ac68334ab93ee5fa0e',1,'NoteSetFnDisabled(void): n_hooks.c'],['../note_8h.html#a8648db242df0d5ac68334ab93ee5fa0e',1,'NoteSetFnDisabled(void): n_hooks.c']]], + ['notesetfni2c_664',['NoteSetFnI2C',['../n__hooks_8c.html#abeb555883ff039880048164763c3b9f0',1,'NoteSetFnI2C(uint32_t notecardAddr, uint32_t maxTransmitSize, i2cResetFn resetFn, i2cTransmitFn transmitFn, i2cReceiveFn receiveFn): n_hooks.c'],['../note_8h.html#abeb555883ff039880048164763c3b9f0',1,'NoteSetFnI2C(uint32_t notecardAddr, uint32_t maxTransmitSize, i2cResetFn resetFn, i2cTransmitFn transmitFn, i2cReceiveFn receiveFn): n_hooks.c']]], + ['notesetfni2cmutex_665',['NoteSetFnI2CMutex',['../n__hooks_8c.html#a6879f42e34e075aec82b499fd5ddd12a',1,'NoteSetFnI2CMutex(mutexFn lockI2Cfn, mutexFn unlockI2Cfn): n_hooks.c'],['../note_8h.html#a6879f42e34e075aec82b499fd5ddd12a',1,'NoteSetFnI2CMutex(mutexFn lockI2Cfn, mutexFn unlockI2Cfn): n_hooks.c']]], + ['notesetfnmutex_666',['NoteSetFnMutex',['../n__hooks_8c.html#a81210c0d43535f1945083f7b3fcad67a',1,'NoteSetFnMutex(mutexFn lockI2Cfn, mutexFn unlockI2Cfn, mutexFn lockNotefn, mutexFn unlockNotefn): n_hooks.c'],['../note_8h.html#a81210c0d43535f1945083f7b3fcad67a',1,'NoteSetFnMutex(mutexFn lockI2Cfn, mutexFn unlockI2Cfn, mutexFn lockNotefn, mutexFn unlockNotefn): n_hooks.c']]], + ['notesetfnnotemutex_667',['NoteSetFnNoteMutex',['../n__hooks_8c.html#a534aa37f7e753dd06a847f429f8e743f',1,'NoteSetFnNoteMutex(mutexFn lockFn, mutexFn unlockFn): n_hooks.c'],['../note_8h.html#a534aa37f7e753dd06a847f429f8e743f',1,'NoteSetFnNoteMutex(mutexFn lockFn, mutexFn unlockFn): n_hooks.c']]], + ['notesetfnserial_668',['NoteSetFnSerial',['../n__hooks_8c.html#a85c66fdcef6d9ea044a9adc37af5afa7',1,'NoteSetFnSerial(serialResetFn resetFn, serialTransmitFn transmitFn, serialAvailableFn availFn, serialReceiveFn receiveFn): n_hooks.c'],['../note_8h.html#a85c66fdcef6d9ea044a9adc37af5afa7',1,'NoteSetFnSerial(serialResetFn resetFn, serialTransmitFn transmitFn, serialAvailableFn availFn, serialReceiveFn receiveFn): n_hooks.c']]], + ['notesetfntransaction_669',['NoteSetFnTransaction',['../n__hooks_8c.html#a946facc30c7f3b5f1820db01fde9fa4d',1,'NoteSetFnTransaction(txnStartFn startFn, txnStopFn stopFn): n_hooks.c'],['../note_8h.html#a946facc30c7f3b5f1820db01fde9fa4d',1,'NoteSetFnTransaction(txnStartFn startFn, txnStopFn stopFn): n_hooks.c']]], + ['noteseti2caddress_670',['NoteSetI2CAddress',['../n__hooks_8c.html#a58d7607711312253b402749133e2933a',1,'NoteSetI2CAddress(uint32_t i2caddress): n_hooks.c'],['../note_8h.html#a58d7607711312253b402749133e2933a',1,'NoteSetI2CAddress(uint32_t i2caddress): n_hooks.c']]], + ['notesetlocation_671',['NoteSetLocation',['../note_8h.html#a54f0c0ac25d91cdff09d4c374f4b9393',1,'note.h']]], + ['notesetlocationmode_672',['NoteSetLocationMode',['../note_8h.html#a38ab54badbef76dd436d557889eaaf83',1,'note.h']]], + ['notesetproductid_673',['NoteSetProductID',['../note_8h.html#a68e1b388237b6d156f07299c8fdea24b',1,'note.h']]], + ['notesetserialnumber_674',['NoteSetSerialNumber',['../note_8h.html#ac4e9ce3c9b56c05603c3a87377abfdda',1,'note.h']]], + ['notesetstsecs_675',['NoteSetSTSecs',['../note_8h.html#a2e8d519c15479dfaf09566ed97ec3711',1,'note.h']]], + ['notesetsyncmode_676',['NoteSetSyncMode',['../note_8h.html#a65b9120ff5b755405d76a3ba992197ac',1,'note.h']]], + ['notesetuploadmode_677',['NoteSetUploadMode',['../note_8h.html#aedfe8eec797fa14b80c9a836a3267a69',1,'note.h']]], + ['notesetuseragent_678',['NoteSetUserAgent',['../note_8h.html#a35ebbb9e71fc6822ec7848df598b1b6f',1,'note.h']]], + ['notesetuseragentcpu_679',['NoteSetUserAgentCPU',['../note_8h.html#a06db056eec95b5d3bce80a00d87720d1',1,'note.h']]], + ['notesetuseragentos_680',['NoteSetUserAgentOS',['../note_8h.html#a6586f487873db10a6cca9f4f2812f2e1',1,'note.h']]], + ['notesleep_681',['NoteSleep',['../note_8h.html#a5495b9b5807536807987af253ee2b918',1,'note.h']]], + ['notesuspendtransactiondebug_682',['NoteSuspendTransactionDebug',['../note_8h.html#ab0427f0cd3e286d8020309ea88687d09',1,'NoteSuspendTransactionDebug(void): n_request.c'],['../n__request_8c.html#ab0427f0cd3e286d8020309ea88687d09',1,'NoteSuspendTransactionDebug(void): n_request.c']]], + ['notetemplate_683',['NoteTemplate',['../note_8h.html#a5de0a3a1b648b9d5c2d0a7c608264f6a',1,'note.h']]], + ['notetime_684',['NoteTime',['../note_8h.html#a0d930f1361f45030bc3638197b329bcb',1,'note.h']]], + ['notetimerefreshmins_685',['NoteTimeRefreshMins',['../note_8h.html#af5568df79a7d26a8807b54853a56b921',1,'note.h']]], + ['notetimeset_686',['NoteTimeSet',['../note_8h.html#a09596cfe3e377e92f4ebf6700e3ac990',1,'note.h']]], + ['notetimest_687',['NoteTimeST',['../note_8h.html#a1f834110044f5d4586ad98bde88084d6',1,'note.h']]], + ['notetimevalid_688',['NoteTimeValid',['../note_8h.html#afc76a1b0c6b4dfa1ab2e7c3d6286583e',1,'note.h']]], + ['notetimevalidst_689',['NoteTimeValidST',['../note_8h.html#abf11915def4e2d9b1e54cb63d13e95e2',1,'note.h']]], + ['notetransaction_690',['NoteTransaction',['../note_8h.html#a8b5e380054a80026a80c531a734f025c',1,'NoteTransaction(J *req): n_request.c'],['../n__request_8c.html#a8b5e380054a80026a80c531a734f025c',1,'NoteTransaction(J *req): n_request.c']]], + ['notetransactionshouldlock_691',['noteTransactionShouldLock',['../n__request_8c.html#ad807b7de69820e7c5f308f8caba96562',1,'n_request.c']]], + ['notetransactionstart_692',['noteTransactionStart',['../n__hooks_8c.html#a31026968acce3c29d9bed1a16606955c',1,'n_hooks.c']]], + ['notetransactionstop_693',['noteTransactionStop',['../n__hooks_8c.html#a710038819ac8776ba26c05b912380182',1,'n_hooks.c']]], + ['noteturboio_694',['NoteTurboIO',['../note_8h.html#a3188b2609ac87faadfb0ec5cb9b158bf',1,'note.h']]], + ['noteunlocki2c_695',['NoteUnlockI2C',['../n__hooks_8c.html#a2a4589fef84a01f2a1bee1c5a7053fc6',1,'NoteUnlockI2C(void): n_hooks.c'],['../note_8h.html#a2a4589fef84a01f2a1bee1c5a7053fc6',1,'NoteUnlockI2C(void): n_hooks.c']]], + ['noteunlocknote_696',['noteUnlockNote',['../n__hooks_8c.html#aeaef70aca07305e46c41c6091afae506',1,'n_hooks.c']]], + ['noteuseragent_697',['NoteUserAgent',['../note_8h.html#a7df3b564875a8975cf524851a4f83ff9',1,'note.h']]], + ['noteuseragentupdate_698',['NoteUserAgentUpdate',['../note_8h.html#ad09beb502758c3c20ea01d0b5940a751',1,'note.h']]], + ['notewake_699',['NoteWake',['../note_8h.html#ab6689989662882c9140822e67d0ae84d',1,'note.h']]] +]; diff --git a/doxygen/html/search/functions_2.html b/doxygen/html/search/functions_2.html new file mode 100644 index 00000000..ca5aa10e --- /dev/null +++ b/doxygen/html/search/functions_2.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/functions_2.js b/doxygen/html/search/functions_2.js new file mode 100644 index 00000000..db20a80b --- /dev/null +++ b/doxygen/html/search/functions_2.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['strlcat_700',['strlcat',['../note_8h.html#ae85b825a7f3d4dcf136b85949b646a46',1,'note.h']]], + ['strlcpy_701',['strlcpy',['../note_8h.html#aeb79f86261de904967d433c1b5e9a1de',1,'note.h']]] +]; diff --git a/doxygen/html/search/mag_sel.svg b/doxygen/html/search/mag_sel.svg new file mode 100644 index 00000000..03626f64 --- /dev/null +++ b/doxygen/html/search/mag_sel.svg @@ -0,0 +1,74 @@ + + + + + + + + image/svg+xml + + + + + + + + + + + diff --git a/doxygen/html/search/nomatches.html b/doxygen/html/search/nomatches.html new file mode 100644 index 00000000..2b9360b6 --- /dev/null +++ b/doxygen/html/search/nomatches.html @@ -0,0 +1,13 @@ + + + + + + + + +
    +
    No Matches
    +
    + + diff --git a/doxygen/html/search/search.css b/doxygen/html/search/search.css new file mode 100644 index 00000000..9074198f --- /dev/null +++ b/doxygen/html/search/search.css @@ -0,0 +1,257 @@ +/*---------------- Search Box */ + +#MSearchBox { + white-space : nowrap; + background: white; + border-radius: 0.65em; + box-shadow: inset 0.5px 0.5px 3px 0px #555; + z-index: 102; +} + +#MSearchBox .left { + display: inline-block; + vertical-align: middle; + height: 1.4em; +} + +#MSearchSelect { + display: inline-block; + vertical-align: middle; + height: 1.4em; + padding: 0 0 0 0.3em; + margin: 0; +} + +#MSearchField { + display: inline-block; + vertical-align: middle; + width: 7.5em; + height: 1.1em; + margin: 0 0.15em; + padding: 0; + line-height: 1em; + border:none; + color: #909090; + outline: none; + font-family: Arial, Verdana, sans-serif; + -webkit-border-radius: 0px; + border-radius: 0px; + background: none; +} + + +#MSearchBox .right { + display: inline-block; + vertical-align: middle; + width: 1.4em; + height: 1.4em; +} + +#MSearchClose { + display: none; + font-size: inherit; + background : none; + border: none; + margin: 0; + padding: 0; + outline: none; + +} + +#MSearchCloseImg { + height: 1.4em; + padding: 0.3em; + margin: 0; +} + +.MSearchBoxActive #MSearchField { + color: #000000; +} + +#main-menu > li:last-child { + /* This
  • object is the parent of the search bar */ + display: flex; + justify-content: center; + align-items: center; + height: 36px; + margin-right: 1em; +} + +/*---------------- Search filter selection */ + +#MSearchSelectWindow { + display: none; + position: absolute; + left: 0; top: 0; + border: 1px solid #90A5CE; + background-color: #F9FAFC; + z-index: 10001; + padding-top: 4px; + padding-bottom: 4px; + -moz-border-radius: 4px; + -webkit-border-top-left-radius: 4px; + -webkit-border-top-right-radius: 4px; + -webkit-border-bottom-left-radius: 4px; + -webkit-border-bottom-right-radius: 4px; + -webkit-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); +} + +.SelectItem { + font: 8pt Arial, Verdana, sans-serif; + padding-left: 2px; + padding-right: 12px; + border: 0px; +} + +span.SelectionMark { + margin-right: 4px; + font-family: monospace; + outline-style: none; + text-decoration: none; +} + +a.SelectItem { + display: block; + outline-style: none; + color: #000000; + text-decoration: none; + padding-left: 6px; + padding-right: 12px; +} + +a.SelectItem:focus, +a.SelectItem:active { + color: #000000; + outline-style: none; + text-decoration: none; +} + +a.SelectItem:hover { + color: #FFFFFF; + background-color: #3D578C; + outline-style: none; + text-decoration: none; + cursor: pointer; + display: block; +} + +/*---------------- Search results window */ + +iframe#MSearchResults { + width: 60ex; + height: 15em; +} + +#MSearchResultsWindow { + display: none; + position: absolute; + left: 0; top: 0; + border: 1px solid #000; + background-color: #EEF1F7; + z-index:10000; +} + +/* ----------------------------------- */ + + +#SRIndex { + clear:both; + padding-bottom: 15px; +} + +.SREntry { + font-size: 10pt; + padding-left: 1ex; +} + +.SRPage .SREntry { + font-size: 8pt; + padding: 1px 5px; +} + +body.SRPage { + margin: 5px 2px; +} + +.SRChildren { + padding-left: 3ex; padding-bottom: .5em +} + +.SRPage .SRChildren { + display: none; +} + +.SRSymbol { + font-weight: bold; + color: #425E97; + font-family: Arial, Verdana, sans-serif; + text-decoration: none; + outline: none; +} + +a.SRScope { + display: block; + color: #425E97; + font-family: Arial, Verdana, sans-serif; + text-decoration: none; + outline: none; +} + +a.SRSymbol:focus, a.SRSymbol:active, +a.SRScope:focus, a.SRScope:active { + text-decoration: underline; +} + +span.SRScope { + padding-left: 4px; + font-family: Arial, Verdana, sans-serif; +} + +.SRPage .SRStatus { + padding: 2px 5px; + font-size: 8pt; + font-style: italic; + font-family: Arial, Verdana, sans-serif; +} + +.SRResult { + display: none; +} + +div.searchresults { + margin-left: 10px; + margin-right: 10px; +} + +/*---------------- External search page results */ + +.searchresult { + background-color: #F0F3F8; +} + +.pages b { + color: white; + padding: 5px 5px 3px 5px; + background-image: url("../tab_a.png"); + background-repeat: repeat-x; + text-shadow: 0 1px 1px #000000; +} + +.pages { + line-height: 17px; + margin-left: 4px; + text-decoration: none; +} + +.hl { + font-weight: bold; +} + +#searchresults { + margin-bottom: 20px; +} + +.searchpages { + margin-top: 10px; +} + diff --git a/doxygen/html/search/search.js b/doxygen/html/search/search.js new file mode 100644 index 00000000..fb226f73 --- /dev/null +++ b/doxygen/html/search/search.js @@ -0,0 +1,816 @@ +/* + @licstart The following is the entire license notice for the JavaScript code in this file. + + The MIT License (MIT) + + Copyright (C) 1997-2020 by Dimitri van Heesch + + 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. + + @licend The above is the entire license notice for the JavaScript code in this file + */ +function convertToId(search) +{ + var result = ''; + for (i=0;i do a search + { + this.Search(); + } + } + + this.OnSearchSelectKey = function(evt) + { + var e = (evt) ? evt : window.event; // for IE + if (e.keyCode==40 && this.searchIndex0) // Up + { + this.searchIndex--; + this.OnSelectItem(this.searchIndex); + } + else if (e.keyCode==13 || e.keyCode==27) + { + this.OnSelectItem(this.searchIndex); + this.CloseSelectionWindow(); + this.DOMSearchField().focus(); + } + return false; + } + + // --------- Actions + + // Closes the results window. + this.CloseResultsWindow = function() + { + this.DOMPopupSearchResultsWindow().style.display = 'none'; + this.DOMSearchClose().style.display = 'none'; + this.Activate(false); + } + + this.CloseSelectionWindow = function() + { + this.DOMSearchSelectWindow().style.display = 'none'; + } + + // Performs a search. + this.Search = function() + { + this.keyTimeout = 0; + + // strip leading whitespace + var searchValue = this.DOMSearchField().value.replace(/^ +/, ""); + + var code = searchValue.toLowerCase().charCodeAt(0); + var idxChar = searchValue.substr(0, 1).toLowerCase(); + if ( 0xD800 <= code && code <= 0xDBFF && searchValue > 1) // surrogate pair + { + idxChar = searchValue.substr(0, 2); + } + + var resultsPage; + var resultsPageWithSearch; + var hasResultsPage; + + var idx = indexSectionsWithContent[this.searchIndex].indexOf(idxChar); + if (idx!=-1) + { + var hexCode=idx.toString(16); + resultsPage = this.resultsPath + '/' + indexSectionNames[this.searchIndex] + '_' + hexCode + this.extension; + resultsPageWithSearch = resultsPage+'?'+escape(searchValue); + hasResultsPage = true; + } + else // nothing available for this search term + { + resultsPage = this.resultsPath + '/nomatches' + this.extension; + resultsPageWithSearch = resultsPage; + hasResultsPage = false; + } + + window.frames.MSearchResults.location = resultsPageWithSearch; + var domPopupSearchResultsWindow = this.DOMPopupSearchResultsWindow(); + + if (domPopupSearchResultsWindow.style.display!='block') + { + var domSearchBox = this.DOMSearchBox(); + this.DOMSearchClose().style.display = 'inline-block'; + if (this.insideFrame) + { + var domPopupSearchResults = this.DOMPopupSearchResults(); + domPopupSearchResultsWindow.style.position = 'relative'; + domPopupSearchResultsWindow.style.display = 'block'; + var width = document.body.clientWidth - 8; // the -8 is for IE :-( + domPopupSearchResultsWindow.style.width = width + 'px'; + domPopupSearchResults.style.width = width + 'px'; + } + else + { + var domPopupSearchResults = this.DOMPopupSearchResults(); + var left = getXPos(domSearchBox) + 150; // domSearchBox.offsetWidth; + var top = getYPos(domSearchBox) + 20; // domSearchBox.offsetHeight + 1; + domPopupSearchResultsWindow.style.display = 'block'; + left -= domPopupSearchResults.offsetWidth; + domPopupSearchResultsWindow.style.top = top + 'px'; + domPopupSearchResultsWindow.style.left = left + 'px'; + } + } + + this.lastSearchValue = searchValue; + this.lastResultsPage = resultsPage; + } + + // -------- Activation Functions + + // Activates or deactivates the search panel, resetting things to + // their default values if necessary. + this.Activate = function(isActive) + { + if (isActive || // open it + this.DOMPopupSearchResultsWindow().style.display == 'block' + ) + { + this.DOMSearchBox().className = 'MSearchBoxActive'; + + var searchField = this.DOMSearchField(); + + if (searchField.value == this.searchLabel) // clear "Search" term upon entry + { + searchField.value = ''; + this.searchActive = true; + } + } + else if (!isActive) // directly remove the panel + { + this.DOMSearchBox().className = 'MSearchBoxInactive'; + this.DOMSearchField().value = this.searchLabel; + this.searchActive = false; + this.lastSearchValue = '' + this.lastResultsPage = ''; + } + } +} + +// ----------------------------------------------------------------------- + +// The class that handles everything on the search results page. +function SearchResults(name) +{ + // The number of matches from the last run of . + this.lastMatchCount = 0; + this.lastKey = 0; + this.repeatOn = false; + + // Toggles the visibility of the passed element ID. + this.FindChildElement = function(id) + { + var parentElement = document.getElementById(id); + var element = parentElement.firstChild; + + while (element && element!=parentElement) + { + if (element.nodeName.toLowerCase() == 'div' && element.className == 'SRChildren') + { + return element; + } + + if (element.nodeName.toLowerCase() == 'div' && element.hasChildNodes()) + { + element = element.firstChild; + } + else if (element.nextSibling) + { + element = element.nextSibling; + } + else + { + do + { + element = element.parentNode; + } + while (element && element!=parentElement && !element.nextSibling); + + if (element && element!=parentElement) + { + element = element.nextSibling; + } + } + } + } + + this.Toggle = function(id) + { + var element = this.FindChildElement(id); + if (element) + { + if (element.style.display == 'block') + { + element.style.display = 'none'; + } + else + { + element.style.display = 'block'; + } + } + } + + // Searches for the passed string. If there is no parameter, + // it takes it from the URL query. + // + // Always returns true, since other documents may try to call it + // and that may or may not be possible. + this.Search = function(search) + { + if (!search) // get search word from URL + { + search = window.location.search; + search = search.substring(1); // Remove the leading '?' + search = unescape(search); + } + + search = search.replace(/^ +/, ""); // strip leading spaces + search = search.replace(/ +$/, ""); // strip trailing spaces + search = search.toLowerCase(); + search = convertToId(search); + + var resultRows = document.getElementsByTagName("div"); + var matches = 0; + + var i = 0; + while (i < resultRows.length) + { + var row = resultRows.item(i); + if (row.className == "SRResult") + { + var rowMatchName = row.id.toLowerCase(); + rowMatchName = rowMatchName.replace(/^sr\d*_/, ''); // strip 'sr123_' + + if (search.length<=rowMatchName.length && + rowMatchName.substr(0, search.length)==search) + { + row.style.display = 'block'; + matches++; + } + else + { + row.style.display = 'none'; + } + } + i++; + } + document.getElementById("Searching").style.display='none'; + if (matches == 0) // no results + { + document.getElementById("NoMatches").style.display='block'; + } + else // at least one result + { + document.getElementById("NoMatches").style.display='none'; + } + this.lastMatchCount = matches; + return true; + } + + // return the first item with index index or higher that is visible + this.NavNext = function(index) + { + var focusItem; + while (1) + { + var focusName = 'Item'+index; + focusItem = document.getElementById(focusName); + if (focusItem && focusItem.parentNode.parentNode.style.display=='block') + { + break; + } + else if (!focusItem) // last element + { + break; + } + focusItem=null; + index++; + } + return focusItem; + } + + this.NavPrev = function(index) + { + var focusItem; + while (1) + { + var focusName = 'Item'+index; + focusItem = document.getElementById(focusName); + if (focusItem && focusItem.parentNode.parentNode.style.display=='block') + { + break; + } + else if (!focusItem) // last element + { + break; + } + focusItem=null; + index--; + } + return focusItem; + } + + this.ProcessKeys = function(e) + { + if (e.type == "keydown") + { + this.repeatOn = false; + this.lastKey = e.keyCode; + } + else if (e.type == "keypress") + { + if (!this.repeatOn) + { + if (this.lastKey) this.repeatOn = true; + return false; // ignore first keypress after keydown + } + } + else if (e.type == "keyup") + { + this.lastKey = 0; + this.repeatOn = false; + } + return this.lastKey!=0; + } + + this.Nav = function(evt,itemIndex) + { + var e = (evt) ? evt : window.event; // for IE + if (e.keyCode==13) return true; + if (!this.ProcessKeys(e)) return false; + + if (this.lastKey==38) // Up + { + var newIndex = itemIndex-1; + var focusItem = this.NavPrev(newIndex); + if (focusItem) + { + var child = this.FindChildElement(focusItem.parentNode.parentNode.id); + if (child && child.style.display == 'block') // children visible + { + var n=0; + var tmpElem; + while (1) // search for last child + { + tmpElem = document.getElementById('Item'+newIndex+'_c'+n); + if (tmpElem) + { + focusItem = tmpElem; + } + else // found it! + { + break; + } + n++; + } + } + } + if (focusItem) + { + focusItem.focus(); + } + else // return focus to search field + { + parent.document.getElementById("MSearchField").focus(); + } + } + else if (this.lastKey==40) // Down + { + var newIndex = itemIndex+1; + var focusItem; + var item = document.getElementById('Item'+itemIndex); + var elem = this.FindChildElement(item.parentNode.parentNode.id); + if (elem && elem.style.display == 'block') // children visible + { + focusItem = document.getElementById('Item'+itemIndex+'_c0'); + } + if (!focusItem) focusItem = this.NavNext(newIndex); + if (focusItem) focusItem.focus(); + } + else if (this.lastKey==39) // Right + { + var item = document.getElementById('Item'+itemIndex); + var elem = this.FindChildElement(item.parentNode.parentNode.id); + if (elem) elem.style.display = 'block'; + } + else if (this.lastKey==37) // Left + { + var item = document.getElementById('Item'+itemIndex); + var elem = this.FindChildElement(item.parentNode.parentNode.id); + if (elem) elem.style.display = 'none'; + } + else if (this.lastKey==27) // Escape + { + parent.searchBox.CloseResultsWindow(); + parent.document.getElementById("MSearchField").focus(); + } + else if (this.lastKey==13) // Enter + { + return true; + } + return false; + } + + this.NavChild = function(evt,itemIndex,childIndex) + { + var e = (evt) ? evt : window.event; // for IE + if (e.keyCode==13) return true; + if (!this.ProcessKeys(e)) return false; + + if (this.lastKey==38) // Up + { + if (childIndex>0) + { + var newIndex = childIndex-1; + document.getElementById('Item'+itemIndex+'_c'+newIndex).focus(); + } + else // already at first child, jump to parent + { + document.getElementById('Item'+itemIndex).focus(); + } + } + else if (this.lastKey==40) // Down + { + var newIndex = childIndex+1; + var elem = document.getElementById('Item'+itemIndex+'_c'+newIndex); + if (!elem) // last child, jump to parent next parent + { + elem = this.NavNext(itemIndex+1); + } + if (elem) + { + elem.focus(); + } + } + else if (this.lastKey==27) // Escape + { + parent.searchBox.CloseResultsWindow(); + parent.document.getElementById("MSearchField").focus(); + } + else if (this.lastKey==13) // Enter + { + return true; + } + return false; + } +} + +function setKeyActions(elem,action) +{ + elem.setAttribute('onkeydown',action); + elem.setAttribute('onkeypress',action); + elem.setAttribute('onkeyup',action); +} + +function setClassAttr(elem,attr) +{ + elem.setAttribute('class',attr); + elem.setAttribute('className',attr); +} + +function createResults() +{ + var results = document.getElementById("SRResults"); + for (var e=0; e + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/typedefs_0.js b/doxygen/html/search/typedefs_0.js new file mode 100644 index 00000000..25bf7f52 --- /dev/null +++ b/doxygen/html/search/typedefs_0.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['debugoutputfn_748',['debugOutputFn',['../note_8h.html#a233e9fec868082bb68e23c6e73af67a2',1,'note.h']]], + ['delaymsfn_749',['delayMsFn',['../note_8h.html#a323baf90f21427329bfb7ef9a61c83d7',1,'note.h']]] +]; diff --git a/doxygen/html/search/typedefs_1.html b/doxygen/html/search/typedefs_1.html new file mode 100644 index 00000000..46cf01e6 --- /dev/null +++ b/doxygen/html/search/typedefs_1.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/typedefs_1.js b/doxygen/html/search/typedefs_1.js new file mode 100644 index 00000000..99f53079 --- /dev/null +++ b/doxygen/html/search/typedefs_1.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['freefn_750',['freeFn',['../note_8h.html#a570f0444ac7f08f8d66bd12cf49b662c',1,'note.h']]] +]; diff --git a/doxygen/html/search/typedefs_2.html b/doxygen/html/search/typedefs_2.html new file mode 100644 index 00000000..6835ee65 --- /dev/null +++ b/doxygen/html/search/typedefs_2.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/typedefs_2.js b/doxygen/html/search/typedefs_2.js new file mode 100644 index 00000000..04da0a7f --- /dev/null +++ b/doxygen/html/search/typedefs_2.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['getmsfn_751',['getMsFn',['../note_8h.html#a4717d9986b1e1b5db55590abd6fc9910',1,'note.h']]] +]; diff --git a/doxygen/html/search/typedefs_3.html b/doxygen/html/search/typedefs_3.html new file mode 100644 index 00000000..01700476 --- /dev/null +++ b/doxygen/html/search/typedefs_3.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/typedefs_3.js b/doxygen/html/search/typedefs_3.js new file mode 100644 index 00000000..68a626f1 --- /dev/null +++ b/doxygen/html/search/typedefs_3.js @@ -0,0 +1,6 @@ +var searchData= +[ + ['i2creceivefn_752',['i2cReceiveFn',['../note_8h.html#aef5eac1396470d4d872d979aaf95cbb2',1,'note.h']]], + ['i2cresetfn_753',['i2cResetFn',['../note_8h.html#ab18cc9957da000e5a05db53d4543d26b',1,'note.h']]], + ['i2ctransmitfn_754',['i2cTransmitFn',['../note_8h.html#a841b338ac017194680b08ec57c179efc',1,'note.h']]] +]; diff --git a/doxygen/html/search/typedefs_4.html b/doxygen/html/search/typedefs_4.html new file mode 100644 index 00000000..81466a5d --- /dev/null +++ b/doxygen/html/search/typedefs_4.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/typedefs_4.js b/doxygen/html/search/typedefs_4.js new file mode 100644 index 00000000..be8340b3 --- /dev/null +++ b/doxygen/html/search/typedefs_4.js @@ -0,0 +1,10 @@ +var searchData= +[ + ['j_755',['J',['../n__cjson_8h.html#a08f69cc109c0024a645dafe4b3cbdeb3',1,'n_cjson.h']]], + ['jbool_756',['Jbool',['../n__cjson_8h.html#abcfad9bdd54f2729b7e1c3891289f8dd',1,'n_cjson.h']]], + ['jhooks_757',['JHooks',['../n__cjson_8h.html#ad0397f28634dba79785c2a66c076bb08',1,'n_cjson.h']]], + ['jinteger_758',['JINTEGER',['../note_8h.html#ab76f50f98a2aef9bf6ea1e6c7a2c8cbb',1,'note.h']]], + ['jnumber_759',['JNUMBER',['../note_8h.html#a9c9eb17c00d2f5af0a9fd4f3bc43bdc6',1,'note.h']]], + ['jtime_760',['JTIME',['../note_8h.html#aaa2abe42069f4e8774798f8e3e89264e',1,'note.h']]], + ['juinteger_761',['JUINTEGER',['../note_8h.html#aa40439c159fdacb5de8314453a6cc241',1,'note.h']]] +]; diff --git a/doxygen/html/search/typedefs_5.html b/doxygen/html/search/typedefs_5.html new file mode 100644 index 00000000..43fbec1f --- /dev/null +++ b/doxygen/html/search/typedefs_5.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/typedefs_5.js b/doxygen/html/search/typedefs_5.js new file mode 100644 index 00000000..84c6f2d5 --- /dev/null +++ b/doxygen/html/search/typedefs_5.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['mallocfn_762',['mallocFn',['../note_8h.html#af700faf8575fb2f45c3881786624b4d6',1,'note.h']]], + ['mutexfn_763',['mutexFn',['../note_8h.html#ac9d4324784f851631c22f78099225463',1,'note.h']]] +]; diff --git a/doxygen/html/search/typedefs_6.html b/doxygen/html/search/typedefs_6.html new file mode 100644 index 00000000..99479c2d --- /dev/null +++ b/doxygen/html/search/typedefs_6.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/typedefs_6.js b/doxygen/html/search/typedefs_6.js new file mode 100644 index 00000000..a9b7c016 --- /dev/null +++ b/doxygen/html/search/typedefs_6.js @@ -0,0 +1,7 @@ +var searchData= +[ + ['nnoteresetfn_764',['nNoteResetFn',['../n__hooks_8c.html#aea3d0ea7684640d1848d2914996faecd',1,'n_hooks.c']]], + ['nreceivefn_765',['nReceiveFn',['../n__hooks_8c.html#ab573aa22885384520bb3080189f246b3',1,'n_hooks.c']]], + ['ntransactionfn_766',['nTransactionFn',['../n__hooks_8c.html#a3af2856f787f9707f6f3cb25d2c28860',1,'n_hooks.c']]], + ['ntransmitfn_767',['nTransmitFn',['../n__hooks_8c.html#a4adc8af3e4ea403988d458615cf6f845',1,'n_hooks.c']]] +]; diff --git a/doxygen/html/search/typedefs_7.html b/doxygen/html/search/typedefs_7.html new file mode 100644 index 00000000..9a825e0a --- /dev/null +++ b/doxygen/html/search/typedefs_7.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/typedefs_7.js b/doxygen/html/search/typedefs_7.js new file mode 100644 index 00000000..3194f6f2 --- /dev/null +++ b/doxygen/html/search/typedefs_7.js @@ -0,0 +1,7 @@ +var searchData= +[ + ['serialavailablefn_768',['serialAvailableFn',['../note_8h.html#a58f8d48fe891877b7702a013e63e6991',1,'note.h']]], + ['serialreceivefn_769',['serialReceiveFn',['../note_8h.html#a9a014c2bc8e94f611f98415b3d6b9569',1,'note.h']]], + ['serialresetfn_770',['serialResetFn',['../note_8h.html#a75873a7790764116d88f80aaaf23263b',1,'note.h']]], + ['serialtransmitfn_771',['serialTransmitFn',['../note_8h.html#a02dd02c70f8ef01f9ded212d5630f5e0',1,'note.h']]] +]; diff --git a/doxygen/html/search/typedefs_8.html b/doxygen/html/search/typedefs_8.html new file mode 100644 index 00000000..e968613e --- /dev/null +++ b/doxygen/html/search/typedefs_8.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/typedefs_8.js b/doxygen/html/search/typedefs_8.js new file mode 100644 index 00000000..8ba16124 --- /dev/null +++ b/doxygen/html/search/typedefs_8.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['txnstartfn_772',['txnStartFn',['../note_8h.html#a294656e8c061b533f96003de5e4687fb',1,'note.h']]], + ['txnstopfn_773',['txnStopFn',['../note_8h.html#a5489831ee66f5f8c29021bfceaffb5ec',1,'note.h']]] +]; diff --git a/doxygen/html/search/variables_0.html b/doxygen/html/search/variables_0.html new file mode 100644 index 00000000..1e477c08 --- /dev/null +++ b/doxygen/html/search/variables_0.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/variables_0.js b/doxygen/html/search/variables_0.js new file mode 100644 index 00000000..51a85be0 --- /dev/null +++ b/doxygen/html/search/variables_0.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['alloc_702',['alloc',['../struct_note_payload_desc.html#afb8e03b00c614d92cde2695938cd8ef1',1,'NotePayloadDesc']]] +]; diff --git a/doxygen/html/search/variables_1.html b/doxygen/html/search/variables_1.html new file mode 100644 index 00000000..ea73d9a4 --- /dev/null +++ b/doxygen/html/search/variables_1.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/variables_1.js b/doxygen/html/search/variables_1.js new file mode 100644 index 00000000..3ad94440 --- /dev/null +++ b/doxygen/html/search/variables_1.js @@ -0,0 +1,6 @@ +var searchData= +[ + ['bits_703',['bits',['../struct_note_m_d5_context.html#a79dcc9210c65fe4f31eb4295b2fc9510',1,'NoteMD5Context']]], + ['buf_704',['buf',['../struct_note_m_d5_context.html#ad58666280287db0368333c2f50465f02',1,'NoteMD5Context']]], + ['buffer_705',['buffer',['../structprintbuffer.html#a754f63618e91db99f7ab6cfc4e629013',1,'printbuffer']]] +]; diff --git a/doxygen/html/search/variables_2.html b/doxygen/html/search/variables_2.html new file mode 100644 index 00000000..0580462e --- /dev/null +++ b/doxygen/html/search/variables_2.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/variables_2.js b/doxygen/html/search/variables_2.js new file mode 100644 index 00000000..accf11e3 --- /dev/null +++ b/doxygen/html/search/variables_2.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['child_706',['child',['../struct_j.html#ab4ff5a4f92fa47b521015ef15e6da518',1,'J']]], + ['content_707',['content',['../structparse__buffer.html#a52ee1184576baa3d5171059ab0e942de',1,'parse_buffer']]] +]; diff --git a/doxygen/html/search/variables_3.html b/doxygen/html/search/variables_3.html new file mode 100644 index 00000000..0d69e761 --- /dev/null +++ b/doxygen/html/search/variables_3.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/variables_3.js b/doxygen/html/search/variables_3.js new file mode 100644 index 00000000..78d4f180 --- /dev/null +++ b/doxygen/html/search/variables_3.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['data_708',['data',['../struct_note_payload_desc.html#a05effe66a8c405ee11e9b1d8758d322a',1,'NotePayloadDesc']]], + ['depth_709',['depth',['../structparse__buffer.html#af613c4ed7d73f76c60c50d1bcf4c67a0',1,'parse_buffer::depth()'],['../structprintbuffer.html#aa7311b5da38ff8d1737824c611b48732',1,'printbuffer::depth()']]] +]; diff --git a/doxygen/html/search/variables_4.html b/doxygen/html/search/variables_4.html new file mode 100644 index 00000000..a4b6506b --- /dev/null +++ b/doxygen/html/search/variables_4.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/variables_4.js b/doxygen/html/search/variables_4.js new file mode 100644 index 00000000..26e48fca --- /dev/null +++ b/doxygen/html/search/variables_4.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['format_710',['format',['../structprintbuffer.html#a38337d25a56957deebce187d9ab089ef',1,'printbuffer']]], + ['free_5ffn_711',['free_fn',['../struct_j_hooks.html#a154d673fa4669abf51f7848c2c299718',1,'JHooks']]] +]; diff --git a/doxygen/html/search/variables_5.html b/doxygen/html/search/variables_5.html new file mode 100644 index 00000000..7e345d16 --- /dev/null +++ b/doxygen/html/search/variables_5.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/variables_5.js b/doxygen/html/search/variables_5.js new file mode 100644 index 00000000..22fce7aa --- /dev/null +++ b/doxygen/html/search/variables_5.js @@ -0,0 +1,22 @@ +var searchData= +[ + ['hookactiveinterface_712',['hookActiveInterface',['../n__hooks_8c.html#a2e1147a166cf94837f8793746231acce',1,'n_hooks.c']]], + ['hookdebugoutput_713',['hookDebugOutput',['../n__hooks_8c.html#a11663e8bd175750e1e06c8201a5478a8',1,'n_hooks.c']]], + ['hookdelayms_714',['hookDelayMs',['../n__hooks_8c.html#a18e7b68c9f867dcd0818086f602e932f',1,'n_hooks.c']]], + ['hookfree_715',['hookFree',['../n__hooks_8c.html#ac3f19a99b0efcdf65efdb56ab8c83950',1,'n_hooks.c']]], + ['hookgetms_716',['hookGetMs',['../n__hooks_8c.html#a06884d23d5f78279deb3a32a43ef4694',1,'n_hooks.c']]], + ['hooki2creceive_717',['hookI2CReceive',['../n__hooks_8c.html#a263455cdbf1fc17b92a975c7535f1950',1,'n_hooks.c']]], + ['hooki2creset_718',['hookI2CReset',['../n__hooks_8c.html#a57e8dca746e7d85e7eabfb0b7bee4572',1,'n_hooks.c']]], + ['hooki2ctransmit_719',['hookI2CTransmit',['../n__hooks_8c.html#aa0d2d6474eba5963389d55f795968cb6',1,'n_hooks.c']]], + ['hooklocki2c_720',['hookLockI2C',['../n__hooks_8c.html#a3f891ce572bd99b70a8c20f999d5942d',1,'n_hooks.c']]], + ['hooklocknote_721',['hookLockNote',['../n__hooks_8c.html#a37517c21bcce9f3a523beb50838b1126',1,'n_hooks.c']]], + ['hookmalloc_722',['hookMalloc',['../n__hooks_8c.html#a82e929c5ea774f51f743646d088c7067',1,'n_hooks.c']]], + ['hookserialavailable_723',['hookSerialAvailable',['../n__hooks_8c.html#a85a763552201e904319a46d7bbaffb2f',1,'n_hooks.c']]], + ['hookserialreceive_724',['hookSerialReceive',['../n__hooks_8c.html#abb53cb4c8b5875405005a10f8e5dd276',1,'n_hooks.c']]], + ['hookserialreset_725',['hookSerialReset',['../n__hooks_8c.html#a8b924ad75dc42dbb9f55e39bbb383e53',1,'n_hooks.c']]], + ['hookserialtransmit_726',['hookSerialTransmit',['../n__hooks_8c.html#adc5dbf6a449a062dc2ce585b377e01c8',1,'n_hooks.c']]], + ['hooktransactionstart_727',['hookTransactionStart',['../n__hooks_8c.html#a2862300245c7f82df19c4f3a3a79f759',1,'n_hooks.c']]], + ['hooktransactionstop_728',['hookTransactionStop',['../n__hooks_8c.html#aee65145a7f7916880913d039ee9dec70',1,'n_hooks.c']]], + ['hookunlocki2c_729',['hookUnlockI2C',['../n__hooks_8c.html#a0188e2a3e1e67ab47bb31ffaca28c0f1',1,'n_hooks.c']]], + ['hookunlocknote_730',['hookUnlockNote',['../n__hooks_8c.html#a79775290fccd64212d68cf8bf37fce1a',1,'n_hooks.c']]] +]; diff --git a/doxygen/html/search/variables_6.html b/doxygen/html/search/variables_6.html new file mode 100644 index 00000000..7d48e75e --- /dev/null +++ b/doxygen/html/search/variables_6.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/variables_6.js b/doxygen/html/search/variables_6.js new file mode 100644 index 00000000..e50a100d --- /dev/null +++ b/doxygen/html/search/variables_6.js @@ -0,0 +1,6 @@ +var searchData= +[ + ['i2caddress_731',['i2cAddress',['../n__hooks_8c.html#ad55843178b5a1e1ecfba8e9b53544c57',1,'n_hooks.c']]], + ['i2cmax_732',['i2cMax',['../n__hooks_8c.html#a6b4abd91cf929e64478a77b3cab5c793',1,'n_hooks.c']]], + ['in_733',['in',['../struct_note_m_d5_context.html#af22373f810c98e50af1890c0a5e8cfa1',1,'NoteMD5Context']]] +]; diff --git a/doxygen/html/search/variables_7.html b/doxygen/html/search/variables_7.html new file mode 100644 index 00000000..5c263409 --- /dev/null +++ b/doxygen/html/search/variables_7.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/variables_7.js b/doxygen/html/search/variables_7.js new file mode 100644 index 00000000..6b76a396 --- /dev/null +++ b/doxygen/html/search/variables_7.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['json_734',['json',['../structerror.html#a9b123855d5dd48e86de846588462b39f',1,'error']]] +]; diff --git a/doxygen/html/search/variables_8.html b/doxygen/html/search/variables_8.html new file mode 100644 index 00000000..dc9ec54a --- /dev/null +++ b/doxygen/html/search/variables_8.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/variables_8.js b/doxygen/html/search/variables_8.js new file mode 100644 index 00000000..bf841978 --- /dev/null +++ b/doxygen/html/search/variables_8.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['length_735',['length',['../structparse__buffer.html#a036970e9335896d3cee8459eda9e2eb9',1,'parse_buffer::length()'],['../structprintbuffer.html#a1a679f8b6fe9b413fb3a87203b0f5bc8',1,'printbuffer::length()'],['../struct_note_payload_desc.html#ad28917f881294856b621632d318f5ea7',1,'NotePayloadDesc::length()']]] +]; diff --git a/doxygen/html/search/variables_9.html b/doxygen/html/search/variables_9.html new file mode 100644 index 00000000..7b014750 --- /dev/null +++ b/doxygen/html/search/variables_9.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/variables_9.js b/doxygen/html/search/variables_9.js new file mode 100644 index 00000000..6251b587 --- /dev/null +++ b/doxygen/html/search/variables_9.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['malloc_5ffn_736',['malloc_fn',['../struct_j_hooks.html#a2e5e46e7f23c87f9c8681607bd28d05a',1,'JHooks']]] +]; diff --git a/doxygen/html/search/variables_a.html b/doxygen/html/search/variables_a.html new file mode 100644 index 00000000..52a724d1 --- /dev/null +++ b/doxygen/html/search/variables_a.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/variables_a.js b/doxygen/html/search/variables_a.js new file mode 100644 index 00000000..f712618a --- /dev/null +++ b/doxygen/html/search/variables_a.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['next_737',['next',['../struct_j.html#aa07e8b542090fe62bf0469e85d69c37c',1,'J']]], + ['noalloc_738',['noalloc',['../structprintbuffer.html#a2055471b46a66241c72beffd81b67e66',1,'printbuffer']]] +]; diff --git a/doxygen/html/search/variables_b.html b/doxygen/html/search/variables_b.html new file mode 100644 index 00000000..f376b27a --- /dev/null +++ b/doxygen/html/search/variables_b.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/variables_b.js b/doxygen/html/search/variables_b.js new file mode 100644 index 00000000..f8dafd65 --- /dev/null +++ b/doxygen/html/search/variables_b.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['offset_739',['offset',['../structparse__buffer.html#af727920073077579942a79de519bb31a',1,'parse_buffer::offset()'],['../structprintbuffer.html#a3ed6f9d24d6591047680492a962dc7c9',1,'printbuffer::offset()']]], + ['omitempty_740',['omitempty',['../structprintbuffer.html#af746da3857d83e6c7cba29cc5bd7a123',1,'printbuffer']]] +]; diff --git a/doxygen/html/search/variables_c.html b/doxygen/html/search/variables_c.html new file mode 100644 index 00000000..6019eba9 --- /dev/null +++ b/doxygen/html/search/variables_c.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/variables_c.js b/doxygen/html/search/variables_c.js new file mode 100644 index 00000000..79c6834d --- /dev/null +++ b/doxygen/html/search/variables_c.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['position_741',['position',['../structerror.html#a24de70a4d517ab351d80c18582cadb66',1,'error']]], + ['prev_742',['prev',['../struct_j.html#a970543539919061d72e5973433964bee',1,'J']]] +]; diff --git a/doxygen/html/search/variables_d.html b/doxygen/html/search/variables_d.html new file mode 100644 index 00000000..f61ae751 --- /dev/null +++ b/doxygen/html/search/variables_d.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/variables_d.js b/doxygen/html/search/variables_d.js new file mode 100644 index 00000000..9e78147f --- /dev/null +++ b/doxygen/html/search/variables_d.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['string_743',['string',['../struct_j.html#aedd40ac50e584c7b93e0046e404ae543',1,'J']]] +]; diff --git a/doxygen/html/search/variables_e.html b/doxygen/html/search/variables_e.html new file mode 100644 index 00000000..7bfd3721 --- /dev/null +++ b/doxygen/html/search/variables_e.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/variables_e.js b/doxygen/html/search/variables_e.js new file mode 100644 index 00000000..bb7f4454 --- /dev/null +++ b/doxygen/html/search/variables_e.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['type_744',['type',['../struct_j.html#a1bb6f40b6adc8640b4beb11102b21c4b',1,'J']]] +]; diff --git a/doxygen/html/search/variables_f.html b/doxygen/html/search/variables_f.html new file mode 100644 index 00000000..d97920d0 --- /dev/null +++ b/doxygen/html/search/variables_f.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/doxygen/html/search/variables_f.js b/doxygen/html/search/variables_f.js new file mode 100644 index 00000000..429aa099 --- /dev/null +++ b/doxygen/html/search/variables_f.js @@ -0,0 +1,6 @@ +var searchData= +[ + ['valueint_745',['valueint',['../struct_j.html#a55e3d5d8de0cc6aff4d92c1b1228f7ea',1,'J']]], + ['valuenumber_746',['valuenumber',['../struct_j.html#ac62cf00a5cadeafc84d8d9fec38cfa50',1,'J']]], + ['valuestring_747',['valuestring',['../struct_j.html#a54f8d507791671d5f5951e8cae540232',1,'J']]] +]; diff --git a/doxygen/html/splitbar.png b/doxygen/html/splitbar.png new file mode 100644 index 00000000..fe895f2c Binary files /dev/null and b/doxygen/html/splitbar.png differ diff --git a/doxygen/html/struct_j.html b/doxygen/html/struct_j.html new file mode 100644 index 00000000..66b5ccff --- /dev/null +++ b/doxygen/html/struct_j.html @@ -0,0 +1,223 @@ + + + + + + + +note-c: J Struct Reference + + + + + + + + + +
    +
    + + + + + + + +
    +
    note-c +  1.0 +
    +
    An easy to use Notecard Library for C/C++
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + +
    +
    + +
    +
    J Struct Reference
    +
    +
    + +

    The core JSON object type used by note-c. + More...

    + +

    #include <n_cjson.h>

    + + + + + + + + + + + + + + + + + + +

    +Data Fields

    struct Jnext
     
    struct Jprev
     
    struct Jchild
     
    int type
     
    char * valuestring
     
    JINTEGER valueint
     
    JNUMBER valuenumber
     
    char * string
     
    +

    Detailed Description

    +

    The core JSON object type used by note-c.

    +

    When using note-c, treat this struct as opaque. You should never have to work directly with its members.

    +

    Field Documentation

    + +

    ◆ child

    + +
    +
    + + + + +
    struct J* J::child
    +
    + +
    +
    + +

    ◆ next

    + +
    +
    + + + + +
    struct J* J::next
    +
    + +
    +
    + +

    ◆ prev

    + +
    +
    + + + + +
    struct J* J::prev
    +
    + +
    +
    + +

    ◆ string

    + +
    +
    + + + + +
    char* J::string
    +
    + +
    +
    + +

    ◆ type

    + +
    +
    + + + + +
    int J::type
    +
    + +
    +
    + +

    ◆ valueint

    + +
    +
    + + + + +
    JINTEGER J::valueint
    +
    + +
    +
    + +

    ◆ valuenumber

    + +
    +
    + + + + +
    JNUMBER J::valuenumber
    +
    + +
    +
    + +

    ◆ valuestring

    + +
    +
    + + + + +
    char* J::valuestring
    +
    + +
    +
    +
    The documentation for this struct was generated from the following file:
      +
    • /home/runner/work/note-c/note-c/n_cjson.h
    • +
    +
    + + + + diff --git a/doxygen/html/struct_j_hooks.html b/doxygen/html/struct_j_hooks.html new file mode 100644 index 00000000..d257d690 --- /dev/null +++ b/doxygen/html/struct_j_hooks.html @@ -0,0 +1,121 @@ + + + + + + + +note-c: JHooks Struct Reference + + + + + + + + + +
    +
    + + + + + + + +
    +
    note-c +  1.0 +
    +
    An easy to use Notecard Library for C/C++
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + +
    +
    + +
    +
    JHooks Struct Reference
    +
    +
    + +

    #include <n_cjson.h>

    + + + + + + +

    +Data Fields

    void *(* malloc_fn )(size_t sz)
     
    void(* free_fn )(void *ptr)
     
    +

    Field Documentation

    + +

    ◆ free_fn

    + +
    +
    + + + + +
    void(* JHooks::free_fn) (void *ptr)
    +
    + +
    +
    + +

    ◆ malloc_fn

    + +
    +
    + + + + +
    void*(* JHooks::malloc_fn) (size_t sz)
    +
    + +
    +
    +
    The documentation for this struct was generated from the following file:
      +
    • /home/runner/work/note-c/note-c/n_cjson.h
    • +
    +
    + + + + diff --git a/doxygen/html/struct_note_m_d5_context.html b/doxygen/html/struct_note_m_d5_context.html new file mode 100644 index 00000000..068a22be --- /dev/null +++ b/doxygen/html/struct_note_m_d5_context.html @@ -0,0 +1,137 @@ + + + + + + + +note-c: NoteMD5Context Struct Reference + + + + + + + + + +
    +
    + + + + + + + +
    +
    note-c +  1.0 +
    +
    An easy to use Notecard Library for C/C++
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + +
    +
    + +
    +
    NoteMD5Context Struct Reference
    +
    +
    + +

    #include <note.h>

    + + + + + + + + +

    +Data Fields

    unsigned long buf [4]
     
    unsigned long bits [2]
     
    unsigned char in [64]
     
    +

    Field Documentation

    + +

    ◆ bits

    + +
    +
    + + + + +
    unsigned long NoteMD5Context::bits[2]
    +
    + +
    +
    + +

    ◆ buf

    + +
    +
    + + + + +
    unsigned long NoteMD5Context::buf[4]
    +
    + +
    +
    + +

    ◆ in

    + +
    +
    + + + + +
    unsigned char NoteMD5Context::in[64]
    +
    + +
    +
    +
    The documentation for this struct was generated from the following file:
      +
    • /home/runner/work/note-c/note-c/note.h
    • +
    +
    + + + + diff --git a/doxygen/html/struct_note_payload_desc.html b/doxygen/html/struct_note_payload_desc.html new file mode 100644 index 00000000..517525ab --- /dev/null +++ b/doxygen/html/struct_note_payload_desc.html @@ -0,0 +1,137 @@ + + + + + + + +note-c: NotePayloadDesc Struct Reference + + + + + + + + + +
    +
    + + + + + + + +
    +
    note-c +  1.0 +
    +
    An easy to use Notecard Library for C/C++
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + +
    +
    + +
    +
    NotePayloadDesc Struct Reference
    +
    +
    + +

    #include <note.h>

    + + + + + + + + +

    +Data Fields

    uint8_t * data
     
    uint32_t alloc
     
    uint32_t length
     
    +

    Field Documentation

    + +

    ◆ alloc

    + +
    +
    + + + + +
    uint32_t NotePayloadDesc::alloc
    +
    + +
    +
    + +

    ◆ data

    + +
    +
    + + + + +
    uint8_t* NotePayloadDesc::data
    +
    + +
    +
    + +

    ◆ length

    + +
    +
    + + + + +
    uint32_t NotePayloadDesc::length
    +
    + +
    +
    +
    The documentation for this struct was generated from the following file:
      +
    • /home/runner/work/note-c/note-c/note.h
    • +
    +
    + + + + diff --git a/doxygen/html/structerror.html b/doxygen/html/structerror.html new file mode 100644 index 00000000..61732cd1 --- /dev/null +++ b/doxygen/html/structerror.html @@ -0,0 +1,119 @@ + + + + + + + +note-c: error Struct Reference + + + + + + + + + +
    +
    + + + + + + + +
    +
    note-c +  1.0 +
    +
    An easy to use Notecard Library for C/C++
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + +
    +
    + +
    +
    error Struct Reference
    +
    +
    + + + + + + +

    +Data Fields

    const unsigned char * json
     
    size_t position
     
    +

    Field Documentation

    + +

    ◆ json

    + +
    +
    + + + + +
    const unsigned char* error::json
    +
    + +
    +
    + +

    ◆ position

    + +
    +
    + + + + +
    size_t error::position
    +
    + +
    +
    +
    The documentation for this struct was generated from the following file:
      +
    • /home/runner/work/note-c/note-c/n_cjson.c
    • +
    +
    + + + + diff --git a/doxygen/html/structparse__buffer.html b/doxygen/html/structparse__buffer.html new file mode 100644 index 00000000..9f312919 --- /dev/null +++ b/doxygen/html/structparse__buffer.html @@ -0,0 +1,151 @@ + + + + + + + +note-c: parse_buffer Struct Reference + + + + + + + + + +
    +
    + + + + + + + +
    +
    note-c +  1.0 +
    +
    An easy to use Notecard Library for C/C++
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + +
    +
    + +
    +
    parse_buffer Struct Reference
    +
    +
    + + + + + + + + + + +

    +Data Fields

    const unsigned char * content
     
    size_t length
     
    size_t offset
     
    size_t depth
     
    +

    Field Documentation

    + +

    ◆ content

    + +
    +
    + + + + +
    const unsigned char* parse_buffer::content
    +
    + +
    +
    + +

    ◆ depth

    + +
    +
    + + + + +
    size_t parse_buffer::depth
    +
    + +
    +
    + +

    ◆ length

    + +
    +
    + + + + +
    size_t parse_buffer::length
    +
    + +
    +
    + +

    ◆ offset

    + +
    +
    + + + + +
    size_t parse_buffer::offset
    +
    + +
    +
    +
    The documentation for this struct was generated from the following file:
      +
    • /home/runner/work/note-c/note-c/n_cjson.c
    • +
    +
    + + + + diff --git a/doxygen/html/structprintbuffer.html b/doxygen/html/structprintbuffer.html new file mode 100644 index 00000000..1a0cb7a1 --- /dev/null +++ b/doxygen/html/structprintbuffer.html @@ -0,0 +1,199 @@ + + + + + + + +note-c: printbuffer Struct Reference + + + + + + + + + +
    +
    + + + + + + + +
    +
    note-c +  1.0 +
    +
    An easy to use Notecard Library for C/C++
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + +
    +
    + +
    +
    printbuffer Struct Reference
    +
    +
    + + + + + + + + + + + + + + + + +

    +Data Fields

    unsigned char * buffer
     
    size_t length
     
    size_t offset
     
    size_t depth
     
    Jbool noalloc
     
    Jbool format
     
    Jbool omitempty
     
    +

    Field Documentation

    + +

    ◆ buffer

    + +
    +
    + + + + +
    unsigned char* printbuffer::buffer
    +
    + +
    +
    + +

    ◆ depth

    + +
    +
    + + + + +
    size_t printbuffer::depth
    +
    + +
    +
    + +

    ◆ format

    + +
    +
    + + + + +
    Jbool printbuffer::format
    +
    + +
    +
    + +

    ◆ length

    + +
    +
    + + + + +
    size_t printbuffer::length
    +
    + +
    +
    + +

    ◆ noalloc

    + +
    +
    + + + + +
    Jbool printbuffer::noalloc
    +
    + +
    +
    + +

    ◆ offset

    + +
    +
    + + + + +
    size_t printbuffer::offset
    +
    + +
    +
    + +

    ◆ omitempty

    + +
    +
    + + + + +
    Jbool printbuffer::omitempty
    +
    + +
    +
    +
    The documentation for this struct was generated from the following file:
      +
    • /home/runner/work/note-c/note-c/n_cjson.c
    • +
    +
    + + + + diff --git a/doxygen/html/sync_off.png b/doxygen/html/sync_off.png new file mode 100644 index 00000000..3b443fc6 Binary files /dev/null and b/doxygen/html/sync_off.png differ diff --git a/doxygen/html/sync_on.png b/doxygen/html/sync_on.png new file mode 100644 index 00000000..e08320fb Binary files /dev/null and b/doxygen/html/sync_on.png differ diff --git a/doxygen/html/tab_a.png b/doxygen/html/tab_a.png new file mode 100644 index 00000000..3b725c41 Binary files /dev/null and b/doxygen/html/tab_a.png differ diff --git a/doxygen/html/tab_b.png b/doxygen/html/tab_b.png new file mode 100644 index 00000000..e2b4a863 Binary files /dev/null and b/doxygen/html/tab_b.png differ diff --git a/doxygen/html/tab_h.png b/doxygen/html/tab_h.png new file mode 100644 index 00000000..fd5cb705 Binary files /dev/null and b/doxygen/html/tab_h.png differ diff --git a/doxygen/html/tab_s.png b/doxygen/html/tab_s.png new file mode 100644 index 00000000..ab478c95 Binary files /dev/null and b/doxygen/html/tab_s.png differ diff --git a/doxygen/html/tabs.css b/doxygen/html/tabs.css new file mode 100644 index 00000000..7d45d36c --- /dev/null +++ b/doxygen/html/tabs.css @@ -0,0 +1 @@ +.sm{position:relative;z-index:9999}.sm,.sm ul,.sm li{display:block;list-style:none;margin:0;padding:0;line-height:normal;direction:ltr;text-align:left;-webkit-tap-highlight-color:rgba(0,0,0,0)}.sm-rtl,.sm-rtl ul,.sm-rtl li{direction:rtl;text-align:right}.sm>li>h1,.sm>li>h2,.sm>li>h3,.sm>li>h4,.sm>li>h5,.sm>li>h6{margin:0;padding:0}.sm ul{display:none}.sm li,.sm a{position:relative}.sm a{display:block}.sm a.disabled{cursor:not-allowed}.sm:after{content:"\00a0";display:block;height:0;font:0px/0 serif;clear:both;visibility:hidden;overflow:hidden}.sm,.sm *,.sm *:before,.sm *:after{-moz-box-sizing:border-box;-webkit-box-sizing:border-box;box-sizing:border-box}.sm-dox{background-image:url("tab_b.png")}.sm-dox a,.sm-dox a:focus,.sm-dox a:hover,.sm-dox a:active{padding:0px 12px;padding-right:43px;font-family:"Lucida Grande","Geneva","Helvetica",Arial,sans-serif;font-size:13px;font-weight:bold;line-height:36px;text-decoration:none;text-shadow:0px 1px 1px rgba(255,255,255,0.9);color:#283A5D;outline:none}.sm-dox a:hover{background-image:url("tab_a.png");background-repeat:repeat-x;color:#fff;text-shadow:0px 1px 1px #000}.sm-dox a.current{color:#D23600}.sm-dox a.disabled{color:#bbb}.sm-dox a span.sub-arrow{position:absolute;top:50%;margin-top:-14px;left:auto;right:3px;width:28px;height:28px;overflow:hidden;font:bold 12px/28px monospace !important;text-align:center;text-shadow:none;background:rgba(255,255,255,0.5);border-radius:5px}.sm-dox a.highlighted span.sub-arrow:before{display:block;content:'-'}.sm-dox>li:first-child>a,.sm-dox>li:first-child>:not(ul) a{border-radius:5px 5px 0 0}.sm-dox>li:last-child>a,.sm-dox>li:last-child>*:not(ul) a,.sm-dox>li:last-child>ul,.sm-dox>li:last-child>ul>li:last-child>a,.sm-dox>li:last-child>ul>li:last-child>*:not(ul) a,.sm-dox>li:last-child>ul>li:last-child>ul,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul{border-radius:0 0 5px 5px}.sm-dox>li:last-child>a.highlighted,.sm-dox>li:last-child>*:not(ul) a.highlighted,.sm-dox>li:last-child>ul>li:last-child>a.highlighted,.sm-dox>li:last-child>ul>li:last-child>*:not(ul) a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>a.highlighted,.sm-dox>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>ul>li:last-child>*:not(ul) a.highlighted{border-radius:0}.sm-dox ul{background:rgba(162,162,162,0.1)}.sm-dox ul a,.sm-dox ul a:focus,.sm-dox ul a:hover,.sm-dox ul a:active{font-size:12px;border-left:8px solid transparent;line-height:36px;text-shadow:none;background-color:white;background-image:none}.sm-dox ul a:hover{background-image:url("tab_a.png");background-repeat:repeat-x;color:#fff;text-shadow:0px 1px 1px #000}.sm-dox ul ul a,.sm-dox ul ul a:hover,.sm-dox ul ul a:focus,.sm-dox ul ul a:active{border-left:16px solid transparent}.sm-dox ul ul ul a,.sm-dox ul ul ul a:hover,.sm-dox ul ul ul a:focus,.sm-dox ul ul ul a:active{border-left:24px solid transparent}.sm-dox ul ul ul ul a,.sm-dox ul ul ul ul a:hover,.sm-dox ul ul ul ul a:focus,.sm-dox ul ul ul ul a:active{border-left:32px solid transparent}.sm-dox ul ul ul ul ul a,.sm-dox ul ul ul ul ul a:hover,.sm-dox ul ul ul ul ul a:focus,.sm-dox ul ul ul ul ul a:active{border-left:40px solid transparent}@media (min-width: 768px){.sm-dox ul{position:absolute;width:12em}.sm-dox li{float:left}.sm-dox.sm-rtl li{float:right}.sm-dox ul li,.sm-dox.sm-rtl ul li,.sm-dox.sm-vertical li{float:none}.sm-dox a{white-space:nowrap}.sm-dox ul a,.sm-dox.sm-vertical a{white-space:normal}.sm-dox .sm-nowrap>li>a,.sm-dox .sm-nowrap>li>:not(ul) a{white-space:nowrap}.sm-dox{padding:0 10px;background-image:url("tab_b.png");line-height:36px}.sm-dox a span.sub-arrow{top:50%;margin-top:-2px;right:12px;width:0;height:0;border-width:4px;border-style:solid dashed dashed dashed;border-color:#283A5D transparent transparent transparent;background:transparent;border-radius:0}.sm-dox a,.sm-dox a:focus,.sm-dox a:active,.sm-dox a:hover,.sm-dox a.highlighted{padding:0px 12px;background-image:url("tab_s.png");background-repeat:no-repeat;background-position:right;border-radius:0 !important}.sm-dox a:hover{background-image:url("tab_a.png");background-repeat:repeat-x;color:#fff;text-shadow:0px 1px 1px #000}.sm-dox a:hover span.sub-arrow{border-color:#fff transparent transparent transparent}.sm-dox a.has-submenu{padding-right:24px}.sm-dox li{border-top:0}.sm-dox>li>ul:before,.sm-dox>li>ul:after{content:'';position:absolute;top:-18px;left:30px;width:0;height:0;overflow:hidden;border-width:9px;border-style:dashed dashed solid dashed;border-color:transparent transparent #bbb transparent}.sm-dox>li>ul:after{top:-16px;left:31px;border-width:8px;border-color:transparent transparent #fff transparent}.sm-dox ul{border:1px solid #bbb;padding:5px 0;background:#fff;border-radius:5px !important;box-shadow:0 5px 9px rgba(0,0,0,0.2)}.sm-dox ul a span.sub-arrow{right:8px;top:50%;margin-top:-5px;border-width:5px;border-color:transparent transparent transparent #555;border-style:dashed dashed dashed solid}.sm-dox ul a,.sm-dox ul a:hover,.sm-dox ul a:focus,.sm-dox ul a:active,.sm-dox ul a.highlighted{color:#555;background-image:none;border:0 !important;color:#555;background-image:none}.sm-dox ul a:hover{background-image:url("tab_a.png");background-repeat:repeat-x;color:#fff;text-shadow:0px 1px 1px #000}.sm-dox ul a:hover span.sub-arrow{border-color:transparent transparent transparent #fff}.sm-dox span.scroll-up,.sm-dox span.scroll-down{position:absolute;display:none;visibility:hidden;overflow:hidden;background:#fff;height:36px}.sm-dox span.scroll-up:hover,.sm-dox span.scroll-down:hover{background:#eee}.sm-dox span.scroll-up:hover span.scroll-up-arrow,.sm-dox span.scroll-up:hover span.scroll-down-arrow{border-color:transparent transparent #D23600 transparent}.sm-dox span.scroll-down:hover span.scroll-down-arrow{border-color:#D23600 transparent transparent transparent}.sm-dox span.scroll-up-arrow,.sm-dox span.scroll-down-arrow{position:absolute;top:0;left:50%;margin-left:-6px;width:0;height:0;overflow:hidden;border-width:6px;border-style:dashed dashed solid dashed;border-color:transparent transparent #555 transparent}.sm-dox span.scroll-down-arrow{top:8px;border-style:solid dashed dashed dashed;border-color:#555 transparent transparent transparent}.sm-dox.sm-rtl a.has-submenu{padding-right:12px;padding-left:24px}.sm-dox.sm-rtl a span.sub-arrow{right:auto;left:12px}.sm-dox.sm-rtl.sm-vertical a.has-submenu{padding:10px 20px}.sm-dox.sm-rtl.sm-vertical a span.sub-arrow{right:auto;left:8px;border-style:dashed solid dashed dashed;border-color:transparent #555 transparent transparent}.sm-dox.sm-rtl>li>ul:before{left:auto;right:30px}.sm-dox.sm-rtl>li>ul:after{left:auto;right:31px}.sm-dox.sm-rtl ul a.has-submenu{padding:10px 20px !important}.sm-dox.sm-rtl ul a span.sub-arrow{right:auto;left:8px;border-style:dashed solid dashed dashed;border-color:transparent #555 transparent transparent}.sm-dox.sm-vertical{padding:10px 0;border-radius:5px}.sm-dox.sm-vertical a{padding:10px 20px}.sm-dox.sm-vertical a:hover,.sm-dox.sm-vertical a:focus,.sm-dox.sm-vertical a:active,.sm-dox.sm-vertical a.highlighted{background:#fff}.sm-dox.sm-vertical a.disabled{background-image:url("tab_b.png")}.sm-dox.sm-vertical a span.sub-arrow{right:8px;top:50%;margin-top:-5px;border-width:5px;border-style:dashed dashed dashed solid;border-color:transparent transparent transparent #555}.sm-dox.sm-vertical>li>ul:before,.sm-dox.sm-vertical>li>ul:after{display:none}.sm-dox.sm-vertical ul a{padding:10px 20px}.sm-dox.sm-vertical ul a:hover,.sm-dox.sm-vertical ul a:focus,.sm-dox.sm-vertical ul a:active,.sm-dox.sm-vertical ul a.highlighted{background:#eee}.sm-dox.sm-vertical ul a.disabled{background:#fff}} diff --git a/doxygen/xml/combine.xslt b/doxygen/xml/combine.xslt new file mode 100644 index 00000000..3bfa82c1 --- /dev/null +++ b/doxygen/xml/combine.xslt @@ -0,0 +1,15 @@ + + + + + + + + + + + + diff --git a/doxygen/xml/compound.xsd b/doxygen/xml/compound.xsd new file mode 100644 index 00000000..6a8a8346 --- /dev/null +++ b/doxygen/xml/compound.xsd @@ -0,0 +1,1215 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/doxygen/xml/index.xml b/doxygen/xml/index.xml new file mode 100644 index 00000000..f11fcd5c --- /dev/null +++ b/doxygen/xml/index.xml @@ -0,0 +1,648 @@ + + + error + json + position + + J + next + prev + child + type + valuestring + valueint + valuenumber + string + + JHooks + malloc_fn + free_fn + + NoteMD5Context + buf + bits + in + + NotePayloadDesc + data + alloc + length + + parse_buffer + content + length + offset + depth + + printbuffer + buffer + length + offset + depth + noalloc + format + omitempty + + n_cjson.c + PRINT_TAB_CHARS + NOTE_C_STATIC + can_read + can_access_at_index + cannot_access_at_index + buffer_at_offset + cjson_min + global_error + JNew_Item + JGetErrorPtr + JGetStringValue + JVersion + Jtolower + case_insensitive_strcmp + Jstrdup + JMalloc + JFree + JDelete + get_decimal_point + parse_number + JSetNumberHelper + ensure + update_offset + print_number + parse_hex4 + utf16_literal_to_utf8 + parse_string + n_htoa16 + print_string_ptr + print_string + parse_value + print_value + parse_array + print_array + parse_object + print_object + buffer_skip_whitespace + skip_utf8_bom + JParseWithOpts + JParse + print + JPrint + JPrintUnformatted + JPrintUnformattedOmitEmpty + JPrintBuffered + printPreallocated + JPrintPreallocatedOmitEmpty + JPrintPreallocated + last_non_omitted_object + JGetArraySize + get_array_item + JGetArrayItem + get_object_item + JGetObjectItem + JGetObjectItemCaseSensitive + JHasObjectItem + suffix_object + create_reference + add_item_to_array + JAddItemToArray + cast_away_const + add_item_to_object + JAddItemToObject + JAddItemToObjectCS + JAddItemReferenceToArray + JAddItemReferenceToObject + JAddTrueToObject + JAddFalseToObject + JAddBoolToObject + JAddNumberToObject + JAddIntToObject + JAddStringToObject + JAddRawToObject + JAddObjectToObject + JAddArrayToObject + JDetachItemViaPointer + JDetachItemFromArray + JDeleteItemFromArray + JDetachItemFromObject + JDetachItemFromObjectCaseSensitive + JDeleteItemFromObject + JDeleteItemFromObjectCaseSensitive + JInsertItemInArray + JReplaceItemViaPointer + JReplaceItemInArray + replace_item_in_object + JReplaceItemInObject + JReplaceItemInObjectCaseSensitive + JCreateTrue + JCreateFalse + JCreateBool + JCreateNumber + JCreateInteger + JCreateString + JCreateStringValue + JCreateStringReference + JCreateObjectReference + JCreateArrayReference + JCreateRaw + JCreateArray + JCreateObject + JCreateIntArray + JCreateNumberArray + JCreateStringArray + JDuplicate + JMinify + JIsInvalid + JIsFalse + JIsTrue + JIsBool + JIsNull + JIsNumber + JIsString + JIsArray + JIsObject + JIsRaw + JCompare + + n_cjson.h + N_CJSON_VERSION_MAJOR + N_CJSON_VERSION_MINOR + N_CJSON_VERSION_PATCH + JInvalid + JFalse + JTrue + JNULL + JNumber + JString + JArray + JObject + JRaw + JIsReference + JStringIsConst + N_CJSON_PUBLIC + N_CJSON_NESTING_LIMIT + JGetObjectItems + JConvertToJSONString + JConvertFromJSONString + JSetIntValue + JSetNumberValue + JArrayForEach + JObjectForEach + J + JHooks + Jbool + JVersion + JInitHooks + JParse + JParseWithOpts + JPrint + JPrintUnformatted + JPrintUnformattedOmitEmpty + JPrintBuffered + JPrintPreallocated + JPrintPreallocatedOmitEmpty + JDelete + JGetArraySize + JGetArrayItem + JGetObjectItem + JGetObjectItemCaseSensitive + JHasObjectItem + JGetErrorPtr + JGetStringValue + JIsInvalid + JIsFalse + JIsTrue + JIsBool + JIsNull + JIsNumber + JIsString + JIsArray + JIsObject + JIsRaw + JCreateTrue + JCreateFalse + JCreateBool + JCreateNumber + JCreateInteger + JCreateString + JCreateRaw + JCreateArray + JCreateObject + JCreateStringValue + JCreateStringReference + JCreateObjectReference + JCreateArrayReference + JCreateIntArray + JCreateNumberArray + JCreateStringArray + JAddItemToArray + JAddItemToObject + JAddItemToObjectCS + JAddItemReferenceToArray + JAddItemReferenceToObject + JDetachItemViaPointer + JDetachItemFromArray + JDeleteItemFromArray + JDetachItemFromObject + JDetachItemFromObjectCaseSensitive + JDeleteItemFromObject + JDeleteItemFromObjectCaseSensitive + JInsertItemInArray + JReplaceItemViaPointer + JReplaceItemInArray + JReplaceItemInObject + JReplaceItemInObjectCaseSensitive + JDuplicate + JCompare + JMinify + JAddTrueToObject + JAddFalseToObject + JAddBoolToObject + JAddNumberToObject + JAddIntToObject + JAddStringToObject + JAddRawToObject + JAddObjectToObject + JAddArrayToObject + JSetNumberHelper + JMalloc + JFree + + n_cjson_helpers.c + JIsPresent + JGetString + JGetArray + JGetObject + JBoolValue + JStringValue + JNumberValue + JGetNumber + JIntValue + JGetInt + JGetBool + JIsNullString + JIsExactString + JContainsString + JAddBinaryToObject + JGetBinaryFromObject + JGetItemName + JItoA + JAtoI + JAllocString + JType + JGetType + JGetItemType + JBaseItemType + + n_hooks.c + NOTE_SHOW_MALLOC + interfaceNone + interfaceSerial + interfaceI2C + nNoteResetFn + nTransactionFn + nReceiveFn + nTransmitFn + hookDebugOutput + hookLockI2C + hookUnlockI2C + hookLockNote + hookUnlockNote + hookTransactionStart + hookTransactionStop + hookMalloc + hookFree + hookDelayMs + hookGetMs + hookActiveInterface + hookSerialReset + hookSerialTransmit + hookSerialAvailable + hookSerialReceive + i2cAddress + i2cMax + hookI2CReset + hookI2CTransmit + hookI2CReceive + notecardReset + notecardTransaction + notecardChunkedReceive + notecardChunkedTransmit + NoteSetFnDefault + NoteSetFn + NoteSetFnDebugOutput + noteIsDebugOutputActive + NoteSetFnTransaction + NoteSetFnMutex + NoteSetFnI2CMutex + NoteSetFnNoteMutex + NoteSetFnSerial + NoteSetFnI2C + NoteSetFnDisabled + NoteDebugIntln + NoteDebugln + NoteDebug + NoteDebugWithLevel + NoteDebugWithLevelLn + NoteGetMs + NoteDelayMs + n_htoa32 + NoteMalloc + NoteFree + NoteLockI2C + NoteUnlockI2C + noteLockNote + noteUnlockNote + noteTransactionStart + noteTransactionStop + noteActiveInterface + noteSerialReset + noteSerialTransmit + noteSerialAvailable + noteSerialReceive + noteI2CReset + noteI2CTransmit + noteI2CReceive + NoteI2CAddress + NoteSetI2CAddress + NoteI2CMax + noteHardReset + noteJSONTransaction + noteChunkedReceive + noteChunkedTransmit + + n_request.c + NOTE_C_STATIC + CRC_FIELD_LENGTH + CRC_FIELD_NAME_OFFSET + CRC_FIELD_NAME_TEST + suppressShowTransactions + resetRequired + lastRequestSeqno + notecardSupportsCrc + lut + crc32 + crcAdd + crcError + errDoc + NoteSuspendTransactionDebug + NoteResumeTransactionDebug + NoteNewRequest + NoteNewCommand + NoteRequest + NoteRequestWithRetry + NoteRequestResponse + NoteRequestResponseWithRetry + NoteRequestResponseJSON + NoteTransaction + noteTransactionShouldLock + NoteResetRequired + NoteReset + NoteErrorContains + NoteErrorClean + n_atoh + + note.h + _NOTE_C_STRINGIZE + NOTE_C_STRINGIZE + NOTE_C_VERSION_MAJOR + NOTE_C_VERSION_MINOR + NOTE_C_VERSION_PATCH + NOTE_C_VERSION + ERRSTR + JINTEGER_MIN + JINTEGER_MAX + NoteNewBody + NoteAddBodyToObject + NoteGetBody + SYNCSTATUS_LEVEL_MAJOR + SYNCSTATUS_LEVEL_MINOR + SYNCSTATUS_LEVEL_DETAILED + SYNCSTATUS_LEVEL_ALGORITHMIC + SYNCSTATUS_LEVEL_ALL + NoteResponseError + NoteResponseErrorContains + NoteDeleteResponse + NOTE_I2C_ADDR_DEFAULT + NOTE_I2C_HEADER_SIZE + NOTE_I2C_MAX_MAX + NOTE_I2C_MAX_DEFAULT + NOTE_C_LOG_LEVEL_ERROR + NOTE_C_LOG_LEVEL_WARN + NOTE_C_LOG_LEVEL_INFO + NOTE_C_LOG_LEVEL_DEBUG + NOTE_C_LOG_FILE_AND_LINE + NOTE_C_LOG_ERROR + NOTE_C_LOG_WARN + NOTE_C_LOG_INFO + NOTE_C_LOG_DEBUG + NOTE_C_LOG_LEVEL + JTYPE_NOT_PRESENT + JTYPE_BOOL_TRUE + JTYPE_BOOL_FALSE + JTYPE_BOOL + JTYPE_NULL + JTYPE_NUMBER_ZERO + JTYPE_NUMBER + JTYPE_STRING_BLANK + JTYPE_STRING_ZERO + JTYPE_STRING_NUMBER + JTYPE_STRING_BOOL_TRUE + JTYPE_STRING_BOOL_FALSE + JTYPE_STRING + JTYPE_OBJECT + JTYPE_ARRAY + JGetObjectItemName + JNTOA_PRECISION + JNTOA_MAX + NOTE_MD5_HASH_SIZE + NOTE_MD5_HASH_STRING_SIZE + NoteSend + NP_SEGTYPE_LEN + NP_SEGLEN_LEN + NP_SEGHDR_LEN + TBOOL + TINT8 + TINT16 + TINT24 + TINT32 + TINT64 + TUINT8 + TUINT16 + TUINT24 + TUINT32 + TFLOAT16 + TFLOAT32 + TFLOAT64 + TSTRING + TSTRINGV + JNUMBER + JINTEGER + JUINTEGER + JTIME + mutexFn + mallocFn + freeFn + delayMsFn + getMsFn + debugOutputFn + serialResetFn + serialTransmitFn + serialAvailableFn + serialReceiveFn + i2cResetFn + i2cTransmitFn + i2cReceiveFn + txnStartFn + txnStopFn + NoteReset + NoteResetRequired + NoteNewRequest + NoteNewCommand + NoteRequestResponse + NoteRequestResponseWithRetry + NoteRequestResponseJSON + NoteSuspendTransactionDebug + NoteResumeTransactionDebug + NoteDebugSyncStatus + NoteRequest + NoteRequestWithRetry + NoteTransaction + NoteErrorContains + NoteErrorClean + NoteSetFnDebugOutput + NoteSetFnTransaction + NoteSetFnMutex + NoteSetFnI2CMutex + NoteSetFnNoteMutex + NoteSetFnDefault + NoteSetFn + NoteSetFnSerial + NoteSetFnI2C + NoteSetFnDisabled + NoteSetI2CAddress + NoteUserAgent + NoteUserAgentUpdate + NoteSetUserAgent + NoteSetUserAgentOS + NoteSetUserAgentCPU + NoteDebug + NoteDebugln + NoteDebugIntln + NoteDebugf + NoteDebugWithLevel + NoteDebugWithLevelLn + NoteMalloc + NoteFree + NoteGetMs + NoteDelayMs + NoteLockI2C + NoteUnlockI2C + NoteI2CAddress + NoteI2CMax + NoteMemAvailable + NotePrint + NotePrintln + NotePrintf + strlcpy + strlcat + JInit + JCheck + JIsPresent + JGetString + JGetNumber + JGetArray + JGetObject + JGetInt + JGetBool + JNumberValue + JStringValue + JBoolValue + JIntValue + JIsNullString + JIsExactString + JContainsString + JAddBinaryToObject + JGetBinaryFromObject + JGetItemName + JAllocString + JType + JGetType + JGetItemType + JBaseItemType + JNtoA + JAtoN + JItoA + JAtoI + JB64EncodeLen + JB64Encode + JB64DecodeLen + JB64Decode + NoteMD5Init + NoteMD5Update + NoteMD5Final + NoteMD5Transform + NoteMD5Hash + NoteMD5HashString + NoteMD5HashToString + NoteBinaryCodecDecode + NoteBinaryCodecEncode + NoteBinaryCodecMaxDecodedLength + NoteBinaryCodecMaxEncodedLength + NoteBinaryStoreDecodedLength + NoteBinaryStoreEncodedLength + NoteBinaryStoreReceive + NoteBinaryStoreReset + NoteBinaryStoreTransmit + NoteSetSTSecs + NoteTimeValid + NoteTimeValidST + NoteTime + NoteTimeST + NoteTimeRefreshMins + NoteTimeSet + NoteLocalTimeST + NoteRegion + NoteLocationValid + NoteLocationValidST + NoteTurboIO + NoteGetEnvInt + NoteGetEnvNumber + NoteGetEnv + NoteSetEnvDefault + NoteSetEnvDefaultNumber + NoteSetEnvDefaultInt + NoteIsConnected + NoteIsConnectedST + NoteGetNetStatus + NoteGetVersion + NoteGetLocation + NoteSetLocation + NoteClearLocation + NoteGetLocationMode + NoteSetLocationMode + NoteGetServiceConfig + NoteGetServiceConfigST + NoteGetStatus + NoteGetStatusST + NoteSleep + NoteWake + NoteFactoryReset + NoteSetSerialNumber + NoteSetProductID + NoteSetUploadMode + NoteSetSyncMode + NoteAdd + NoteSendToRoute + NoteGetVoltage + NoteGetTemperature + NoteGetContact + NoteSetContact + NotePayloadSaveAndSleep + NotePayloadRetrieveAfterSleep + NotePayloadSet + NotePayloadFree + NotePayloadAddSegment + NotePayloadFindSegment + NotePayloadGetSegment + NoteTemplate + + diff --git a/doxygen/xml/index.xsd b/doxygen/xml/index.xsd new file mode 100644 index 00000000..edb1d347 --- /dev/null +++ b/doxygen/xml/index.xsd @@ -0,0 +1,70 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/doxygen/xml/n__cjson_8c.xml b/doxygen/xml/n__cjson_8c.xml new file mode 100644 index 00000000..d4df3557 --- /dev/null +++ b/doxygen/xml/n__cjson_8c.xml @@ -0,0 +1,5251 @@ + + + + n_cjson.c + string.h + stdio.h + math.h + stdlib.h + limits.h + ctype.h + n_lib.h + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + error + parse_buffer + printbuffer + + + PRINT_TAB_CHARS + 4 + + + + + + + + + + NOTE_C_STATIC + static + + + + + + + + + + can_read + buffer + size + ((buffer != NULL) && (((buffer)->offset + size) <= (buffer)->length)) + + + + + + + + + + can_access_at_index + buffer + index + ((buffer != NULL) && (((buffer)->offset + index) < (buffer)->length)) + + + + + + + + + + cannot_access_at_index + buffer + index + (!can_access_at_index(buffer, index)) + + + + + + + + + + buffer_at_offset + buffer + ((buffer)->content + (buffer)->offset) + + + + + + + + + + cjson_min + a + b + ((a < b) ? a : b) + + + + + + + + + + + + error + error global_error + + global_error + = { NULL, 0 } + + + + + + + + + + + + J * + static J * JNew_Item + (void) + JNew_Item + + void + + + + + + + + + + + const char * + const char* JGetErrorPtr + (void) + JGetErrorPtr + + void + + + + + + + + + + + char * + char* JGetStringValue + (J *item) + JGetStringValue + + J * + item + + + + + + + + + + + const char * + const char* JVersion + (void) + JVersion + + void + + + + + + + + + + + char + static char Jtolower + (char c) + Jtolower + + char + c + + + + + + + + + + + int + static int case_insensitive_strcmp + (const unsigned char *string1, const unsigned char *string2) + case_insensitive_strcmp + + const unsigned char * + string1 + + + const unsigned char * + string2 + + + + + + + + + + + unsigned char * + static unsigned char* Jstrdup + (const unsigned char *string) + Jstrdup + + const unsigned char * + string + + + + + + + + + + + void * + void* JMalloc + (size_t size) + JMalloc + + size_t + size + + +Dynamically allocate a block of memory of the given size. + + +This is simply a wrapper around the memory allocation function provided by the user via NoteSetFn. + + +size + + +The number of bytes to allocate. + + + +A pointer to the first byte of the allocated memory or NULL on error. + + + + + + + + + void + void JFree + (void *p) + JFree + + void * + p + + +Free a block of dynamically allocated memory. + + +This is simply a wrapper around the memory free function provided by the user via NoteSetFn. + + +p + + +A pointer to the block of memory to free. + + + + + + + + + + + void + void JDelete + (J *item) + JDelete + + J * + item + + +Free a J object. + + + + +item + + +A pointer to the object. + + + + + + + + + + + unsigned char + static unsigned char get_decimal_point + (void) + get_decimal_point + + void + + + + + + + + + + + Jbool + static Jbool parse_number + (J *const item, parse_buffer *const input_buffer) + parse_number + + J *const + item + + + parse_buffer *const + input_buffer + + + + + + + + + + + JNUMBER + JNUMBER JSetNumberHelper + (J *object, JNUMBER number) + JSetNumberHelper + + J * + object + + + JNUMBER + number + + + + + + + + + + + unsigned char * + static unsigned char* ensure + (printbuffer *const p, size_t needed) + ensure + + printbuffer *const + p + + + size_t + needed + + + + + + + + + + + void + static void update_offset + (printbuffer *const buffer) + update_offset + + printbuffer *const + buffer + + + + + + + + + + + Jbool + static Jbool print_number + (const J *const item, printbuffer *const output_buffer) + print_number + + const J *const + item + + + printbuffer *const + output_buffer + + + + + + + + + + + unsigned long + static unsigned long parse_hex4 + (const unsigned char *const input) + parse_hex4 + + const unsigned char *const + input + + + + + + + + + + + unsigned char + static unsigned char utf16_literal_to_utf8 + (const unsigned char *const input_pointer, const unsigned char *const input_end, unsigned char **output_pointer) + utf16_literal_to_utf8 + + const unsigned char *const + input_pointer + + + const unsigned char *const + input_end + + + unsigned char ** + output_pointer + + + + + + + + + + + Jbool + static Jbool parse_string + (J *const item, parse_buffer *const input_buffer) + parse_string + + J *const + item + + + parse_buffer *const + input_buffer + + + + + + + + + + + void + void n_htoa16 + (uint16_t n, unsigned char *p) + n_htoa16 + + uint16_t + n + + + unsigned char * + p + + + + + + + + + + + Jbool + static Jbool print_string_ptr + (const unsigned char *const input, printbuffer *const output_buffer) + print_string_ptr + + const unsigned char *const + input + + + printbuffer *const + output_buffer + + + + + + + + + + + Jbool + static Jbool print_string + (const J *const item, printbuffer *const p) + print_string + + const J *const + item + + + printbuffer *const + p + + + + + + + + + + + Jbool + static Jbool parse_value + (J *const item, parse_buffer *const input_buffer) + parse_value + + J *const + item + + + parse_buffer *const + input_buffer + + + + + + + + + + + Jbool + static Jbool print_value + (const J *const item, printbuffer *const output_buffer) + print_value + + const J *const + item + + + printbuffer *const + output_buffer + + + + + + + + + + + Jbool + static Jbool parse_array + (J *const item, parse_buffer *const input_buffer) + parse_array + + J *const + item + + + parse_buffer *const + input_buffer + + + + + + + + + + + Jbool + static Jbool print_array + (const J *const item, printbuffer *const output_buffer) + print_array + + const J *const + item + + + printbuffer *const + output_buffer + + + + + + + + + + + Jbool + static Jbool parse_object + (J *const item, parse_buffer *const input_buffer) + parse_object + + J *const + item + + + parse_buffer *const + input_buffer + + + + + + + + + + + Jbool + static Jbool print_object + (const J *const item, printbuffer *const output_buffer) + print_object + + const J *const + item + + + printbuffer *const + output_buffer + + + + + + + + + + + parse_buffer * + static parse_buffer* buffer_skip_whitespace + (parse_buffer *const buffer) + buffer_skip_whitespace + + parse_buffer *const + buffer + + + + + + + + + + + parse_buffer * + static parse_buffer* skip_utf8_bom + (parse_buffer *const buffer) + skip_utf8_bom + + parse_buffer *const + buffer + + + + + + + + + + + J * + J* JParseWithOpts + (const char *value, const char **return_parse_end, Jbool require_null_terminated) + JParseWithOpts + + const char * + value + + + const char ** + return_parse_end + + + Jbool + require_null_terminated + + + + + + + + + + + J * + J* JParse + (const char *value) + JParse + + const char * + value + + +Parse the passed in C-string as JSON and return a J object representing it. + + + + +value + + +The JSON object as a C-string. + + + +A J object or NULL on error (e.g. the string was invalid JSON). + + + + + + + + + unsigned char * + static unsigned char* print + (const J *const item, Jbool format, Jbool omitempty) + print + + const J *const + item + + + Jbool + format + + + Jbool + omitempty + + + + + + + + + + + char * + char* JPrint + (const J *item) + JPrint + + const J * + item + + + + + + + + + + + char * + char* JPrintUnformatted + (const J *item) + JPrintUnformatted + + const J * + item + + +Get the unformatted string representation of a J object. + + +The string returned by this function is dynamically allocated and MUST be freed by the caller with JFree. Unformatted means that the minimum JSON string is produced, without any additional whitespace. + + +item + + +The JSON object to get the unformatted string representation of. + + + +The string or NULL on error. + + + + + + + + + char * + char* JPrintUnformattedOmitEmpty + (const J *item) + JPrintUnformattedOmitEmpty + + const J * + item + + + + + + + + + + + char * + char* JPrintBuffered + (const J *item, int prebuffer, Jbool fmt) + JPrintBuffered + + const J * + item + + + int + prebuffer + + + Jbool + fmt + + + + + + + + + + + Jbool + static Jbool printPreallocated + (J *item, char *buf, const int len, const Jbool fmt, const Jbool omit) + printPreallocated + + J * + item + + + char * + buf + + + const int + len + + + const Jbool + fmt + + + const Jbool + omit + + + + + + + + + + + Jbool + Jbool JPrintPreallocatedOmitEmpty + (J *item, char *buf, const int len, const Jbool fmt) + JPrintPreallocatedOmitEmpty + + J * + item + + + char * + buf + + + const int + len + + + const Jbool + fmt + + + + + + + + + + + Jbool + Jbool JPrintPreallocated + (J *item, char *buf, const int len, const Jbool fmt) + JPrintPreallocated + + J * + item + + + char * + buf + + + const int + len + + + const Jbool + fmt + + + + + + + + + + + bool + static bool last_non_omitted_object + (J *item, printbuffer *const output_buffer) + last_non_omitted_object + + J * + item + + + printbuffer *const + output_buffer + + + + + + + + + + + int + int JGetArraySize + (const J *array) + JGetArraySize + + const J * + array + + + + + + + + + + + J * + static J* get_array_item + (const J *array, size_t index) + get_array_item + + const J * + array + + + size_t + index + + + + + + + + + + + J * + J* JGetArrayItem + (const J *array, int index) + JGetArrayItem + + const J * + array + + + int + index + + + + + + + + + + + J * + static J* get_object_item + (const J *const object, const char *const name, const Jbool case_sensitive) + get_object_item + + const J *const + object + + + const char *const + name + + + const Jbool + case_sensitive + + + + + + + + + + + J * + J* JGetObjectItem + (const J *const object, const char *const string) + JGetObjectItem + + const J *const + object + + + const char *const + string + + + + + + + + + + + J * + J* JGetObjectItemCaseSensitive + (const J *const object, const char *const string) + JGetObjectItemCaseSensitive + + const J *const + object + + + const char *const + string + + + + + + + + + + + Jbool + Jbool JHasObjectItem + (const J *object, const char *string) + JHasObjectItem + + const J * + object + + + const char * + string + + + + + + + + + + + void + static void suffix_object + (J *prev, J *item) + suffix_object + + J * + prev + + + J * + item + + + + + + + + + + + J * + static J* create_reference + (const J *item) + create_reference + + const J * + item + + + + + + + + + + + Jbool + static Jbool add_item_to_array + (J *array, J *item) + add_item_to_array + + J * + array + + + J * + item + + + + + + + + + + + void + void JAddItemToArray + (J *array, J *item) + JAddItemToArray + + J * + array + + + J * + item + + + + + + + + + + + void * + static void* cast_away_const + (const void *string) + cast_away_const + + const void * + string + + + + + + + + + + + Jbool + static Jbool add_item_to_object + (J *const object, const char *const string, J *const item, const Jbool constant_key) + add_item_to_object + + J *const + object + + + const char *const + string + + + J *const + item + + + const Jbool + constant_key + + + + + + + + + + + void + void JAddItemToObject + (J *object, const char *string, J *item) + JAddItemToObject + + J * + object + + + const char * + string + + + J * + item + + + + + + + + + + + void + void JAddItemToObjectCS + (J *object, const char *string, J *item) + JAddItemToObjectCS + + J * + object + + + const char * + string + + + J * + item + + + + + + + + + + + void + void JAddItemReferenceToArray + (J *array, J *item) + JAddItemReferenceToArray + + J * + array + + + J * + item + + + + + + + + + + + void + void JAddItemReferenceToObject + (J *object, const char *string, J *item) + JAddItemReferenceToObject + + J * + object + + + const char * + string + + + J * + item + + + + + + + + + + + J * + J* JAddTrueToObject + (J *const object, const char *const name) + JAddTrueToObject + + J *const + object + + + const char *const + name + + + + + + + + + + + J * + J* JAddFalseToObject + (J *const object, const char *const name) + JAddFalseToObject + + J *const + object + + + const char *const + name + + + + + + + + + + + J * + J* JAddBoolToObject + (J *const object, const char *const name, const Jbool boolean) + JAddBoolToObject + + J *const + object + + + const char *const + name + + + const Jbool + boolean + + +Add a boolean field to a J object. + + + + +object + + +The object to add the field to. + + + + +name + + +The name of the field. + + + + +boolean + + +The value of the field. + + + +A pointer to the newly-added boolean field or NULL on error. + + + + + + + + + J * + J* JAddNumberToObject + (J *const object, const char *const name, const JNUMBER number) + JAddNumberToObject + + J *const + object + + + const char *const + name + + + const JNUMBER + number + + +Add a number field to a J object. + + + + +object + + +The object to add the field to. + + + + +name + + +The name of the field. + + + + +number + + +The value of the field. + + + +A pointer to the newly-added number field or NULL on error. + + + + + + + + + J * + J* JAddIntToObject + (J *const object, const char *const name, const JINTEGER integer) + JAddIntToObject + + J *const + object + + + const char *const + name + + + const JINTEGER + integer + + + + + + + + + + + J * + J* JAddStringToObject + (J *const object, const char *const name, const char *const string) + JAddStringToObject + + J *const + object + + + const char *const + name + + + const char *const + string + + +Add a string field to a J object. + + + + +object + + +The object to add the field to. + + + + +name + + +The name of the field. + + + + +string + + +The value of the field. + + + +A pointer to the newly-added string field or NULL on error. + + + + + + + + + J * + J* JAddRawToObject + (J *const object, const char *const name, const char *const raw) + JAddRawToObject + + J *const + object + + + const char *const + name + + + const char *const + raw + + + + + + + + + + + J * + J* JAddObjectToObject + (J *const object, const char *const name) + JAddObjectToObject + + J *const + object + + + const char *const + name + + +Add an object field to another J object. + + + + +object + + +The object to add the field to. + + + + +name + + +The name of the field. + + + +A pointer to the newly-added object field or NULL on error. + + + + + + + + + J * + J* JAddArrayToObject + (J *const object, const char *const name) + JAddArrayToObject + + J *const + object + + + const char *const + name + + +Add an array field to a J object. + + + + +object + + +The object to add the field to. + + + + +name + + +The name of the field. + + + +A pointer to the newly-added array field or NULL on error. + + + + + + + + + J * + J* JDetachItemViaPointer + (J *parent, J *const item) + JDetachItemViaPointer + + J * + parent + + + J *const + item + + + + + + + + + + + J * + J* JDetachItemFromArray + (J *array, int which) + JDetachItemFromArray + + J * + array + + + int + which + + + + + + + + + + + void + void JDeleteItemFromArray + (J *array, int which) + JDeleteItemFromArray + + J * + array + + + int + which + + + + + + + + + + + J * + J* JDetachItemFromObject + (J *object, const char *string) + JDetachItemFromObject + + J * + object + + + const char * + string + + + + + + + + + + + J * + J* JDetachItemFromObjectCaseSensitive + (J *object, const char *string) + JDetachItemFromObjectCaseSensitive + + J * + object + + + const char * + string + + + + + + + + + + + void + void JDeleteItemFromObject + (J *object, const char *string) + JDeleteItemFromObject + + J * + object + + + const char * + string + + + + + + + + + + + void + void JDeleteItemFromObjectCaseSensitive + (J *object, const char *string) + JDeleteItemFromObjectCaseSensitive + + J * + object + + + const char * + string + + + + + + + + + + + void + void JInsertItemInArray + (J *array, int which, J *newitem) + JInsertItemInArray + + J * + array + + + int + which + + + J * + newitem + + + + + + + + + + + Jbool + Jbool JReplaceItemViaPointer + (J *const parent, J *const item, J *replacement) + JReplaceItemViaPointer + + J *const + parent + + + J *const + item + + + J * + replacement + + + + + + + + + + + void + void JReplaceItemInArray + (J *array, int which, J *newitem) + JReplaceItemInArray + + J * + array + + + int + which + + + J * + newitem + + + + + + + + + + + Jbool + static Jbool replace_item_in_object + (J *object, const char *string, J *replacement, Jbool case_sensitive) + replace_item_in_object + + J * + object + + + const char * + string + + + J * + replacement + + + Jbool + case_sensitive + + + + + + + + + + + void + void JReplaceItemInObject + (J *object, const char *string, J *newitem) + JReplaceItemInObject + + J * + object + + + const char * + string + + + J * + newitem + + + + + + + + + + + void + void JReplaceItemInObjectCaseSensitive + (J *object, const char *string, J *newitem) + JReplaceItemInObjectCaseSensitive + + J * + object + + + const char * + string + + + J * + newitem + + + + + + + + + + + J * + J* JCreateTrue + (void) + JCreateTrue + + void + + + + + + + + + + + J * + J* JCreateFalse + (void) + JCreateFalse + + void + + + + + + + + + + + J * + J* JCreateBool + (Jbool b) + JCreateBool + + Jbool + b + + + + + + + + + + + J * + J* JCreateNumber + (JNUMBER num) + JCreateNumber + + JNUMBER + num + + + + + + + + + + + J * + J* JCreateInteger + (JINTEGER integer) + JCreateInteger + + JINTEGER + integer + + + + + + + + + + + J * + J* JCreateString + (const char *string) + JCreateString + + const char * + string + + + + + + + + + + + J * + J* JCreateStringValue + (const char *string) + JCreateStringValue + + const char * + string + + + + + + + + + + + J * + J* JCreateStringReference + (const char *string) + JCreateStringReference + + const char * + string + + + + + + + + + + + J * + J* JCreateObjectReference + (const J *child) + JCreateObjectReference + + const J * + child + + + + + + + + + + + J * + J* JCreateArrayReference + (const J *child) + JCreateArrayReference + + const J * + child + + + + + + + + + + + J * + J* JCreateRaw + (const char *raw) + JCreateRaw + + const char * + raw + + + + + + + + + + + J * + J* JCreateArray + (void) + JCreateArray + + void + + + + + + + + + + + J * + J* JCreateObject + (void) + JCreateObject + + void + + +Create a new J object. + + +To free the object, use JDelete. +A pointer to the newly-created object. + + + + + + + + + J * + J* JCreateIntArray + (const long int *numbers, int count) + JCreateIntArray + + const long int * + numbers + + + int + count + + + + + + + + + + + J * + J* JCreateNumberArray + (const JNUMBER *numbers, int count) + JCreateNumberArray + + const JNUMBER * + numbers + + + int + count + + + + + + + + + + + J * + J* JCreateStringArray + (const char **strings, int count) + JCreateStringArray + + const char ** + strings + + + int + count + + + + + + + + + + + J * + J* JDuplicate + (const J *item, Jbool recurse) + JDuplicate + + const J * + item + + + Jbool + recurse + + + + + + + + + + + void + void JMinify + (char *json) + JMinify + + char * + json + + + + + + + + + + + Jbool + Jbool JIsInvalid + (const J *const item) + JIsInvalid + + const J *const + item + + + + + + + + + + + Jbool + Jbool JIsFalse + (const J *const item) + JIsFalse + + const J *const + item + + + + + + + + + + + Jbool + Jbool JIsTrue + (const J *const item) + JIsTrue + + const J *const + item + + + + + + + + + + + Jbool + Jbool JIsBool + (const J *const item) + JIsBool + + const J *const + item + + + + + + + + + + + Jbool + Jbool JIsNull + (const J *const item) + JIsNull + + const J *const + item + + + + + + + + + + + Jbool + Jbool JIsNumber + (const J *const item) + JIsNumber + + const J *const + item + + + + + + + + + + + Jbool + Jbool JIsString + (const J *const item) + JIsString + + const J *const + item + + + + + + + + + + + Jbool + Jbool JIsArray + (const J *const item) + JIsArray + + const J *const + item + + + + + + + + + + + Jbool + Jbool JIsObject + (const J *const item) + JIsObject + + const J *const + item + + + + + + + + + + + Jbool + Jbool JIsRaw + (const J *const item) + JIsRaw + + const J *const + item + + + + + + + + + + + Jbool + Jbool JCompare + (const J *const a, const J *const b, const Jbool case_sensitive) + JCompare + + const J *const + a + + + const J *const + b + + + const Jbool + case_sensitive + + + + + + + + + + + + + +Written by Ray Ozzie and Blues Inc. team. +Portions Copyright (c) 2019 Blues Inc. MIT License. Use of this source code is governed by licenses granted by the copyright holder including that found in the LICENSE file. +MODIFIED for use in notecard primarily by altering default memory allocator and by renaming the functions so that they won't conflict with a developer's own decision to incorporate the actual production cJSON into their own app. In no way shall this interfere with a production cJSON. +Renaming was done as follows: CJSON_ -> N_CJSON_ cJSON_ -> J cJSON -> J +Portions Copyright (c) 2009-2017 Dave Gamble and cJSON contributors +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 i 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. + + + +/*disablewarningsaboutoldC89functionsinMSVC*/ +#if!defined(_CRT_SECURE_NO_DEPRECATE)&&defined(_MSC_VER) +#define_CRT_SECURE_NO_DEPRECATE +#endif + +#ifdef__GNUC__ +#pragmaGCCvisibilitypush(default) +#endif +#ifdefined(_MSC_VER) +#pragmawarning(push) +/*disablewarningaboutsinglelinecommentsinsystemheaders*/ +#pragmawarning(disable:4001) +#endif + +#include<string.h> +#include<stdio.h> +#include<math.h> +#include<stdlib.h> +#include<limits.h> +#include<ctype.h> + +//ForNote,disabledependencies +#undefENABLE_LOCALES + +#include"n_lib.h" + +#ifdefENABLE_LOCALES +#include<locale.h> +#endif + +#ifdefined(_MSC_VER) +#pragmawarning(pop) +#endif +#ifdef__GNUC__ +#pragmaGCCvisibilitypop +#endif + +#definePRINT_TAB_CHARS4 + +#ifdefNOTE_C_TEST +#include"test_static.h" +#else +#defineNOTE_C_STATICstatic +#endif + +typedefstruct{ +constunsignedchar*json; +size_tposition; +}error; +staticerrorglobal_error={NULL,0}; + +//Forwards +staticJ*JNew_Item(void); + +N_CJSON_PUBLIC(constchar*)JGetErrorPtr(void) +{ +return(constchar*)(global_error.json+global_error.position); +} + +N_CJSON_PUBLIC(char*)JGetStringValue(J*item) +{ +if(!JIsString(item)){ +returnNULL; +} + +returnitem->valuestring; +} + +/*Thisisasafeguardtopreventcopy-pastersfromusingincompatibleCandheaderfiles*/ +#if(N_CJSON_VERSION_MAJOR!=1)||(N_CJSON_VERSION_MINOR!=7)||(N_CJSON_VERSION_PATCH!=7) +#errorJ.handJ.chavedifferentversions.Makesurethatbothhavethesame. +#endif + +N_CJSON_PUBLIC(constchar*)JVersion(void) +{ +returnNOTE_C_STRINGIZE(N_CJSON_VERSION_MAJOR)"."NOTE_C_STRINGIZE(N_CJSON_VERSION_MINOR)"."NOTE_C_STRINGIZE(N_CJSON_VERSION_PATCH); +} + +NOTE_C_STATICcharJtolower(charc) +{ +if(c<'A'||c>'Z'){ +returnc; +} + +//32isthedistancebetweenanyASCIIuppercaseletteranditslowercase +//counterpart. +returnc+32; +} + +/*Caseinsensitivestringcomparison,doesn'tconsidertwoNULLpointersequalthough*/ +staticintcase_insensitive_strcmp(constunsignedchar*string1,constunsignedchar*string2) +{ +if((string1==NULL)||(string2==NULL)){ +return1; +} + +if(string1==string2){ +return0; +} + +for(;Jtolower(*string1)==Jtolower(*string2);(void)string1++,string2++){ +if(*string1=='\0'){ +return0; +} +} + +returnJtolower(*string1)-Jtolower(*string2); +} + +staticunsignedchar*Jstrdup(constunsignedchar*string) +{ +size_tlength=0; +unsignedchar*copy=NULL; + +if(string==NULL){ +returnNULL; +} + +length=strlen((constchar*)string)+sizeof(""); +copy=(unsignedchar*)_Malloc(length); +if(copy==NULL){ +returnNULL; +} +memcpy(copy,string,length); + +returncopy; +} + +N_CJSON_PUBLIC(void*)JMalloc(size_tsize) +{ +return_Malloc(size); +} + +N_CJSON_PUBLIC(void)JFree(void*p) +{ +_Free(p); +} + +/*Internalconstructor.*/ +staticJ*JNew_Item(void) +{ +J*node=(J*)_Malloc(sizeof(J)); +if(node){ +memset(node,'\0',sizeof(J)); +} + +returnnode; +} + +N_CJSON_PUBLIC(void)JDelete(J*item) +{ +J*next=NULL; +while(item!=NULL){ +next=item->next; +if(!(item->type&JIsReference)&&(item->child!=NULL)){ +JDelete(item->child); +} +if(!(item->type&JIsReference)&&(item->valuestring!=NULL)){ +_Free(item->valuestring); +} +if(!(item->type&JStringIsConst)&&(item->string!=NULL)){ +_Free(item->string); +} +_Free(item); +item=next; +} +} + +/*getthedecimalpointcharacterofthecurrentlocale*/ +staticunsignedcharget_decimal_point(void) +{ +#ifdefENABLE_LOCALES +structlconv*lconv=localeconv(); +return(unsignedchar)lconv->decimal_point[0]; +#else +return'.'; +#endif +} + +typedefstruct{ +constunsignedchar*content; +size_tlength; +size_toffset; +size_tdepth;/*Howdeeplynested(inarrays/objects)istheinputatthecurrentoffset.*/ +}parse_buffer; + +/*checkifthegivensizeislefttoreadinagivenparsebuffer(startingwith1)*/ +#definecan_read(buffer,size)((buffer!=NULL)&&(((buffer)->offset+size)<=(buffer)->length)) +/*checkifthebuffercanbeaccessedatthegivenindex(startingwith0)*/ +#definecan_access_at_index(buffer,index)((buffer!=NULL)&&(((buffer)->offset+index)<(buffer)->length)) +#definecannot_access_at_index(buffer,index)(!can_access_at_index(buffer,index)) +/*getapointertothebufferattheposition*/ +#definebuffer_at_offset(buffer)((buffer)->content+(buffer)->offset) + +/*Parsetheinputtexttogenerateanumber,andpopulatetheresultintoitem.*/ +staticJboolparse_number(J*constitem,parse_buffer*constinput_buffer) +{ +JNUMBERnumber=0; +unsignedchar*after_end=NULL; +unsignedcharnumber_c_string[64]; +unsignedchardecimal_point=get_decimal_point(); +size_ti=0; + +if((input_buffer==NULL)||(input_buffer->content==NULL)){ +returnfalse; +} + +/*copythenumberintoatemporarybufferandreplace'.'withthedecimalpoint +*ofthecurrentlocale(forstrtod) +*Thisalsotakescareof'\0'notnecessarilybeingavailableformarkingtheendoftheinput*/ +for(i=0;(i<(sizeof(number_c_string)-1))&&can_access_at_index(input_buffer,i);i++){ +switch(buffer_at_offset(input_buffer)[i]){ +case'0': +case'1': +case'2': +case'3': +case'4': +case'5': +case'6': +case'7': +case'8': +case'9': +case'+': +case'-': +case'e': +case'E': +number_c_string[i]=buffer_at_offset(input_buffer)[i]; +break; + +case'.': +number_c_string[i]=decimal_point; +break; + +default: +gotoloop_end; +} +} +loop_end: +number_c_string[i]='\0'; + +number=JAtoN((constchar*)number_c_string,(char**)&after_end); +if(number_c_string==after_end){ +returnfalse;/*parse_error*/ +} +item->valuenumber=number; + +//Saturatevalueintinthecaseofoverflow. +if(number>=JINTEGER_MAX){ +item->valueint=JINTEGER_MAX; +}elseif(number<=JINTEGER_MIN){ +item->valueint=JINTEGER_MIN; +}else{ +item->valueint=JAtoI((constchar*)number_c_string); +} + +item->type=JNumber; + +input_buffer->offset+=(size_t)(after_end-number_c_string); +returntrue; +} + +/*don'taskme,buttheoriginalJSetNumberValuereturnsanintegerorJNUMBER*/ +N_CJSON_PUBLIC(JNUMBER)JSetNumberHelper(J*object,JNUMBERnumber) +{ +if(object==NULL){ +returnnumber; +} + +//Saturatevalueintinthecaseofoverflow. +if(number>=JINTEGER_MAX){ +object->valueint=JINTEGER_MAX; +}elseif(number<=JINTEGER_MIN){ +object->valueint=JINTEGER_MIN; +}else{ +object->valueint=(JINTEGER)number; +} + +returnobject->valuenumber=number; +} + +typedefstruct{ +unsignedchar*buffer; +size_tlength; +size_toffset; +size_tdepth;/*currentnestingdepth(forformattedprinting)*/ +Jboolnoalloc; +Jboolformat;/*isthisprintaformattedprint*/ +Jboolomitempty; +}printbuffer; + +/*reallocprintbufferifnecessarytohaveatleast"needed"bytesmore*/ +staticunsignedchar*ensure(printbuffer*constp,size_tneeded) +{ +unsignedchar*newbuffer=NULL; +size_tnewsize=0; + +if((p==NULL)||(p->buffer==NULL)){ +returnNULL; +} + +if((p->length>0)&&(p->offset>=p->length)){ +/*makesurethatoffsetisvalid*/ +returnNULL; +} + +if(needed>INT_MAX){ +/*sizesbiggerthanINT_MAXarecurrentlynotsupported*/ +returnNULL; +} + +needed+=p->offset+1; +if(needed<=p->length){ +returnp->buffer+p->offset; +} + +if(p->noalloc){ +returnNULL; +} + +/*calculatenewbuffersize*/ +if(needed>(INT_MAX/2)){ +/*overflowofint,useINT_MAXifpossible*/ +if(needed<=INT_MAX){ +newsize=INT_MAX; +}else{ +returnNULL; +} +}else{ +newsize=needed*2; +} + +/*otherwisereallocatemanually*/ +newbuffer=(unsignedchar*)_Malloc(newsize); +if(!newbuffer){ +_Free(p->buffer); +p->length=0; +p->buffer=NULL; +returnNULL; +} +if(newbuffer){ +memcpy(newbuffer,p->buffer,p->offset+1); +} +_Free(p->buffer); + +p->length=newsize; +p->buffer=newbuffer; + +returnnewbuffer+p->offset; +} + +/*calculatethenewlengthofthestringinaprintbufferandupdatetheoffset*/ +staticvoidupdate_offset(printbuffer*constbuffer) +{ +constunsignedchar*buffer_pointer=NULL; +if((buffer==NULL)||(buffer->buffer==NULL)){ +return; +} +buffer_pointer=buffer->buffer+buffer->offset; + +buffer->offset+=strlen((constchar*)buffer_pointer); +} + +/*Renderthenumbernicelyfromthegivenitemintoastring.*/ +staticJboolprint_number(constJ*constitem,printbuffer*constoutput_buffer) +{ +if(item==NULL){ +returnfalse; +} + +unsignedchar*output_pointer=NULL; +JNUMBERvnum=item->valuenumber; +JINTEGERvint=item->valueint; +intlength=0; +size_ti=0; +unsignedcharnumber_buffer[JNTOA_MAX];/*temporarybuffertoprintthenumberinto*/ +unsignedchardecimal_point=get_decimal_point(); + +if(output_buffer==NULL){ +returnfalse; +} + +/*ThischecksforNaNandInfinity*/ +if((vnum*0)!=0){ +char*nbuf=(char*)number_buffer; +strlcpy(nbuf,"null",JNTOA_MAX); +length=strlen(nbuf); +}else{ +char*nbuf=(char*)number_buffer; + +if(vnum!=(JNUMBER)vint){ +JNtoA(vnum,nbuf,-1); +}else{ +JItoA(vint,nbuf); +} + +length=strlen(nbuf); +} + +/*conversionfailedorbufferoverrunoccured*/ +if((length<0)||(length>(int)(sizeof(number_buffer)-1))){ +returnfalse; +} + +/*reserveappropriatespaceintheoutput*/ +output_pointer=ensure(output_buffer,(size_t)length+sizeof("")); +if(output_pointer==NULL){ +returnfalse; +} + +/*copytheprintednumbertotheoutputandreplacelocale +*dependentdecimalpointwith'.'*/ +for(i=0;i<((size_t)length);i++){ +if(number_buffer[i]==decimal_point){ +output_pointer[i]='.'; +continue; +} + +output_pointer[i]=number_buffer[i]; +} +output_pointer[i]='\0'; + +output_buffer->offset+=(size_t)length; + +returntrue; +} + +/*parse4digithexadecimalnumber*/ +staticunsignedlongparse_hex4(constunsignedchar*constinput) +{ +unsignedlonginth=0; +size_ti=0; + +for(i=0;i<4;i++){ +/*parsedigit*/ +if((input[i]>='0')&&(input[i]<='9')){ +h+=(unsignedint)input[i]-'0'; +}elseif((input[i]>='A')&&(input[i]<='F')){ +h+=(unsignedint)10+input[i]-'A'; +}elseif((input[i]>='a')&&(input[i]<='f')){ +h+=(unsignedint)10+input[i]-'a'; +}else{/*invalid*/ +return0; +} + +if(i<3){ +/*shiftlefttomakeplaceforthenextnibble*/ +h=h<<4; +} +} + +returnh; +} + +/*convertsaUTF-16literaltoUTF-8 +*Aliteralcanbeoneortwosequencesoftheform\uXXXX*/ +staticunsignedcharutf16_literal_to_utf8(constunsignedchar*constinput_pointer,constunsignedchar*constinput_end,unsignedchar**output_pointer) +{ +longunsignedintcodepoint=0; +unsignedlongintfirst_code=0; +constunsignedchar*first_sequence=input_pointer; +unsignedcharutf8_length=0; +unsignedcharutf8_position=0; +unsignedcharsequence_length=0; +unsignedcharfirst_byte_mark=0; + +if((input_end-first_sequence)<6){ +/*inputendsunexpectedly*/ +gotofail; +} + +/*getthefirstutf16sequence*/ +first_code=parse_hex4(first_sequence+2); + +/*checkthatthecodeisvalid*/ +if(((first_code>=0xDC00)&&(first_code<=0xDFFF))){ +gotofail; +} + +/*UTF16surrogatepair*/ +if((first_code>=0xD800)&&(first_code<=0xDBFF)){ +constunsignedchar*second_sequence=first_sequence+6; +unsignedintsecond_code=0; +sequence_length=12;/*\uXXXX\uXXXX*/ + +if((input_end-second_sequence)<6){ +/*inputendsunexpectedly*/ +gotofail; +} + +if((second_sequence[0]!='\\')||(second_sequence[1]!='u')){ +/*missingsecondhalfofthesurrogatepair*/ +gotofail; +} + +/*getthesecondutf16sequence*/ +second_code=parse_hex4(second_sequence+2); +/*checkthatthecodeisvalid*/ +if((second_code<0xDC00)||(second_code>0xDFFF)){ +/*invalidsecondhalfofthesurrogatepair*/ +gotofail; +} + + +/*calculatetheunicodecodepointfromthesurrogatepair*/ +codepoint=0x10000+(((first_code&0x3FF)<<10)|(second_code&0x3FF)); +}else{ +sequence_length=6;/*\uXXXX*/ +codepoint=first_code; +} + +/*encodeasUTF-8 +*takesatmaximum4bytestoencode: +*11110xxx10xxxxxx10xxxxxx10xxxxxx*/ +if(codepoint<0x80){ +/*normalascii,encoding0xxxxxxx*/ +utf8_length=1; +}elseif(codepoint<0x800){ +/*twobytes,encoding110xxxxx10xxxxxx*/ +utf8_length=2; +first_byte_mark=0xC0;/*11000000*/ +}elseif(codepoint<0x10000){ +/*threebytes,encoding1110xxxx10xxxxxx10xxxxxx*/ +utf8_length=3; +first_byte_mark=0xE0;/*11100000*/ +}elseif(codepoint<=0x10FFFF){ +/*fourbytes,encoding1110xxxx10xxxxxx10xxxxxx10xxxxxx*/ +utf8_length=4; +first_byte_mark=0xF0;/*11110000*/ +}else{ +/*invalidunicodecodepoint*/ +gotofail; +} + +/*encodeasutf8*/ +for(utf8_position=(unsignedchar)(utf8_length-1);utf8_position>0;utf8_position--){ +/*10xxxxxx*/ +(*output_pointer)[utf8_position]=(unsignedchar)((codepoint|0x80)&0xBF); +codepoint>>=6; +} +/*encodefirstbyte*/ +if(utf8_length>1){ +(*output_pointer)[0]=(unsignedchar)((codepoint|first_byte_mark)&0xFF); +}else{ +(*output_pointer)[0]=(unsignedchar)(codepoint&0x7F); +} + +*output_pointer+=utf8_length; + +returnsequence_length; + +fail: +return0; +} + +/*Parsetheinputtextintoanunescapedcinput,andpopulateitem.*/ +staticJboolparse_string(J*constitem,parse_buffer*constinput_buffer) +{ +constunsignedchar*input_pointer=buffer_at_offset(input_buffer)+1; +constunsignedchar*input_end=buffer_at_offset(input_buffer)+1; +unsignedchar*output_pointer=NULL; +unsignedchar*output=NULL; + +/*notastring*/ +if(buffer_at_offset(input_buffer)[0]!='\"'){ +gotofail; +} + +{ +/*calculateapproximatesizeoftheoutput(overestimate)*/ +size_tallocation_length=0; +size_tskipped_bytes=0; +while(((size_t)(input_end-input_buffer->content)<input_buffer->length)&&(*input_end!='\"')){ +/*isescapesequence*/ +if(input_end[0]=='\\'){ +if((size_t)(input_end+1-input_buffer->content)>=input_buffer->length){ +/*preventbufferoverflowwhenlastinputcharacterisabackslash*/ +gotofail; +} +skipped_bytes++; +input_end++; +} +input_end++; +} +if(((size_t)(input_end-input_buffer->content)>=input_buffer->length)||(*input_end!='\"')){ +gotofail;/*stringendedunexpectedly*/ +} + +/*Thisisatmosthowmuchweneedfortheoutput*/ +allocation_length=(size_t)(input_end-buffer_at_offset(input_buffer))-skipped_bytes; +output=(unsignedchar*)_Malloc(allocation_length+1);//trailing'\0' +if(output==NULL){ +gotofail;/*allocationfailure*/ +} +} + +output_pointer=output; +/*loopthroughthestringliteral*/ +while(input_pointer<input_end){ +if(*input_pointer!='\\'){ +*output_pointer++=*input_pointer++; +} +/*escapesequence*/ +else{ +unsignedcharsequence_length=2; +if((input_end-input_pointer)<1){ +gotofail; +} + +switch(input_pointer[1]){ +case'b': +*output_pointer++='\b'; +break; +case'f': +*output_pointer++='\f'; +break; +case'n': +*output_pointer++='\n'; +break; +case'r': +*output_pointer++='\r'; +break; +case't': +*output_pointer++='\t'; +break; +case'\"': +case'\\': +case'/': +*output_pointer++=input_pointer[1]; +break; + +/*UTF-16literal*/ +case'u': +sequence_length=utf16_literal_to_utf8(input_pointer,input_end,&output_pointer); +if(sequence_length==0){ +/*failedtoconvertUTF16-literaltoUTF-8*/ +gotofail; +} +break; + +default: +gotofail; +} +input_pointer+=sequence_length; +} +} + +/*zeroterminatetheoutput*/ +*output_pointer='\0'; + +item->type=JString; +item->valuestring=(char*)output; + +input_buffer->offset=(size_t)(input_end-input_buffer->content); +input_buffer->offset++; + +returntrue; + +fail: +if(output!=NULL){ +_Free(output); +} + +if(input_pointer!=NULL){ +input_buffer->offset=(size_t)(input_pointer-input_buffer->content); +} + +returnfalse; +} + +/*Converta16-bitnumberto4hexdigits,null-terminatingit*/ +voidn_htoa16(uint16_tn,unsignedchar*p) +{ +inti; +for(i=0;i<4;i++){ +uint16_tnibble=(n>>12)&0xff; +n=n<<4; +if(nibble>=10){ +*p++='A'+(nibble-10); +}else{ +*p++='0'+nibble; +} +} +*p='\0'; +} + +/*Renderthecstringprovidedtoanescapedversionthatcanbeprinted.*/ +staticJboolprint_string_ptr(constunsignedchar*constinput,printbuffer*constoutput_buffer) +{ +constunsignedchar*input_pointer=NULL; +unsignedchar*output=NULL; +unsignedchar*output_pointer=NULL; +size_toutput_length=0; +/*numbersofadditionalcharactersneededforescaping*/ +size_tescape_characters=0; + +if(output_buffer==NULL){ +returnfalse; +} + +/*emptystring*/ +if(input==NULL){ +output=ensure(output_buffer,2);//sizeof("\"\"") +if(output==NULL){ +returnfalse; +} +output[0]='"'; +output[1]='"'; +output[2]='\0'; + +returntrue; +} + +/*set"flag"to1ifsomethingneedstobeescaped*/ +for(input_pointer=input;*input_pointer;input_pointer++){ +switch(*input_pointer){ +case'\"': +case'\\': +case'\b': +case'\f': +case'\n': +case'\r': +case'\t': +/*onecharacterescapesequence*/ +escape_characters++; +break; +default: +if(*input_pointer<32){ +/*UTF-16escapesequenceuXXXX*/ +escape_characters+=5; +} +break; +} +} +output_length=(size_t)(input_pointer-input)+escape_characters; + +output=ensure(output_buffer,output_length+2);//sizeof("\"\"") +if(output==NULL){ +returnfalse; +} + +/*nocharactershavetobeescaped*/ +if(escape_characters==0){ +output[0]='\"'; +memcpy(output+1,input,output_length); +output[output_length+1]='\"'; +output[output_length+2]='\0'; + +returntrue; +} + +output[0]='\"'; +output_pointer=output+1; +/*copythestring*/ +for(input_pointer=input;*input_pointer!='\0';(void)input_pointer++,output_pointer++){ +if((*input_pointer>31)&&(*input_pointer!='\"')&&(*input_pointer!='\\')){ +/*normalcharacter,copy*/ +*output_pointer=*input_pointer; +}else{ +/*characterneedstobeescaped*/ +*output_pointer++='\\'; +switch(*input_pointer){ +case'\\': +*output_pointer='\\'; +break; +case'\"': +*output_pointer='\"'; +break; +case'\b': +*output_pointer='b'; +break; +case'\f': +*output_pointer='f'; +break; +case'\n': +*output_pointer='n'; +break; +case'\r': +*output_pointer='r'; +break; +case'\t': +*output_pointer='t'; +break; +default: +/*escapeandprintasunicodecodepoint*/ +*output_pointer++='u'; +n_htoa16(*input_pointer,output_pointer); +output_pointer+=4; +break; +} +} +} +output[output_length+1]='\"'; +output[output_length+2]='\0'; + +returntrue; +} + +/*Invokeprint_string_ptr(whichisuseful)onanitem.*/ +staticJboolprint_string(constJ*constitem,printbuffer*constp) +{ +returnprint_string_ptr((unsignedchar*)item->valuestring,p); +} + +/*Predeclaretheseprototypes.*/ +staticJboolparse_value(J*constitem,parse_buffer*constinput_buffer); +staticJboolprint_value(constJ*constitem,printbuffer*constoutput_buffer); +staticJboolparse_array(J*constitem,parse_buffer*constinput_buffer); +staticJboolprint_array(constJ*constitem,printbuffer*constoutput_buffer); +staticJboolparse_object(J*constitem,parse_buffer*constinput_buffer); +staticJboolprint_object(constJ*constitem,printbuffer*constoutput_buffer); + +/*Utilitytojumpwhitespaceandcr/lf*/ +staticparse_buffer*buffer_skip_whitespace(parse_buffer*constbuffer) +{ +if((buffer==NULL)||(buffer->content==NULL)){ +returnNULL; +} + +while(can_access_at_index(buffer,0)&&(buffer_at_offset(buffer)[0]<=32)){ +buffer->offset++; +} + +if(buffer->offset==buffer->length){ +buffer->offset--; +} + +returnbuffer; +} + +/*skiptheUTF-8BOM(byteordermark)ifitisatthebeginningofabuffer*/ +staticparse_buffer*skip_utf8_bom(parse_buffer*constbuffer) +{ +if((buffer==NULL)||(buffer->content==NULL)||(buffer->offset!=0)){ +returnNULL; +} + +if(can_access_at_index(buffer,4)&&(strncmp((constchar*)buffer_at_offset(buffer),"\xEF\xBB\xBF",3)==0)){ +buffer->offset+=3; +} + +returnbuffer; +} + +/*Parseanobject-createanewroot,andpopulate.*/ +N_CJSON_PUBLIC(J*)JParseWithOpts(constchar*value,constchar**return_parse_end,Jboolrequire_null_terminated) +{ +parse_bufferbuffer={0,0,0,0}; +J*item=NULL; + +/*reseterrorposition*/ +global_error.json=NULL; +global_error.position=0; + +if(value==NULL){ +gotofail; +} + +buffer.content=(constunsignedchar*)value; +buffer.length=strlen((constchar*)value)+1;//Trailing'\0' +buffer.offset=0; + +item=JNew_Item(); +if(item==NULL){/*memoryfail*/ +gotofail; +} + +if(!parse_value(item,buffer_skip_whitespace(skip_utf8_bom(&buffer)))){ +/*parsefailure.episset.*/ +gotofail; +} + +/*ifwerequirenull-terminatedJSONwithoutappendedgarbage,skipandthencheckforanullterminator*/ +if(require_null_terminated){ +buffer_skip_whitespace(&buffer); +if((buffer.offset>=buffer.length)||buffer_at_offset(&buffer)[0]!='\0'){ +gotofail; +} +} +if(return_parse_end){ +*return_parse_end=(constchar*)buffer_at_offset(&buffer); +} + +returnitem; + +fail: +if(item!=NULL){ +JDelete(item); +} + +if(value!=NULL){ +errorlocal_error; +local_error.json=(constunsignedchar*)value; +local_error.position=0; + +if(buffer.offset<buffer.length){ +local_error.position=buffer.offset; +}elseif(buffer.length>0){ +local_error.position=buffer.length-1; +} + +if(return_parse_end!=NULL){ +*return_parse_end=(constchar*)local_error.json+local_error.position; +} + +global_error=local_error; +} + +returnNULL; +} + +N_CJSON_PUBLIC(J*)JParse(constchar*value) +{ +returnJParseWithOpts(value,0,0); +} + +#definecjson_min(a,b)((a<b)?a:b) + +staticunsignedchar*print(constJ*constitem,Jboolformat,Jboolomitempty) +{ +staticconstsize_tdefault_buffer_size=128; +printbufferbuffer[1]; +unsignedchar*printed=NULL; + +memset(buffer,0,sizeof(buffer)); + +/*createbuffer*/ +buffer->buffer=(unsignedchar*)_Malloc(default_buffer_size); +buffer->length=default_buffer_size; +buffer->format=format; +buffer->omitempty=omitempty; +if(buffer->buffer==NULL){ +gotofail; +} + +/*printthevalue*/ +if(!print_value(item,buffer)){ +gotofail; +} +update_offset(buffer); + +/*copytheJSONovertoanewbuffer*/ +printed=(unsignedchar*)_Malloc(buffer->offset+1); +if(printed==NULL){ +gotofail; +} +memcpy(printed,buffer->buffer,cjson_min(buffer->length,buffer->offset+1)); +printed[buffer->offset]='\0';/*justtobesure*/ + +/*freethebuffer*/ +_Free(buffer->buffer); + +returnprinted; + +fail: +if(buffer->buffer!=NULL){ +_Free(buffer->buffer); +} + +if(printed!=NULL){ +_Free(printed); +} + +returnNULL; +} + +/*RenderaJitem/entity/structuretotext.*/ +N_CJSON_PUBLIC(char*)JPrint(constJ*item) +{ +if(item==NULL){ +returnNULL; +} +return(char*)print(item,true,false); +} + +N_CJSON_PUBLIC(char*)JPrintUnformatted(constJ*item) +{ +if(item==NULL){ +returnNULL; +} +return(char*)print(item,false,false); +} + +N_CJSON_PUBLIC(char*)JPrintUnformattedOmitEmpty(constJ*item) +{ +if(item==NULL){ +returnNULL; +} +return(char*)print(item,false,true); +} + +N_CJSON_PUBLIC(char*)JPrintBuffered(constJ*item,intprebuffer,Jboolfmt) +{ +printbufferp={0,0,0,0,0,0,0}; + +if(item==NULL){ +returnNULL; +} + +if(prebuffer<0){ +returnNULL; +} + +p.buffer=(unsignedchar*)_Malloc((size_t)prebuffer); +if(!p.buffer){ +returnNULL; +} + +p.length=(size_t)prebuffer; +p.offset=0; +p.noalloc=false; +p.format=fmt; + +if(!print_value(item,&p)){ +_Free(p.buffer); +returnNULL; +} + +return(char*)p.buffer; +} + +staticJboolprintPreallocated(J*item,char*buf,constintlen,constJboolfmt,constJboolomit) +{ +printbufferp={0,0,0,0,0,0,0}; + +if(item==NULL){ +returnfalse; +} +if((len<0)||(buf==NULL)){ +returnfalse; +} + +p.buffer=(unsignedchar*)buf; +p.length=(size_t)len; +p.offset=0; +p.noalloc=true; +p.format=fmt; +p.omitempty=omit; + +returnprint_value(item,&p); +} + +N_CJSON_PUBLIC(Jbool)JPrintPreallocatedOmitEmpty(J*item,char*buf,constintlen,constJboolfmt) +{ +returnprintPreallocated(item,buf,len,fmt,true); +} + +N_CJSON_PUBLIC(Jbool)JPrintPreallocated(J*item,char*buf,constintlen,constJboolfmt) +{ +returnprintPreallocated(item,buf,len,fmt,false); +} + +/*Parsercore-whenencounteringtext,processappropriately.*/ +staticJboolparse_value(J*constitem,parse_buffer*constinput_buffer) +{ +if(item==NULL){ +returnfalse; +} +if((input_buffer==NULL)||(input_buffer->content==NULL)){ +returnfalse;/*noinput*/ +} + +/*parsethedifferenttypesofvalues*/ +/*null*/ +if(can_read(input_buffer,4)&&(strncmp((constchar*)buffer_at_offset(input_buffer),c_null,c_null_len)==0)){ +item->type=JNULL; +input_buffer->offset+=4; +returntrue; +} +/*false*/ +if(can_read(input_buffer,5)&&(strncmp((constchar*)buffer_at_offset(input_buffer),c_false,c_false_len)==0)){ +item->type=JFalse; +input_buffer->offset+=5; +returntrue; +} +/*true*/ +if(can_read(input_buffer,4)&&(strncmp((constchar*)buffer_at_offset(input_buffer),c_true,c_true_len)==0)){ +item->type=JTrue; +item->valueint=1; +input_buffer->offset+=4; +returntrue; +} +/*string*/ +if(can_access_at_index(input_buffer,0)&&(buffer_at_offset(input_buffer)[0]=='\"')){ +returnparse_string(item,input_buffer); +} +/*number*/ +if(can_access_at_index(input_buffer,0)&&((buffer_at_offset(input_buffer)[0]=='-')||((buffer_at_offset(input_buffer)[0]>='0')&&(buffer_at_offset(input_buffer)[0]<='9')))){ +returnparse_number(item,input_buffer); +} +/*array*/ +if(can_access_at_index(input_buffer,0)&&(buffer_at_offset(input_buffer)[0]=='[')){ +returnparse_array(item,input_buffer); +} +/*object*/ +if(can_access_at_index(input_buffer,0)&&(buffer_at_offset(input_buffer)[0]=='{')){ +returnparse_object(item,input_buffer); +} + +returnfalse; +} + +/*Renderavaluetotext.*/ +staticJboolprint_value(constJ*constitem,printbuffer*constoutput_buffer) +{ +unsignedchar*output=NULL; + +if((item==NULL)||(output_buffer==NULL)){ +returnfalse; +} + +switch((item->type)&0xFF){ +caseJNULL: +output=ensure(output_buffer,c_null_len+1); +if(output==NULL){ +returnfalse; +} +strlcpy((char*)output,c_null,c_null_len+1); +returntrue; + +caseJFalse: +output=ensure(output_buffer,c_false_len+1); +if(output==NULL){ +returnfalse; +} +strlcpy((char*)output,c_false,c_false_len+1); +returntrue; + +caseJTrue: +output=ensure(output_buffer,c_true_len+1); +if(output==NULL){ +returnfalse; +} +strlcpy((char*)output,c_true,c_true_len+1); +returntrue; + +caseJNumber: +returnprint_number(item,output_buffer); + +caseJRaw:{ +size_traw_length=0; +if(item->valuestring==NULL){ +returnfalse; +} + +raw_length=strlen(item->valuestring)+1;//Trailing'\0'; +output=ensure(output_buffer,raw_length); +if(output==NULL){ +returnfalse; +} +memcpy(output,item->valuestring,raw_length); +returntrue; +} + +caseJString: +returnprint_string(item,output_buffer); + +caseJArray: +returnprint_array(item,output_buffer); + +caseJObject: +returnprint_object(item,output_buffer); + +default: +returnfalse; +} +} + +/*Buildanarrayfrominputtext.*/ +staticJboolparse_array(J*constitem,parse_buffer*constinput_buffer) +{ +J*head=NULL;/*headofthelinkedlist*/ +J*current_item=NULL; + +if(input_buffer->depth>=N_CJSON_NESTING_LIMIT){ +returnfalse;/*todeeplynested*/ +} +input_buffer->depth++; + +if(buffer_at_offset(input_buffer)[0]!='['){ +/*notanarray*/ +gotofail; +} + +input_buffer->offset++; +buffer_skip_whitespace(input_buffer); +if(can_access_at_index(input_buffer,0)&&(buffer_at_offset(input_buffer)[0]==']')){ +/*emptyarray*/ +gotosuccess; +} + +/*checkifweskippedtotheendofthebuffer*/ +if(cannot_access_at_index(input_buffer,0)){ +input_buffer->offset--; +gotofail; +} + +/*stepbacktocharacterinfrontofthefirstelement*/ +input_buffer->offset--; +/*loopthroughthecommaseparatedarrayelements*/ +do{ +/*allocatenextitem*/ +J*new_item=JNew_Item(); +if(new_item==NULL){ +gotofail;/*allocationfailure*/ +} + +/*attachnextitemtolist*/ +if(head==NULL){ +/*startthelinkedlist*/ +current_item=head=new_item; +}else{ +/*addtotheendandadvance*/ +current_item->next=new_item; +new_item->prev=current_item; +current_item=new_item; +} + +/*parsenextvalue*/ +input_buffer->offset++; +buffer_skip_whitespace(input_buffer); +if(!parse_value(current_item,input_buffer)){ +gotofail;/*failedtoparsevalue*/ +} +buffer_skip_whitespace(input_buffer); +}while(can_access_at_index(input_buffer,0)&&(buffer_at_offset(input_buffer)[0]==',')); + +if(cannot_access_at_index(input_buffer,0)||buffer_at_offset(input_buffer)[0]!=']'){ +gotofail;/*expectedendofarray*/ +} + +success: +input_buffer->depth--; + +item->type=JArray; +item->child=head; + +input_buffer->offset++; + +returntrue; + +fail: +if(head!=NULL){ +JDelete(head); +} + +returnfalse; +} + +/*Renderanarraytotext*/ +staticJboolprint_array(constJ*constitem,printbuffer*constoutput_buffer) +{ +unsignedchar*output_pointer=NULL; +size_tlength=0; +J*current_element=item->child; + +if(output_buffer==NULL){ +returnfalse; +} + +/*Composetheoutputarray.*/ +/*openingsquarebracket*/ +output_pointer=ensure(output_buffer,1); +if(output_pointer==NULL){ +returnfalse; +} + +*output_pointer='['; +output_buffer->offset++; +output_buffer->depth++; + +while(current_element!=NULL){ +if(!print_value(current_element,output_buffer)){ +returnfalse; +} +update_offset(output_buffer); +if(current_element->next){ +length=(size_t)(output_buffer->format?2:1); +output_pointer=ensure(output_buffer,length+1); +if(output_pointer==NULL){ +returnfalse; +} +*output_pointer++=','; +if(output_buffer->format){ +*output_pointer++=''; +} +*output_pointer='\0'; +output_buffer->offset+=length; +} +current_element=current_element->next; +} + +output_pointer=ensure(output_buffer,2); +if(output_pointer==NULL){ +returnfalse; +} +*output_pointer++=']'; +*output_pointer='\0'; +output_buffer->depth--; + +returntrue; +} + +/*Buildanobjectfromthetext.*/ +staticJboolparse_object(J*constitem,parse_buffer*constinput_buffer) +{ +J*head=NULL;/*linkedlisthead*/ +J*current_item=NULL; + +if(input_buffer->depth>=N_CJSON_NESTING_LIMIT){ +returnfalse;/*todeeplynested*/ +} +input_buffer->depth++; + +if(cannot_access_at_index(input_buffer,0)||(buffer_at_offset(input_buffer)[0]!='{')){ +gotofail;/*notanobject*/ +} + +input_buffer->offset++; +buffer_skip_whitespace(input_buffer); +if(can_access_at_index(input_buffer,0)&&(buffer_at_offset(input_buffer)[0]=='}')){ +gotosuccess;/*emptyobject*/ +} + +/*checkifweskippedtotheendofthebuffer*/ +if(cannot_access_at_index(input_buffer,0)){ +input_buffer->offset--; +gotofail; +} + +/*stepbacktocharacterinfrontofthefirstelement*/ +input_buffer->offset--; +/*loopthroughthecommaseparatedarrayelements*/ +do{ +/*allocatenextitem*/ +J*new_item=JNew_Item(); +if(new_item==NULL){ +gotofail;/*allocationfailure*/ +} + +/*attachnextitemtolist*/ +if(head==NULL){ +/*startthelinkedlist*/ +current_item=head=new_item; +}else{ +/*addtotheendandadvance*/ +current_item->next=new_item; +new_item->prev=current_item; +current_item=new_item; +} + +/*parsethenameofthechild*/ +input_buffer->offset++; +buffer_skip_whitespace(input_buffer); +if(!parse_string(current_item,input_buffer)){ +gotofail;/*failetoparsename*/ +} +buffer_skip_whitespace(input_buffer); + +/*swapvaluestringandstring,becauseweparsedthename*/ +current_item->string=current_item->valuestring; +current_item->valuestring=NULL; + +if(cannot_access_at_index(input_buffer,0)||(buffer_at_offset(input_buffer)[0]!=':')){ +gotofail;/*invalidobject*/ +} + +/*parsethevalue*/ +input_buffer->offset++; +buffer_skip_whitespace(input_buffer); +if(!parse_value(current_item,input_buffer)){ +gotofail;/*failedtoparsevalue*/ +} +buffer_skip_whitespace(input_buffer); +}while(can_access_at_index(input_buffer,0)&&(buffer_at_offset(input_buffer)[0]==',')); + +if(cannot_access_at_index(input_buffer,0)||(buffer_at_offset(input_buffer)[0]!='}')){ +gotofail;/*expectedendofobject*/ +} + +success: +input_buffer->depth--; + +item->type=JObject; +item->child=head; + +input_buffer->offset++; +returntrue; + +fail: +if(head!=NULL){ +JDelete(head); +} + +returnfalse; +} + +/*Seeifthereisanothernon-omitteditemlookingforward*/ +staticboollast_non_omitted_object(J*item,printbuffer*constoutput_buffer) +{ +if(!output_buffer->omitempty){ +return(item->next==0); +} +while(item->next!=0){ +item=item->next; +inttype=JGetItemType(item); +if(type!=JTYPE_BOOL_FALSE&&type!=JTYPE_NUMBER_ZERO&&type!=JTYPE_STRING_BLANK){ +returnfalse; +} +} +returntrue; +} + +/*Renderanobjecttotext.*/ +staticJboolprint_object(constJ*constitem,printbuffer*constoutput_buffer) +{ +unsignedchar*output_pointer=NULL; +size_tlength=0; +J*current_item=item->child; + +if(output_buffer==NULL){ +returnfalse; +} + +/*Composetheoutput:*/ +length=(size_t)(output_buffer->format?2:1);/*fmt:{\n*/ +output_pointer=ensure(output_buffer,length+1); +if(output_pointer==NULL){ +returnfalse; +} + +*output_pointer++='{'; +output_buffer->depth++; +if(output_buffer->format){ +*output_pointer++='\n'; +} +output_buffer->offset+=length; + +while(current_item){ +if(output_buffer->format){ +size_ti; +#if(PRINT_TAB_CHARS==0) +intneeded=output_buffer->depth; +#else +intneeded=output_buffer->depth*PRINT_TAB_CHARS; +#endif +output_pointer=ensure(output_buffer,needed); +if(output_pointer==NULL){ +returnfalse; +} +for(i=0;i<output_buffer->depth;i++){ +#if(PRINT_TAB_CHARS==0) +*output_pointer++='\t'; +output_buffer_offset++; +#else +for(inttc=0;tc<PRINT_TAB_CHARS;tc++){ +*output_pointer++=''; +output_buffer->offset++; +} +#endif +} +} + +/*Seeifitshouldbeeliminatedbecaseofomitempty*/ +boolomit=false; +if(output_buffer->omitempty){ +inttype=JGetItemType(current_item); +omit=(type==JTYPE_BOOL_FALSE||type==JTYPE_NUMBER_ZERO||type==JTYPE_STRING_BLANK); +} + +/*printitemonlyifnotomitted*/ +if(!omit){ + +/*printkey*/ +if(!print_string_ptr((unsignedchar*)current_item->string,output_buffer)){ +returnfalse; +} +update_offset(output_buffer); + +length=(size_t)(output_buffer->format?2:1); +output_pointer=ensure(output_buffer,length); +if(output_pointer==NULL){ +returnfalse; +} +*output_pointer++=':'; +if(output_buffer->format){ +#if(PRINT_TAB_CHARS==0) +*output_pointer++='\t'; +#else +*output_pointer++=''; +#endif +} +output_buffer->offset+=length; + +/*printvalue*/ +if(!print_value(current_item,output_buffer)){ +returnfalse; +} +update_offset(output_buffer); + +/*printcommaifnotlast*/ +boolmore_fields_coming=!last_non_omitted_object(current_item,output_buffer); +length=(size_t)((output_buffer->format?1:0)+(more_fields_coming?1:0)); +output_pointer=ensure(output_buffer,length+1); +if(output_pointer==NULL){ +returnfalse; +} +if(more_fields_coming){ +*output_pointer++=','; +} + +if(output_buffer->format){ +*output_pointer++='\n'; +} +*output_pointer='\0'; +output_buffer->offset+=length; +} + +current_item=current_item->next; +} + +#if(PRINT_TAB_CHARS==0) +intneeded=output_buffer->format?(output_buffer->depth-1):0; +#else +intneeded=output_buffer->format?((output_buffer->depth-1)*PRINT_TAB_CHARS):0; +#endif +needed+=2;//}\0 +output_pointer=ensure(output_buffer,needed); +if(output_pointer==NULL){ +returnfalse; +} +if(output_buffer->format){ +size_ti; +for(i=0;i<(output_buffer->depth-1);i++){ +#if(PRINT_TAB_CHARS==0) +*output_pointer++='\t'; +#else +for(inttc=0;tc<PRINT_TAB_CHARS;tc++){ +*output_pointer++=''; +} +#endif +} +} +*output_pointer++='}'; +*output_pointer='\0'; +output_buffer->depth--; + +returntrue; +} + +/*GetArraysize/item/objectitem.*/ +N_CJSON_PUBLIC(int)JGetArraySize(constJ*array) +{ +J*child=NULL; +size_tsize=0; + +if(array==NULL){ +return0; +} + +child=array->child; + +while(child!=NULL){ +size++; +child=child->next; +} + +/*FIXME:Canoverflowhere.CannotbefixedwithoutbreakingtheAPI*/ + +return(int)size; +} + +staticJ*get_array_item(constJ*array,size_tindex) +{ +J*current_child=NULL; + +if(array==NULL){ +returnNULL; +} + +current_child=array->child; +while((current_child!=NULL)&&(index>0)){ +index--; +current_child=current_child->next; +} + +returncurrent_child; +} + +N_CJSON_PUBLIC(J*)JGetArrayItem(constJ*array,intindex) +{ +if(array==NULL){ +returnNULL; +} +if(index<0){ +returnNULL; +} + +returnget_array_item(array,(size_t)index); +} + +staticJ*get_object_item(constJ*constobject,constchar*constname,constJboolcase_sensitive) +{ +J*current_element=NULL; + +if((object==NULL)||(name==NULL)){ +returnNULL; +} + +current_element=object->child; +if(case_sensitive){ +while((current_element!=NULL)&&(strcmp(name,current_element->string)!=0)){ +current_element=current_element->next; +} +}else{ +while((current_element!=NULL)&&(case_insensitive_strcmp((constunsignedchar*)name,(constunsignedchar*)(current_element->string))!=0)){ +current_element=current_element->next; +} +} + +returncurrent_element; +} + +N_CJSON_PUBLIC(J*)JGetObjectItem(constJ*constobject,constchar*conststring) +{ +if(object==NULL){ +returnNULL; +} +returnget_object_item(object,string,false); +} + +N_CJSON_PUBLIC(J*)JGetObjectItemCaseSensitive(constJ*constobject,constchar*conststring) +{ +if(object==NULL){ +returnNULL; +} +returnget_object_item(object,string,true); +} + +N_CJSON_PUBLIC(Jbool)JHasObjectItem(constJ*object,constchar*string) +{ +if(object==NULL){ +returnfalse; +} +returnJGetObjectItem(object,string)?1:0; +} + +/*Utilityforarraylisthandling.*/ +staticvoidsuffix_object(J*prev,J*item) +{ +prev->next=item; +item->prev=prev; +} + +/*Utilityforhandlingreferences.*/ +staticJ*create_reference(constJ*item) +{ +J*reference=NULL; +if(item==NULL){ +returnNULL; +} + +reference=JNew_Item(); +if(reference==NULL){ +returnNULL; +} + +memcpy(reference,item,sizeof(J)); +reference->string=NULL; +reference->type|=JIsReference; +reference->next=reference->prev=NULL; +returnreference; +} + +staticJbooladd_item_to_array(J*array,J*item) +{ +J*child=NULL; + +if((item==NULL)||(array==NULL)){ +returnfalse; +} + +child=array->child; + +if(child==NULL){ +/*listisempty,startnewone*/ +array->child=item; +}else{ +/*appendtotheend*/ +while(child->next){ +child=child->next; +} +suffix_object(child,item); +} + +returntrue; +} + +/*Additemtoarray/object.*/ +N_CJSON_PUBLIC(void)JAddItemToArray(J*array,J*item) +{ +if(array==NULL||item==NULL){ +return; +} +add_item_to_array(array,item); +} + +#ifdefined(__clang__)||(defined(__GNUC__)&&((__GNUC__>4)||((__GNUC__==4)&&(__GNUC_MINOR__>5)))) +#pragmaGCCdiagnosticpush +#endif +#ifdef__GNUC__ +#pragmaGCCdiagnosticignored"-Wcast-qual" +#endif +/*helperfunctiontocastawayconst*/ +staticvoid*cast_away_const(constvoid*string) +{ +return(void*)string; +} +#ifdefined(__clang__)||(defined(__GNUC__)&&((__GNUC__>4)||((__GNUC__==4)&&(__GNUC_MINOR__>5)))) +#pragmaGCCdiagnosticpop +#endif + + +staticJbooladd_item_to_object(J*constobject,constchar*conststring,J*constitem,constJboolconstant_key) +{ +char*new_key=NULL; +intnew_type=JInvalid; + +if((object==NULL)||(string==NULL)||(item==NULL)){ +returnfalse; +} + +if(constant_key){ +new_key=(char*)cast_away_const(string); +new_type=item->type|JStringIsConst; +}else{ +new_key=(char*)Jstrdup((constunsignedchar*)string); +if(new_key==NULL){ +returnfalse; +} + +new_type=item->type&~JStringIsConst; +} + +if(!(item->type&JStringIsConst)&&(item->string!=NULL)){ +_Free(item->string); +} + +item->string=new_key; +item->type=new_type; + +returnadd_item_to_array(object,item); +} + +N_CJSON_PUBLIC(void)JAddItemToObject(J*object,constchar*string,J*item) +{ +if(object==NULL||string==NULL||item==NULL){ +return; +} +add_item_to_object(object,string,item,false); +} + +/*Addanitemtoanobjectwithconstantstringaskey*/ +N_CJSON_PUBLIC(void)JAddItemToObjectCS(J*object,constchar*string,J*item) +{ +if(object==NULL||string==NULL||item==NULL){ +return; +} +add_item_to_object(object,string,item,true); +} + +N_CJSON_PUBLIC(void)JAddItemReferenceToArray(J*array,J*item) +{ +if(array==NULL||item==NULL){ +return; +} +add_item_to_array(array,create_reference(item)); +} + +N_CJSON_PUBLIC(void)JAddItemReferenceToObject(J*object,constchar*string,J*item) +{ +if(object==NULL||string==NULL||item==NULL){ +return; +} +add_item_to_object(object,string,create_reference(item),false); +} + +N_CJSON_PUBLIC(J*)JAddTrueToObject(J*constobject,constchar*constname) +{ +if(object==NULL){ +returnNULL; +} + +J*true_item=JCreateTrue(); +if(add_item_to_object(object,name,true_item,false)){ +returntrue_item; +} + +JDelete(true_item); +returnNULL; +} + +N_CJSON_PUBLIC(J*)JAddFalseToObject(J*constobject,constchar*constname) +{ +if(object==NULL){ +returnNULL; +} + +J*false_item=JCreateFalse(); +if(add_item_to_object(object,name,false_item,false)){ +returnfalse_item; +} + +JDelete(false_item); +returnNULL; +} + +N_CJSON_PUBLIC(J*)JAddBoolToObject(J*constobject,constchar*constname,constJboolboolean) +{ +if(object==NULL){ +returnNULL; +} + +J*bool_item=JCreateBool(boolean); +if(add_item_to_object(object,name,bool_item,false)){ +returnbool_item; +} + +JDelete(bool_item); +returnNULL; +} + +N_CJSON_PUBLIC(J*)JAddNumberToObject(J*constobject,constchar*constname,constJNUMBERnumber) +{ +if(object==NULL){ +returnNULL; +} + +J*number_item=JCreateNumber(number); +if(add_item_to_object(object,name,number_item,false)){ +returnnumber_item; +} + +JDelete(number_item); +returnNULL; +} + +N_CJSON_PUBLIC(J*)JAddIntToObject(J*constobject,constchar*constname,constJINTEGERinteger) +{ +if(object==NULL){ +returnNULL; +} + +J*integer_item=JCreateInteger(integer); +if(add_item_to_object(object,name,integer_item,false)){ +returninteger_item; +} + +JDelete(integer_item); +returnNULL; +} + +N_CJSON_PUBLIC(J*)JAddStringToObject(J*constobject,constchar*constname,constchar*conststring) +{ +if(object==NULL||string==NULL){ +returnNULL; +} + +J*string_item=JCreateString(string); +if(add_item_to_object(object,name,string_item,false)){ +returnstring_item; +} + +JDelete(string_item); +returnNULL; +} + +N_CJSON_PUBLIC(J*)JAddRawToObject(J*constobject,constchar*constname,constchar*constraw) +{ +if(object==NULL||raw==NULL){ +returnNULL; +} + +J*raw_item=JCreateRaw(raw); +if(add_item_to_object(object,name,raw_item,false)){ +returnraw_item; +} + +JDelete(raw_item); +returnNULL; +} + +N_CJSON_PUBLIC(J*)JAddObjectToObject(J*constobject,constchar*constname) +{ +if(object==NULL){ +returnNULL; +} + +J*object_item=JCreateObject(); +if(add_item_to_object(object,name,object_item,false)){ +returnobject_item; +} + +JDelete(object_item); +returnNULL; +} + +N_CJSON_PUBLIC(J*)JAddArrayToObject(J*constobject,constchar*constname) +{ +if(object==NULL){ +returnNULL; +} + +J*array=JCreateArray(); +if(add_item_to_object(object,name,array,false)){ +returnarray; +} + +JDelete(array); +returnNULL; +} + +N_CJSON_PUBLIC(J*)JDetachItemViaPointer(J*parent,J*constitem) +{ +if(parent==NULL||item==NULL){ +returnNULL; +} + +if(item->prev!=NULL){ +/*notthefirstelement*/ +item->prev->next=item->next; +} +if(item->next!=NULL){ +/*notthelastelement*/ +item->next->prev=item->prev; +} + +if(item==parent->child){ +/*firstelement*/ +parent->child=item->next; +} +/*makesurethedetacheditemdoesn'tpointanywhereanymore*/ +item->prev=NULL; +item->next=NULL; + +returnitem; +} + +N_CJSON_PUBLIC(J*)JDetachItemFromArray(J*array,intwhich) +{ +if(array==NULL){ +returnNULL; +} +if(which<0){ +returnNULL; +} + +returnJDetachItemViaPointer(array,get_array_item(array,(size_t)which)); +} + +N_CJSON_PUBLIC(void)JDeleteItemFromArray(J*array,intwhich) +{ +if(array==NULL){ +return; +} +JDelete(JDetachItemFromArray(array,which)); +} + +N_CJSON_PUBLIC(J*)JDetachItemFromObject(J*object,constchar*string) +{ +if(object==NULL){ +returnNULL; +} + +J*to_detach=JGetObjectItem(object,string); + +returnJDetachItemViaPointer(object,to_detach); +} + +N_CJSON_PUBLIC(J*)JDetachItemFromObjectCaseSensitive(J*object,constchar*string) +{ +if(object==NULL){ +returnNULL; +} + +J*to_detach=JGetObjectItemCaseSensitive(object,string); + +returnJDetachItemViaPointer(object,to_detach); +} + +N_CJSON_PUBLIC(void)JDeleteItemFromObject(J*object,constchar*string) +{ +if(object==NULL){ +return; +} +JDelete(JDetachItemFromObject(object,string)); +} + +N_CJSON_PUBLIC(void)JDeleteItemFromObjectCaseSensitive(J*object,constchar*string) +{ +if(object==NULL){ +return; +} +JDelete(JDetachItemFromObjectCaseSensitive(object,string)); +} + +/*Replacearray/objectitemswithnewones.*/ +N_CJSON_PUBLIC(void)JInsertItemInArray(J*array,intwhich,J*newitem) +{ +if(array==NULL||newitem==NULL){ +return; +} + +J*after_inserted=NULL; + +if(which<0){ +return; +} + +after_inserted=get_array_item(array,(size_t)which); +if(after_inserted==NULL){ +add_item_to_array(array,newitem); +return; +} + +newitem->next=after_inserted; +newitem->prev=after_inserted->prev; +after_inserted->prev=newitem; +if(after_inserted==array->child){ +array->child=newitem; +}else{ +newitem->prev->next=newitem; +} +} + +N_CJSON_PUBLIC(Jbool)JReplaceItemViaPointer(J*constparent,J*constitem,J*replacement) +{ +if(parent==NULL||replacement==NULL||item==NULL){ +returnfalse; +} + +if(replacement==item){ +returntrue; +} + +replacement->next=item->next; +replacement->prev=item->prev; + +if(replacement->next!=NULL){ +replacement->next->prev=replacement; +} +if(replacement->prev!=NULL){ +replacement->prev->next=replacement; +} +if(parent->child==item){ +parent->child=replacement; +} + +item->next=NULL; +item->prev=NULL; +JDelete(item); + +returntrue; +} + +N_CJSON_PUBLIC(void)JReplaceItemInArray(J*array,intwhich,J*newitem) +{ +if(array==NULL||newitem==NULL){ +return; +} + +if(which<0){ +return; +} + +JReplaceItemViaPointer(array,get_array_item(array,(size_t)which),newitem); +} + +staticJboolreplace_item_in_object(J*object,constchar*string,J*replacement,Jboolcase_sensitive) +{ +if(object==NULL||replacement==NULL||string==NULL){ +returnfalse; +} + +/*replacethenameinthereplacement*/ +if(!(replacement->type&JStringIsConst)&&(replacement->string!=NULL)){ +_Free(replacement->string); +} +replacement->string=(char*)Jstrdup((constunsignedchar*)string); +replacement->type&=~JStringIsConst; + +JReplaceItemViaPointer(object,get_object_item(object,string,case_sensitive),replacement); + +returntrue; +} + +N_CJSON_PUBLIC(void)JReplaceItemInObject(J*object,constchar*string,J*newitem) +{ +if(object==NULL||newitem==NULL){ +return; +} +replace_item_in_object(object,string,newitem,false); +} + +N_CJSON_PUBLIC(void)JReplaceItemInObjectCaseSensitive(J*object,constchar*string,J*newitem) +{ +if(object==NULL||newitem==NULL){ +return; +} +replace_item_in_object(object,string,newitem,true); +} + +N_CJSON_PUBLIC(J*)JCreateTrue(void) +{ +J*item=JNew_Item(); +if(item){ +item->type=JTrue; +} +returnitem; +} + +N_CJSON_PUBLIC(J*)JCreateFalse(void) +{ +J*item=JNew_Item(); +if(item){ +item->type=JFalse; +} +returnitem; +} + +N_CJSON_PUBLIC(J*)JCreateBool(Jboolb) +{ +J*item=JNew_Item(); +if(item){ +item->type=b?JTrue:JFalse; +} +returnitem; +} + +N_CJSON_PUBLIC(J*)JCreateNumber(JNUMBERnum) +{ +J*item=JNew_Item(); +if(item){ +item->type=JNumber; +item->valuenumber=num; + +//Saturatevalueintinthecaseofoverflow. +if(num>=JINTEGER_MAX){ +item->valueint=JINTEGER_MAX; +}elseif(num<=JINTEGER_MIN){ +item->valueint=JINTEGER_MIN; +}else{ +item->valueint=(JINTEGER)num; +} +} +returnitem; +} + +N_CJSON_PUBLIC(J*)JCreateInteger(JINTEGERinteger) +{ +J*item=JNew_Item(); +if(item){ +item->type=JNumber; +item->valuenumber=(JNUMBER)integer; +item->valueint=integer; +} +returnitem; +} + +N_CJSON_PUBLIC(J*)JCreateString(constchar*string) +{ +J*item=JNew_Item(); +if(item){ +item->type=JString; +item->valuestring=(char*)Jstrdup((constunsignedchar*)string); +if(!item->valuestring){ +JDelete(item); +returnNULL; +} +} +returnitem; +} + +N_CJSON_PUBLIC(J*)JCreateStringValue(constchar*string) +{ +J*item=JNew_Item(); +if(item!=NULL){ +item->type=JString; +item->valuestring=(char*)cast_away_const(string); +} +returnitem; +} + +N_CJSON_PUBLIC(J*)JCreateStringReference(constchar*string) +{ +J*item=JNew_Item(); +if(item!=NULL){ +item->type=JString|JIsReference; +item->valuestring=(char*)cast_away_const(string); +} +returnitem; +} + +N_CJSON_PUBLIC(J*)JCreateObjectReference(constJ*child) +{ +if(child==NULL){ +returnNULL; +} +J*item=JNew_Item(); +if(item!=NULL){ +item->type=JObject|JIsReference; +item->child=(J*)cast_away_const(child); +} +returnitem; +} + +N_CJSON_PUBLIC(J*)JCreateArrayReference(constJ*child) +{ +if(child==NULL){ +returnNULL; +} +J*item=JNew_Item(); +if(item!=NULL){ +item->type=JArray|JIsReference; +item->child=(J*)cast_away_const(child); +} +returnitem; +} + +N_CJSON_PUBLIC(J*)JCreateRaw(constchar*raw) +{ +J*item=JNew_Item(); +if(item){ +item->type=JRaw; +item->valuestring=(char*)Jstrdup((constunsignedchar*)raw); +if(!item->valuestring){ +JDelete(item); +returnNULL; +} +} +returnitem; +} + +N_CJSON_PUBLIC(J*)JCreateArray(void) +{ +J*item=JNew_Item(); +if(item){ +item->type=JArray; +} +returnitem; +} + +N_CJSON_PUBLIC(J*)JCreateObject(void) +{ +J*item=JNew_Item(); +if(item){ +item->type=JObject; +} +returnitem; +} + +/*CreateArrays:*/ +N_CJSON_PUBLIC(J*)JCreateIntArray(constlongint*numbers,intcount) +{ +size_ti=0; +J*n=NULL; +J*p=NULL; +J*a=NULL; + +if((count<0)||(numbers==NULL)){ +returnNULL; +} + +a=JCreateArray(); +for(i=0;a&&(i<(size_t)count);i++){ +n=JCreateNumber(numbers[i]); +if(!n){ +JDelete(a); +returnNULL; +} +if(!i){ +a->child=n; +}else{ +suffix_object(p,n); +} +p=n; +} + +returna; +} + +N_CJSON_PUBLIC(J*)JCreateNumberArray(constJNUMBER*numbers,intcount) +{ +size_ti=0; +J*n=NULL; +J*p=NULL; +J*a=NULL; + +if((count<0)||(numbers==NULL)){ +returnNULL; +} + +a=JCreateArray(); + +for(i=0;a&&(i<(size_t)count);i++){ +n=JCreateNumber(numbers[i]); +if(!n){ +JDelete(a); +returnNULL; +} +if(!i){ +a->child=n; +}else{ +suffix_object(p,n); +} +p=n; +} + +returna; +} + +N_CJSON_PUBLIC(J*)JCreateStringArray(constchar**strings,intcount) +{ +size_ti=0; +J*n=NULL; +J*p=NULL; +J*a=NULL; + +if((count<0)||(strings==NULL)){ +returnNULL; +} + +a=JCreateArray(); + +for(i=0;a&&(i<(size_t)count);i++){ +n=JCreateString(strings[i]); +if(!n){ +JDelete(a); +returnNULL; +} +if(!i){ +a->child=n; +}else{ +suffix_object(p,n); +} +p=n; +} + +returna; +} + +/*Duplication*/ +N_CJSON_PUBLIC(J*)JDuplicate(constJ*item,Jboolrecurse) +{ +J*newitem=NULL; +J*child=NULL; +J*next=NULL; +J*newchild=NULL; + +/*Bailonbadptr*/ +if(!item){ +gotofail; +} +/*Createnewitem*/ +newitem=JNew_Item(); +if(!newitem){ +gotofail; +} +/*Copyoverallvars*/ +newitem->type=item->type&(~JIsReference); +newitem->valueint=item->valueint; +newitem->valuenumber=item->valuenumber; +if(item->valuestring){ +newitem->valuestring=(char*)Jstrdup((unsignedchar*)item->valuestring); +if(!newitem->valuestring){ +gotofail; +} +} +if(item->string){ +newitem->string=(item->type&JStringIsConst)?item->string:(char*)Jstrdup((unsignedchar*)item->string); +if(!newitem->string){ +gotofail; +} +} +/*Ifnon-recursive,thenwe'redone!*/ +if(!recurse){ +returnnewitem; +} +/*Walkthe->nextchainforthechild.*/ +child=item->child; +while(child!=NULL){ +newchild=JDuplicate(child,true);/*Duplicate(withrecurse)eachiteminthe->nextchain*/ +if(!newchild){ +gotofail; +} +if(next!=NULL){ +/*Ifnewitem->childalreadyset,thencrosswire->prevand->nextandmoveon*/ +next->next=newchild; +newchild->prev=next; +next=newchild; +}else{ +/*Setnewitem->childandmovetoit*/ +newitem->child=newchild; +next=newchild; +} +child=child->next; +} + +returnnewitem; + +fail: +if(newitem!=NULL){ +JDelete(newitem); +} + +returnNULL; +} + +N_CJSON_PUBLIC(void)JMinify(char*json) +{ +unsignedchar*into=(unsignedchar*)json; + +if(json==NULL){ +return; +} + +while(*json){ +if(*json==''){ +json++; +}elseif(*json=='\t'){ +/*Whitespacecharacters.*/ +json++; +}elseif(*json=='\r'){ +json++; +}elseif(*json=='\n'){ +json++; +}elseif((*json=='/')&&(json[1]=='/')){ +/*double-slashcomments,toendofline.*/ +while(*json&&(*json!='\n')){ +json++; +} +}elseif((*json=='/')&&(json[1]=='*')){ +/*multilinecomments.*/ +while(*json&&!((*json=='*')&&(json[1]=='/'))){ +json++; +} +json+=2; +}elseif(*json=='\"'){ +/*stringliterals,whichare\"sensitive.*/ +*into++=(unsignedchar)*json++; +while(*json&&(*json!='\"')){ +if(*json=='\\'){ +*into++=(unsignedchar)*json++; +} +*into++=(unsignedchar)*json++; +} +*into++=(unsignedchar)*json++; +}else{ +/*Allothercharacters.*/ +*into++=(unsignedchar)*json++; +} +} + +/*andnull-terminate.*/ +*into='\0'; +} + +N_CJSON_PUBLIC(Jbool)JIsInvalid(constJ*constitem) +{ +if(item==NULL){ +returnfalse; +} +return(item->type&0xFF)==JInvalid; +} + +N_CJSON_PUBLIC(Jbool)JIsFalse(constJ*constitem) +{ +if(item==NULL){ +returnfalse; +} +return(item->type&0xFF)==JFalse; +} + +N_CJSON_PUBLIC(Jbool)JIsTrue(constJ*constitem) +{ +if(item==NULL){ +returnfalse; +} +return(item->type&0xff)==JTrue; +} + + +N_CJSON_PUBLIC(Jbool)JIsBool(constJ*constitem) +{ +if(item==NULL){ +returnfalse; +} +return(item->type&(JTrue|JFalse))!=0; +} +N_CJSON_PUBLIC(Jbool)JIsNull(constJ*constitem) +{ +if(item==NULL){ +returnfalse; +} +return(item->type&0xFF)==JNULL; +} + +N_CJSON_PUBLIC(Jbool)JIsNumber(constJ*constitem) +{ +if(item==NULL){ +returnfalse; +} +return(item->type&0xFF)==JNumber; +} + +N_CJSON_PUBLIC(Jbool)JIsString(constJ*constitem) +{ +if(item==NULL){ +returnfalse; +} +return(item->type&0xFF)==JString; +} + +N_CJSON_PUBLIC(Jbool)JIsArray(constJ*constitem) +{ +if(item==NULL){ +returnfalse; +} +return(item->type&0xFF)==JArray; +} + +N_CJSON_PUBLIC(Jbool)JIsObject(constJ*constitem) +{ +if(item==NULL){ +returnfalse; +} +return(item->type&0xFF)==JObject; +} + +N_CJSON_PUBLIC(Jbool)JIsRaw(constJ*constitem) +{ +if(item==NULL){ +returnfalse; +} +return(item->type&0xFF)==JRaw; +} + +N_CJSON_PUBLIC(Jbool)JCompare(constJ*consta,constJ*constb,constJboolcase_sensitive) +{ +if((a==NULL)||(b==NULL)||((a->type&0xFF)!=(b->type&0xFF))||JIsInvalid(a)){ +returnfalse; +} + +/*checkiftypeisvalid*/ +switch(a->type&0xFF){ +caseJFalse: +caseJTrue: +caseJNULL: +caseJNumber: +caseJString: +caseJRaw: +caseJArray: +caseJObject: +break; + +default: +returnfalse; +} + +/*identicalobjectsareequal*/ +if(a==b){ +returntrue; +} + +switch(a->type&0xFF){ +/*inthesecasesandequaltypeisenough*/ +caseJFalse: +caseJTrue: +caseJNULL: +returntrue; + +caseJNumber: +if(a->valuenumber==b->valuenumber){ +returntrue; +} +returnfalse; + +caseJString: +caseJRaw: +if((a->valuestring==NULL)||(b->valuestring==NULL)){ +returnfalse; +} +if(strcmp(a->valuestring,b->valuestring)==0){ +returntrue; +} + +returnfalse; + +caseJArray:{ +J*a_element=a->child; +J*b_element=b->child; + +for(;(a_element!=NULL)&&(b_element!=NULL);){ +if(!JCompare(a_element,b_element,case_sensitive)){ +returnfalse; +} + +a_element=a_element->next; +b_element=b_element->next; +} + +/*oneofthearraysislongerthantheother*/ +if(a_element!=b_element){ +returnfalse; +} + +returntrue; +} + +caseJObject:{ +J*a_element=NULL; +J*b_element=NULL; +JArrayForEach(a_element,a){ +/*TODOThishasO(n^2)runtime,whichishorrible!*/ +b_element=get_object_item(b,a_element->string,case_sensitive); +if(b_element==NULL){ +returnfalse; +} + +if(!JCompare(a_element,b_element,case_sensitive)){ +returnfalse; +} +} + +/*doingthistwice,onceonaandbtopreventtruecomparisonifasubsetofb +*TODO:Dothistheproperway,thisisjustafixfornow*/ +JArrayForEach(b_element,b){ +a_element=get_object_item(a,b_element->string,case_sensitive); +if(a_element==NULL){ +returnfalse; +} + +if(!JCompare(b_element,a_element,case_sensitive)){ +returnfalse; +} +} + +returntrue; +} + +default: +returnfalse; +} +} + + + + diff --git a/doxygen/xml/n__cjson_8h.xml b/doxygen/xml/n__cjson_8h.xml new file mode 100644 index 00000000..cb0d8d5e --- /dev/null +++ b/doxygen/xml/n__cjson_8h.xml @@ -0,0 +1,2356 @@ + + + + n_cjson.h + stddef.h + /home/runner/work/note-c/note-c/note.h + + + + + + + + + + + + + + + + + + + + + + + + J + JHooks + + + N_CJSON_VERSION_MAJOR + 1 + + + + + + + + + + N_CJSON_VERSION_MINOR + 7 + + + + + + + + + + N_CJSON_VERSION_PATCH + 7 + + + + + + + + + + JInvalid + (0) + + + + + + + + + + JFalse + (1 << 0) + + + + + + + + + + JTrue + (1 << 1) + + + + + + + + + + JNULL + (1 << 2) + + + + + + + + + + JNumber + (1 << 3) + + + + + + + + + + JString + (1 << 4) + + + + + + + + + + JArray + (1 << 5) + + + + + + + + + + JObject + (1 << 6) + + + + + + + + + + JRaw + (1 << 7) /* raw json */ + + + + + + + + + + JIsReference + 256 + + + + + + + + + + JStringIsConst + 512 + + + + + + + + + + N_CJSON_PUBLIC + type + type + + + + + + + + + + N_CJSON_NESTING_LIMIT + 100 + +The maximum nesting level for JSON objects before a parsing error. + + +Default value: 100 +For example, if you have a JSON object that contains multiple, nested objects like this { + "x": + { + "x:" + { + . + . + . + } + } +} + And the nesting level exceeds N_CJSON_NESTING_LIMIT, then calling JParse on a J * representing this object will return an error (NULL). +This exists to prevent the cJSON parser from causing a stack overflow. The user may override this macro at build time (e.g. -DN_CJSON_NESTING_LIMIT=200) to increase or reduce the limit. + + + + + + + JGetObjectItems + JGetArraySize + + + + + + + + + + JConvertToJSONString + JPrintUnformatted + + + + + + + + + + JConvertFromJSONString + JParse + + + + + + + + + + JSetIntValue + object + number + ((object) ? (object)->valueint = (object)->valuenumber = (number) : (number)) + + + + + + + + + + JSetNumberValue + object + number + ((object != NULL) ? JSetNumberHelper(object, (JNUMBER)number) : (number)) + + + + + + + + + + JArrayForEach + element + array + for(element = (array != NULL) ? (array)->child : NULL; element != NULL; element = element->next) + + + + + + + + + + JObjectForEach + element + array + JArrayForEach(element, array) + + + + + + + + + + + + struct J + typedef struct J J + + J + +The core JSON object type used by note-c. + + +When using note-c, treat this struct as opaque. You should never have to work directly with its members. + + + + + + + struct JHooks + typedef struct JHooks JHooks + + JHooks + + + + + + + + + + int + typedef int Jbool + + Jbool + + + + + + + + + + + + const char * + const char* JVersion + (void) + JVersion + + void + + + + + + + + + + + void + void JInitHooks + (JHooks *hooks) + JInitHooks + + JHooks * + hooks + + + + + + + + + + + J * + J* JParse + (const char *value) + JParse + + const char * + value + + +Parse the passed in C-string as JSON and return a J object representing it. + + + + +value + + +The JSON object as a C-string. + + + +A J object or NULL on error (e.g. the string was invalid JSON). + + + + + + + + + J * + J* JParseWithOpts + (const char *value, const char **return_parse_end, Jbool require_null_terminated) + JParseWithOpts + + const char * + value + + + const char ** + return_parse_end + + + Jbool + require_null_terminated + + + + + + + + + + + char * + char* JPrint + (const J *item) + JPrint + + const J * + item + + + + + + + + + + + char * + char* JPrintUnformatted + (const J *item) + JPrintUnformatted + + const J * + item + + +Get the unformatted string representation of a J object. + + +The string returned by this function is dynamically allocated and MUST be freed by the caller with JFree. Unformatted means that the minimum JSON string is produced, without any additional whitespace. + + +item + + +The JSON object to get the unformatted string representation of. + + + +The string or NULL on error. + + + + + + + + + char * + char* JPrintUnformattedOmitEmpty + (const J *item) + JPrintUnformattedOmitEmpty + + const J * + item + + + + + + + + + + + char * + char* JPrintBuffered + (const J *item, int prebuffer, Jbool fmt) + JPrintBuffered + + const J * + item + + + int + prebuffer + + + Jbool + fmt + + + + + + + + + + + Jbool + Jbool JPrintPreallocated + (J *item, char *buffer, const int length, const Jbool format) + JPrintPreallocated + + J * + item + + + char * + buffer + + + const int + length + + + const Jbool + format + + + + + + + + + + + Jbool + Jbool JPrintPreallocatedOmitEmpty + (J *item, char *buffer, const int length, const Jbool format) + JPrintPreallocatedOmitEmpty + + J * + item + + + char * + buffer + + + const int + length + + + const Jbool + format + + + + + + + + + + + void + void JDelete + (J *c) + JDelete + + J * + c + item + + +Free a J object. + + + + +item + + +A pointer to the object. + + + + + + + + + + + int + int JGetArraySize + (const J *array) + JGetArraySize + + const J * + array + + + + + + + + + + + J * + J* JGetArrayItem + (const J *array, int index) + JGetArrayItem + + const J * + array + + + int + index + + + + + + + + + + + J * + J* JGetObjectItem + (const J *const object, const char *const string) + JGetObjectItem + + const J *const + object + + + const char *const + string + + + + + + + + + + + J * + J* JGetObjectItemCaseSensitive + (const J *const object, const char *const string) + JGetObjectItemCaseSensitive + + const J *const + object + + + const char *const + string + + + + + + + + + + + Jbool + Jbool JHasObjectItem + (const J *object, const char *string) + JHasObjectItem + + const J * + object + + + const char * + string + + + + + + + + + + + const char * + const char* JGetErrorPtr + (void) + JGetErrorPtr + + void + + + + + + + + + + + char * + char* JGetStringValue + (J *item) + JGetStringValue + + J * + item + + + + + + + + + + + Jbool + Jbool JIsInvalid + (const J *const item) + JIsInvalid + + const J *const + item + + + + + + + + + + + Jbool + Jbool JIsFalse + (const J *const item) + JIsFalse + + const J *const + item + + + + + + + + + + + Jbool + Jbool JIsTrue + (const J *const item) + JIsTrue + + const J *const + item + + + + + + + + + + + Jbool + Jbool JIsBool + (const J *const item) + JIsBool + + const J *const + item + + + + + + + + + + + Jbool + Jbool JIsNull + (const J *const item) + JIsNull + + const J *const + item + + + + + + + + + + + Jbool + Jbool JIsNumber + (const J *const item) + JIsNumber + + const J *const + item + + + + + + + + + + + Jbool + Jbool JIsString + (const J *const item) + JIsString + + const J *const + item + + + + + + + + + + + Jbool + Jbool JIsArray + (const J *const item) + JIsArray + + const J *const + item + + + + + + + + + + + Jbool + Jbool JIsObject + (const J *const item) + JIsObject + + const J *const + item + + + + + + + + + + + Jbool + Jbool JIsRaw + (const J *const item) + JIsRaw + + const J *const + item + + + + + + + + + + + J * + J* JCreateTrue + (void) + JCreateTrue + + void + + + + + + + + + + + J * + J* JCreateFalse + (void) + JCreateFalse + + void + + + + + + + + + + + J * + J* JCreateBool + (Jbool boolean) + JCreateBool + + Jbool + boolean + + + + + + + + + + + J * + J* JCreateNumber + (JNUMBER num) + JCreateNumber + + JNUMBER + num + + + + + + + + + + + J * + J* JCreateInteger + (JINTEGER integer) + JCreateInteger + + JINTEGER + integer + + + + + + + + + + + J * + J* JCreateString + (const char *string) + JCreateString + + const char * + string + + + + + + + + + + + J * + J* JCreateRaw + (const char *raw) + JCreateRaw + + const char * + raw + + + + + + + + + + + J * + J* JCreateArray + (void) + JCreateArray + + void + + + + + + + + + + + J * + J* JCreateObject + (void) + JCreateObject + + void + + +Create a new J object. + + +To free the object, use JDelete. +A pointer to the newly-created object. + + + + + + + + + J * + J* JCreateStringValue + (const char *string) + JCreateStringValue + + const char * + string + + + + + + + + + + + J * + J* JCreateStringReference + (const char *string) + JCreateStringReference + + const char * + string + + + + + + + + + + + J * + J* JCreateObjectReference + (const J *child) + JCreateObjectReference + + const J * + child + + + + + + + + + + + J * + J* JCreateArrayReference + (const J *child) + JCreateArrayReference + + const J * + child + + + + + + + + + + + J * + J* JCreateIntArray + (const long int *numbers, int count) + JCreateIntArray + + const long int * + numbers + + + int + count + + + + + + + + + + + J * + J* JCreateNumberArray + (const JNUMBER *numbers, int count) + JCreateNumberArray + + const JNUMBER * + numbers + + + int + count + + + + + + + + + + + J * + J* JCreateStringArray + (const char **strings, int count) + JCreateStringArray + + const char ** + strings + + + int + count + + + + + + + + + + + void + void JAddItemToArray + (J *array, J *item) + JAddItemToArray + + J * + array + + + J * + item + + + + + + + + + + + void + void JAddItemToObject + (J *object, const char *string, J *item) + JAddItemToObject + + J * + object + + + const char * + string + + + J * + item + + + + + + + + + + + void + void JAddItemToObjectCS + (J *object, const char *string, J *item) + JAddItemToObjectCS + + J * + object + + + const char * + string + + + J * + item + + + + + + + + + + + void + void JAddItemReferenceToArray + (J *array, J *item) + JAddItemReferenceToArray + + J * + array + + + J * + item + + + + + + + + + + + void + void JAddItemReferenceToObject + (J *object, const char *string, J *item) + JAddItemReferenceToObject + + J * + object + + + const char * + string + + + J * + item + + + + + + + + + + + J * + J* JDetachItemViaPointer + (J *parent, J *const item) + JDetachItemViaPointer + + J * + parent + + + J *const + item + + + + + + + + + + + J * + J* JDetachItemFromArray + (J *array, int which) + JDetachItemFromArray + + J * + array + + + int + which + + + + + + + + + + + void + void JDeleteItemFromArray + (J *array, int which) + JDeleteItemFromArray + + J * + array + + + int + which + + + + + + + + + + + J * + J* JDetachItemFromObject + (J *object, const char *string) + JDetachItemFromObject + + J * + object + + + const char * + string + + + + + + + + + + + J * + J* JDetachItemFromObjectCaseSensitive + (J *object, const char *string) + JDetachItemFromObjectCaseSensitive + + J * + object + + + const char * + string + + + + + + + + + + + void + void JDeleteItemFromObject + (J *object, const char *string) + JDeleteItemFromObject + + J * + object + + + const char * + string + + + + + + + + + + + void + void JDeleteItemFromObjectCaseSensitive + (J *object, const char *string) + JDeleteItemFromObjectCaseSensitive + + J * + object + + + const char * + string + + + + + + + + + + + void + void JInsertItemInArray + (J *array, int which, J *newitem) + JInsertItemInArray + + J * + array + + + int + which + + + J * + newitem + + + + + + + + + + + Jbool + Jbool JReplaceItemViaPointer + (J *const parent, J *const item, J *replacement) + JReplaceItemViaPointer + + J *const + parent + + + J *const + item + + + J * + replacement + + + + + + + + + + + void + void JReplaceItemInArray + (J *array, int which, J *newitem) + JReplaceItemInArray + + J * + array + + + int + which + + + J * + newitem + + + + + + + + + + + void + void JReplaceItemInObject + (J *object, const char *string, J *newitem) + JReplaceItemInObject + + J * + object + + + const char * + string + + + J * + newitem + + + + + + + + + + + void + void JReplaceItemInObjectCaseSensitive + (J *object, const char *string, J *newitem) + JReplaceItemInObjectCaseSensitive + + J * + object + + + const char * + string + + + J * + newitem + + + + + + + + + + + J * + J* JDuplicate + (const J *item, Jbool recurse) + JDuplicate + + const J * + item + + + Jbool + recurse + + + + + + + + + + + Jbool + Jbool JCompare + (const J *const a, const J *const b, const Jbool case_sensitive) + JCompare + + const J *const + a + + + const J *const + b + + + const Jbool + case_sensitive + + + + + + + + + + + void + void JMinify + (char *json) + JMinify + + char * + json + + + + + + + + + + + J * + J* JAddTrueToObject + (J *const object, const char *const name) + JAddTrueToObject + + J *const + object + + + const char *const + name + + + + + + + + + + + J * + J* JAddFalseToObject + (J *const object, const char *const name) + JAddFalseToObject + + J *const + object + + + const char *const + name + + + + + + + + + + + J * + J* JAddBoolToObject + (J *const object, const char *const name, const Jbool boolean) + JAddBoolToObject + + J *const + object + + + const char *const + name + + + const Jbool + boolean + + +Add a boolean field to a J object. + + + + +object + + +The object to add the field to. + + + + +name + + +The name of the field. + + + + +boolean + + +The value of the field. + + + +A pointer to the newly-added boolean field or NULL on error. + + + + + + + + + J * + J* JAddNumberToObject + (J *const object, const char *const name, const JNUMBER number) + JAddNumberToObject + + J *const + object + + + const char *const + name + + + const JNUMBER + number + + +Add a number field to a J object. + + + + +object + + +The object to add the field to. + + + + +name + + +The name of the field. + + + + +number + + +The value of the field. + + + +A pointer to the newly-added number field or NULL on error. + + + + + + + + + J * + J* JAddIntToObject + (J *const object, const char *const name, const JINTEGER integer) + JAddIntToObject + + J *const + object + + + const char *const + name + + + const JINTEGER + integer + + + + + + + + + + + J * + J* JAddStringToObject + (J *const object, const char *const name, const char *const string) + JAddStringToObject + + J *const + object + + + const char *const + name + + + const char *const + string + + +Add a string field to a J object. + + + + +object + + +The object to add the field to. + + + + +name + + +The name of the field. + + + + +string + + +The value of the field. + + + +A pointer to the newly-added string field or NULL on error. + + + + + + + + + J * + J* JAddRawToObject + (J *const object, const char *const name, const char *const raw) + JAddRawToObject + + J *const + object + + + const char *const + name + + + const char *const + raw + + + + + + + + + + + J * + J* JAddObjectToObject + (J *const object, const char *const name) + JAddObjectToObject + + J *const + object + + + const char *const + name + + +Add an object field to another J object. + + + + +object + + +The object to add the field to. + + + + +name + + +The name of the field. + + + +A pointer to the newly-added object field or NULL on error. + + + + + + + + + J * + J* JAddArrayToObject + (J *const object, const char *const name) + JAddArrayToObject + + J *const + object + + + const char *const + name + + +Add an array field to a J object. + + + + +object + + +The object to add the field to. + + + + +name + + +The name of the field. + + + +A pointer to the newly-added array field or NULL on error. + + + + + + + + + JNUMBER + JNUMBER JSetNumberHelper + (J *object, JNUMBER number) + JSetNumberHelper + + J * + object + + + JNUMBER + number + + + + + + + + + + + void * + void* JMalloc + (size_t size) + JMalloc + + size_t + size + + +Dynamically allocate a block of memory of the given size. + + +This is simply a wrapper around the memory allocation function provided by the user via NoteSetFn. + + +size + + +The number of bytes to allocate. + + + +A pointer to the first byte of the allocated memory or NULL on error. + + + + + + + + + void + void JFree + (void *object) + JFree + + void * + object + p + + +Free a block of dynamically allocated memory. + + +This is simply a wrapper around the memory free function provided by the user via NoteSetFn. + + +p + + +A pointer to the block of memory to free. + + + + + + + + + + + + + +Written by Ray Ozzie and Blues Inc. team. +Portions Copyright (c) 2019 Blues Inc. MIT License. Use of this source code is governed by licenses granted by the copyright holder including that found in the LICENSE file. +MODIFIED for use in notecard primarily by altering default memory allocator and by renaming the functions so that they won't conflict with a developer's own decision to incorporate the actual production cJSON into their own app. In no way shall this interfere with a production cJSON. +Renaming was done as follows: CJSON_ -> N_CJSON_ cJSON_ -> J cJSON -> J +Portions Copyright (c) 2009-2017 Dave Gamble and cJSON contributors +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 i 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. + + + +#ifndefJ_h +#defineJ_h + +#ifdef__cplusplus +extern"C" +{ +#endif + +/*projectversion*/ +#defineN_CJSON_VERSION_MAJOR1 +#defineN_CJSON_VERSION_MINOR7 +#defineN_CJSON_VERSION_PATCH7 + +#include<stddef.h> + +/*JTypes:*/ +#defineJInvalid(0) +#defineJFalse(1<<0) +#defineJTrue(1<<1) +#defineJNULL(1<<2) +#defineJNumber(1<<3) +#defineJString(1<<4) +#defineJArray(1<<5) +#defineJObject(1<<6) +#defineJRaw(1<<7)/*rawjson*/ + +#defineJIsReference256 +#defineJStringIsConst512 + +typedefstructJ{ +/*next/prevallowyoutowalkarray/objectchains.Alternatively,useGetArraySize/GetArrayItem/GetObjectItem*/ +structJ*next; +structJ*prev; +/*Anarrayorobjectitemwillhaveachildpointerpointingtoachainoftheitemsinthearray/object.*/ +structJ*child; + +/*Thetypeoftheitem,asabove.*/ +inttype; + +/*Theitem'sstring,iftype==JStringandtype==JRaw*/ +char*valuestring; +/*writingtovalueintisDEPRECATED,useJSetNumberValueinstead*/ +JINTEGERvalueint; +/*Theitem'snumber,iftype==JNumber*/ +JNUMBERvaluenumber; +/*Theitem'snamestring,ifthisitemisthechildof,orisinthelistofsubitemsofanobject.*/ +char*string; +}J; + +typedefstructJHooks{ +void*(*malloc_fn)(size_tsz); +void(*free_fn)(void*ptr); +}JHooks; + +typedefintJbool; + +#if!defined(__WINDOWS__)&&(defined(WIN32)||defined(WIN64)||defined(_MSC_VER)||defined(_WIN32)) +#define__WINDOWS__ +#endif +#ifdef__WINDOWS__ + +/*Whencompilingforwindows,wespecifyaspecificcallingconventiontoavoidissueswherewearebeingcalledfromaprojectwithadifferentdefaultcallingconvention.Forwindowsyouhave2defineoptions: + +N_CJSON_HIDE_SYMBOLS-Definethisinthecasewhereyoudon'twanttoeverdllexportsymbols +N_CJSON_EXPORT_SYMBOLS-Definethisonlibrarybuildwhenyouwanttodllexportsymbols(default) +N_CJSON_IMPORT_SYMBOLS-Definethisifyouwanttodllimportsymbol + +For*nixbuildsthatsupportvisibilityattribute,youcandefinesimilarbehaviorby + +settingdefaultvisibilitytohiddenbyadding +-fvisibility=hidden(forgcc) +or +-xldscope=hidden(forsuncc) +toCFLAGS + +thenusingtheN_CJSON_API_VISIBILITYflagto"export"thesamesymbolsthewayN_CJSON_EXPORT_SYMBOLSdoes + +*/ + +/*exportsymbolsbydefault,thisisnecessaryforcopypastingtheCandheaderfile*/ +#if!defined(N_CJSON_HIDE_SYMBOLS)&&!defined(N_CJSON_IMPORT_SYMBOLS)&&!defined(N_CJSON_EXPORT_SYMBOLS) +#defineN_CJSON_EXPORT_SYMBOLS +#endif + +#ifdefined(N_CJSON_HIDE_SYMBOLS) +#defineN_CJSON_PUBLIC(type)type__stdcall +#elifdefined(N_CJSON_EXPORT_SYMBOLS) +#defineN_CJSON_PUBLIC(type)__declspec(dllexport)type__stdcall +#elifdefined(N_CJSON_IMPORT_SYMBOLS) +#defineN_CJSON_PUBLIC(type)__declspec(dllimport)type__stdcall +#endif +#else/*!WIN32*/ +#if(defined(__GNUC__)||defined(__SUNPRO_CC)||defined(__SUNPRO_C))&&defined(N_CJSON_API_VISIBILITY) +#defineN_CJSON_PUBLIC(type)__attribute__((visibility("default")))type +#else +#defineN_CJSON_PUBLIC(type)type +#endif +#endif + +#ifndefN_CJSON_NESTING_LIMIT +#defineN_CJSON_NESTING_LIMIT100 +#endif + +/*returnstheversionofJasastring*/ +N_CJSON_PUBLIC(constchar*)JVersion(void); + +/*Supplymalloc,reallocandfreefunctionstoJ*/ +N_CJSON_PUBLIC(void)JInitHooks(JHooks*hooks); + +/*MemoryManagement:thecallerisalwaysresponsibletofreetheresultsfromallvariantsofJParse(withJDelete)andJPrint(withstdlibfree,JHooks.free_fn,orJFreeasappropriate).TheexceptionisJPrintPreallocated,wherethecallerhasfullresponsibilityofthebuffer.*/ +/*SupplyablockofJSON,andthisreturnsaJobjectyoucaninterrogate.*/ +N_CJSON_PUBLIC(J*)JParse(constchar*value); +/*ParseWithOptsallowsyoutorequire(andcheck)thattheJSONisnullterminated,andtoretrievethepointertothefinalbyteparsed.*/ +/*Ifyousupplyaptrinreturn_parse_endandparsingfails,thenreturn_parse_endwillcontainapointertotheerrorsowillmatchJGetErrorPtr().*/ +N_CJSON_PUBLIC(J*)JParseWithOpts(constchar*value,constchar**return_parse_end,Jboolrequire_null_terminated); + +/*RenderaJentitytotextfortransfer/storage.*/ +N_CJSON_PUBLIC(char*)JPrint(constJ*item); +/*RenderaJentitytotextfortransfer/storagewithoutanyformatting.*/ +N_CJSON_PUBLIC(char*)JPrintUnformatted(constJ*item); +/*RenderaJentitytotextfortransfer/storagewithoutanyformattingandwithoutfieldsthatarefalse,0,or"".*/ +N_CJSON_PUBLIC(char*)JPrintUnformattedOmitEmpty(constJ*item); +/*RenderaJentitytotextusingabufferedstrategy.prebufferisaguessatthefinalsize.guessingwellreducesreallocation.fmt=0givesunformatted,=1givesformatted*/ +N_CJSON_PUBLIC(char*)JPrintBuffered(constJ*item,intprebuffer,Jboolfmt); +/*RenderaJentitytotextusingabufferalreadyallocatedinmemorywithgivenlength.Returns1onsuccessand0onfailure.*/ +/*NOTE:Jisnotalways100%accurateinestimatinghowmuchmemoryitwilluse,sotobesafeallocate5bytesmorethanyouactuallyneed*/ +N_CJSON_PUBLIC(Jbool)JPrintPreallocated(J*item,char*buffer,constintlength,constJboolformat); +N_CJSON_PUBLIC(Jbool)JPrintPreallocatedOmitEmpty(J*item,char*buffer,constintlength,constJboolformat); +/*DeleteaJentityandallsubentities.*/ +N_CJSON_PUBLIC(void)JDelete(J*c); + +/*Returnsthenumberofitemsinanarray(orobject).*/ +N_CJSON_PUBLIC(int)JGetArraySize(constJ*array); +#defineJGetObjectItemsJGetArraySize +/*Retrieveitemnumber"index"fromarray"array".ReturnsNULLifunsuccessful.*/ +N_CJSON_PUBLIC(J*)JGetArrayItem(constJ*array,intindex); +/*Getitem"string"fromobject.Caseinsensitive.*/ +N_CJSON_PUBLIC(J*)JGetObjectItem(constJ*constobject,constchar*conststring); +N_CJSON_PUBLIC(J*)JGetObjectItemCaseSensitive(constJ*constobject,constchar*conststring); +N_CJSON_PUBLIC(Jbool)JHasObjectItem(constJ*object,constchar*string); +/*Foranalysingfailedparses.Thisreturnsapointertotheparseerror.You'llprobablyneedtolookafewcharsbacktomakesenseofit.DefinedwhenJParse()returns0.0whenJParse()succeeds.*/ +N_CJSON_PUBLIC(constchar*)JGetErrorPtr(void); + +/*Checkiftheitemisastringandreturnitsvaluestring*/ +N_CJSON_PUBLIC(char*)JGetStringValue(J*item); + +/*Thesefunctionscheckthetypeofanitem*/ +N_CJSON_PUBLIC(Jbool)JIsInvalid(constJ*constitem); +N_CJSON_PUBLIC(Jbool)JIsFalse(constJ*constitem); +N_CJSON_PUBLIC(Jbool)JIsTrue(constJ*constitem); +N_CJSON_PUBLIC(Jbool)JIsBool(constJ*constitem); +N_CJSON_PUBLIC(Jbool)JIsNull(constJ*constitem); +N_CJSON_PUBLIC(Jbool)JIsNumber(constJ*constitem); +N_CJSON_PUBLIC(Jbool)JIsString(constJ*constitem); +N_CJSON_PUBLIC(Jbool)JIsArray(constJ*constitem); +N_CJSON_PUBLIC(Jbool)JIsObject(constJ*constitem); +N_CJSON_PUBLIC(Jbool)JIsRaw(constJ*constitem); + +/*ThesecallscreateaJitemoftheappropriatetype.*/ +N_CJSON_PUBLIC(J*)JCreateTrue(void); +N_CJSON_PUBLIC(J*)JCreateFalse(void); +N_CJSON_PUBLIC(J*)JCreateBool(Jboolboolean); +N_CJSON_PUBLIC(J*)JCreateNumber(JNUMBERnum); +N_CJSON_PUBLIC(J*)JCreateInteger(JINTEGERinteger); +N_CJSON_PUBLIC(J*)JCreateString(constchar*string); +/*rawjson*/ +N_CJSON_PUBLIC(J*)JCreateRaw(constchar*raw); +N_CJSON_PUBLIC(J*)JCreateArray(void); +N_CJSON_PUBLIC(J*)JCreateObject(void); + +/*Createastringwherevaluestringreferencesastringso +*itwillnotbefreedbyJDelete*/ +N_CJSON_PUBLIC(J*)JCreateStringValue(constchar*string); +N_CJSON_PUBLIC(J*)JCreateStringReference(constchar*string); +/*Createanobject/arrraythatonlyreferencesit'selementsso +*theywillnotbefreedbyJDelete*/ +N_CJSON_PUBLIC(J*)JCreateObjectReference(constJ*child); +N_CJSON_PUBLIC(J*)JCreateArrayReference(constJ*child); + +/*TheseutilitiescreateanArrayofcountitems.*/ +N_CJSON_PUBLIC(J*)JCreateIntArray(constlongint*numbers,intcount); +N_CJSON_PUBLIC(J*)JCreateNumberArray(constJNUMBER*numbers,intcount); +N_CJSON_PUBLIC(J*)JCreateStringArray(constchar**strings,intcount); + +/*Appenditemtothespecifiedarray/object.*/ +N_CJSON_PUBLIC(void)JAddItemToArray(J*array,J*item); +N_CJSON_PUBLIC(void)JAddItemToObject(J*object,constchar*string,J*item); +/*Usethiswhenstringisdefinitelyconst(i.e.aliteral,orasgoodas),andwilldefinitelysurvivetheJobject. +*WARNING:Whenthisfunctionwasused,makesuretoalwayscheckthat(item->type&JStringIsConst)iszerobefore +*writingto`item->string`*/ +N_CJSON_PUBLIC(void)JAddItemToObjectCS(J*object,constchar*string,J*item); +/*Appendreferencetoitemtothespecifiedarray/object.UsethiswhenyouwanttoaddanexistingJtoanewJ,butdon'twanttocorruptyourexistingJ.*/ +N_CJSON_PUBLIC(void)JAddItemReferenceToArray(J*array,J*item); +N_CJSON_PUBLIC(void)JAddItemReferenceToObject(J*object,constchar*string,J*item); + +/*Remove/DetatchitemsfromArrays/Objects.*/ +N_CJSON_PUBLIC(J*)JDetachItemViaPointer(J*parent,J*constitem); +N_CJSON_PUBLIC(J*)JDetachItemFromArray(J*array,intwhich); +N_CJSON_PUBLIC(void)JDeleteItemFromArray(J*array,intwhich); +N_CJSON_PUBLIC(J*)JDetachItemFromObject(J*object,constchar*string); +N_CJSON_PUBLIC(J*)JDetachItemFromObjectCaseSensitive(J*object,constchar*string); +N_CJSON_PUBLIC(void)JDeleteItemFromObject(J*object,constchar*string); +N_CJSON_PUBLIC(void)JDeleteItemFromObjectCaseSensitive(J*object,constchar*string); + +/*Updatearrayitems.*/ +N_CJSON_PUBLIC(void)JInsertItemInArray(J*array,intwhich,J*newitem);/*Shiftspre-existingitemstotheright.*/ +N_CJSON_PUBLIC(Jbool)JReplaceItemViaPointer(J*constparent,J*constitem,J*replacement); +N_CJSON_PUBLIC(void)JReplaceItemInArray(J*array,intwhich,J*newitem); +N_CJSON_PUBLIC(void)JReplaceItemInObject(J*object,constchar*string,J*newitem); +N_CJSON_PUBLIC(void)JReplaceItemInObjectCaseSensitive(J*object,constchar*string,J*newitem); + +/*DuplicateaJitem*/ +N_CJSON_PUBLIC(J*)JDuplicate(constJ*item,Jboolrecurse); +/*Duplicatewillcreateanew,identicalJitemtotheoneyoupass,innewmemorythatwill +needtobereleased.Withrecurse!=0,itwillduplicateanychildrenconnectedtotheitem. +Theitem->nextand->prevpointersarealwayszeroonreturnfromDuplicate.*/ +/*RecursivelycomparetwoJitemsforequality.IfeitheraorbisNULLorinvalid,theywillbeconsideredunequal. +*case_sensitivedeterminesifobjectkeysaretreatedcasesensitive(1)orcaseinsensitive(0)*/ +N_CJSON_PUBLIC(Jbool)JCompare(constJ*consta,constJ*constb,constJboolcase_sensitive); + + +N_CJSON_PUBLIC(void)JMinify(char*json); + +/*Helperfunctionsforcreatingandaddingitemstoanobjectatthesametime. +*TheyreturntheaddeditemorNULLonfailure.*/ +N_CJSON_PUBLIC(J*)JAddTrueToObject(J*constobject,constchar*constname); +N_CJSON_PUBLIC(J*)JAddFalseToObject(J*constobject,constchar*constname); +N_CJSON_PUBLIC(J*)JAddBoolToObject(J*constobject,constchar*constname,constJboolboolean); +N_CJSON_PUBLIC(J*)JAddNumberToObject(J*constobject,constchar*constname,constJNUMBERnumber); +N_CJSON_PUBLIC(J*)JAddIntToObject(J*constobject,constchar*constname,constJINTEGERinteger); +N_CJSON_PUBLIC(J*)JAddStringToObject(J*constobject,constchar*constname,constchar*conststring); +N_CJSON_PUBLIC(J*)JAddRawToObject(J*constobject,constchar*constname,constchar*constraw); +N_CJSON_PUBLIC(J*)JAddObjectToObject(J*constobject,constchar*constname); +N_CJSON_PUBLIC(J*)JAddArrayToObject(J*constobject,constchar*constname); +#defineJConvertToJSONStringJPrintUnformatted +#defineJConvertFromJSONStringJParse + +/*Whenassigninganintegervalue,itneedstobepropagatedtovaluenumbertoo.*/ +#defineJSetIntValue(object,number)((object)?(object)->valueint=(object)->valuenumber=(number):(number)) +/*helperfortheJSetNumberValuemacro*/ +N_CJSON_PUBLIC(JNUMBER)JSetNumberHelper(J*object,JNUMBERnumber); +#defineJSetNumberValue(object,number)((object!=NULL)?JSetNumberHelper(object,(JNUMBER)number):(number)) + +/*Macroforiteratingoveranarrayorobject*/ +#defineJArrayForEach(element,array)for(element=(array!=NULL)?(array)->child:NULL;element!=NULL;element=element->next) +//Iterateoverthefieldsofanobject +#defineJObjectForEach(element,array)JArrayForEach(element,array) + +/*malloc/freeobjectsusingthemalloc/freefunctionsthathavebeensetwithJInitHooks*/ +N_CJSON_PUBLIC(void*)JMalloc(size_tsize); +N_CJSON_PUBLIC(void)JFree(void*object); + +#ifdef__cplusplus +} +#endif + +#endif + + + + diff --git a/doxygen/xml/n__cjson__helpers_8c.xml b/doxygen/xml/n__cjson__helpers_8c.xml new file mode 100644 index 00000000..2f64d92c --- /dev/null +++ b/doxygen/xml/n__cjson__helpers_8c.xml @@ -0,0 +1,1503 @@ + + + + n_cjson_helpers.c + stdlib.h + string.h + time.h + n_lib.h + + + + + + + + + + + + + + + + + + + + + + + + + + + + + bool + bool JIsPresent + (J *json, const char *field) + JIsPresent + + J * + json + + + const char * + field + + +Determine if a field is present in a JSON object. + + + + +json + + +The JSON object. + + + + +field + + +The field to find. + + + +True if the field is present, or false if the field is not present or the JSON object is NULL. + + + + + + + + + char * + char* JGetString + (J *json, const char *field) + JGetString + + J * + json + + + const char * + field + + +Get the value of a string field from a JSON object. + + + + +json + + +The JSON object. + + + + +field + + +The string field to query. + + + +A pointer to the string if the field exists and is a string, otherwise the empty string (""). + +The returned string is a pointer to the string contained in the JSON object. It is not a copy of the string, so once the JSON object is freed, the pointer is no longer valid. + + + + + + + + + J * + J* JGetArray + (J *json, const char *field) + JGetArray + + J * + json + + + const char * + field + + +Get the value of an array field from a JSON object. + + + + +json + + +The JSON object. + + + + +field + + +The array field to query. + + + +A pointer to the array, which is itself a JSON object (J *), if the field exists and is an array, otherwise NULL. + +The returned JSON object is a pointer to the array contained in the parent JSON object. It is not a copy, so once the parent JSON object is freed, the pointer is no longer valid. + + + + + + + + + J * + J* JGetObject + (J *json, const char *field) + JGetObject + + J * + json + + + const char * + field + + +Get the value of an object field from a JSON object. + + + + +json + + +The JSON object. + + + + +field + + +The object field to query. + + + +A pointer to the object, which is itself a JSON object (J *), if the field exists and is an object, otherwise NULL. + +The returned JSON object is a pointer to the object contained in the parent JSON object. It is not a copy, so once the parent JSON object is freed, the pointer is no longer valid. + + + + + + + + + bool + bool JBoolValue + (J *item) + JBoolValue + + J * + item + + +Return the boolean representation of an item. + + + + +item + + +The JSON item. + + + +The boolean value. + + + + + + + + + char * + char* JStringValue + (J *item) + JStringValue + + J * + item + + +Return the string representation of an item. + + + + +item + + +The JSON item. + + + +The string value, or empty string, if NULL. + + + + + + + + + JNUMBER + JNUMBER JNumberValue + (J *item) + JNumberValue + + J * + item + + +Return the number representation of an item. + + + + +item + + +The JSON item. + + + +The number, or 0.0, if NULL. + + + + + + + + + JNUMBER + JNUMBER JGetNumber + (J *json, const char *field) + JGetNumber + + J * + json + + + const char * + field + + +Get the floating point value of a number field from a JSON object. + + + + +json + + +The JSON object. + + + + +field + + +The number field to query. + + + +The value of the number field if the field exists and is a number, otherwise 0.0. + +The returned value is the floating point representation of the number. + +JGetInt + +JGetBool + + + + + + + + + JINTEGER + JINTEGER JIntValue + (J *item) + JIntValue + + J * + item + + +Return the integer representation of an item. + + + + +item + + +The JSON item. + + + +The number, or 0, if NULL. + + + + + + + + + JINTEGER + JINTEGER JGetInt + (J *json, const char *field) + JGetInt + + J * + json + + + const char * + field + + +Get the integer value of a number field from a JSON object. + + + + +json + + +The JSON object. + + + + +field + + +The number field to query. + + + +The value of the number field if the field exists and is a number, otherwise 0. + +The returned value is the integer representation of the number. + +JGetBool + +JGetNumber + + + + + + + + + bool + bool JGetBool + (J *json, const char *field) + JGetBool + + J * + json + + + const char * + field + + +Get the value of a boolean field from a JSON object. + + + + +json + + +The JSON object. + + + + +field + + +The boolean field to query. + + + +The value of the boolean field if it exists and is a boolean, otherwise false. + +JGetInt + +JGetNumber + + + + + + + + + bool + bool JIsNullString + (J *json, const char *field) + JIsNullString + + J * + json + + + const char * + field + + +Determine if a JSON object is valid and if a field is not present, or null. + + + + +json + + +The JSON response object. + + + + +field + + +The field to return. + + + +bool. False if the field is not present, or NULL. + + + + + + + + + bool + bool JIsExactString + (J *json, const char *field, const char *teststr) + JIsExactString + + J * + json + + + const char * + field + + + const char * + teststr + + +Determine if a field exists, is a string and matches a provided value. + + + + +json + + +The JSON response object. + + + + +field + + +The field to check. + + + + +teststr + + +The string to test against the returned value. + + + +bol. Whether the fields match exactly. + + + + + + + + + bool + bool JContainsString + (J *json, const char *field, const char *substr) + JContainsString + + J * + json + + + const char * + field + + + const char * + substr + + +Determine if a field exists, is a string and contains a provided value. + + + + +json + + +The JSON response object. + + + + +field + + +The field to check. + + + + +substr + + +The string to test against the returned value. + + + +bol. Whether the provided string is found within the field. + + + + + + + + + bool + bool JAddBinaryToObject + (J *json, const char *fieldName, const void *binaryData, uint32_t binaryDataLen) + JAddBinaryToObject + + J * + json + + + const char * + fieldName + + + const void * + binaryData + + + uint32_t + binaryDataLen + + +Add binary data as a Base64-encoded string field to a JSON object. + + + + +json + + +The JSON object. + + + + +fieldName + + +The name to use for the field. + + + + +binaryData + + +A buffer of binary data to encode. + + + + +binaryDataLen + + +The length of the binary data in bytes. + + + +True if the string was successfully encoded and added to the object, otherwise false. + + + + + + + + + bool + bool JGetBinaryFromObject + (J *json, const char *fieldName, uint8_t **retBinaryData, uint32_t *retBinaryDataLen) + JGetBinaryFromObject + + J * + json + + + const char * + fieldName + + + uint8_t ** + retBinaryData + + + uint32_t * + retBinaryDataLen + + +Decode a Base64-encoded string field in a JSON object and return the decoded bytes. + + + + +json + + +The JSON object. + + + + +fieldName + + +The name of the field. + + + + +retBinaryData + + +A pointer to a pointer, used to hold the pointer to the decoded bytes. + + + + +retBinaryDataLen + + +A pointer to an unsigned integer, used to hold the length of the decoded bytes. + + + +True if the string was successfully decoded and returned, otherwise false. + +The returned binary buffer must be freed by the user with JFree when it is no longer needed. + +On error, the returned binary buffer and data length shall be set to NULL and zero (0), respectively. + + + + + + + + + const char * + const char* JGetItemName + (const J *item) + JGetItemName + + const J * + item + + +Get the object name. + + + + +item + + +The JSON object. + + + +The name, or the empty string, if NULL. + + + + + + + + + void + void JItoA + (JINTEGER n, char *s) + JItoA + + JINTEGER + n + + + char * + s + + +Convert an integer to text. + + + + +n + + +The integer to convert. + + + + +s + + +The buffer to hold the text. + + + +The buffer must be large enough because no bounds checking is done. + + + + + + + + + JINTEGER + JINTEGER JAtoI + (const char *string) + JAtoI + + const char * + string + + +Convert text to an integer. + + + + +string + + +A null-terminated text buffer + + + +An integer, or 0 if invalid + + + + + + + + + char * + char* JAllocString + (uint8_t *buffer, uint32_t len) + JAllocString + + uint8_t * + buffer + + + uint32_t + len + + +Convert a buffer/len to a null-terminated c-string. + + + + +buffer + + +A buffer containing the bytes to convert. + + + + +len + + +The length of buffer in bytes. + + + +If buffer is NULL or length 0, the empty string. If allocation fails, NULL. On success, the converted c-string. The returned string must be freed with NoteFree. + + + + + + + + + const char * + const char* JType + (J *item) + JType + + J * + item + + +Return the type of an item, as a string. + + + + +item + + +The JSON item. + + + +The type + + + + + + + + + int + int JGetType + (J *json, const char *field) + JGetType + + J * + json + + + const char * + field + + +Get the type of a field, as an int usable in a switch statement. + + + + +json + + +The JSON object containing the field. + + + + +field + + +The field's name. + + + +The type of the field on success. JTYPE_NOT_PRESENT on error or if the field doesn't exist. + + + + + + + + + int + int JGetItemType + (J *item) + JGetItemType + + J * + item + + + + + + + + + + + int + int JBaseItemType + (int type) + JBaseItemType + + int + type + + + + + + + + + + + + + +Written by Ray Ozzie and Blues Inc. team. +Copyright (c) 2019 Blues Inc. MIT License. Use of this source code is governed by licenses granted by the copyright holder including that found in the LICENSE file. + + + +#include<stdlib.h> +#include<string.h> +#include<time.h> +#include"n_lib.h" + +boolJIsPresent(J*json,constchar*field) +{ +if(json==NULL){ +returnfalse; +} +return(JGetObjectItem(json,field)!=NULL); +} + +char*JGetString(J*json,constchar*field) +{ +if(json==NULL){ +return(char*)c_nullstring; +} +J*item=JGetObjectItem(json,field); +if(item==NULL){ +return(char*)c_nullstring; +} +if(!JIsString(item)){ +return(char*)c_nullstring; +} +if(item->valuestring==NULL){ +return(char*)c_nullstring; +} +returnitem->valuestring; +} + +J*JGetArray(J*json,constchar*field) +{ +if(json==NULL){ +returnNULL; +} +J*item=JGetObjectItem(json,field); +if(item==NULL){ +returnNULL; +} +if(!JIsArray(item)){ +returnNULL; +} +returnitem; +} + +J*JGetObject(J*json,constchar*field) +{ +if(json==NULL){ +returnNULL; +} +J*item=JGetObjectItem(json,field); +if(item==NULL){ +returnNULL; +} +if(!JIsObject(item)){ +returnNULL; +} +returnitem; +} + +//**************************************************************************/ +/**************************************************************************/ +boolJBoolValue(J*item) +{ +if(item==NULL){ +returnfalse; +} +return((item->type&0xff)==JTrue); +} + +//**************************************************************************/ +/**************************************************************************/ +char*JStringValue(J*item) +{ +if(item==NULL){ +return(char*)""; +} +returnitem->valuestring; +} + +//**************************************************************************/ +/**************************************************************************/ +JNUMBERJNumberValue(J*item) +{ +if(item==NULL){ +return0.0; +} +returnitem->valuenumber; +} + +JNUMBERJGetNumber(J*json,constchar*field) +{ +if(json==NULL){ +return0.0; +} +J*item=JGetObjectItem(json,field); +if(item==NULL){ +return0.0; +} +if(!JIsNumber(item)){ +return0.0; +} +returnJNumberValue(item); +} + +//**************************************************************************/ +/**************************************************************************/ +JINTEGERJIntValue(J*item) +{ +if(item==NULL){ +return0; +} +returnitem->valueint; +} + +JINTEGERJGetInt(J*json,constchar*field) +{ +if(json==NULL){ +return0; +} +J*item=JGetObjectItem(json,field); +if(item==NULL){ +return0; +} +if(!JIsNumber(item)){ +return0; +} +returnJIntValue(item); +} + +boolJGetBool(J*json,constchar*field) +{ +if(json==NULL){ +returnfalse; +} +J*item=JGetObjectItem(json,field); +if(item==NULL){ +returnfalse; +} +if(!JIsBool(item)){ +returnfalse; +} +returnJIsTrue(item); +} + +//**************************************************************************/ +/**************************************************************************/ +boolJIsNullString(J*json,constchar*field) +{ +if(json==NULL){ +returnfalse; +} +J*item=JGetObjectItem(json,field); +if(item==NULL){ +returntrue; +} +if(!JIsString(item)){ +returnfalse; +} +if(item->valuestring==NULL){ +returntrue; +} +if(item->valuestring[0]=='\0'){ +returntrue; +} +returnfalse; +} + +//**************************************************************************/ +/**************************************************************************/ +boolJIsExactString(J*json,constchar*field,constchar*teststr) +{ +if(json==NULL){ +returnfalse; +} +J*item=JGetObjectItem(json,field); +if(item==NULL){ +returnfalse; +} +if(!JIsString(item)){ +returnfalse; +} +if(item->valuestring==NULL){ +returnfalse; +} +if(strlen(teststr)==0){ +returnfalse; +} +return(strcmp(item->valuestring,teststr)==0); +} + +//**************************************************************************/ +/**************************************************************************/ +boolJContainsString(J*json,constchar*field,constchar*substr) +{ +if(json==NULL){ +returnfalse; +} +J*item=JGetObjectItem(json,field); +if(item==NULL){ +returnfalse; +} +if(!JIsString(item)){ +returnfalse; +} +if(item->valuestring==NULL){ +returnfalse; +} +if(strlen(substr)==0){ +returnfalse; +} +return(strstr(item->valuestring,substr)!=NULL); +} + + +boolJAddBinaryToObject(J*json,constchar*fieldName,constvoid*binaryData,uint32_tbinaryDataLen) +{ +if(json==NULL){ +returnfalse; +} +unsignedstringDataLen=JB64EncodeLen(binaryDataLen); +char*stringData=(char*)_Malloc(stringDataLen); +if(stringData==NULL){ +returnfalse; +} +JB64Encode(stringData,binaryData,binaryDataLen); +J*stringItem=JCreateStringValue(stringData); +if(stringItem==NULL){ +_Free(stringData); +returnfalse; +} +JAddItemToObject(json,fieldName,stringItem); +returntrue; +} + + +boolJGetBinaryFromObject(J*json,constchar*fieldName,uint8_t**retBinaryData,uint32_t*retBinaryDataLen) +{ +//InitializethereturnvaluestoNULLandzero. +*retBinaryData=NULL; +*retBinaryDataLen=0; + +if(json==NULL){ +returnfalse; +} + +//Insomecases,thecallermayalreadyhaveextractedthestringfromadifferentfield,inwhich +//case"json"willbesettothepayloadpointer. +char*payload; +if(fieldName==NULL){ +payload=(char*)json; +}else{ +payload=JGetString(json,fieldName); +} +if(payload[0]=='\0'){ +returnfalse; +} + +//Allocateabufferforthepayload,withanextra'conveniencebyte'fornulltermination.(seebelow) +char*p=(char*)_Malloc(JB64DecodeLen(payload)+1); +if(p==NULL){ +returnfalse; +} +uint32_tactualLen=JB64Decode(p,payload); + +//Asaconveniencetothecaller,null-terminatethereturnedbufferincaseit'sastring. +//(Ifwedidn'tdothis,thecallerwouldbeforcedtoallocanotherbufferoflength+1and +//copyittoaddthenullterminator,whileit'seasyforustodoithere.) +p[actualLen]='\0'; + +//Returnthebinarytothecaller +*retBinaryData=(uint8_t*)p; +*retBinaryDataLen=actualLen; +returntrue; + +} + +//**************************************************************************/ +/**************************************************************************/ +constchar*JGetItemName(constJ*item) +{ +if(item==NULL||item->string==NULL){ +return""; +} +returnitem->string; +} + +//**************************************************************************/ +/**************************************************************************/ +voidJItoA(JINTEGERn,char*s) +{ +charc; +//Conversiontounsignedisrequiredtohandlethecasewherenis +//JINTEGER_MIN.Inthatcase,applyingtheunaryminusoperatortothe +//signedversionofnoverflowsandthebehaviorisundefined.Bychanging +//ntobeunsigned,theunaryminusoperatorbehavesdifferently,andthere +//isnooverflow.Seehttps://stackoverflow.com/q/8026694. +JUINTEGERunsignedN=n; +longinti,j; +if(n<0){ +unsignedN=-unsignedN; +} +i=0; +do{ +s[i++]=unsignedN%10+'0'; +}while((unsignedN/=10)>0); +if(n<0){ +s[i++]='-'; +} +s[i]='\0'; +for(i=0,j=strlen(s)-1;i<j;i++,j--){ +c=s[i]; +s[i]=s[j]; +s[j]=c; +} +} + +//**************************************************************************/ +/**************************************************************************/ +JINTEGERJAtoI(constchar*string) +{ +JINTEGERresult=0; +unsignedintdigit; +intsign; +while(*string==''){ +string+=1; +} +if(*string=='-'){ +sign=1; +string+=1; +}else{ +sign=0; +if(*string=='+'){ +string+=1; +} +} +for(;;string+=1){ +digit=*string-'0'; +if(digit>9){ +break; +} +result=(10*result)+digit; +} +if(sign){ +result=-result; +} +returnresult; +} + +//**************************************************************************/ +/**************************************************************************/ +char*JAllocString(uint8_t*buffer,uint32_tlen) +{ +char*buf=_Malloc(len+1); +if(buf==NULL){ +returnNULL; +} +if(len>0){ +memcpy(buf,buffer,len); +} +buf[len]='\0'; +returnbuf; +} + +//**************************************************************************/ +/**************************************************************************/ +constchar*JType(J*item) +{ +if(item==NULL){ +return""; +} +switch(item->type&0xff){ +caseJTrue: +caseJFalse: +return"bool"; +caseJNULL: +return"null"; +caseJNumber: +return"number"; +caseJRaw: +caseJString: +return"string"; +caseJObject: +return"object"; +caseJArray: +return"array"; +} +return"invalid"; +} + +//**************************************************************************/ +/**************************************************************************/ +intJGetType(J*json,constchar*field) +{ +if(json==NULL||field==NULL){ +returnJTYPE_NOT_PRESENT; +} +returnJGetItemType(JGetObjectItem(json,field)); +} + +//Getthe +intJGetItemType(J*item) +{ +constchar*v; +if(item==NULL){ +returnJTYPE_NOT_PRESENT; +} +switch(item->type&0xff){ +caseJTrue: +returnJTYPE_BOOL_TRUE; +caseJFalse: +returnJTYPE_BOOL_FALSE; +caseJNULL: +returnJTYPE_NULL; +caseJNumber: +if(item->valueint==0&&item->valuenumber==0){ +returnJTYPE_NUMBER_ZERO; +} +returnJTYPE_NUMBER; +caseJRaw: +caseJString:{ +v=item->valuestring; +if(v==NULL||v[0]==0){ +returnJTYPE_STRING_BLANK; +} +intvlen=strlen(v); +char*endstr; +JNUMBERvalue=JAtoN(v,&endstr); +if(endstr[0]==0){ +if(value==0){ +returnJTYPE_STRING_ZERO; +} +returnJTYPE_STRING_NUMBER; +} +if(vlen==4&&( +(v[0]=='t'||v[0]=='T') +&&(v[1]=='r'||v[1]=='R') +&&(v[2]=='u'||v[2]=='U') +&&(v[3]=='e'||v[3]=='E'))){ +returnJTYPE_STRING_BOOL_TRUE; +} +if(vlen==5&&( +(v[0]=='f'||v[0]=='F') +&&(v[1]=='a'||v[1]=='A') +&&(v[2]=='l'||v[2]=='L') +&&(v[3]=='s'||v[3]=='S') +&&(v[4]=='e'||v[4]=='E'))){ +returnJTYPE_STRING_BOOL_FALSE; +} +returnJTYPE_STRING; +} +caseJObject: +returnJTYPE_OBJECT; +caseJArray: +returnJTYPE_ARRAY; +} +returnJTYPE_NOT_PRESENT; +} + +//Coalescetothebasetypes +intJBaseItemType(inttype) +{ +switch(type){ +caseJTYPE_BOOL_TRUE: +returnJTYPE_BOOL; +caseJTYPE_BOOL_FALSE: +returnJTYPE_BOOL; +caseJTYPE_NUMBER_ZERO: +returnJTYPE_NUMBER; +caseJTYPE_STRING_BLANK: +returnJTYPE_STRING; +caseJTYPE_STRING_ZERO: +returnJTYPE_STRING; +caseJTYPE_STRING_NUMBER: +returnJTYPE_STRING; +caseJTYPE_STRING_BOOL_TRUE: +returnJTYPE_STRING; +caseJTYPE_STRING_BOOL_FALSE: +returnJTYPE_STRING; +} +returntype; +} + + + + diff --git a/doxygen/xml/n__hooks_8c.xml b/doxygen/xml/n__hooks_8c.xml new file mode 100644 index 00000000..c3a5098c --- /dev/null +++ b/doxygen/xml/n__hooks_8c.xml @@ -0,0 +1,2606 @@ + + + + n_hooks.c + stdio.h + stdarg.h + stdlib.h + n_lib.h + + + + + + + + + + + + + + + + + + + + + + + + + + + + + NOTE_SHOW_MALLOC + false + +Show malloc operations for debugging in very low mem environments. + + + + + + + + + interfaceNone + 0 + + + + + + + + + + interfaceSerial + 1 + + + + + + + + + + interfaceI2C + 2 + + + + + + + + + + + + bool(* + typedef bool(* nNoteResetFn) (void) + )(void) + nNoteResetFn + + + + + + + + + + const char *(* + typedef const char*(* nTransactionFn) (const char *, size_t, char **, uint32_t) + )(const char *, size_t, char **, uint32_t) + nTransactionFn + + + + + + + + + + const char *(* + typedef const char*(* nReceiveFn) (uint8_t *, uint32_t *, bool, uint32_t, uint32_t *) + )(uint8_t *, uint32_t *, bool, uint32_t, uint32_t *) + nReceiveFn + + + + + + + + + + const char *(* + typedef const char*(* nTransmitFn) (uint8_t *, uint32_t, bool) + )(uint8_t *, uint32_t, bool) + nTransmitFn + + + + + + + + + + + + debugOutputFn + debugOutputFn hookDebugOutput + + hookDebugOutput + = NULL + +Hook for the calling platform's debug interface, if any. + + + + + + + + + mutexFn + mutexFn hookLockI2C + + hookLockI2C + = NULL + +Hook for the calling platform's I2C lock function. + + + + + + + + + mutexFn + mutexFn hookUnlockI2C + + hookUnlockI2C + = NULL + +Hook for the calling platform's I2C unlock function. + + + + + + + + + mutexFn + mutexFn hookLockNote + + hookLockNote + = NULL + +Hook for the calling platform's Notecard lock function. + + + + + + + + + mutexFn + mutexFn hookUnlockNote + + hookUnlockNote + = NULL + +Hook for the calling platform's Notecard lock function. + + + + + + + + + txnStartFn + txnStartFn hookTransactionStart + + hookTransactionStart + = NULL + +Hook for the calling platform's transaction initiation function. + + + + + + + + + txnStopFn + txnStopFn hookTransactionStop + + hookTransactionStop + = NULL + +Hook for the calling platform's transaction completion function. + + + + + + + + + mallocFn + mallocFn hookMalloc + + hookMalloc + = NULL + +Hook for the calling platform's memory allocation function. + + + + + + + + + freeFn + freeFn hookFree + + hookFree + = NULL + +Hook for the calling platform's memory free function. + + + + + + + + + delayMsFn + delayMsFn hookDelayMs + + hookDelayMs + = NULL + +Hook for the calling platform's delay function. + + + + + + + + + getMsFn + getMsFn hookGetMs + + hookGetMs + = NULL + +Hook for the calling platform's millis timing function. + + + + + + + + + uint32_t + uint32_t hookActiveInterface + + hookActiveInterface + = interfaceNone + +Hook for the calling platform's current active interface. Value is one of: + + + +interfaceNone = 0 (default) +interfaceSerial = 1 +interfaceI2C = 2 + + + + + + + + + serialResetFn + serialResetFn hookSerialReset + + hookSerialReset + = NULL + +Hook for the calling platform's Serial reset function. + + + + + + + + + serialTransmitFn + serialTransmitFn hookSerialTransmit + + hookSerialTransmit + = NULL + +Hook for the calling platform's Serial transmit function. + + + + + + + + + serialAvailableFn + serialAvailableFn hookSerialAvailable + + hookSerialAvailable + = NULL + +Hook for the calling platform's Serial data available function. + + + + + + + + + serialReceiveFn + serialReceiveFn hookSerialReceive + + hookSerialReceive + = NULL + +Hook for the calling platform's Serial receive function. + + + + + + + + + uint32_t + uint32_t i2cAddress + + i2cAddress + = 0 + +Hook for the calling platform's I2C address. + + + + + + + + + uint32_t + uint32_t i2cMax + + i2cMax + = 0 + +Hook for the calling platform's I2C maximum segment size, in bytes. + + + + + + + + + i2cResetFn + i2cResetFn hookI2CReset + + hookI2CReset + = NULL + +Hook for the calling platform's I2C reset function. + + + + + + + + + i2cTransmitFn + i2cTransmitFn hookI2CTransmit + + hookI2CTransmit + = NULL + +Hook for the calling platform's transmit function. + + + + + + + + + i2cReceiveFn + i2cReceiveFn hookI2CReceive + + hookI2CReceive + = NULL + +Hook for the calling platform's I2C receive function. + + + + + + + + + nNoteResetFn + nNoteResetFn notecardReset + + notecardReset + = NULL + + + + + + + + + + nTransactionFn + nTransactionFn notecardTransaction + + notecardTransaction + = NULL + + + + + + + + + + nReceiveFn + nReceiveFn notecardChunkedReceive + + notecardChunkedReceive + = NULL + + + + + + + + + + nTransmitFn + nTransmitFn notecardChunkedTransmit + + notecardChunkedTransmit + = NULL + + + + + + + + + + + + void + void NoteSetFnDefault + (mallocFn mallocfn, freeFn freefn, delayMsFn delayfn, getMsFn millisfn) + NoteSetFnDefault + + mallocFn + mallocfn + + + freeFn + freefn + + + delayMsFn + delayfn + + + getMsFn + millisfn + + +Set the default memory and timing hooks if they aren't already set. + + + + +mallocfn + + +The default memory allocation malloc function to use. + + + + +freefn + + +The default memory free function to use. + + + + +delayfn + + +The default delay function to use. + + + + +millisfn + + +The default 'millis' function to use. + + + + + + + + + + + void + void NoteSetFn + (mallocFn mallocHook, freeFn freeHook, delayMsFn delayMsHook, getMsFn getMsHook) + NoteSetFn + + mallocFn + mallocHook + + + freeFn + freeHook + + + delayMsFn + delayMsHook + + + getMsFn + getMsHook + + +Set the platform-specific memory and timing hooks. + + + + +mallocHook + + +The platform-specific memory allocation function (i.e. malloc). + + + + +freeHook + + +The platform-specific memory free function (i.e. free). + + + + +delayMsHook + + +The platform-specific millisecond delay function. + + + + +getMsHook + + +The platform-specific millisecond counter function. + + + + + + + + + + + void + void NoteSetFnDebugOutput + (debugOutputFn fn) + NoteSetFnDebugOutput + + debugOutputFn + fn + + +Set the platform-specific debug output function. + + + + +fn + + +A function pointer to call for debug output. + + + + + + + + + + + bool + bool noteIsDebugOutputActive + (void) + noteIsDebugOutputActive + + void + + +Determine if a debug output function has been set. + + +A boolean indicating whether a debug ouput function was provided. + + + + + + + + + void + void NoteSetFnTransaction + (txnStartFn startFn, txnStopFn stopFn) + NoteSetFnTransaction + + txnStartFn + startFn + + + txnStopFn + stopFn + + +Set the platform-specific transaction initiation/completion fn's. + + + + +startFn + + +The platform-specific transaction initiation function to use. + + + + +stopFn + + +The platform-specific transaction completion function to use. to use. + + + + + + + + + + + void + void NoteSetFnMutex + (mutexFn lockI2Cfn, mutexFn unlockI2Cfn, mutexFn lockNotefn, mutexFn unlockNotefn) + NoteSetFnMutex + + mutexFn + lockI2Cfn + + + mutexFn + unlockI2Cfn + + + mutexFn + lockNotefn + + + mutexFn + unlockNotefn + + +Set the platform-specific mutex functions for I2C and the Notecard. + + + + +lockI2Cfn + + +The platform-specific I2C lock function to use. + + + + +unlockI2Cfn + + +The platform-specific I2C unlock function to use. + + + + +lockNotefn + + +The platform-specific Notecard lock function to use. + + + + +unlockNotefn + + +The platform-specific Notecard unlock function to use. + + + + + + + + + + + void + void NoteSetFnI2CMutex + (mutexFn lockI2Cfn, mutexFn unlockI2Cfn) + NoteSetFnI2CMutex + + mutexFn + lockI2Cfn + + + mutexFn + unlockI2Cfn + + +Set the platform-specific mutex functions for I2C. + + + + +lockI2Cfn + + +The platform-specific I2C lock function. + + + + +unlockI2Cfn + + +The platform-specific I2C unlock function. + + + + + + + + + + + void + void NoteSetFnNoteMutex + (mutexFn lockFn, mutexFn unlockFn) + NoteSetFnNoteMutex + + mutexFn + lockFn + + + mutexFn + unlockFn + + +Set the platform-specific mutex functions for the Notecard. + + + + +lockFn + + +The platform-specific Notecard lock function. + + + + +unlockFn + + +The platform-specific Notecard unlock function. + + + + + + + + + + + void + void NoteSetFnSerial + (serialResetFn resetFn, serialTransmitFn transmitFn, serialAvailableFn availFn, serialReceiveFn receiveFn) + NoteSetFnSerial + + serialResetFn + resetFn + + + serialTransmitFn + transmitFn + + + serialAvailableFn + availFn + + + serialReceiveFn + receiveFn + + +Set the platform-specific hooks for communicating with the Notecard over serial. + + + + +resetFn + + +The platform-specific serial reset function. + + + + +transmitFn + + +The platform-specific serial transmit function. + + + + +availFn + + +The platform-specific serial available function. + + + + +receiveFn + + +The platform-specific serial receive function. + + + + + + + + + + + void + void NoteSetFnI2C + (uint32_t notecardAddr, uint32_t maxTransmitSize, i2cResetFn resetFn, i2cTransmitFn transmitFn, i2cReceiveFn receiveFn) + NoteSetFnI2C + + uint32_t + notecardAddr + + + uint32_t + maxTransmitSize + + + i2cResetFn + resetFn + + + i2cTransmitFn + transmitFn + + + i2cReceiveFn + receiveFn + + +Set the platform-specific hooks for communicating with the Notecard over I2C, as well as the I2C address of the Notecard and maximum transmission size. + + + + +notecardAddr + + +The I2C address of the Notecard. Pass 0 to use the default address. + + + + +maxTransmitSize + + +The max number of bytes to send to the Notecard in a single I2C segment. Pass 0 to use the default maximum transmission size. + + + + +resetFn + + +The platform-specific I2C reset function. + + + + +transmitFn + + +The platform-specific I2C transmit function. + + + + +receiveFn + + +The platform-specific I2C receive function. + + + + + + + + + + + void + void NoteSetFnDisabled + (void) + NoteSetFnDisabled + + void + + +Set the platform-specific communications method to be disabled. + + + + + + + + + void + void NoteDebugIntln + (const char *line, int n) + NoteDebugIntln + + const char * + line + + + int + n + + +Write a number to the debug stream and output a newline. + + + + +line + + +A debug string for output. + + + + +n + + +The number to write. + + + + + + + + + + + void + void NoteDebugln + (const char *line) + NoteDebugln + + const char * + line + + +Write text to the debug stream and output a newline. + + + + +line + + +A debug string for output. + + + + + + + + + + + void + void NoteDebug + (const char *line) + NoteDebug + + const char * + line + + +Write to the debug stream. + + + + +line + + +A debug string for output. + + + + + + + + + + + void + void NoteDebugWithLevel + (uint8_t level, const char *msg) + NoteDebugWithLevel + + uint8_t + level + + + const char * + msg + + +Write the message to the debug stream, if the level is less than or equal to NOTE_C_LOG_LEVEL. Otherwise, the message is dropped. + + + + +level + + +The log level of the message. See the NOTE_C_LOG_LEVEL_* macros in note.h for possible values. + + + + +msg + + +The debug message. + + + + + + + + + + + void + void NoteDebugWithLevelLn + (uint8_t level, const char *msg) + NoteDebugWithLevelLn + + uint8_t + level + + + const char * + msg + + +Same as NoteDebugWithLevel, but add a newline at the end. + + + + +level + + +The log level of the message. See the NOTE_C_LOG_LEVEL_* macros in note.h for possible values. + + + + +msg + + +The debug message. + + + + + + + + + + + uint32_t + uint32_t NoteGetMs + (void) + NoteGetMs + + void + + +Get the current milliseconds value from the platform-specific hook. + + +The current milliseconds value. + + + + + + + + + void + void NoteDelayMs + (uint32_t ms) + NoteDelayMs + + uint32_t + ms + + +Delay milliseconds using the platform-specific hook. + + + + +ms + + +the milliseconds delay value. + + + + + + + + + + + void + void n_htoa32 + (uint32_t n, char *p) + n_htoa32 + + uint32_t + n + + + char * + p + + +Convert number to a hex string. + + + + +n + + +the number + + + + +p + + +the buffer to return it into + + + + + + + + + + + void * + void* NoteMalloc + (size_t size) + NoteMalloc + + size_t + size + + +Allocate a memory chunk using the platform-specific hook. + + + + +size + + +the number of bytes to allocate. + + + + + + + + + + + void + void NoteFree + (void *p) + NoteFree + + void * + p + + +Free memory using the platform-specific hook. + + + + +p + + +A pointer to the memory address to free. + + + + + + + + + + + void + void NoteLockI2C + (void) + NoteLockI2C + + void + + +Lock the I2C bus using the platform-specific hook. + + + + + + + + + void + void NoteUnlockI2C + (void) + NoteUnlockI2C + + void + + +Unlock the I2C bus using the platform-specific hook. + + + + + + + + + void + void noteLockNote + (void) + noteLockNote + + void + + +Lock the Notecard using the platform-specific hook. + + + + + + + + + void + void noteUnlockNote + (void) + noteUnlockNote + + void + + +Unlock the Notecard using the platform-specific hook. + + + + + + + + + bool + bool noteTransactionStart + (uint32_t timeoutMs) + noteTransactionStart + + uint32_t + timeoutMs + + +Indicate that we're initiating a transaction using the platform-specific hook. + + + + + + + + + void + void noteTransactionStop + (void) + noteTransactionStop + + void + + +Indicate that we've completed a transaction using the platform-specific hook. + + + + + + + + + const char * + const char* noteActiveInterface + (void) + noteActiveInterface + + void + + +Get the active interface's name. + + +A string + + + + + + + + + bool + bool noteSerialReset + (void) + noteSerialReset + + void + + +Reset the Serial bus using the platform-specific hook. + + +A boolean indicating whether the Serial bus was reset successfully. + + + + + + + + + void + void noteSerialTransmit + (uint8_t *text, size_t len, bool flush) + noteSerialTransmit + + uint8_t * + text + + + size_t + len + + + bool + flush + + +Transmit bytes over Serial using the platform-specific hook. + + + + +text + + +The bytes to transmit. + + + + +len + + +The length of bytes. + + + + +flush + + +true to flush the bytes upon transmit. + + + + + + + + + + + bool + bool noteSerialAvailable + (void) + noteSerialAvailable + + void + + +Determine if Serial bus is available using the platform-specific hook. + + +A boolean indicating whether the Serial bus is available to read. + + + + + + + + + char + char noteSerialReceive + (void) + noteSerialReceive + + void + + +Obtain a character from the Serial bus using the platform-specific hook. + + +A character from the Serial bus. + + + + + + + + + bool + bool noteI2CReset + (uint16_t DevAddress) + noteI2CReset + + uint16_t + DevAddress + + +Reset the I2C bus using the platform-specific hook. + + +A boolean indicating whether the I2C bus was reset successfully. + + + + + + + + + const char * + const char* noteI2CTransmit + (uint16_t DevAddress, uint8_t *pBuffer, uint16_t Size) + noteI2CTransmit + + uint16_t + DevAddress + + + uint8_t * + pBuffer + + + uint16_t + Size + + +Transmit bytes over I2C using the platform-specific hook. + + + + +DevAddress + + +the I2C address for transmission. + + + + +pBuffer + + +The bytes to transmit. + + + + +Size + + +The length of bytes. + + + +A c-string from the platform-specific hook, or an error string if the bus is not active. + + + + + + + + + const char * + const char* noteI2CReceive + (uint16_t DevAddress, uint8_t *pBuffer, uint16_t Size, uint32_t *available) + noteI2CReceive + + uint16_t + DevAddress + + + uint8_t * + pBuffer + + + uint16_t + Size + + + uint32_t * + available + + +Receive bytes from I2C using the platform-specific hook. + + + + +DevAddress + + +the I2C address for transmission. + + + + +pBuffer + + +(out) A buffer in which to place received bytes. + + + + +Size + + +The length of bytes. + + + + +available + + +(out) The number of bytes left to read. + + + +A c-string from the platform-specific hook, or an error string if the bus is not active. + + + + + + + + + uint32_t + uint32_t NoteI2CAddress + (void) + NoteI2CAddress + + void + + +Get the I2C address of the Notecard. + + +The current I2C address. + + + + + + + + + void + void NoteSetI2CAddress + (uint32_t i2caddress) + NoteSetI2CAddress + + uint32_t + i2caddress + + +Set the I2C address for communication with the Notecard. + + + + +i2caddress + + +the I2C address to use for the Notecard. + + + + + + + + + + + uint32_t + uint32_t NoteI2CMax + (void) + NoteI2CMax + + void + + +Determine the maximum number of bytes for each segment of data sent to the Notecard over I2C. + + +A 32-bit integer of the maximum number of bytes per I2C segment. + + + + + + + + + bool + bool noteHardReset + (void) + noteHardReset + + void + + +Perform a hard reset on the Notecard using the platform-specific hook. + + +A boolean indicating whether the Notecard has been reset successfully. + + + + + + + + + const char * + const char* noteJSONTransaction + (const char *request, size_t reqLen, char **response, uint32_t timeoutMs) + noteJSONTransaction + + const char * + request + + + size_t + reqLen + + + char ** + response + + + uint32_t + timeoutMs + + +Perform a JSON request to the Notecard using the currently-set platform hook. + + + + +request + + +A string containing the JSON request object, which MUST BE terminated with a newline character. + + + + +reqLen + + +the string length of the JSON request. + + + + +response + + +[out] A c-string buffer that will contain the newline (' +') terminated JSON response from the Notercard. If NULL, no response will be captured. + + + + +timeoutMs + + +The maximum amount of time, in milliseconds, to wait for data to arrive. Passing zero (0) disables the timeout. + + + +NULL if successful, or an error string if the transaction failed or the hook has not been set. + + + + + + + + + const char * + const char* noteChunkedReceive + (uint8_t *buffer, uint32_t *size, bool delay, uint32_t timeoutMs, uint32_t *available) + noteChunkedReceive + + uint8_t * + buffer + + + uint32_t * + size + + + bool + delay + + + uint32_t + timeoutMs + + + uint32_t * + available + + +Receive bytes over from the Notecard using the currently-set platform hook. + + + + +buffer + + +A buffer to receive bytes into. + + + + +size + + +(in/out) +(in) The size of the buffer in bytes. +(out) The length of the received data in bytes. + + + + + + +delay + + +Respect standard processing delays. + + + + +timeoutMs + + +The maximum amount of time, in milliseconds, to wait for data to arrive. Passing zero (0) disables the timeout. + + + + +available + + +(in/out) +(in) The amount of bytes to request. Sending zero (0) will initiate a priming query when using the I2C interface. +(out) The amount of bytes unable to fit into the provided buffer. + + + + + +A c-string with an error, or NULL if no error ocurred. + + + + + + + + + const char * + const char* noteChunkedTransmit + (uint8_t *buffer, uint32_t size, bool delay) + noteChunkedTransmit + + uint8_t * + buffer + + + uint32_t + size + + + bool + delay + + +Transmit bytes over to the Notecard using the currently-set platform hook. + + + + +buffer + + +A buffer of bytes to transmit. + + + + +size + + +The count of bytes in the buffer to send + + + + +delay + + +Respect standard processing delays. + + + +A c-string with an error, or NULL if no error ocurred. + + + + + + + + + + + +Hooks allow libraries dependent on note-c to provide platform- or MCU-specific functions for common functions like I2C locking/unlocking, memory allocation and freeing, delays, and communicating with the Notecard over I2C and Serial. Using these hooks, note-c is able to manage Notecard transaction logic, and defer to platform functionality, when needed. +Written by Ray Ozzie and Blues Inc. team. +Copyright (c) 2019 Blues Inc. MIT License. Use of this source code is governed by licenses granted by the copyright holder including that found in the LICENSE file. + + + +#include<stdio.h> +#include<stdarg.h> +#include<stdlib.h> +#include"n_lib.h" + +//**************************************************************************/ +/**************************************************************************/ +#defineNOTE_SHOW_MALLOCfalse +#ifNOTE_SHOW_MALLOC +#include<string.h> +void*malloc_show(size_tlen); +#endif + +//WhichI/Oporttouse +#defineinterfaceNone0 +#defineinterfaceSerial1 +#defineinterfaceI2C2 + +//ExternalizedHooks +//**************************************************************************/ +/**************************************************************************/ +debugOutputFnhookDebugOutput=NULL; +//**************************************************************************/ +/**************************************************************************/ +mutexFnhookLockI2C=NULL; +//**************************************************************************/ +/**************************************************************************/ +mutexFnhookUnlockI2C=NULL; +//**************************************************************************/ +/**************************************************************************/ +mutexFnhookLockNote=NULL; +//**************************************************************************/ +/**************************************************************************/ +mutexFnhookUnlockNote=NULL; +//**************************************************************************/ +/**************************************************************************/ +txnStartFnhookTransactionStart=NULL; +//**************************************************************************/ +/**************************************************************************/ +txnStopFnhookTransactionStop=NULL; +//**************************************************************************/ +/**************************************************************************/ +mallocFnhookMalloc=NULL; +//**************************************************************************/ +/**************************************************************************/ +freeFnhookFree=NULL; +//**************************************************************************/ +/**************************************************************************/ +delayMsFnhookDelayMs=NULL; +//**************************************************************************/ +/**************************************************************************/ +getMsFnhookGetMs=NULL; +//**************************************************************************/ +/**************************************************************************/ +uint32_thookActiveInterface=interfaceNone; + +//**************************************************************************/ +/**************************************************************************/ +serialResetFnhookSerialReset=NULL; +//**************************************************************************/ +/**************************************************************************/ +serialTransmitFnhookSerialTransmit=NULL; +//**************************************************************************/ +/**************************************************************************/ +serialAvailableFnhookSerialAvailable=NULL; +//**************************************************************************/ +/**************************************************************************/ +serialReceiveFnhookSerialReceive=NULL; + +//**************************************************************************/ +/**************************************************************************/ +uint32_ti2cAddress=0; +//**************************************************************************/ +/**************************************************************************/ +uint32_ti2cMax=0; +//**************************************************************************/ +/**************************************************************************/ +i2cResetFnhookI2CReset=NULL; +//**************************************************************************/ +/**************************************************************************/ +i2cTransmitFnhookI2CTransmit=NULL; +//**************************************************************************/ +/**************************************************************************/ +i2cReceiveFnhookI2CReceive=NULL; + +//Internalhooks +typedefbool(*nNoteResetFn)(void); +typedefconstchar*(*nTransactionFn)(constchar*,size_t,char**,uint32_t); +typedefconstchar*(*nReceiveFn)(uint8_t*,uint32_t*,bool,uint32_t,uint32_t*); +typedefconstchar*(*nTransmitFn)(uint8_t*,uint32_t,bool); +staticnNoteResetFnnotecardReset=NULL; +staticnTransactionFnnotecardTransaction=NULL; +staticnReceiveFnnotecardChunkedReceive=NULL; +staticnTransmitFnnotecardChunkedTransmit=NULL; + +voidNoteSetFnDefault(mallocFnmallocfn,freeFnfreefn,delayMsFndelayfn,getMsFnmillisfn) +{ +if(hookMalloc==NULL){ +hookMalloc=mallocfn; +} +if(hookFree==NULL){ +hookFree=freefn; +} +if(hookDelayMs==NULL){ +hookDelayMs=delayfn; +} +if(hookGetMs==NULL){ +hookGetMs=millisfn; +} +} + +voidNoteSetFn(mallocFnmallocHook,freeFnfreeHook,delayMsFndelayMsHook, +getMsFngetMsHook) +{ +hookMalloc=mallocHook; +hookFree=freeHook; +hookDelayMs=delayMsHook; +hookGetMs=getMsHook; +} + +//**************************************************************************/ +/**************************************************************************/ +voidNoteSetFnDebugOutput(debugOutputFnfn) +{ +hookDebugOutput=fn; +} + +//**************************************************************************/ +/**************************************************************************/ +boolnoteIsDebugOutputActive(void) +{ +returnhookDebugOutput!=NULL; +} + +//**************************************************************************/ +/**************************************************************************/ +voidNoteSetFnTransaction(txnStartFnstartFn,txnStopFnstopFn) +{ +hookTransactionStart=startFn; +hookTransactionStop=stopFn; +} + +//**************************************************************************/ +/**************************************************************************/ +voidNoteSetFnMutex(mutexFnlockI2Cfn,mutexFnunlockI2Cfn,mutexFnlockNotefn,mutexFnunlockNotefn) +{ +hookLockI2C=lockI2Cfn; +hookUnlockI2C=unlockI2Cfn; +hookLockNote=lockNotefn; +hookUnlockNote=unlockNotefn; +} + +voidNoteSetFnI2CMutex(mutexFnlockI2Cfn,mutexFnunlockI2Cfn) +{ +hookLockI2C=lockI2Cfn; +hookUnlockI2C=unlockI2Cfn; +} + +voidNoteSetFnNoteMutex(mutexFnlockFn,mutexFnunlockFn) +{ +hookLockNote=lockFn; +hookUnlockNote=unlockFn; +} + +voidNoteSetFnSerial(serialResetFnresetFn,serialTransmitFntransmitFn, +serialAvailableFnavailFn,serialReceiveFnreceiveFn) +{ +hookActiveInterface=interfaceSerial; + +hookSerialReset=resetFn; +hookSerialTransmit=transmitFn; +hookSerialAvailable=availFn; +hookSerialReceive=receiveFn; + +notecardReset=serialNoteReset; +notecardTransaction=serialNoteTransaction; +notecardChunkedReceive=serialChunkedReceive; +notecardChunkedTransmit=serialChunkedTransmit; +} + +voidNoteSetFnI2C(uint32_tnotecardAddr,uint32_tmaxTransmitSize, +i2cResetFnresetFn,i2cTransmitFntransmitFn, +i2cReceiveFnreceiveFn) +{ +i2cAddress=notecardAddr; +i2cMax=maxTransmitSize; + +hookActiveInterface=interfaceI2C; + +hookI2CReset=resetFn; +hookI2CTransmit=transmitFn; +hookI2CReceive=receiveFn; + +notecardReset=i2cNoteReset; +notecardTransaction=i2cNoteTransaction; +notecardChunkedReceive=i2cChunkedReceive; +notecardChunkedTransmit=i2cChunkedTransmit; +} + +//**************************************************************************/ +/**************************************************************************/ +voidNoteSetFnDisabled(void) +{ + +hookActiveInterface=interfaceNone; + +notecardReset=NULL; +notecardTransaction=NULL; +notecardChunkedReceive=NULL; +notecardChunkedTransmit=NULL; + +} + +//Runtimehookwrappers + +//**************************************************************************/ +/**************************************************************************/ +voidNoteDebugIntln(constchar*line,intn) +{ +if(line!=NULL){ +_Debug(line); +} +charstr[16]; +JItoA(n,str); +_Debug(str); +_Debug(c_newline); +} + +//**************************************************************************/ +/**************************************************************************/ +voidNoteDebugln(constchar*line) +{ +_Debug(line); +_Debug(c_newline); +} + +//**************************************************************************/ +/**************************************************************************/ +voidNoteDebug(constchar*line) +{ +#ifndefNOTE_NODEBUG +if(hookDebugOutput!=NULL){ +hookDebugOutput(line); +} +#endif +} + +//**************************************************************************/ +/**************************************************************************/ +voidNoteDebugWithLevel(uint8_tlevel,constchar*msg) +{ +#ifndefNOTE_NODEBUG + +if(level>NOTE_C_LOG_LEVEL){ +return; +} + +_Debug(msg); + +#endif//!NOTE_NODEBUG +} + +//**************************************************************************/ +/**************************************************************************/ +voidNoteDebugWithLevelLn(uint8_tlevel,constchar*msg) +{ +_DebugWithLevel(level,msg); +_DebugWithLevel(level,c_newline); +} + +//**************************************************************************/ +/**************************************************************************/ +uint32_tNoteGetMs(void) +{ +if(hookGetMs==NULL){ +return0; +} +returnhookGetMs(); +} + +//**************************************************************************/ +/**************************************************************************/ +voidNoteDelayMs(uint32_tms) +{ +if(hookDelayMs!=NULL){ +hookDelayMs(ms); +} +} + +#ifNOTE_SHOW_MALLOC||!defined(NOTE_C_LOW_MEM) +//**************************************************************************/ +/**************************************************************************/ +voidn_htoa32(uint32_tn,char*p) +{ +inti; +for(i=0;i<8;i++){ +uint32_tnibble=(n>>28)&0xff; +n=n<<4; +if(nibble>=10){ +*p++='A'+(nibble-10); +}else{ +*p++='0'+nibble; +} +} +*p='\0'; +} +#endif + +#ifNOTE_SHOW_MALLOC +//**************************************************************************/ +/**************************************************************************/ +void*malloc_show(size_tlen) +{ +charstr[16]; +JItoA(len,str); +hookDebugOutput("malloc"); +hookDebugOutput(str); +void*p=hookMalloc(len); +if(p==NULL){ +hookDebugOutput("FAIL"); +}else{ +n_htoa32((uint32_t)p,str); +hookDebugOutput(str); +} +returnp; +} +#endif + +//**************************************************************************/ +/**************************************************************************/ +void*NoteMalloc(size_tsize) +{ +if(hookMalloc==NULL){ +returnNULL; +} +#ifNOTE_SHOW_MALLOC +returnmalloc_show(size); +#else +returnhookMalloc(size); +#endif +} + +//**************************************************************************/ +/**************************************************************************/ +voidNoteFree(void*p) +{ +if(hookFree!=NULL){ +#ifNOTE_SHOW_MALLOC +charstr[16]; +n_htoa32((uint32_t)p,str); +hookDebugOutput("free"); +hookDebugOutput(str); +#endif +hookFree(p); +} +} + +//**************************************************************************/ +/**************************************************************************/ +voidNoteLockI2C(void) +{ +if(hookLockI2C!=NULL){ +hookLockI2C(); +} +} + +//**************************************************************************/ +/**************************************************************************/ +voidNoteUnlockI2C(void) +{ +if(hookUnlockI2C!=NULL){ +hookUnlockI2C(); +} +} + +//**************************************************************************/ +/**************************************************************************/ +voidnoteLockNote(void) +{ +if(hookLockNote!=NULL){ +hookLockNote(); +} +} + +//**************************************************************************/ +/**************************************************************************/ +voidnoteUnlockNote(void) +{ +if(hookUnlockNote!=NULL){ +hookUnlockNote(); +} +} + +//**************************************************************************/ +/**************************************************************************/ +boolnoteTransactionStart(uint32_ttimeoutMs) +{ +if(hookTransactionStart!=NULL){ +returnhookTransactionStart(timeoutMs); +} +returntrue; +} + +//**************************************************************************/ +/**************************************************************************/ +voidnoteTransactionStop(void) +{ +if(hookTransactionStop!=NULL){ +hookTransactionStop(); +} +} + +//**************************************************************************/ +/**************************************************************************/ +constchar*noteActiveInterface(void) +{ +switch(hookActiveInterface){ +caseinterfaceSerial: +return"serial"; +caseinterfaceI2C: +return"i2c"; +} +return"unknown"; +} + +//**************************************************************************/ +/**************************************************************************/ +boolnoteSerialReset(void) +{ +if(hookActiveInterface==interfaceSerial&&hookSerialReset!=NULL){ +returnhookSerialReset(); +} +returntrue; +} + +//**************************************************************************/ +/**************************************************************************/ +voidnoteSerialTransmit(uint8_t*text,size_tlen,boolflush) +{ +if(hookActiveInterface==interfaceSerial&&hookSerialTransmit!=NULL){ +hookSerialTransmit(text,len,flush); +} +} + +//**************************************************************************/ +/**************************************************************************/ +boolnoteSerialAvailable(void) +{ +if(hookActiveInterface==interfaceSerial&&hookSerialAvailable!=NULL){ +returnhookSerialAvailable(); +} +returnfalse; +} + +//**************************************************************************/ +/**************************************************************************/ +charnoteSerialReceive(void) +{ +if(hookActiveInterface==interfaceSerial&&hookSerialReceive!=NULL){ +returnhookSerialReceive(); +} +return0; +} + +//**************************************************************************/ +/**************************************************************************/ +boolnoteI2CReset(uint16_tDevAddress) +{ +if(hookActiveInterface==interfaceI2C&&hookI2CReset!=NULL){ +returnhookI2CReset(DevAddress); +} +returntrue; +} + +//**************************************************************************/ +/**************************************************************************/ +constchar*noteI2CTransmit(uint16_tDevAddress,uint8_t*pBuffer,uint16_tSize) +{ +if(hookActiveInterface==interfaceI2C&&hookI2CTransmit!=NULL){ +returnhookI2CTransmit(DevAddress,pBuffer,Size); +} +return"i2cnotactive"; +} + +//**************************************************************************/ +/**************************************************************************/ +constchar*noteI2CReceive(uint16_tDevAddress,uint8_t*pBuffer,uint16_tSize,uint32_t*available) +{ +if(hookActiveInterface==interfaceI2C&&hookI2CReceive!=NULL){ +returnhookI2CReceive(DevAddress,pBuffer,Size,available); +} +return"i2cnotactive"; +} + +//**************************************************************************/ +/**************************************************************************/ +uint32_tNoteI2CAddress(void) +{ +if(i2cAddress==0){ +returnNOTE_I2C_ADDR_DEFAULT; +} +returni2cAddress; +} + +//**************************************************************************/ +/**************************************************************************/ +voidNoteSetI2CAddress(uint32_ti2caddress) +{ +i2cAddress=i2caddress; +} + +//**************************************************************************/ +/**************************************************************************/ +uint32_tNoteI2CMax(void) +{ +//ManyArduinolibraries(suchasESP32)havealimitlessthan32,soifthemaxisn'tspecified +//wemustassumetheworstandsegmenttheI2Cmessagesintoverytinychunks. +if(i2cMax==0){ +returnNOTE_I2C_MAX_DEFAULT; +} +//Notedesignspecs +if(i2cMax>NOTE_I2C_MAX_MAX){ +i2cMax=NOTE_I2C_MAX_MAX; +} +returni2cMax; +} + + +//**************************************************************************/ +/**************************************************************************/ +boolnoteHardReset(void) +{ +if(notecardReset==NULL){ +returntrue; +} +returnnotecardReset(); +} + + +//**************************************************************************/ +/**************************************************************************/ +constchar*noteJSONTransaction(constchar*request,size_treqLen,char**response,uint32_ttimeoutMs) +{ +if(notecardTransaction==NULL||hookActiveInterface==interfaceNone){ +return"i2corserialinterfacemustbeselected"; +} +returnnotecardTransaction(request,reqLen,response,timeoutMs); +} + +/**************************************************************************/ +/**************************************************************************/ +constchar*noteChunkedReceive(uint8_t*buffer,uint32_t*size,booldelay, +uint32_ttimeoutMs,uint32_t*available) +{ +if(notecardChunkedReceive==NULL||hookActiveInterface==interfaceNone){ +return"i2corserialinterfacemustbeselected"; +} +returnnotecardChunkedReceive(buffer,size,delay,timeoutMs,available); +} + +/**************************************************************************/ +/**************************************************************************/ +constchar*noteChunkedTransmit(uint8_t*buffer,uint32_tsize,booldelay) +{ +if(notecardChunkedTransmit==NULL||hookActiveInterface==interfaceNone){ +return"i2corserialinterfacemustbeselected"; +} +returnnotecardChunkedTransmit(buffer,size,delay); +} + + + + diff --git a/doxygen/xml/n__request_8c.xml b/doxygen/xml/n__request_8c.xml new file mode 100644 index 00000000..19bc76f7 --- /dev/null +++ b/doxygen/xml/n__request_8c.xml @@ -0,0 +1,1530 @@ + + + + n_request.c + n_lib.h + + + + + + + + + + + + + + NOTE_C_STATIC + static + + + + + + + + + + CRC_FIELD_LENGTH + 22 + + + + + + + + + + CRC_FIELD_NAME_OFFSET + 1 + + + + + + + + + + CRC_FIELD_NAME_TEST + "\"crc\":\"" + + + + + + + + + + + + int + int suppressShowTransactions + + suppressShowTransactions + = 0 + + + + + + + + + + bool + bool resetRequired + + resetRequired + = true + + + + + + + + + + uint16_t + uint16_t lastRequestSeqno + + lastRequestSeqno + = 0 + + + + + + + + + + bool + bool notecardSupportsCrc + + notecardSupportsCrc + = false + + + + + + + + + + uint32_t + uint32_t lut[16] + [16] + lut + = { + 0x00000000, 0x1DB71064, 0x3B6E20C8, 0x26D930AC, 0x76DC4190, 0x6B6B51F4, + 0x4DB26158, 0x5005713C, 0xEDB88320, 0xF00F9344, 0xD6D6A3E8, 0xCB61B38C, + 0x9B64C2B0, 0x86D3D2D4, 0xA00AE278, 0xBDBDF21C +} + + + + + + + + + + + + int32_t + static int32_t crc32 + (const void *data, size_t length) + crc32 + + const void * + data + + + size_t + length + + +Compute the CRC32 of the passed in buffer. + + +Small lookup-table half-byte CRC32 algorithm. See https://create.stephan-brumme.com/crc32/#half-byte + + +data + + +The buffer. + + + + +length + + +The length of the buffer. + + + +The CRC32 of the buffer. + + + + + + + + + char * + static char * crcAdd + (char *json, uint16_t seqno) + crcAdd + + char * + json + + + uint16_t + seqno + + +Append a "crc" field to the passed in JSON buffer. + + +The "crc" field has a value of the form "SSSS:CCCCCCCC", where SSSS is the passed in sequence number and CCCCCCCC is the CRC32. + + +json + + +The JSON buffer to both add the CRC32 to and to compute the CRC32 over. + + + + +seqno + + +A 16-bit sequence number to include as a part of the CRC. + + + +A dynamically-allocated version of the passed in buffer with the CRC field added or NULL on error. + + + + + + + + + bool + static bool crcError + (char *json, uint16_t shouldBeSeqno) + crcError + + char * + json + + + uint16_t + shouldBeSeqno + + +Check the passed in JSON for CRC and sequence number errors. + + +If the calculated CRC32 doesn't match what's in the buffer, that's an error. If the sequence number in the buffer doesn't match shouldBeSeqno, that's an error. If there is no CRC field in the buffer, that's not an error UNLESS this function has been given a buffer with a CRC field before. In this case, the lack of a CRC field is an error. + + +json + + +The JSON buffer for which the CRC should be checked. Note that the CRC is stripped from the input JSON regardless of whether or not there was an error. + + + + +shouldBeSeqno + + +The expected sequence number. + + + +true if there's an error and false otherwise. + + + + + + + + + J * + static J* errDoc + (uint32_t id, const char *errmsg) + errDoc + + uint32_t + id + + + const char * + errmsg + + + + + + + + + + + void + void NoteSuspendTransactionDebug + (void) + NoteSuspendTransactionDebug + + void + + +Suppress showing transaction details. + + + + + + + + + void + void NoteResumeTransactionDebug + (void) + NoteResumeTransactionDebug + + void + + +Resume showing transaction details. + + + + + + + + + J * + J* NoteNewRequest + (const char *request) + NoteNewRequest + + const char * + request + + +Create a new JSON request. + + +Creates a dynamically allocated J object with one field "req" whose value is the passed in request string. + + +request + + +The name of the request, for example hub.set. + + + +A J object with the "req" field populated. + + + + + + + + + J * + J* NoteNewCommand + (const char *request) + NoteNewCommand + + const char * + request + + +Create a new JSON command. + + +Create a dynamically allocated J object with one field "cmd" whose value is the passed in request string. The difference between a command and a request is that the Notecard does not send a response to commands, only to requests. + + +request + + +The name of the command (e.g. card.attn). + + + +A J object with the "cmd" field populated. + + + + + + + + + bool + bool NoteRequest + (J *req) + NoteRequest + + J * + req + + +Send a request to the Notecard. + + +The passed in request object is always freed, regardless of if the request was successful or not. The response from the Notecard, if any, is freed and not returned to the caller. + + +req + + +Pointer to a J request object. + + + +true if successful and false if an error occurs (e.g. out of memory or the response from the Notecard has an "err" field). If req is a command rather than a request, a true return value indicates that the command was sent without error. However, since the Notecard sends no response to commands, it does not guarantee that the command was received and processed by the Notecard. + +NoteRequestResponse if you need to work with the response. + + + + + + + + + bool + bool NoteRequestWithRetry + (J *req, uint32_t timeoutSeconds) + NoteRequestWithRetry + + J * + req + + + uint32_t + timeoutSeconds + + +Send a request to the Notecard, retrying it until it succeeds or it times out. + + +The passed in request object is always freed, regardless of if the request was successful or not. The response from the Notecard, if any, is freed and not returned to the caller. + + +req + + +Pointer to a J request object. + + + + +timeoutSeconds + + +Time limit for retires, in seconds, if there is no response, or if the response contains an I/O error. + + + +true if successful and false if an error occurs (e.g. out of memory or the response from the Notecard has an "err" field). + +NoteRequestResponseWithRetry if you need to work with the response. + + + + + + + + + J * + J* NoteRequestResponse + (J *req) + NoteRequestResponse + + J * + req + + +Send a request to the Notecard and return the response. + + +The passed in request object is always freed, regardless of if the request was successful or not. + + +req + + +Pointer to a J request object. + + + +A J object with the response or NULL if there was an error sending the request. + +NoteResponseError to check the response for errors. + + + + + + + + + J * + J* NoteRequestResponseWithRetry + (J *req, uint32_t timeoutSeconds) + NoteRequestResponseWithRetry + + J * + req + + + uint32_t + timeoutSeconds + + +Send a request to the Notecard, retrying it until it succeeds or it times out, and return the response. + + +The passed in request object is always freed, regardless of if the request was successful or not. + + +req + + +Pointer to a J request object. + + + + +timeoutSeconds + + +Time limit for retires, in seconds, if there is no response, or if the response contains an I/O error. + + + +A J object with the response or NULL if there was an error sending the request. + +NoteResponseError to check the response for errors. + + + + + + + + + char * + char* NoteRequestResponseJSON + (const char *reqJSON) + NoteRequestResponseJSON + + const char * + reqJSON + + +Send a request to the Notecard and return the response. + + +Unlike NoteRequestResponse, this function expects the request to be a valid JSON C-string, rather than a J object. The string is expected to be newline-terminated, otherwise the call produces undefined behavior. The response is returned as a dynamically allocated JSON C-string. The response string is verbatim what was sent by the Notecard, which IS newline-terminated. The caller is responsible for freeing the response string. If the request was a command (i.e. it uses "cmd" instead of "req"), this function returns NULL, because the Notecard does not send a response to commands. + + +reqJSON + + +A valid newline-terminated JSON C-string containing the request. + + + +A newline-terminated JSON C-string with the response, or NULL if there was no response or if there was an error. + +When a "cmd" is sent, it is not possible to determine if an error occurred. + + + + + + + + + J * + J* NoteTransaction + (J *req) + NoteTransaction + + J * + req + + +Send a request to the Notecard and return the response. + + +This function doesn't free the passed in request object. The caller is responsible for freeing it. + + +req + + +Pointer to a J request object. + + + +A J object with the response or NULL if there was an error sending the request. + +NoteResponseError to check the response for errors. + + + + + + + + + J * + J* noteTransactionShouldLock + (J *req, bool lockNotecard) + noteTransactionShouldLock + + J * + req + + + bool + lockNotecard + + +Same as NoteTransaction, but takes an additional parameter that indicates if the Notecard should be locked. + + + + +req + + +The J cJSON request object. + + + + +lockNotecard + + +Set to true if the Notecard should be locked and false otherwise. + + + +a J cJSON object with the response, or NULL if there is insufficient memory. + + + + + + + + + void + void NoteResetRequired + (void) + NoteResetRequired + + void + + +Mark that a reset will be required before doing further I/O on a given port. + + + + + + + + + bool + bool NoteReset + (void) + NoteReset + + void + + +Initialize or re-initialize the module. + + +True if the reset was successful and false if not. + + + + + + + + + bool + bool NoteErrorContains + (const char *errstr, const char *errtype) + NoteErrorContains + + const char * + errstr + + + const char * + errtype + + +Check to see if a Notecard error is present in a JSON string. + + +Only Notecard errors enclosed in {} (e.g. {io} for an I/O error) are guaranteed by the API. + + +errstr + + +The string to check for errors. + + + + +errtype + + +The error substring to search for in errstr. + + + +true if errstr contains errtype and false otherwise. + + + + + + + + + void + void NoteErrorClean + (char *begin) + NoteErrorClean + + char * + begin + + +Clean error strings out of the specified buffer. + + +Notecard errors are enclosed in {} (e.g. {io} for an I/O error). This function takes the input string and removes all errors from it, meaning it removes any substrings matching the pattern {some error string}, including the braces. + + +begin + + +A C-string to to clean of errors. + + + + + + + + + + + uint64_t + uint64_t n_atoh + (char *p, int maxLen) + n_atoh + + char * + p + + + int + maxLen + + +Convert a hex string to a 64-bit unsigned integer. + + + + +p + + +The hex string to convert. + + + + +maxLen + + +The length of the hex string. + + + +The converted number. + + + + + + + + + + + +Written by Ray Ozzie and Blues Inc. team. +Copyright (c) 2019 Blues Inc. MIT License. Use of this source code is governed by licenses granted by the copyright holder including that found in the LICENSE file. + + + +#include"n_lib.h" + +#ifdefNOTE_C_TEST +#include"test_static.h" +#else +#defineNOTE_C_STATICstatic +#endif + +//Forflowtracing +staticintsuppressShowTransactions=0; + +//Flagthatgetssetwheneveranerroroccursthatshouldforceareset +staticboolresetRequired=true; + +//CRCdata +#ifndefNOTE_C_LOW_MEM +staticuint16_tlastRequestSeqno=0; +#defineCRC_FIELD_LENGTH22//,"crc":"SSSS:CCCCCCCC" +#defineCRC_FIELD_NAME_OFFSET1 +#defineCRC_FIELD_NAME_TEST"\"crc\":\"" +NOTE_C_STATICint32_tcrc32(constvoid*data,size_tlength); +NOTE_C_STATICchar*crcAdd(char*json,uint16_tseqno); +NOTE_C_STATICboolcrcError(char*json,uint16_tshouldBeSeqno); + +staticboolnotecardSupportsCrc=false; +#endif + +NOTE_C_STATICJ*errDoc(uint32_tid,constchar*errmsg) +{ +J*rspdoc=JCreateObject(); +if(rspdoc!=NULL){ +JAddStringToObject(rspdoc,c_err,errmsg); +JAddStringToObject(rspdoc,"src","note-c"); +if(id){ +JAddIntToObject(rspdoc,"id",id); +} +if(suppressShowTransactions==0){ +_DebugWithLevel(NOTE_C_LOG_LEVEL_ERROR,"[ERROR]"); +_DebugWithLevel(NOTE_C_LOG_LEVEL_ERROR,"{\"err\":\""); +_DebugWithLevel(NOTE_C_LOG_LEVEL_ERROR,errmsg); +_DebugWithLevelLn(NOTE_C_LOG_LEVEL_ERROR,"\",\"src\":\"note-c\"}"); +} +} + +returnrspdoc; +} + +voidNoteSuspendTransactionDebug(void) +{ +suppressShowTransactions++; +} + +voidNoteResumeTransactionDebug(void) +{ +suppressShowTransactions--; +} + +J*NoteNewRequest(constchar*request) +{ +J*reqdoc=JCreateObject(); +if(reqdoc!=NULL){ +JAddStringToObject(reqdoc,c_req,request); +} +returnreqdoc; +} + +J*NoteNewCommand(constchar*request) +{ +J*reqdoc=JCreateObject(); +if(reqdoc!=NULL){ +JAddStringToObject(reqdoc,c_cmd,request); +} +returnreqdoc; +} + +boolNoteRequest(J*req) +{ +J*rsp=NoteRequestResponse(req); +if(rsp==NULL){ +returnfalse; +} + +//Checkforatransactionerror,andexit +boolsuccess=JIsNullString(rsp,c_err); +JDelete(rsp); + +returnsuccess; +} + +boolNoteRequestWithRetry(J*req,uint32_ttimeoutSeconds) +{ +J*rsp=NoteRequestResponseWithRetry(req,timeoutSeconds); +//Ifthereisnoresponsereturnfalse +if(rsp==NULL){ +returnfalse; +} + +//Checkforatransactionerror,andexit +boolsuccess=JIsNullString(rsp,c_err); +JDelete(rsp); + +returnsuccess; +} + +J*NoteRequestResponse(J*req) +{ +//Exitifnullrequest.Thisallowssafeexecutionoftheform +//NoteRequestResponse(NoteNewRequest("xxx")) +if(req==NULL){ +returnNULL; +} +//Executethetransaction +J*rsp=NoteTransaction(req); +if(rsp==NULL){ +JDelete(req); +returnNULL; +} +//Freetherequestandexit +JDelete(req); +returnrsp; +} + +J*NoteRequestResponseWithRetry(J*req,uint32_ttimeoutSeconds) +{ +//Exitifnullrequest.Thisallowssafeexecutionoftheform +//NoteRequestResponse(NoteNewRequest("xxx")) +if(req==NULL){ +returnNULL; +} + +J*rsp; + +//Calculateexpirytimeinmilliseconds +uint32_tstartMs=_GetMs(); +uint32_ttimeoutMs=timeoutSeconds*1000; + +while(true){ +//Executethetransaction +rsp=NoteTransaction(req); + +//Loopifthereisnoresponse,orifthereisanioerror +if((rsp==NULL)||(JContainsString(rsp,c_err,c_ioerr)&&!JContainsString(rsp,c_err,c_unsupported))){ + +//Freeerrorresponse +if(rsp!=NULL){ +JDelete(rsp); +rsp=NULL; +} +}else{ + +//Exitlooponnon-nullresponsewithoutioerror +break; +} + +//Exitloopontimeout +if(_GetMs()-startMs>=timeoutMs){ +break; +} +} + +//Freetherequest +JDelete(req); + +//Returntheresponse +returnrsp; +} + +char*NoteRequestResponseJSON(constchar*reqJSON) +{ +uint32_ttransactionTimeoutMs=(CARD_INTER_TRANSACTION_TIMEOUT_SEC*1000); +char*rspJSON=NULL; + +if(reqJSON==NULL){ +returnNULL; +} + +//MakesurethatwegetaccesstotheNotecardbeforetransacting. +if(!_TransactionStart(transactionTimeoutMs)){ +returnNULL; +} + +_LockNote(); + +//Manuallytokenizethestringtosearchformultipleembeddedcommands(cannotusestrtok) +for(;;){ +constchar*endPtr; +constchar*constnewlinePtr=strchr(reqJSON,'\n'); + +//Ifstringisnotnewline-terminated,thenallocateanewstringandterminateit +if(NULL==newlinePtr){ +//AllJSONstringsshouldbenewline-terminatedtomeetthespecification,however +//thisisrequiredtoensurebackwardcompatibilitywiththepreviousimplementation. +constsize_ttempLen=strlen(reqJSON); +if(0==tempLen){ +NOTE_C_LOG_ERROR(ERRSTR("request:jsonbufzerolength",c_bad)); +break; +} + +NOTE_C_LOG_WARN(ERRSTR("Memoryallocationduetomalformedrequest(notnewline-terminated)",c_bad)); +char*consttemp=_Malloc(tempLen+2);//+2fornewlineandnull-terminator +if(temp==NULL){ +NOTE_C_LOG_ERROR(ERRSTR("request:jsonbufmallocfailed",c_mem)); +break; +} + +memcpy(temp,reqJSON,tempLen); +temp[tempLen]='\n'; +temp[tempLen+1]='\0'; +reqJSON=temp; +endPtr=&temp[tempLen]; +}else{ +endPtr=newlinePtr; +} +constsize_treqLen=((endPtr-reqJSON)+1); + +boolisCmd=false; +if(strstr(reqJSON,"\"cmd\":")!=NULL){ +//Onlycall`JParse()`afterverifyingtheprovidedrequest +//appearstocontainacommand(i.e.wefind`"cmd":`). +J*jsonObj=JParse(reqJSON); +if(!jsonObj){ +//InvalidJSON. +if(NULL==newlinePtr){ +_Free((void*)reqJSON); +} +break; +} +isCmd=JIsPresent(jsonObj,"cmd"); +JDelete(jsonObj); +} + +if(!isCmd){ +constchar*errstr=_Transaction(reqJSON,reqLen,&rspJSON,transactionTimeoutMs); +if(errstr!=NULL){ +NOTE_C_LOG_ERROR(errstr); +uint32_tid=0; +if(reqJSON!=NULL){ +J*req=JParse(reqJSON); +if(req!=NULL){ +id=JGetInt(req,"id"); +JDelete(req); +} +} +J*errdoc=errDoc(id,errstr); +if(errdoc!=NULL){ +char*errdocJSON=JPrintUnformatted(errdoc); +JDelete(errdoc); +if(errdocJSON!=NULL){ +uint32_terrdocJSONLen=strlen(errdocJSON); +rspJSON=(char*)_Malloc(errdocJSONLen+2); +if(rspJSON!=NULL){ +memcpy(rspJSON,errdocJSON,errdocJSONLen); +rspJSON[errdocJSONLen++]='\n'; +rspJSON[errdocJSONLen]='\0'; +} +_Free((void*)errdocJSON); +} +} +} +if(NULL==newlinePtr){ +_Free((void*)reqJSON); +} +break; +}else{ +//Ifit'sacommand,theNotecardwillnotrespond,sowepassNULLfor +//theresponseparameter. +constchar*errstr=_Transaction(reqJSON,reqLen,NULL,transactionTimeoutMs); +reqJSON=(endPtr+1); +if(errstr!=NULL){ +NOTE_C_LOG_ERROR(errstr); +} +} + +//Cleanupifweallocatedanewstring +if(NULL==newlinePtr){ +_Free((void*)reqJSON); +} +} + +_UnlockNote(); +_TransactionStop(); + +returnrspJSON; +} + +J*NoteTransaction(J*req) +{ +returnnoteTransactionShouldLock(req,true); +} + +/**************************************************************************/ +/**************************************************************************/ +J*noteTransactionShouldLock(J*req,boollockNotecard) +{ +//Validateincaseofmemoryfailureoftherequestor +if(req==NULL){ +returnNULL; +} + +//Makesurethatwegetaccesstothenotecardhardwarebeforewebegin +if(!_TransactionStart(CARD_INTER_TRANSACTION_TIMEOUT_SEC*1000)){ +returnNULL; +} + +//Determinetherequestorcommandtype +constchar*reqType=JGetString(req,"req"); +constchar*cmdType=JGetString(req,"cmd"); + +//Addtheuseragentobjectonlywhenwe'redoingahub.setandonlywhenwe're +//specifyingtheproductUID.Theintentisthatweonlypiggybackuseragent +//datawhenthehostisinitializingtheNotecard,asopposedtoeverytime +//thehostdoesahub.settochangemode. +#ifndefNOTE_DISABLE_USER_AGENT +if(!JIsPresent(req,"body")&&(strcmp(reqType,"hub.set")==0)&&JIsPresent(req,"product")){ +J*body=NoteUserAgent(); +if(body!=NULL){ +JAddItemToObject(req,"body",body); +} +} +#endif + +//Determinewhetherornotaresponsewillbeexpected,byvirtueof"cmd"beingpresent +boolnoResponseExpected=(reqType[0]=='\0'&&cmdType[0]!='\0'); + +//Ifaresetofthemoduleisrequiredforanyreason,doitnow. +//Wemustdothisbeforeacquiringlock. +if(resetRequired){ +if(!NoteReset()){ +_TransactionStop(); +returnNULL; +} +} + +if(lockNotecard){ +_LockNote(); +} + +//ExtracttheIDoftherequestsothaterrorscanbereturnedwiththesameID +uint32_tid=JGetInt(req,"id"); + +//SerializetheJSONrequest +char*json=JPrintUnformatted(req); +if(json==NULL){ +J*errRsp=errDoc(id,ERRSTR("can'tconverttoJSON",c_bad)); +if(lockNotecard){ +_UnlockNote(); +} +_TransactionStop(); +returnerrRsp; +} + +//Ifitisarequest(asopposedtoacommand),includeaCRCsothatthe +//requestmightberetriedifitisreceivedinacorruptedstate.(Wecan +//onlydothisonrequestsbecauseforcmd'sthereisno'responsechannel' +//wherewecanfindoutthatthecmdfailed.NotethataSeqnoisincluded +//aspartoftheCRCdatasothattwoidenticalrequestsoccurringwithinthe +//modulusofseqnoneveraremistakenasbeingthesamerequestbeingretried. +uint8_tlastRequestRetries=0; +#ifndefNOTE_C_LOW_MEM +boollastRequestCrcAdded=false; +if(!noResponseExpected){ +char*newJson=crcAdd(json,lastRequestSeqno); +if(newJson!=NULL){ +JFree(json); +json=newJson; +lastRequestCrcAdded=true; +} +} +#endif//!NOTE_C_LOW_MEM + +//Whennote.addorweb.*requestsareusedtotransferbinarydata,the +//timetocompletethetransactioncanvarydependingonthesizeof +//thepayloadandnetworkconditions.Therefore,it'spossiblefor +//thesetransactionstotimeoutprematurely. +// +//Thealgorithmbelow,executesthefollowinglogic: +//-Iftherequestisa`note.add`,setthetimeoutvaluetothe +//valueofthe"milliseconds"parameter,ifitexists.Ifit +//doesn't,usethe"seconds"parameter.Ifthatdoesn'texist, +//usethestandardtimeoutof`CARD_INTER_TRANSACTION_TIMEOUT_SEC`. +//-Iftherequestisa`web.*`,followthesamelogic,butinstead +//ofusingthestandardtimeout,usetheNotecardtimeoutof90 +//secondsforall`web.*`transactions. +uint32_ttransactionTimeoutMs=(CARD_INTER_TRANSACTION_TIMEOUT_SEC*1000); + +//Interrogatetherequest +if(JContainsString(req,(reqType?"req":"cmd"),"note.add")){ +if(JIsPresent(req,"milliseconds")){ +NOTE_C_LOG_DEBUG("Using`milliseconds`parametervaluefor" +"timeout."); +transactionTimeoutMs=JGetInt(req,"milliseconds"); +}elseif(JIsPresent(req,"seconds")){ +NOTE_C_LOG_DEBUG("Using`seconds`parametervaluefortimeout."); +transactionTimeoutMs=(JGetInt(req,"seconds")*1000); +} +}elseif(JContainsString(req,(reqType?"req":"cmd"),"web.")){ +NOTE_C_LOG_DEBUG("web.*requestreceived."); +if(JIsPresent(req,"milliseconds")){ +NOTE_C_LOG_DEBUG("Using`milliseconds`parametervaluefor" +"timeout."); +transactionTimeoutMs=JGetInt(req,"milliseconds"); +}elseif(JIsPresent(req,"seconds")){ +NOTE_C_LOG_DEBUG("Using`seconds`parametervaluefortimeout."); +transactionTimeoutMs=(JGetInt(req,"seconds")*1000); +}else{ +NOTE_C_LOG_DEBUG("No`milliseconds`or`seconds`parameter" +"provided.Defaultingto90-secondtimeout."); +transactionTimeoutMs=(90*1000); +} +} + +//Ifwe'reperformingretries,thisiswherewecomebackto +constchar*errStr=NULL; +char*responseJSON=NULL; +J*rsp=NULL; +while(true){ +//Ifnoretrypossibility,breakout +if(lastRequestRetries>CARD_REQUEST_RETRIES_ALLOWED){ +break; +}else{ +//freeonretry +JDelete(rsp); +} + +//resetvariables +rsp=NULL; +responseJSON=NULL; + +//Trace +if(suppressShowTransactions==0){ +NOTE_C_LOG_INFO(json); +} + +//SwapNULL-terminatorfornewline-terminator +constsize_tjsonLen=strlen(json); +json[jsonLen]='\n'; + +//Performthetransaction +if(noResponseExpected){ +errStr=_Transaction(json,(jsonLen+1),NULL,transactionTimeoutMs); +break; +} +errStr=_Transaction(json,(jsonLen+1),&responseJSON,transactionTimeoutMs); + +//Swapnewline-terminatorforNULL-terminator +json[jsonLen]='\0'; + +//Ifthere'sanI/Oerroronthetransaction,retry +if(errStr!=NULL){ +JFree(responseJSON); +resetRequired=!_Reset(); +lastRequestRetries++; +NOTE_C_LOG_WARN(ERRSTR("retryingI/Oerrordetectedbyhost",c_iobad)); +_DelayMs(500); +continue; +} + +#ifndefNOTE_C_LOW_MEM +//IfwesentaCRCintherequest,examinetheresponseJSONtoseeif +//ithasaCRCerror.NotethattheCRCisstrippedfromthe +//responseJSONasaside-effectofthismethod. +if(lastRequestCrcAdded&&crcError(responseJSON,lastRequestSeqno)){ +JFree(responseJSON); +errStr="crcerror{io}"; +lastRequestRetries++; +NOTE_C_LOG_ERROR(ERRSTR("CRCerroronresponse",c_iobad)); +_DelayMs(500); +continue; +} +#endif//!NOTE_C_LOW_MEM + +//SeeiftheresponseJSONcan'tbeunmarshaled,orifitcontainsan{io}error +rsp=JParse(responseJSON); +boolisBadBin=false; +boolisIoError=false; +if(rsp!=NULL){ +isBadBin=JContainsString(rsp,c_err,c_badbinerr); +isIoError=JContainsString(rsp,c_err,c_ioerr)&&!JContainsString(rsp,c_err,c_unsupported); +}else{ +//FailedtoparseresponseasJSON +if(responseJSON==NULL){ +NOTE_C_LOG_ERROR(ERRSTR("responseexpected,butresponseisNULL.",c_ioerr)); +}else{ +#ifndefNOTE_C_LOW_MEM +_DebugWithLevel(NOTE_C_LOG_LEVEL_ERROR,"[ERROR]"); +_DebugWithLevel(NOTE_C_LOG_LEVEL_ERROR,"invalidJSON:"); +_DebugWithLevel(NOTE_C_LOG_LEVEL_ERROR,responseJSON); +#else +NOTE_C_LOG_ERROR(c_ioerr); +#endif +} +isIoError=true; +} +if(isIoError||isBadBin){ +NOTE_C_LOG_ERROR(JGetString(rsp,c_err)); +JFree(responseJSON); + +if(isBadBin){ +errStr=ERRSTR("notecardbinaryi/oerror{bad-bin}{io}",c_badbinerr); +NOTE_C_LOG_DEBUG("{bad-bin}isnotelibigleforretry"); +break; +}else{ +errStr=ERRSTR("notecardi/oerror{io}",c_ioerr); +lastRequestRetries++; +NOTE_C_LOG_WARN(ERRSTR("retryingI/Oerrordetectedbynotecard",c_iobad)); +_DelayMs(500); +continue; +} +} + +//Transactioncompleted +break; +} + +//Bumptherequestsequencenumbernowthatwe'veprocessedthisrequest,successorerror +#ifndefNOTE_C_LOW_MEM +lastRequestSeqno++; +#endif + +//FreetheoriginalserializedJSONrequest +JFree(json); + +//Iferror,queueupareset +if(errStr!=NULL){ +JDelete(rsp); +NoteResetRequired(); +J*errRsp=errDoc(id,errStr); +if(lockNotecard){ +_UnlockNote(); +} +_TransactionStop(); +returnerrRsp; +} + +//Exitwithablankobject(withnoerrfield)ifnoresponseexpected +if(noResponseExpected){ +if(lockNotecard){ +_UnlockNote(); +} +_TransactionStop(); +returnJCreateObject(); +} + +//Debug +if(suppressShowTransactions==0){ +NOTE_C_LOG_INFO(responseJSON); +} + +//Discardthebuffernowthatithasbeenlogged +JFree(responseJSON); + +if(lockNotecard){ +_UnlockNote(); +} + +_TransactionStop(); + +//Done +returnrsp; + +} + +voidNoteResetRequired(void) +{ +resetRequired=true; +} + +boolNoteReset(void) +{ +_LockNote(); +resetRequired=!_Reset(); +_UnlockNote(); +return!resetRequired; +} + +boolNoteErrorContains(constchar*errstr,constchar*errtype) +{ +return(strstr(errstr,errtype)!=NULL); +} + +voidNoteErrorClean(char*begin) +{ +while(true){ +char*end=&begin[strlen(begin)+1]; +char*beginBrace=strchr(begin,'{'); +if(beginBrace==NULL){ +break; +} +if(beginBrace>begin&&*(beginBrace-1)==''){ +beginBrace--; +} +char*endBrace=strchr(beginBrace,'}'); +if(endBrace==NULL){ +break; +} +char*afterBrace=endBrace+1; +memmove(beginBrace,afterBrace,end-afterBrace); +} +} + +#ifndefNOTE_C_LOW_MEM + +uint64_tn_atoh(char*p,intmaxLen) +{ +uint64_tn=0; +char*ep=p+maxLen; +while(p<ep){ +charch=*p++; +booldigit=(ch>='0'&&ch<='9'); +boollcase=(ch>='a'&&ch<='f'); +boolspace=(ch==''); +boolucase=(ch>='A'&&ch<='F'); +if(!digit&&!lcase&&!space&&!ucase){ +break; +} +n*=16; +if(digit){ +n+=ch-'0'; +}elseif(lcase){ +n+=10+(ch-'a'); +}elseif(ucase){ +n+=10+(ch-'A'); +} +} +return(n); +} + +staticuint32_tlut[16]={ +0x00000000,0x1DB71064,0x3B6E20C8,0x26D930AC,0x76DC4190,0x6B6B51F4, +0x4DB26158,0x5005713C,0xEDB88320,0xF00F9344,0xD6D6A3E8,0xCB61B38C, +0x9B64C2B0,0x86D3D2D4,0xA00AE278,0xBDBDF21C +}; + +NOTE_C_STATICint32_tcrc32(constvoid*data,size_tlength) +{ +uint32_tpreviousCrc32=0; +uint32_tcrc=~previousCrc32; +unsignedchar*current=(unsignedchar*)data; +while(length--){ +crc=lut[(crc^*current)&0x0F]^(crc>>4); +crc=lut[(crc^(*current>>4))&0x0F]^(crc>>4); +current++; +} +return~crc; +} + +NOTE_C_STATICchar*crcAdd(char*json,uint16_tseqno) +{ + +//Allocateablockthesizeoftheinputjsonplusthesizeof +//thefieldtobeadded.NotethattheinputJSONendsin'"}'and +//thiswillbereplacedwithacombinationof4hexdigitsofthe +//seqnoplus8hexdigitsoftheCRC32,andthe'}'willbe +//transformedinto',"crc":"SSSS:CCCCCCCC"}'whereSSSSisthe +//seqnoandCCCCCCCCisthecrc32.Notethatthecommais +//replacedwithaspaceiftheinputjsondoesn'tcontain +//anyfields,sothatwealwaysreturncompliantJSON. +size_tjsonLen=strlen(json); +//MinimumJSONis"{}"andmustendwithaclosing"}". +if(jsonLen<2||json[jsonLen-1]!='}'){ +returnNULL; +} +char*newJson=(char*)_Malloc(jsonLen+CRC_FIELD_LENGTH+1); +if(newJson==NULL){ +returnNULL; +} +boolisEmptyObject=(memchr(json,':',jsonLen)==NULL); +size_tnewJsonLen=jsonLen-1; +memcpy(newJson,json,newJsonLen); +newJson[newJsonLen++]=(isEmptyObject?'':',');//Replace} +newJson[newJsonLen++]='"';//+1 +newJson[newJsonLen++]='c';//+2 +newJson[newJsonLen++]='r';//+3 +newJson[newJsonLen++]='c';//+4 +newJson[newJsonLen++]='"';//+5 +newJson[newJsonLen++]=':';//+6 +newJson[newJsonLen++]='"';//+7 +n_htoa16(seqno,(uint8_t*)&newJson[newJsonLen]); +newJsonLen+=4;//+11 +newJson[newJsonLen++]=':';//+12 +n_htoa32(crc32(json,jsonLen),&newJson[newJsonLen]); +newJsonLen+=8;//+20 +newJson[newJsonLen++]='"';//+21 +newJson[newJsonLen++]='}';//+22==CRC_FIELD_LENGTH +newJson[newJsonLen]='\0';//null-terminatedasitcamein +returnnewJson; +} + +NOTE_C_STATICboolcrcError(char*json,uint16_tshouldBeSeqno) +{ +//Stripoffanycrlfforcrccalculation +size_tjsonLen=strlen(json); +while(jsonLen>0&&json[jsonLen-1]<=''){ +jsonLen--; +} +//MinimumvalidJSONis"{}"(2bytes)andmustendwithaclosing"}". +if(jsonLen<CRC_FIELD_LENGTH+2||json[jsonLen-1]!='}'){ +returnfalse; +} +//SeeifithasacompliantCRCfield +size_tfieldOffset=((jsonLen-1)-CRC_FIELD_LENGTH); +if(memcmp(&json[fieldOffset+CRC_FIELD_NAME_OFFSET],CRC_FIELD_NAME_TEST,sizeof(CRC_FIELD_NAME_TEST)-1)!=0){ +//Ifwe'veseenaCRCbefore,weshouldseeoneeverytime +returnnotecardSupportsCrc?true:false; +} +//Ifwegethere,we'veseenatleastoneCRCfromtheNotecard,soweshouldexpectit. +notecardSupportsCrc=true; +char*p=&json[fieldOffset+CRC_FIELD_NAME_OFFSET+(sizeof(CRC_FIELD_NAME_TEST)-1)]; +uint16_tactualSeqno=(uint16_t)n_atoh(p,4); +uint32_tactualCrc32=(uint32_t)n_atoh(p+5,8); +json[fieldOffset++]='}'; +json[fieldOffset]='\0'; +uint32_tshouldBeCrc32=crc32(json,fieldOffset); +return(shouldBeSeqno!=actualSeqno||shouldBeCrc32!=actualCrc32); +} + +#endif//!NOTE_C_LOW_MEM + + + + diff --git a/doxygen/xml/note_8h.xml b/doxygen/xml/note_8h.xml new file mode 100644 index 00000000..121e9a04 --- /dev/null +++ b/doxygen/xml/note_8h.xml @@ -0,0 +1,6088 @@ + + + + note.h + float.h + limits.h + stdbool.h + stdint.h + n_cjson.h + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + NoteMD5Context + NotePayloadDesc + + + _NOTE_C_STRINGIZE + x + #x + + + + + + + + + + NOTE_C_STRINGIZE + x + _NOTE_C_STRINGIZE(x) + + + + + + + + + + NOTE_C_VERSION_MAJOR + 2 + + + + + + + + + + NOTE_C_VERSION_MINOR + 2 + + + + + + + + + + NOTE_C_VERSION_PATCH + 1 + + + + + + + + + + NOTE_C_VERSION + NOTE_C_STRINGIZE(NOTE_C_VERSION_MAJOR) "." NOTE_C_STRINGIZE(NOTE_C_VERSION_MINOR) "." NOTE_C_STRINGIZE(NOTE_C_VERSION_PATCH) + + + + + + + + + + ERRSTR + x + y + (x) + + + + + + + + + + JINTEGER_MIN + INT64_MIN + + + + + + + + + + JINTEGER_MAX + INT64_MAX + + + + + + + + + + NoteNewBody + JCreateObject + + + + + + + + + + NoteAddBodyToObject + a + b + JAddItemToObject(a, "body", b) + + + + + + + + + + NoteGetBody + a + JGetObject(a, "body") + + + + + + + + + + SYNCSTATUS_LEVEL_MAJOR + 0 + + + + + + + + + + SYNCSTATUS_LEVEL_MINOR + 1 + + + + + + + + + + SYNCSTATUS_LEVEL_DETAILED + 2 + + + + + + + + + + SYNCSTATUS_LEVEL_ALGORITHMIC + 3 + + + + + + + + + + SYNCSTATUS_LEVEL_ALL + -1 + + + + + + + + + + NoteResponseError + rsp + (!JIsNullString(rsp, "err")) + +Check if the Notecard response contains an error. + + + + +rsp + + +The response to check. + + + +true if there's an error and false if there's not. + + + + + + + + + NoteResponseErrorContains + rsp + errstr + (JContainsString(rsp, "err", errstr)) + + + + + + + + + + NoteDeleteResponse + rsp + JDelete(rsp) + +Free a response from the Notecard. + + + + +rsp + + +The response to free. + + + + + + + + + + + NOTE_I2C_ADDR_DEFAULT + 0x17 + +The default I2C address of the Notecard. + + + + + + + + + NOTE_I2C_HEADER_SIZE + 2 + + + + + + + + + + NOTE_I2C_MAX_MAX + (UCHAR_MAX - NOTE_I2C_HEADER_SIZE) + + + + + + + + + + NOTE_I2C_MAX_DEFAULT + 30 + +The maximum number of bytes to request from or transmit to the Notecard in a single chunk. + + + + + + + + + NOTE_C_LOG_LEVEL_ERROR + 0 + + + + + + + + + + NOTE_C_LOG_LEVEL_WARN + 1 + + + + + + + + + + NOTE_C_LOG_LEVEL_INFO + 2 + + + + + + + + + + NOTE_C_LOG_LEVEL_DEBUG + 3 + + + + + + + + + + NOTE_C_LOG_FILE_AND_LINE + lvl + + + + + + + + + + NOTE_C_LOG_ERROR + msg + do { \ + NOTE_C_LOG_FILE_AND_LINE(NOTE_C_LOG_LEVEL_ERROR); \ + NoteDebugWithLevel(NOTE_C_LOG_LEVEL_ERROR, "[ERROR] "); \ + NoteDebugWithLevelLn(NOTE_C_LOG_LEVEL_ERROR, msg); \ +} while (0); + + + + + + + + + + NOTE_C_LOG_WARN + msg + do { \ + NOTE_C_LOG_FILE_AND_LINE(NOTE_C_LOG_LEVEL_WARN); \ + NoteDebugWithLevel(NOTE_C_LOG_LEVEL_WARN, "[WARN] "); \ + NoteDebugWithLevelLn(NOTE_C_LOG_LEVEL_WARN, msg); \ +} while (0); + + + + + + + + + + NOTE_C_LOG_INFO + msg + do { \ + NOTE_C_LOG_FILE_AND_LINE(NOTE_C_LOG_LEVEL_INFO); \ + NoteDebugWithLevel(NOTE_C_LOG_LEVEL_INFO, "[INFO] "); \ + NoteDebugWithLevelLn(NOTE_C_LOG_LEVEL_INFO, msg); \ +} while (0); + + + + + + + + + + NOTE_C_LOG_DEBUG + msg + do { \ + NOTE_C_LOG_FILE_AND_LINE(NOTE_C_LOG_LEVEL_DEBUG); \ + NoteDebugWithLevel(NOTE_C_LOG_LEVEL_DEBUG, "[DEBUG] "); \ + NoteDebugWithLevelLn(NOTE_C_LOG_LEVEL_DEBUG, msg); \ +} while (0); + + + + + + + + + + NOTE_C_LOG_LEVEL + NOTE_C_LOG_LEVEL_INFO + + + + + + + + + + JTYPE_NOT_PRESENT + 0 + + + + + + + + + + JTYPE_BOOL_TRUE + 1 + + + + + + + + + + JTYPE_BOOL_FALSE + 2 + + + + + + + + + + JTYPE_BOOL + JTYPE_BOOL_TRUE + + + + + + + + + + JTYPE_NULL + 3 + + + + + + + + + + JTYPE_NUMBER_ZERO + 4 + + + + + + + + + + JTYPE_NUMBER + 5 + + + + + + + + + + JTYPE_STRING_BLANK + 6 + + + + + + + + + + JTYPE_STRING_ZERO + 7 + + + + + + + + + + JTYPE_STRING_NUMBER + 8 + + + + + + + + + + JTYPE_STRING_BOOL_TRUE + 9 + + + + + + + + + + JTYPE_STRING_BOOL_FALSE + 10 + + + + + + + + + + JTYPE_STRING + 11 + + + + + + + + + + JTYPE_OBJECT + 12 + + + + + + + + + + JTYPE_ARRAY + 13 + + + + + + + + + + JGetObjectItemName + j + (j->string) + + + + + + + + + + JNTOA_PRECISION + (16) + + + + + + + + + + JNTOA_MAX + (44) + + + + + + + + + + NOTE_MD5_HASH_SIZE + 16 + + + + + + + + + + NOTE_MD5_HASH_STRING_SIZE + (((NOTE_MD5_HASH_SIZE)*2)+1) + + + + + + + + + + NoteSend + NoteAdd + + + + + + + + + + NP_SEGTYPE_LEN + 4 + + + + + + + + + + NP_SEGLEN_LEN + sizeof(uint32_t) + + + + + + + + + + NP_SEGHDR_LEN + (NP_SEGTYPE_LEN + NP_SEGLEN_LEN) + + + + + + + + + + TBOOL + true + + + + + + + + + + TINT8 + 11 + + + + + + + + + + TINT16 + 12 + + + + + + + + + + TINT24 + 13 + + + + + + + + + + TINT32 + 14 + + + + + + + + + + TINT64 + 18 + + + + + + + + + + TUINT8 + 21 + + + + + + + + + + TUINT16 + 22 + + + + + + + + + + TUINT24 + 23 + + + + + + + + + + TUINT32 + 24 + + + + + + + + + + TFLOAT16 + 12.1 + + + + + + + + + + TFLOAT32 + 14.1 + + + + + + + + + + TFLOAT64 + 18.1 + + + + + + + + + + TSTRING + N + _NOTE_C_STRINGIZE(N) + + + + + + + + + + TSTRINGV + _NOTE_C_STRINGIZE(0) + + + + + + + + + + + + double + typedef double JNUMBER + + JNUMBER + +The floating point type used for JSON handling in note-c. + + + + + + + + + int64_t + typedef int64_t JINTEGER + + JINTEGER + +The signed integer type used for JSON handling in note-c. + + + + + + + + + uint64_t + typedef uint64_t JUINTEGER + + JUINTEGER + +The unsigned integer type used for JSON handling in note-c. + + + + + + + + + JUINTEGER + typedef JUINTEGER JTIME + + JTIME + + + + + + + + + + void(* + mutexFn + )(void) + mutexFn + +The type for the various mutex (i.e. lock/unlock) hooks. + + + + + + + + + void *(* + mallocFn + )(size_t size) + mallocFn + +The type for the memory allocation hook. + + + + +size + + +The number of bytes to allocate. + + + +A pointer to the newly allocated memory or NULL on failure. + + + + + + + + + void(* + freeFn + )(void *mem) + freeFn + +The type for the memory freeing hook. + + + + +mem + + +Pointer to the memory to free. + + + + + + + + + + + void(* + delayMsFn + )(uint32_t ms) + delayMsFn + +The type for the millisecond delay hook. + + + + +ms + + +The number of milliseconds to delay for. + + + + + + + + + + + uint32_t(* + getMsFn + )(void) + getMsFn + +The type for the millisecond counter hook. + + +The value of the millisecond counter. + + + + + + + + + size_t(* + typedef size_t(* debugOutputFn) (const char *text) + )(const char *text) + debugOutputFn + + + + + + + + + + bool(* + serialResetFn + )(void) + serialResetFn + +The type for the serial reset hook. + + +This hook is used to reset the serial peripheral used to communicate with the Notecard. +true on success and false on failure. + + + + + + + + + void(* + serialTransmitFn + )(uint8_t *txBuf, size_t txBufSize, bool flush) + serialTransmitFn + +The type for the serial transmit hook. + + + + +txBuf + + +A buffer of bytes to transmit to the Notecard. + + + + +txBufSize + + +The size, in bytes, of txBuf. + + + + +flush + + +If true, flush the serial peripheral's transmit buffer. + + + + + + + + + + + bool(* + serialAvailableFn + )(void) + serialAvailableFn + +The type for the serial available hook. + + +true if there's data to read and false otherwise. + + + + + + + + + char(* + serialReceiveFn + )(void) + serialReceiveFn + +The type for the serial receive hook. + + +The received byte. + + + + + + + + + bool(* + i2cResetFn + )(uint16_t address) + i2cResetFn + +The type for the I2C reset hook. + + +This hook is used to reset the I2C peripheral used to communicate with the Notecard. + + +address + + +The I2C address of the Notecard. + + + + + + + + + + + const char *(* + i2cTransmitFn + )(uint16_t address, uint8_t *txBuf, uint16_t txBufSize) + i2cTransmitFn + +The type for the I2C transmit hook. + + +This hook is used to send a buffer of bytes to the Notecard. + + +address + + +The I2C address of the Notecard to transmit the data to. + + + + +txBuf + + +A buffer of bytes to transmit to the Notecard. + + + + +txBufSize + + +The size, in bytes, of txBuf. + + + +NULL on success and an error string on failure. + + + + + + + + + const char *(* + i2cReceiveFn + )(uint16_t address, uint8_t *rxBuf, uint16_t rxBufSize, uint32_t *available) + i2cReceiveFn + +The type for the I2C receive hook. + + +This hook is used to receive a buffer of bytes from the Notecard. + + +address + + +The I2C address of the Notecard sending the data to receive. + + + + +rxBuf + + +A buffer to hold the data received from the Notecard. + + + + +rxBufSize + + +The size, in bytes, of rxBuf. + + + + +available + + +The number of bytes remaining to be received, if any. + + + +NULL on success and an error string on failure. + + + + + + + + + bool(* + typedef bool(* txnStartFn) (uint32_t timeoutMs) + )(uint32_t timeoutMs) + txnStartFn + + + + + + + + + + void(* + typedef void(* txnStopFn) (void) + )(void) + txnStopFn + + + + + + + + + + + + bool + bool NoteReset + (void) + NoteReset + + void + + +Initialize or re-initialize the module. + + +True if the reset was successful and false if not. + + + + + + + + + void + void NoteResetRequired + (void) + NoteResetRequired + + void + + +Mark that a reset will be required before doing further I/O on a given port. + + + + + + + + + J * + J* NoteNewRequest + (const char *request) + NoteNewRequest + + const char * + request + + +Create a new JSON request. + + +Creates a dynamically allocated J object with one field "req" whose value is the passed in request string. + + +request + + +The name of the request, for example hub.set. + + + +A J object with the "req" field populated. + + + + + + + + + J * + J* NoteNewCommand + (const char *request) + NoteNewCommand + + const char * + request + + +Create a new JSON command. + + +Create a dynamically allocated J object with one field "cmd" whose value is the passed in request string. The difference between a command and a request is that the Notecard does not send a response to commands, only to requests. + + +request + + +The name of the command (e.g. card.attn). + + + +A J object with the "cmd" field populated. + + + + + + + + + J * + J* NoteRequestResponse + (J *req) + NoteRequestResponse + + J * + req + + +Send a request to the Notecard and return the response. + + +The passed in request object is always freed, regardless of if the request was successful or not. + + +req + + +Pointer to a J request object. + + + +A J object with the response or NULL if there was an error sending the request. + +NoteResponseError to check the response for errors. + + + + + + + + + J * + J* NoteRequestResponseWithRetry + (J *req, uint32_t timeoutSeconds) + NoteRequestResponseWithRetry + + J * + req + + + uint32_t + timeoutSeconds + + +Send a request to the Notecard, retrying it until it succeeds or it times out, and return the response. + + +The passed in request object is always freed, regardless of if the request was successful or not. + + +req + + +Pointer to a J request object. + + + + +timeoutSeconds + + +Time limit for retires, in seconds, if there is no response, or if the response contains an I/O error. + + + +A J object with the response or NULL if there was an error sending the request. + +NoteResponseError to check the response for errors. + + + + + + + + + char * + char* NoteRequestResponseJSON + (const char *reqJSON) + NoteRequestResponseJSON + + const char * + reqJSON + + +Send a request to the Notecard and return the response. + + +Unlike NoteRequestResponse, this function expects the request to be a valid JSON C-string, rather than a J object. The string is expected to be newline-terminated, otherwise the call produces undefined behavior. The response is returned as a dynamically allocated JSON C-string. The response string is verbatim what was sent by the Notecard, which IS newline-terminated. The caller is responsible for freeing the response string. If the request was a command (i.e. it uses "cmd" instead of "req"), this function returns NULL, because the Notecard does not send a response to commands. + + +reqJSON + + +A valid newline-terminated JSON C-string containing the request. + + + +A newline-terminated JSON C-string with the response, or NULL if there was no response or if there was an error. + +When a "cmd" is sent, it is not possible to determine if an error occurred. + + + + + + + + + void + void NoteSuspendTransactionDebug + (void) + NoteSuspendTransactionDebug + + void + + +Suppress showing transaction details. + + + + + + + + + void + void NoteResumeTransactionDebug + (void) + NoteResumeTransactionDebug + + void + + +Resume showing transaction details. + + + + + + + + + bool + bool NoteDebugSyncStatus + (int pollFrequencyMs, int maxLevel) + NoteDebugSyncStatus + + int + pollFrequencyMs + + + int + maxLevel + + + + + + + + + + + bool + bool NoteRequest + (J *req) + NoteRequest + + J * + req + + +Send a request to the Notecard. + + +The passed in request object is always freed, regardless of if the request was successful or not. The response from the Notecard, if any, is freed and not returned to the caller. + + +req + + +Pointer to a J request object. + + + +true if successful and false if an error occurs (e.g. out of memory or the response from the Notecard has an "err" field). If req is a command rather than a request, a true return value indicates that the command was sent without error. However, since the Notecard sends no response to commands, it does not guarantee that the command was received and processed by the Notecard. + +NoteRequestResponse if you need to work with the response. + + + + + + + + + bool + bool NoteRequestWithRetry + (J *req, uint32_t timeoutSeconds) + NoteRequestWithRetry + + J * + req + + + uint32_t + timeoutSeconds + + +Send a request to the Notecard, retrying it until it succeeds or it times out. + + +The passed in request object is always freed, regardless of if the request was successful or not. The response from the Notecard, if any, is freed and not returned to the caller. + + +req + + +Pointer to a J request object. + + + + +timeoutSeconds + + +Time limit for retires, in seconds, if there is no response, or if the response contains an I/O error. + + + +true if successful and false if an error occurs (e.g. out of memory or the response from the Notecard has an "err" field). + +NoteRequestResponseWithRetry if you need to work with the response. + + + + + + + + + J * + J* NoteTransaction + (J *req) + NoteTransaction + + J * + req + + +Send a request to the Notecard and return the response. + + +This function doesn't free the passed in request object. The caller is responsible for freeing it. + + +req + + +Pointer to a J request object. + + + +A J object with the response or NULL if there was an error sending the request. + +NoteResponseError to check the response for errors. + + + + + + + + + bool + bool NoteErrorContains + (const char *errstr, const char *errtype) + NoteErrorContains + + const char * + errstr + + + const char * + errtype + + +Check to see if a Notecard error is present in a JSON string. + + +Only Notecard errors enclosed in {} (e.g. {io} for an I/O error) are guaranteed by the API. + + +errstr + + +The string to check for errors. + + + + +errtype + + +The error substring to search for in errstr. + + + +true if errstr contains errtype and false otherwise. + + + + + + + + + void + void NoteErrorClean + (char *errbuf) + NoteErrorClean + + char * + errbuf + begin + + +Clean error strings out of the specified buffer. + + +Notecard errors are enclosed in {} (e.g. {io} for an I/O error). This function takes the input string and removes all errors from it, meaning it removes any substrings matching the pattern {some error string}, including the braces. + + +begin + + +A C-string to to clean of errors. + + + + + + + + + + + void + void NoteSetFnDebugOutput + (debugOutputFn fn) + NoteSetFnDebugOutput + + debugOutputFn + fn + + +Set the platform-specific debug output function. + + + + +fn + + +A function pointer to call for debug output. + + + + + + + + + + + void + void NoteSetFnTransaction + (txnStartFn startFn, txnStopFn stopFn) + NoteSetFnTransaction + + txnStartFn + startFn + + + txnStopFn + stopFn + + +Set the platform-specific transaction initiation/completion fn's. + + + + +startFn + + +The platform-specific transaction initiation function to use. + + + + +stopFn + + +The platform-specific transaction completion function to use. to use. + + + + + + + + + + + void + void NoteSetFnMutex + (mutexFn lockI2Cfn, mutexFn unlockI2Cfn, mutexFn lockNotefn, mutexFn unlockNotefn) + NoteSetFnMutex + + mutexFn + lockI2Cfn + + + mutexFn + unlockI2Cfn + + + mutexFn + lockNotefn + + + mutexFn + unlockNotefn + + +Set the platform-specific mutex functions for I2C and the Notecard. + + + + +lockI2Cfn + + +The platform-specific I2C lock function to use. + + + + +unlockI2Cfn + + +The platform-specific I2C unlock function to use. + + + + +lockNotefn + + +The platform-specific Notecard lock function to use. + + + + +unlockNotefn + + +The platform-specific Notecard unlock function to use. + + + + + + + + + + + void + void NoteSetFnI2CMutex + (mutexFn lockI2Cfn, mutexFn unlockI2Cfn) + NoteSetFnI2CMutex + + mutexFn + lockI2Cfn + + + mutexFn + unlockI2Cfn + + +Set the platform-specific mutex functions for I2C. + + + + +lockI2Cfn + + +The platform-specific I2C lock function. + + + + +unlockI2Cfn + + +The platform-specific I2C unlock function. + + + + + + + + + + + void + void NoteSetFnNoteMutex + (mutexFn lockFn, mutexFn unlockFn) + NoteSetFnNoteMutex + + mutexFn + lockFn + + + mutexFn + unlockFn + + +Set the platform-specific mutex functions for the Notecard. + + + + +lockFn + + +The platform-specific Notecard lock function. + + + + +unlockFn + + +The platform-specific Notecard unlock function. + + + + + + + + + + + void + void NoteSetFnDefault + (mallocFn mallocfn, freeFn freefn, delayMsFn delayfn, getMsFn millisfn) + NoteSetFnDefault + + mallocFn + mallocfn + + + freeFn + freefn + + + delayMsFn + delayfn + + + getMsFn + millisfn + + +Set the default memory and timing hooks if they aren't already set. + + + + +mallocfn + + +The default memory allocation malloc function to use. + + + + +freefn + + +The default memory free function to use. + + + + +delayfn + + +The default delay function to use. + + + + +millisfn + + +The default 'millis' function to use. + + + + + + + + + + + void + void NoteSetFn + (mallocFn mallocHook, freeFn freeHook, delayMsFn delayMsHook, getMsFn getMsHook) + NoteSetFn + + mallocFn + mallocHook + + + freeFn + freeHook + + + delayMsFn + delayMsHook + + + getMsFn + getMsHook + + +Set the platform-specific memory and timing hooks. + + + + +mallocHook + + +The platform-specific memory allocation function (i.e. malloc). + + + + +freeHook + + +The platform-specific memory free function (i.e. free). + + + + +delayMsHook + + +The platform-specific millisecond delay function. + + + + +getMsHook + + +The platform-specific millisecond counter function. + + + + + + + + + + + void + void NoteSetFnSerial + (serialResetFn resetFn, serialTransmitFn transmitFn, serialAvailableFn availFn, serialReceiveFn receiveFn) + NoteSetFnSerial + + serialResetFn + resetFn + + + serialTransmitFn + transmitFn + + + serialAvailableFn + availFn + + + serialReceiveFn + receiveFn + + +Set the platform-specific hooks for communicating with the Notecard over serial. + + + + +resetFn + + +The platform-specific serial reset function. + + + + +transmitFn + + +The platform-specific serial transmit function. + + + + +availFn + + +The platform-specific serial available function. + + + + +receiveFn + + +The platform-specific serial receive function. + + + + + + + + + + + void + void NoteSetFnI2C + (uint32_t notecardAddr, uint32_t maxTransmitSize, i2cResetFn resetFn, i2cTransmitFn transmitFn, i2cReceiveFn receiveFn) + NoteSetFnI2C + + uint32_t + notecardAddr + + + uint32_t + maxTransmitSize + + + i2cResetFn + resetFn + + + i2cTransmitFn + transmitFn + + + i2cReceiveFn + receiveFn + + +Set the platform-specific hooks for communicating with the Notecard over I2C, as well as the I2C address of the Notecard and maximum transmission size. + + + + +notecardAddr + + +The I2C address of the Notecard. Pass 0 to use the default address. + + + + +maxTransmitSize + + +The max number of bytes to send to the Notecard in a single I2C segment. Pass 0 to use the default maximum transmission size. + + + + +resetFn + + +The platform-specific I2C reset function. + + + + +transmitFn + + +The platform-specific I2C transmit function. + + + + +receiveFn + + +The platform-specific I2C receive function. + + + + + + + + + + + void + void NoteSetFnDisabled + (void) + NoteSetFnDisabled + + void + + +Set the platform-specific communications method to be disabled. + + + + + + + + + void + void NoteSetI2CAddress + (uint32_t i2caddress) + NoteSetI2CAddress + + uint32_t + i2caddress + + +Set the I2C address for communication with the Notecard. + + + + +i2caddress + + +the I2C address to use for the Notecard. + + + + + + + + + + + J * + J* NoteUserAgent + (void) + NoteUserAgent + + void + + + + + + + + + + + void + void NoteUserAgentUpdate + (J *ua) + NoteUserAgentUpdate + + J * + ua + + + + + + + + + + + void + void NoteSetUserAgent + (char *agent) + NoteSetUserAgent + + char * + agent + + + + + + + + + + + void + void NoteSetUserAgentOS + (char *os_name, char *os_platform, char *os_family, char *os_version) + NoteSetUserAgentOS + + char * + os_name + + + char * + os_platform + + + char * + os_family + + + char * + os_version + + + + + + + + + + + void + void NoteSetUserAgentCPU + (int cpu_mem, int cpu_mhz, int cpu_cores, char *cpu_vendor, char *cpu_name) + NoteSetUserAgentCPU + + int + cpu_mem + + + int + cpu_mhz + + + int + cpu_cores + + + char * + cpu_vendor + + + char * + cpu_name + + + + + + + + + + + void + void NoteDebug + (const char *message) + NoteDebug + + const char * + message + line + + +Write to the debug stream. + + + + +line + + +A debug string for output. + + + + + + + + + + + void + void NoteDebugln + (const char *message) + NoteDebugln + + const char * + message + line + + +Write text to the debug stream and output a newline. + + + + +line + + +A debug string for output. + + + + + + + + + + + void + void NoteDebugIntln + (const char *message, int n) + NoteDebugIntln + + const char * + message + line + + + int + n + + +Write a number to the debug stream and output a newline. + + + + +line + + +A debug string for output. + + + + +n + + +The number to write. + + + + + + + + + + + void + void NoteDebugf + (const char *format,...) + NoteDebugf + + const char * + format + + + ... + + + + + + + + + + + void + void NoteDebugWithLevel + (uint8_t level, const char *msg) + NoteDebugWithLevel + + uint8_t + level + + + const char * + msg + + +Write the message to the debug stream, if the level is less than or equal to NOTE_C_LOG_LEVEL. Otherwise, the message is dropped. + + + + +level + + +The log level of the message. See the NOTE_C_LOG_LEVEL_* macros in note.h for possible values. + + + + +msg + + +The debug message. + + + + + + + + + + + void + void NoteDebugWithLevelLn + (uint8_t level, const char *msg) + NoteDebugWithLevelLn + + uint8_t + level + + + const char * + msg + + +Same as NoteDebugWithLevel, but add a newline at the end. + + + + +level + + +The log level of the message. See the NOTE_C_LOG_LEVEL_* macros in note.h for possible values. + + + + +msg + + +The debug message. + + + + + + + + + + + void * + void* NoteMalloc + (size_t size) + NoteMalloc + + size_t + size + + +Allocate a memory chunk using the platform-specific hook. + + + + +size + + +the number of bytes to allocate. + + + + + + + + + + + void + void NoteFree + (void *) + NoteFree + + void * + p + + +Free memory using the platform-specific hook. + + + + +p + + +A pointer to the memory address to free. + + + + + + + + + + + uint32_t + uint32_t NoteGetMs + (void) + NoteGetMs + + void + + +Get the current milliseconds value from the platform-specific hook. + + +The current milliseconds value. + + + + + + + + + void + void NoteDelayMs + (uint32_t ms) + NoteDelayMs + + uint32_t + ms + + +Delay milliseconds using the platform-specific hook. + + + + +ms + + +the milliseconds delay value. + + + + + + + + + + + void + void NoteLockI2C + (void) + NoteLockI2C + + void + + +Lock the I2C bus using the platform-specific hook. + + + + + + + + + void + void NoteUnlockI2C + (void) + NoteUnlockI2C + + void + + +Unlock the I2C bus using the platform-specific hook. + + + + + + + + + uint32_t + uint32_t NoteI2CAddress + (void) + NoteI2CAddress + + void + + +Get the I2C address of the Notecard. + + +The current I2C address. + + + + + + + + + uint32_t + uint32_t NoteI2CMax + (void) + NoteI2CMax + + void + + +Determine the maximum number of bytes for each segment of data sent to the Notecard over I2C. + + +A 32-bit integer of the maximum number of bytes per I2C segment. + + + + + + + + + uint32_t + uint32_t NoteMemAvailable + (void) + NoteMemAvailable + + void + + + + + + + + + + + bool + bool NotePrint + (const char *text) + NotePrint + + const char * + text + + + + + + + + + + + void + void NotePrintln + (const char *line) + NotePrintln + + const char * + line + + + + + + + + + + + bool + bool NotePrintf + (const char *format,...) + NotePrintf + + const char * + format + + + ... + + + + + + + + + + + size_t + size_t strlcpy + (char *dst, const char *src, size_t siz) + strlcpy + + char * + dst + + + const char * + src + + + size_t + siz + + + + + + + + + + + size_t + size_t strlcat + (char *dst, const char *src, size_t siz) + strlcat + + char * + dst + + + const char * + src + + + size_t + siz + + + + + + + + + + + void + void JInit + (void) + JInit + + void + + + + + + + + + + + void + void JCheck + (void) + JCheck + + void + + + + + + + + + + + bool + bool JIsPresent + (J *json, const char *field) + JIsPresent + + J * + json + + + const char * + field + + +Determine if a field is present in a JSON object. + + + + +json + + +The JSON object. + + + + +field + + +The field to find. + + + +True if the field is present, or false if the field is not present or the JSON object is NULL. + + + + + + + + + char * + char* JGetString + (J *json, const char *field) + JGetString + + J * + json + + + const char * + field + + +Get the value of a string field from a JSON object. + + + + +json + + +The JSON object. + + + + +field + + +The string field to query. + + + +A pointer to the string if the field exists and is a string, otherwise the empty string (""). + +The returned string is a pointer to the string contained in the JSON object. It is not a copy of the string, so once the JSON object is freed, the pointer is no longer valid. + + + + + + + + + JNUMBER + JNUMBER JGetNumber + (J *json, const char *field) + JGetNumber + + J * + json + + + const char * + field + + +Get the floating point value of a number field from a JSON object. + + + + +json + + +The JSON object. + + + + +field + + +The number field to query. + + + +The value of the number field if the field exists and is a number, otherwise 0.0. + +The returned value is the floating point representation of the number. + +JGetInt + +JGetBool + + + + + + + + + J * + J* JGetArray + (J *json, const char *field) + JGetArray + + J * + json + + + const char * + field + + +Get the value of an array field from a JSON object. + + + + +json + + +The JSON object. + + + + +field + + +The array field to query. + + + +A pointer to the array, which is itself a JSON object (J *), if the field exists and is an array, otherwise NULL. + +The returned JSON object is a pointer to the array contained in the parent JSON object. It is not a copy, so once the parent JSON object is freed, the pointer is no longer valid. + + + + + + + + + J * + J* JGetObject + (J *json, const char *field) + JGetObject + + J * + json + + + const char * + field + + +Get the value of an object field from a JSON object. + + + + +json + + +The JSON object. + + + + +field + + +The object field to query. + + + +A pointer to the object, which is itself a JSON object (J *), if the field exists and is an object, otherwise NULL. + +The returned JSON object is a pointer to the object contained in the parent JSON object. It is not a copy, so once the parent JSON object is freed, the pointer is no longer valid. + + + + + + + + + JINTEGER + JINTEGER JGetInt + (J *json, const char *field) + JGetInt + + J * + json + + + const char * + field + + +Get the integer value of a number field from a JSON object. + + + + +json + + +The JSON object. + + + + +field + + +The number field to query. + + + +The value of the number field if the field exists and is a number, otherwise 0. + +The returned value is the integer representation of the number. + +JGetBool + +JGetNumber + + + + + + + + + bool + bool JGetBool + (J *json, const char *field) + JGetBool + + J * + json + + + const char * + field + + +Get the value of a boolean field from a JSON object. + + + + +json + + +The JSON object. + + + + +field + + +The boolean field to query. + + + +The value of the boolean field if it exists and is a boolean, otherwise false. + +JGetInt + +JGetNumber + + + + + + + + + JNUMBER + JNUMBER JNumberValue + (J *item) + JNumberValue + + J * + item + + +Return the number representation of an item. + + + + +item + + +The JSON item. + + + +The number, or 0.0, if NULL. + + + + + + + + + char * + char* JStringValue + (J *item) + JStringValue + + J * + item + + +Return the string representation of an item. + + + + +item + + +The JSON item. + + + +The string value, or empty string, if NULL. + + + + + + + + + bool + bool JBoolValue + (J *item) + JBoolValue + + J * + item + + +Return the boolean representation of an item. + + + + +item + + +The JSON item. + + + +The boolean value. + + + + + + + + + JINTEGER + JINTEGER JIntValue + (J *item) + JIntValue + + J * + item + + +Return the integer representation of an item. + + + + +item + + +The JSON item. + + + +The number, or 0, if NULL. + + + + + + + + + bool + bool JIsNullString + (J *json, const char *field) + JIsNullString + + J * + json + + + const char * + field + + +Determine if a JSON object is valid and if a field is not present, or null. + + + + +json + + +The JSON response object. + + + + +field + + +The field to return. + + + +bool. False if the field is not present, or NULL. + + + + + + + + + bool + bool JIsExactString + (J *json, const char *field, const char *teststr) + JIsExactString + + J * + json + + + const char * + field + + + const char * + teststr + + +Determine if a field exists, is a string and matches a provided value. + + + + +json + + +The JSON response object. + + + + +field + + +The field to check. + + + + +teststr + + +The string to test against the returned value. + + + +bol. Whether the fields match exactly. + + + + + + + + + bool + bool JContainsString + (J *json, const char *field, const char *substr) + JContainsString + + J * + json + + + const char * + field + + + const char * + substr + + +Determine if a field exists, is a string and contains a provided value. + + + + +json + + +The JSON response object. + + + + +field + + +The field to check. + + + + +substr + + +The string to test against the returned value. + + + +bol. Whether the provided string is found within the field. + + + + + + + + + bool + bool JAddBinaryToObject + (J *json, const char *fieldName, const void *binaryData, uint32_t binaryDataLen) + JAddBinaryToObject + + J * + json + + + const char * + fieldName + + + const void * + binaryData + + + uint32_t + binaryDataLen + + +Add binary data as a Base64-encoded string field to a JSON object. + + + + +json + + +The JSON object. + + + + +fieldName + + +The name to use for the field. + + + + +binaryData + + +A buffer of binary data to encode. + + + + +binaryDataLen + + +The length of the binary data in bytes. + + + +True if the string was successfully encoded and added to the object, otherwise false. + + + + + + + + + bool + bool JGetBinaryFromObject + (J *json, const char *fieldName, uint8_t **retBinaryData, uint32_t *retBinaryDataLen) + JGetBinaryFromObject + + J * + json + + + const char * + fieldName + + + uint8_t ** + retBinaryData + + + uint32_t * + retBinaryDataLen + + +Decode a Base64-encoded string field in a JSON object and return the decoded bytes. + + + + +json + + +The JSON object. + + + + +fieldName + + +The name of the field. + + + + +retBinaryData + + +A pointer to a pointer, used to hold the pointer to the decoded bytes. + + + + +retBinaryDataLen + + +A pointer to an unsigned integer, used to hold the length of the decoded bytes. + + + +True if the string was successfully decoded and returned, otherwise false. + +The returned binary buffer must be freed by the user with JFree when it is no longer needed. + +On error, the returned binary buffer and data length shall be set to NULL and zero (0), respectively. + + + + + + + + + const char * + const char* JGetItemName + (const J *item) + JGetItemName + + const J * + item + + +Get the object name. + + + + +item + + +The JSON object. + + + +The name, or the empty string, if NULL. + + + + + + + + + char * + char* JAllocString + (uint8_t *buffer, uint32_t len) + JAllocString + + uint8_t * + buffer + + + uint32_t + len + + +Convert a buffer/len to a null-terminated c-string. + + + + +buffer + + +A buffer containing the bytes to convert. + + + + +len + + +The length of buffer in bytes. + + + +If buffer is NULL or length 0, the empty string. If allocation fails, NULL. On success, the converted c-string. The returned string must be freed with NoteFree. + + + + + + + + + const char * + const char* JType + (J *item) + JType + + J * + item + + +Return the type of an item, as a string. + + + + +item + + +The JSON item. + + + +The type + + + + + + + + + int + int JGetType + (J *json, const char *field) + JGetType + + J * + json + + + const char * + field + + +Get the type of a field, as an int usable in a switch statement. + + + + +json + + +The JSON object containing the field. + + + + +field + + +The field's name. + + + +The type of the field on success. JTYPE_NOT_PRESENT on error or if the field doesn't exist. + + + + + + + + + int + int JGetItemType + (J *item) + JGetItemType + + J * + item + + + + + + + + + + + int + int JBaseItemType + (int type) + JBaseItemType + + int + type + + + + + + + + + + + char * + char* JNtoA + (JNUMBER f, char *buf, int precision) + JNtoA + + JNUMBER + f + + + char * + buf + + + int + precision + + + + + + + + + + + JNUMBER + JNUMBER JAtoN + (const char *string, char **endPtr) + JAtoN + + const char * + string + + + char ** + endPtr + + + + + + + + + + + void + void JItoA + (JINTEGER n, char *s) + JItoA + + JINTEGER + n + + + char * + s + + +Convert an integer to text. + + + + +n + + +The integer to convert. + + + + +s + + +The buffer to hold the text. + + + +The buffer must be large enough because no bounds checking is done. + + + + + + + + + JINTEGER + JINTEGER JAtoI + (const char *s) + JAtoI + + const char * + s + string + + +Convert text to an integer. + + + + +string + + +A null-terminated text buffer + + + +An integer, or 0 if invalid + + + + + + + + + int + int JB64EncodeLen + (int len) + JB64EncodeLen + + int + len + + + + + + + + + + + int + int JB64Encode + (char *coded_dst, const char *plain_src, int len_plain_src) + JB64Encode + + char * + coded_dst + + + const char * + plain_src + + + int + len_plain_src + + + + + + + + + + + int + int JB64DecodeLen + (const char *coded_src) + JB64DecodeLen + + const char * + coded_src + + + + + + + + + + + int + int JB64Decode + (char *plain_dst, const char *coded_src) + JB64Decode + + char * + plain_dst + + + const char * + coded_src + + + + + + + + + + + void + void NoteMD5Init + (NoteMD5Context *ctx) + NoteMD5Init + + NoteMD5Context * + ctx + + + + + + + + + + + void + void NoteMD5Update + (NoteMD5Context *ctx, unsigned char const *buf, unsigned long len) + NoteMD5Update + + NoteMD5Context * + ctx + + + unsigned char const * + buf + + + unsigned long + len + + + + + + + + + + + void + void NoteMD5Final + (unsigned char *digest, NoteMD5Context *ctx) + NoteMD5Final + + unsigned char * + digest + + + NoteMD5Context * + ctx + + + + + + + + + + + void + void NoteMD5Transform + (unsigned long buf[4], const unsigned char inraw[64]) + NoteMD5Transform + + unsigned long + buf + [4] + + + const unsigned char + inraw + [64] + + + + + + + + + + + void + void NoteMD5Hash + (unsigned char *data, unsigned long len, unsigned char *retHash) + NoteMD5Hash + + unsigned char * + data + + + unsigned long + len + + + unsigned char * + retHash + + + + + + + + + + + void + void NoteMD5HashString + (unsigned char *data, unsigned long len, char *strbuf, unsigned long buflen) + NoteMD5HashString + + unsigned char * + data + + + unsigned long + len + + + char * + strbuf + + + unsigned long + buflen + + + + + + + + + + + void + void NoteMD5HashToString + (unsigned char *hash, char *strbuf, unsigned long buflen) + NoteMD5HashToString + + unsigned char * + hash + + + char * + strbuf + + + unsigned long + buflen + + + + + + + + + + + uint32_t + uint32_t NoteBinaryCodecDecode + (const uint8_t *encData, uint32_t encDataLen, uint8_t *decBuf, uint32_t decBufSize) + NoteBinaryCodecDecode + + const uint8_t * + encData + + + uint32_t + encDataLen + + + uint8_t * + decBuf + + + uint32_t + decBufSize + + + + + + + + + + + uint32_t + uint32_t NoteBinaryCodecEncode + (const uint8_t *decData, uint32_t decDataLen, uint8_t *encBuf, uint32_t encBufSize) + NoteBinaryCodecEncode + + const uint8_t * + decData + + + uint32_t + decDataLen + + + uint8_t * + encBuf + + + uint32_t + encBufSize + + + + + + + + + + + uint32_t + uint32_t NoteBinaryCodecMaxDecodedLength + (uint32_t bufferSize) + NoteBinaryCodecMaxDecodedLength + + uint32_t + bufferSize + + + + + + + + + + + uint32_t + uint32_t NoteBinaryCodecMaxEncodedLength + (uint32_t unencodedLength) + NoteBinaryCodecMaxEncodedLength + + uint32_t + unencodedLength + + + + + + + + + + + const char * + const char* NoteBinaryStoreDecodedLength + (uint32_t *len) + NoteBinaryStoreDecodedLength + + uint32_t * + len + + + + + + + + + + + const char * + const char* NoteBinaryStoreEncodedLength + (uint32_t *len) + NoteBinaryStoreEncodedLength + + uint32_t * + len + + + + + + + + + + + const char * + const char* NoteBinaryStoreReceive + (uint8_t *buffer, uint32_t bufLen, uint32_t decodedOffset, uint32_t decodedLen) + NoteBinaryStoreReceive + + uint8_t * + buffer + + + uint32_t + bufLen + + + uint32_t + decodedOffset + + + uint32_t + decodedLen + + + + + + + + + + + const char * + const char* NoteBinaryStoreReset + (void) + NoteBinaryStoreReset + + void + + + + + + + + + + + const char * + const char* NoteBinaryStoreTransmit + (uint8_t *unencodedData, uint32_t unencodedLen, uint32_t bufLen, uint32_t notecardOffset) + NoteBinaryStoreTransmit + + uint8_t * + unencodedData + + + uint32_t + unencodedLen + + + uint32_t + bufLen + + + uint32_t + notecardOffset + + + + + + + + + + + uint32_t + uint32_t NoteSetSTSecs + (uint32_t secs) + NoteSetSTSecs + + uint32_t + secs + + + + + + + + + + + bool + bool NoteTimeValid + (void) + NoteTimeValid + + void + + + + + + + + + + + bool + bool NoteTimeValidST + (void) + NoteTimeValidST + + void + + + + + + + + + + + JTIME + JTIME NoteTime + (void) + NoteTime + + void + + + + + + + + + + + JTIME + JTIME NoteTimeST + (void) + NoteTimeST + + void + + + + + + + + + + + void + void NoteTimeRefreshMins + (uint32_t mins) + NoteTimeRefreshMins + + uint32_t + mins + + + + + + + + + + + void + void NoteTimeSet + (JTIME secondsUTC, int offset, char *zone, char *country, char *area) + NoteTimeSet + + JTIME + secondsUTC + + + int + offset + + + char * + zone + + + char * + country + + + char * + area + + + + + + + + + + + bool + bool NoteLocalTimeST + (uint16_t *retYear, uint8_t *retMonth, uint8_t *retDay, uint8_t *retHour, uint8_t *retMinute, uint8_t *retSecond, char **retWeekday, char **retZone) + NoteLocalTimeST + + uint16_t * + retYear + + + uint8_t * + retMonth + + + uint8_t * + retDay + + + uint8_t * + retHour + + + uint8_t * + retMinute + + + uint8_t * + retSecond + + + char ** + retWeekday + + + char ** + retZone + + + + + + + + + + + bool + bool NoteRegion + (char **retCountry, char **retArea, char **retZone, int *retZoneOffset) + NoteRegion + + char ** + retCountry + + + char ** + retArea + + + char ** + retZone + + + int * + retZoneOffset + + + + + + + + + + + bool + bool NoteLocationValid + (char *errbuf, uint32_t errbuflen) + NoteLocationValid + + char * + errbuf + + + uint32_t + errbuflen + + + + + + + + + + + bool + bool NoteLocationValidST + (char *errbuf, uint32_t errbuflen) + NoteLocationValidST + + char * + errbuf + + + uint32_t + errbuflen + + + + + + + + + + + void + void NoteTurboIO + (bool enable) + NoteTurboIO + + bool + enable + + + + + + + + + + + JINTEGER + JINTEGER NoteGetEnvInt + (const char *variable, JINTEGER defaultVal) + NoteGetEnvInt + + const char * + variable + + + JINTEGER + defaultVal + + + + + + + + + + + JNUMBER + JNUMBER NoteGetEnvNumber + (const char *variable, JNUMBER defaultVal) + NoteGetEnvNumber + + const char * + variable + + + JNUMBER + defaultVal + + + + + + + + + + + bool + bool NoteGetEnv + (const char *variable, const char *defaultVal, char *buf, uint32_t buflen) + NoteGetEnv + + const char * + variable + + + const char * + defaultVal + + + char * + buf + + + uint32_t + buflen + + + + + + + + + + + bool + bool NoteSetEnvDefault + (const char *variable, char *buf) + NoteSetEnvDefault + + const char * + variable + + + char * + buf + + + + + + + + + + + bool + bool NoteSetEnvDefaultNumber + (const char *variable, JNUMBER defaultVal) + NoteSetEnvDefaultNumber + + const char * + variable + + + JNUMBER + defaultVal + + + + + + + + + + + bool + bool NoteSetEnvDefaultInt + (const char *variable, JINTEGER defaultVal) + NoteSetEnvDefaultInt + + const char * + variable + + + JINTEGER + defaultVal + + + + + + + + + + + bool + bool NoteIsConnected + (void) + NoteIsConnected + + void + + + + + + + + + + + bool + bool NoteIsConnectedST + (void) + NoteIsConnectedST + + void + + + + + + + + + + + bool + bool NoteGetNetStatus + (char *statusBuf, int statusBufLen) + NoteGetNetStatus + + char * + statusBuf + + + int + statusBufLen + + + + + + + + + + + bool + bool NoteGetVersion + (char *versionBuf, int versionBufLen) + NoteGetVersion + + char * + versionBuf + + + int + versionBufLen + + + + + + + + + + + bool + bool NoteGetLocation + (JNUMBER *retLat, JNUMBER *retLon, JTIME *time, char *statusBuf, int statusBufLen) + NoteGetLocation + + JNUMBER * + retLat + + + JNUMBER * + retLon + + + JTIME * + time + + + char * + statusBuf + + + int + statusBufLen + + + + + + + + + + + bool + bool NoteSetLocation + (JNUMBER lat, JNUMBER lon) + NoteSetLocation + + JNUMBER + lat + + + JNUMBER + lon + + + + + + + + + + + bool + bool NoteClearLocation + (void) + NoteClearLocation + + void + + + + + + + + + + + bool + bool NoteGetLocationMode + (char *modeBuf, int modeBufLen) + NoteGetLocationMode + + char * + modeBuf + + + int + modeBufLen + + + + + + + + + + + bool + bool NoteSetLocationMode + (const char *mode, uint32_t seconds) + NoteSetLocationMode + + const char * + mode + + + uint32_t + seconds + + + + + + + + + + + bool + bool NoteGetServiceConfig + (char *productBuf, int productBufLen, char *serviceBuf, int serviceBufLen, char *deviceBuf, int deviceBufLen, char *snBuf, int snBufLen) + NoteGetServiceConfig + + char * + productBuf + + + int + productBufLen + + + char * + serviceBuf + + + int + serviceBufLen + + + char * + deviceBuf + + + int + deviceBufLen + + + char * + snBuf + + + int + snBufLen + + + + + + + + + + + bool + bool NoteGetServiceConfigST + (char *productBuf, int productBufLen, char *serviceBuf, int serviceBufLen, char *deviceBuf, int deviceBufLen, char *snBuf, int snBufLen) + NoteGetServiceConfigST + + char * + productBuf + + + int + productBufLen + + + char * + serviceBuf + + + int + serviceBufLen + + + char * + deviceBuf + + + int + deviceBufLen + + + char * + snBuf + + + int + snBufLen + + + + + + + + + + + bool + bool NoteGetStatus + (char *statusBuf, int statusBufLen, JTIME *bootTime, bool *retUSB, bool *retSignals) + NoteGetStatus + + char * + statusBuf + + + int + statusBufLen + + + JTIME * + bootTime + + + bool * + retUSB + + + bool * + retSignals + + + + + + + + + + + bool + bool NoteGetStatusST + (char *statusBuf, int statusBufLen, JTIME *bootTime, bool *retUSB, bool *retSignals) + NoteGetStatusST + + char * + statusBuf + + + int + statusBufLen + + + JTIME * + bootTime + + + bool * + retUSB + + + bool * + retSignals + + + + + + + + + + + bool + bool NoteSleep + (char *stateb64, uint32_t seconds, const char *modes) + NoteSleep + + char * + stateb64 + + + uint32_t + seconds + + + const char * + modes + + + + + + + + + + + bool + bool NoteWake + (int stateLen, void *state) + NoteWake + + int + stateLen + + + void * + state + + + + + + + + + + + bool + bool NoteFactoryReset + (bool deleteConfigSettings) + NoteFactoryReset + + bool + deleteConfigSettings + + + + + + + + + + + bool + bool NoteSetSerialNumber + (const char *sn) + NoteSetSerialNumber + + const char * + sn + + + + + + + + + + + bool + bool NoteSetProductID + (const char *productID) + NoteSetProductID + + const char * + productID + + + + + + + + + + + bool + bool NoteSetUploadMode + (const char *uploadMode, int uploadMinutes, bool align) + NoteSetUploadMode + + const char * + uploadMode + + + int + uploadMinutes + + + bool + align + + + + + + + + + + + bool + bool NoteSetSyncMode + (const char *uploadMode, int uploadMinutes, int downloadMinutes, bool align, bool sync) + NoteSetSyncMode + + const char * + uploadMode + + + int + uploadMinutes + + + int + downloadMinutes + + + bool + align + + + bool + sync + + + + + + + + + + + bool + bool NoteAdd + (const char *target, J *body, bool urgent) + NoteAdd + + const char * + target + + + J * + body + + + bool + urgent + + + + + + + + + + + bool + bool NoteSendToRoute + (const char *method, const char *routeAlias, char *notefile, J *body) + NoteSendToRoute + + const char * + method + + + const char * + routeAlias + + + char * + notefile + + + J * + body + + + + + + + + + + + bool + bool NoteGetVoltage + (JNUMBER *voltage) + NoteGetVoltage + + JNUMBER * + voltage + + + + + + + + + + + bool + bool NoteGetTemperature + (JNUMBER *temp) + NoteGetTemperature + + JNUMBER * + temp + + + + + + + + + + + bool + bool NoteGetContact + (char *nameBuf, int nameBufLen, char *orgBuf, int orgBufLen, char *roleBuf, int roleBufLen, char *emailBuf, int emailBufLen) + NoteGetContact + + char * + nameBuf + + + int + nameBufLen + + + char * + orgBuf + + + int + orgBufLen + + + char * + roleBuf + + + int + roleBufLen + + + char * + emailBuf + + + int + emailBufLen + + + + + + + + + + + bool + bool NoteSetContact + (char *nameBuf, char *orgBuf, char *roleBuf, char *emailBuf) + NoteSetContact + + char * + nameBuf + + + char * + orgBuf + + + char * + roleBuf + + + char * + emailBuf + + + + + + + + + + + bool + bool NotePayloadSaveAndSleep + (NotePayloadDesc *desc, uint32_t seconds, const char *modes) + NotePayloadSaveAndSleep + + NotePayloadDesc * + desc + + + uint32_t + seconds + + + const char * + modes + + + + + + + + + + + bool + bool NotePayloadRetrieveAfterSleep + (NotePayloadDesc *desc) + NotePayloadRetrieveAfterSleep + + NotePayloadDesc * + desc + + + + + + + + + + + void + void NotePayloadSet + (NotePayloadDesc *desc, uint8_t *buf, uint32_t buflen) + NotePayloadSet + + NotePayloadDesc * + desc + + + uint8_t * + buf + + + uint32_t + buflen + + + + + + + + + + + void + void NotePayloadFree + (NotePayloadDesc *desc) + NotePayloadFree + + NotePayloadDesc * + desc + + + + + + + + + + + bool + bool NotePayloadAddSegment + (NotePayloadDesc *desc, const char segtype[NP_SEGTYPE_LEN], void *pdata, uint32_t plen) + NotePayloadAddSegment + + NotePayloadDesc * + desc + + + const char + segtype + [NP_SEGTYPE_LEN] + + + void * + pdata + + + uint32_t + plen + + + + + + + + + + + bool + bool NotePayloadFindSegment + (NotePayloadDesc *desc, const char segtype[NP_SEGTYPE_LEN], void *pdata, uint32_t *plen) + NotePayloadFindSegment + + NotePayloadDesc * + desc + + + const char + segtype + [NP_SEGTYPE_LEN] + + + void * + pdata + + + uint32_t * + plen + + + + + + + + + + + bool + bool NotePayloadGetSegment + (NotePayloadDesc *desc, const char segtype[NP_SEGTYPE_LEN], void *pdata, uint32_t len) + NotePayloadGetSegment + + NotePayloadDesc * + desc + + + const char + segtype + [NP_SEGTYPE_LEN] + + + void * + pdata + + + uint32_t + len + + + + + + + + + + + bool + bool NoteTemplate + (const char *notefileID, J *templateBody) + NoteTemplate + + const char * + notefileID + + + J * + templateBody + + + + + + + + + + + + + +Written by Ray Ozzie and Blues Inc. team. +Copyright (c) 2019 Blues Inc. MIT License. Use of this source code is governed by licenses granted by the copyright holder including that found in the LICENSE file. +This library bundles the cJSON JSON parser library. + + + +#pragmaonce + +//Incasethey'renotyetdefined +#include<float.h> +#include<limits.h> +#include<stdbool.h> +#include<stdint.h> + +#define_NOTE_C_STRINGIZE(x)#x +#defineNOTE_C_STRINGIZE(x)_NOTE_C_STRINGIZE(x) + +#defineNOTE_C_VERSION_MAJOR2 +#defineNOTE_C_VERSION_MINOR2 +#defineNOTE_C_VERSION_PATCH1 + +#defineNOTE_C_VERSIONNOTE_C_STRINGIZE(NOTE_C_VERSION_MAJOR)"."NOTE_C_STRINGIZE(NOTE_C_VERSION_MINOR)"."NOTE_C_STRINGIZE(NOTE_C_VERSION_PATCH) + +//Ifdoubleandfloatarethesamesize,thenwemustbeonasmallMCU.Turn +//onNOTE_C_LOW_MEMtoconservememory. +#ifdefined(FLT_MAX_EXP)&&defined(DBL_MAX_EXP) +#if(FLT_MAX_EXP==DBL_MAX_EXP) +#defineNOTE_C_LOW_MEM +#endif +#elifdefined(__FLT_MAX_EXP__)&&defined(__DBL_MAX_EXP__) +#if(__FLT_MAX_EXP__==__DBL_MAX_EXP__) +#defineNOTE_C_LOW_MEM +#endif +#else +#errorWhatarefloatingpointexponentlengthsymbolsforthiscompiler? +#endif + +//NOTE_LOWMEMistheoldnameofNOTE_C_LOW_MEM.IfNOTE_LOWMEMisdefined, +//wedefineNOTE_C_LOW_MEMaswell,forbackwardscompatibility.NOTE_FLOATis +//alsonolongerusedinternally,butusedtobedefinedwhenNOTE_LOWMEMwas +//defined.It'salsopreservedhereforbackwardscompatibility. +#ifdefNOTE_LOWMEM +#defineNOTE_C_LOW_MEM +#defineNOTE_FLOAT +#endif + +#ifdefNOTE_C_LOW_MEM +#defineERRSTR(x,y)(y) +#else +#defineERRSTR(x,y)(x) +#endif + +#ifdefNOTE_C_TEST_SINGLE_PRECISION +typedeffloatJNUMBER; +#else +typedefdoubleJNUMBER; +#endif + +typedefint64_tJINTEGER; +#defineJINTEGER_MININT64_MIN +#defineJINTEGER_MAXINT64_MAX + +typedefuint64_tJUINTEGER; + +//UNIXEpochtime(alsoknownasPOSIXtime)isthenumberofsecondsthathaveelapsedsince +//00:00:00Thursday,1January1970,CoordinatedUniversalTime(UTC).Inthisproject,italways +//originatesfromtheNotecard,whichsynchronizesthetimefromboththecellnetworkandGPS. +typedefJUINTEGERJTIME; + +//C-callablefunctions +#ifdef__cplusplus +extern"C"{ +#endif + +//cJSONwrappers +#include"n_cjson.h" + +//Notecardhookfunctions + +typedefvoid(*mutexFn)(void); +typedefvoid*(*mallocFn)(size_tsize); +typedefvoid(*freeFn)(void*mem); +typedefvoid(*delayMsFn)(uint32_tms); +typedefuint32_t(*getMsFn)(void); +typedefsize_t(*debugOutputFn)(constchar*text); + +typedefbool(*serialResetFn)(void); +typedefvoid(*serialTransmitFn)(uint8_t*txBuf,size_ttxBufSize,boolflush); +typedefbool(*serialAvailableFn)(void); + +typedefchar(*serialReceiveFn)(void); +typedefbool(*i2cResetFn)(uint16_taddress); +typedefconstchar*(*i2cTransmitFn)(uint16_taddress,uint8_t*txBuf, +uint16_ttxBufSize); +typedefconstchar*(*i2cReceiveFn)(uint16_taddress,uint8_t*rxBuf, +uint16_trxBufSize,uint32_t*available); +typedefbool(*txnStartFn)(uint32_ttimeoutMs); +typedefvoid(*txnStopFn)(void); + +//ExternalAPI +boolNoteReset(void); +voidNoteResetRequired(void); +#defineNoteNewBodyJCreateObject +#defineNoteAddBodyToObject(a,b)JAddItemToObject(a,"body",b) +#defineNoteGetBody(a)JGetObject(a,"body") +J*NoteNewRequest(constchar*request); +J*NoteNewCommand(constchar*request); +J*NoteRequestResponse(J*req); +J*NoteRequestResponseWithRetry(J*req,uint32_ttimeoutSeconds); +char*NoteRequestResponseJSON(constchar*reqJSON); +voidNoteSuspendTransactionDebug(void); +voidNoteResumeTransactionDebug(void); +#defineSYNCSTATUS_LEVEL_MAJOR0 +#defineSYNCSTATUS_LEVEL_MINOR1 +#defineSYNCSTATUS_LEVEL_DETAILED2 +#defineSYNCSTATUS_LEVEL_ALGORITHMIC3 +#defineSYNCSTATUS_LEVEL_ALL-1 +boolNoteDebugSyncStatus(intpollFrequencyMs,intmaxLevel); +boolNoteRequest(J*req); +boolNoteRequestWithRetry(J*req,uint32_ttimeoutSeconds); +#defineNoteResponseError(rsp)(!JIsNullString(rsp,"err")) +#defineNoteResponseErrorContains(rsp,errstr)(JContainsString(rsp,"err",errstr)) +#defineNoteDeleteResponse(rsp)JDelete(rsp) +J*NoteTransaction(J*req); +boolNoteErrorContains(constchar*errstr,constchar*errtype); +voidNoteErrorClean(char*errbuf); +voidNoteSetFnDebugOutput(debugOutputFnfn); +voidNoteSetFnTransaction(txnStartFnstartFn,txnStopFnstopFn); +voidNoteSetFnMutex(mutexFnlockI2Cfn,mutexFnunlockI2Cfn,mutexFnlockNotefn, +mutexFnunlockNotefn); +voidNoteSetFnI2CMutex(mutexFnlockI2Cfn,mutexFnunlockI2Cfn); +voidNoteSetFnNoteMutex(mutexFnlockFn,mutexFnunlockFn); +voidNoteSetFnDefault(mallocFnmallocfn,freeFnfreefn,delayMsFndelayfn, +getMsFnmillisfn); +voidNoteSetFn(mallocFnmallocHook,freeFnfreeHook,delayMsFndelayMsHook, +getMsFngetMsHook); +voidNoteSetFnSerial(serialResetFnresetFn,serialTransmitFntransmitFn, +serialAvailableFnavailFn,serialReceiveFnreceiveFn); +voidNoteSetFnI2C(uint32_tnotecardAddr,uint32_tmaxTransmitSize, +i2cResetFnresetFn,i2cTransmitFntransmitFn, +i2cReceiveFnreceiveFn); +voidNoteSetFnDisabled(void); +voidNoteSetI2CAddress(uint32_ti2caddress); + +//TheNotecard,whosedefaultI2Caddressisbelow,usesaserial-to-i2c +//protocolwhose"bytecount"mustfitintoasinglebyteandwhichmustnot +//includea2-byteheaderfield.Thisiswhythemaximumthatcanbe +//transmittedbynote-cinasingleI2CI/Ois255-2=253bytes. + +#defineNOTE_I2C_ADDR_DEFAULT0x17 + +//Serial-to-i2cprotocolheadersizeinbytes +#ifndefNOTE_I2C_HEADER_SIZE +#defineNOTE_I2C_HEADER_SIZE2 +#endif + +//Maximumbytescapableofbeingtransmittedinasingleread/writeoperation +#ifndefNOTE_I2C_MAX_MAX +#defineNOTE_I2C_MAX_MAX(UCHAR_MAX-NOTE_I2C_HEADER_SIZE) +#endif + +//InARDUINOimplementations,whichtodateisthelargestuseofthislibrary, +//theWirepackageisimplementedinabroadvarietyofwaysbydifferent +//vendors.Thedefaultimplementationhasamere32-bytestaticI2Cbuffer, +//whichmeansthatthemaximumtobetransmittedinasingleI/O(givenour +//2-byteserial-to-i2cprotocolheader)is30bytes.However,ifweknow +//thespecificplatform(suchasSTM32DUINO)wecanrelaxthisrestriction. +#ifdefined(NOTE_I2C_MAX_DEFAULT) +//userisoverridingitatcompiletime +#elifdefined(ARDUINO_ARCH_STM32) +//weknowthatstm32duinodynamicallyallocatesI/Obuffer +#defineNOTE_I2C_MAX_DEFAULTNOTE_I2C_MAX_MAX +#else +//defaulttowhat'sknowntobesafeforallArduinoimplementations +#defineNOTE_I2C_MAX_DEFAULT30 +#endif + +//Useragent +J*NoteUserAgent(void); +voidNoteUserAgentUpdate(J*ua); +voidNoteSetUserAgent(char*agent); +voidNoteSetUserAgentOS(char*os_name,char*os_platform,char*os_family,char*os_version); +voidNoteSetUserAgentCPU(intcpu_mem,intcpu_mhz,intcpu_cores,char*cpu_vendor,char*cpu_name); + +//Callstothefunctionssetabove +voidNoteDebug(constchar*message); +voidNoteDebugln(constchar*message); +voidNoteDebugIntln(constchar*message,intn); +voidNoteDebugf(constchar*format,...); + +#defineNOTE_C_LOG_LEVEL_ERROR0 +#defineNOTE_C_LOG_LEVEL_WARN1 +#defineNOTE_C_LOG_LEVEL_INFO2 +#defineNOTE_C_LOG_LEVEL_DEBUG3 + +voidNoteDebugWithLevel(uint8_tlevel,constchar*msg); +voidNoteDebugWithLevelLn(uint8_tlevel,constchar*msg); + +#ifdefNOTE_C_LOG_SHOW_FILE_AND_LINE +#defineNOTE_C_LOG_FILE_AND_LINE(lvl)do{\ +NoteDebugWithLevel(lvl,__FILE__":"NOTE_C_STRINGIZE(__LINE__)"");\ +}while(0); +#else +#defineNOTE_C_LOG_FILE_AND_LINE(lvl) +#endif + +#defineNOTE_C_LOG_ERROR(msg)do{\ +NOTE_C_LOG_FILE_AND_LINE(NOTE_C_LOG_LEVEL_ERROR);\ +NoteDebugWithLevel(NOTE_C_LOG_LEVEL_ERROR,"[ERROR]");\ +NoteDebugWithLevelLn(NOTE_C_LOG_LEVEL_ERROR,msg);\ +}while(0); + +#defineNOTE_C_LOG_WARN(msg)do{\ +NOTE_C_LOG_FILE_AND_LINE(NOTE_C_LOG_LEVEL_WARN);\ +NoteDebugWithLevel(NOTE_C_LOG_LEVEL_WARN,"[WARN]");\ +NoteDebugWithLevelLn(NOTE_C_LOG_LEVEL_WARN,msg);\ +}while(0); + +#defineNOTE_C_LOG_INFO(msg)do{\ +NOTE_C_LOG_FILE_AND_LINE(NOTE_C_LOG_LEVEL_INFO);\ +NoteDebugWithLevel(NOTE_C_LOG_LEVEL_INFO,"[INFO]");\ +NoteDebugWithLevelLn(NOTE_C_LOG_LEVEL_INFO,msg);\ +}while(0); + +#defineNOTE_C_LOG_DEBUG(msg)do{\ +NOTE_C_LOG_FILE_AND_LINE(NOTE_C_LOG_LEVEL_DEBUG);\ +NoteDebugWithLevel(NOTE_C_LOG_LEVEL_DEBUG,"[DEBUG]");\ +NoteDebugWithLevelLn(NOTE_C_LOG_LEVEL_DEBUG,msg);\ +}while(0); + +//ThemaxloglevelforNoteDebugWithLevelisonlyconfigurableat +//compile-time,viaNOTE_C_LOG_LEVEL. +#ifndefNOTE_C_LOG_LEVEL +#defineNOTE_C_LOG_LEVELNOTE_C_LOG_LEVEL_INFO +#endif + +void*NoteMalloc(size_tsize); +voidNoteFree(void*); +uint32_tNoteGetMs(void); +voidNoteDelayMs(uint32_tms); +voidNoteLockI2C(void); +voidNoteUnlockI2C(void); +uint32_tNoteI2CAddress(void); +uint32_tNoteI2CMax(void); +uint32_tNoteMemAvailable(void); +boolNotePrint(constchar*text); +voidNotePrintln(constchar*line); +boolNotePrintf(constchar*format,...); + +//Stringhelperstohelpencouragetheworldtoabandonthehorribly-error-pronestrn* +size_tstrlcpy(char*dst,constchar*src,size_tsiz); +size_tstrlcat(char*dst,constchar*src,size_tsiz); + +//JSONhelpers +voidJInit(void); +voidJCheck(void); +boolJIsPresent(J*json,constchar*field); +char*JGetString(J*json,constchar*field); +JNUMBERJGetNumber(J*json,constchar*field); +J*JGetArray(J*json,constchar*field); +J*JGetObject(J*json,constchar*field); +JINTEGERJGetInt(J*json,constchar*field); +boolJGetBool(J*json,constchar*field); +JNUMBERJNumberValue(J*item); +char*JStringValue(J*item); +boolJBoolValue(J*item); +JINTEGERJIntValue(J*item); +boolJIsNullString(J*json,constchar*field); +boolJIsExactString(J*json,constchar*field,constchar*teststr); +boolJContainsString(J*json,constchar*field,constchar*substr); +boolJAddBinaryToObject(J*json,constchar*fieldName,constvoid*binaryData,uint32_tbinaryDataLen); +boolJGetBinaryFromObject(J*json,constchar*fieldName,uint8_t**retBinaryData,uint32_t*retBinaryDataLen); +constchar*JGetItemName(constJ*item); +char*JAllocString(uint8_t*buffer,uint32_tlen); +constchar*JType(J*item); + +#defineJTYPE_NOT_PRESENT0 +#defineJTYPE_BOOL_TRUE1 +#defineJTYPE_BOOL_FALSE2 +#defineJTYPE_BOOLJTYPE_BOOL_TRUE +#defineJTYPE_NULL3 +#defineJTYPE_NUMBER_ZERO4 +#defineJTYPE_NUMBER5 +#defineJTYPE_STRING_BLANK6 +#defineJTYPE_STRING_ZERO7 +#defineJTYPE_STRING_NUMBER8 +#defineJTYPE_STRING_BOOL_TRUE9 +#defineJTYPE_STRING_BOOL_FALSE10 +#defineJTYPE_STRING11 +#defineJTYPE_OBJECT12 +#defineJTYPE_ARRAY13 +intJGetType(J*json,constchar*field); +intJGetItemType(J*item); +intJBaseItemType(inttype); +#defineJGetObjectItemName(j)(j->string) + +//HelperfunctionsforappsthatwishtolimittheirClibrarydependencies +#defineJNTOA_PRECISION(16) +#defineJNTOA_MAX(44) +char*JNtoA(JNUMBERf,char*buf,intprecision); +JNUMBERJAtoN(constchar*string,char**endPtr); +voidJItoA(JINTEGERn,char*s); +JINTEGERJAtoI(constchar*s); +intJB64EncodeLen(intlen); +intJB64Encode(char*coded_dst,constchar*plain_src,intlen_plain_src); +intJB64DecodeLen(constchar*coded_src); +intJB64Decode(char*plain_dst,constchar*coded_src); + +//MD5Helperfunctions +typedefstruct{ +unsignedlongbuf[4]; +unsignedlongbits[2]; +unsignedcharin[64]; +}NoteMD5Context; +#defineNOTE_MD5_HASH_SIZE16 +#defineNOTE_MD5_HASH_STRING_SIZE(((NOTE_MD5_HASH_SIZE)*2)+1) +voidNoteMD5Init(NoteMD5Context*ctx); +voidNoteMD5Update(NoteMD5Context*ctx,unsignedcharconst*buf,unsignedlonglen); +voidNoteMD5Final(unsignedchar*digest,NoteMD5Context*ctx); +voidNoteMD5Transform(unsignedlongbuf[4],constunsignedcharinraw[64]); +voidNoteMD5Hash(unsignedchar*data,unsignedlonglen,unsignedchar*retHash); +voidNoteMD5HashString(unsignedchar*data,unsignedlonglen,char*strbuf,unsignedlongbuflen); +voidNoteMD5HashToString(unsignedchar*hash,char*strbuf,unsignedlongbuflen); + +//High-levelhelperfunctionsthatarebothusefulandservetoshowdevelopers +//howtocalltheAPI +uint32_tNoteBinaryCodecDecode(constuint8_t*encData,uint32_tencDataLen, +uint8_t*decBuf,uint32_tdecBufSize); +uint32_tNoteBinaryCodecEncode(constuint8_t*decData,uint32_tdecDataLen, +uint8_t*encBuf,uint32_tencBufSize); +uint32_tNoteBinaryCodecMaxDecodedLength(uint32_tbufferSize); +uint32_tNoteBinaryCodecMaxEncodedLength(uint32_tunencodedLength); +constchar*NoteBinaryStoreDecodedLength(uint32_t*len); +constchar*NoteBinaryStoreEncodedLength(uint32_t*len); +constchar*NoteBinaryStoreReceive(uint8_t*buffer,uint32_tbufLen, +uint32_tdecodedOffset,uint32_tdecodedLen); +constchar*NoteBinaryStoreReset(void); +constchar*NoteBinaryStoreTransmit(uint8_t*unencodedData,uint32_tunencodedLen, +uint32_tbufLen,uint32_tnotecardOffset); +uint32_tNoteSetSTSecs(uint32_tsecs); +boolNoteTimeValid(void); +boolNoteTimeValidST(void); +JTIMENoteTime(void); +JTIMENoteTimeST(void); +voidNoteTimeRefreshMins(uint32_tmins); +voidNoteTimeSet(JTIMEsecondsUTC,intoffset,char*zone,char*country,char*area); +boolNoteLocalTimeST(uint16_t*retYear,uint8_t*retMonth,uint8_t*retDay,uint8_t*retHour,uint8_t*retMinute,uint8_t*retSecond,char**retWeekday,char**retZone); +boolNoteRegion(char**retCountry,char**retArea,char**retZone,int*retZoneOffset); +boolNoteLocationValid(char*errbuf,uint32_terrbuflen); +boolNoteLocationValidST(char*errbuf,uint32_terrbuflen); +voidNoteTurboIO(boolenable); +JINTEGERNoteGetEnvInt(constchar*variable,JINTEGERdefaultVal); +JNUMBERNoteGetEnvNumber(constchar*variable,JNUMBERdefaultVal); +boolNoteGetEnv(constchar*variable,constchar*defaultVal,char*buf,uint32_tbuflen); +boolNoteSetEnvDefault(constchar*variable,char*buf); +boolNoteSetEnvDefaultNumber(constchar*variable,JNUMBERdefaultVal); +boolNoteSetEnvDefaultInt(constchar*variable,JINTEGERdefaultVal); +boolNoteIsConnected(void); +boolNoteIsConnectedST(void); +boolNoteGetNetStatus(char*statusBuf,intstatusBufLen); +boolNoteGetVersion(char*versionBuf,intversionBufLen); +boolNoteGetLocation(JNUMBER*retLat,JNUMBER*retLon,JTIME*time,char*statusBuf,intstatusBufLen); +boolNoteSetLocation(JNUMBERlat,JNUMBERlon); +boolNoteClearLocation(void); +boolNoteGetLocationMode(char*modeBuf,intmodeBufLen); +boolNoteSetLocationMode(constchar*mode,uint32_tseconds); +boolNoteGetServiceConfig(char*productBuf,intproductBufLen,char*serviceBuf,intserviceBufLen,char*deviceBuf,intdeviceBufLen,char*snBuf,intsnBufLen); +boolNoteGetServiceConfigST(char*productBuf,intproductBufLen,char*serviceBuf,intserviceBufLen,char*deviceBuf,intdeviceBufLen,char*snBuf,intsnBufLen); +boolNoteGetStatus(char*statusBuf,intstatusBufLen,JTIME*bootTime,bool*retUSB,bool*retSignals); +boolNoteGetStatusST(char*statusBuf,intstatusBufLen,JTIME*bootTime,bool*retUSB,bool*retSignals); +boolNoteSleep(char*stateb64,uint32_tseconds,constchar*modes); +boolNoteWake(intstateLen,void*state); +boolNoteFactoryReset(booldeleteConfigSettings); +boolNoteSetSerialNumber(constchar*sn); +boolNoteSetProductID(constchar*productID); +boolNoteSetUploadMode(constchar*uploadMode,intuploadMinutes,boolalign); +boolNoteSetSyncMode(constchar*uploadMode,intuploadMinutes,intdownloadMinutes,boolalign,boolsync); +#defineNoteSendNoteAdd +boolNoteAdd(constchar*target,J*body,boolurgent); +boolNoteSendToRoute(constchar*method,constchar*routeAlias,char*notefile,J*body); +boolNoteGetVoltage(JNUMBER*voltage); +boolNoteGetTemperature(JNUMBER*temp); +boolNoteGetContact(char*nameBuf,intnameBufLen,char*orgBuf,intorgBufLen,char*roleBuf,introleBufLen,char*emailBuf,intemailBufLen); +boolNoteSetContact(char*nameBuf,char*orgBuf,char*roleBuf,char*emailBuf); + +//Definitionsnecessaryforpayloaddescriptor +#defineNP_SEGTYPE_LEN4 +#defineNP_SEGLEN_LENsizeof(uint32_t) +#defineNP_SEGHDR_LEN(NP_SEGTYPE_LEN+NP_SEGLEN_LEN) +typedefstruct{ +uint8_t*data; +uint32_talloc; +uint32_tlength; +}NotePayloadDesc; +boolNotePayloadSaveAndSleep(NotePayloadDesc*desc,uint32_tseconds,constchar*modes); +boolNotePayloadRetrieveAfterSleep(NotePayloadDesc*desc); +voidNotePayloadSet(NotePayloadDesc*desc,uint8_t*buf,uint32_tbuflen); +voidNotePayloadFree(NotePayloadDesc*desc); +boolNotePayloadAddSegment(NotePayloadDesc*desc,constcharsegtype[NP_SEGTYPE_LEN],void*pdata,uint32_tplen); +boolNotePayloadFindSegment(NotePayloadDesc*desc,constcharsegtype[NP_SEGTYPE_LEN],void*pdata,uint32_t*plen); +boolNotePayloadGetSegment(NotePayloadDesc*desc,constcharsegtype[NP_SEGTYPE_LEN],void*pdata,uint32_tlen); + +//Hard-wiredconstantsusedtospecifyfieldtypeswhencreatingnotetemplates +#defineTBOOLtrue//bool +#defineTINT811//1-bytesignedinteger +#defineTINT1612//2-bytesignedinteger +#defineTINT2413//3-bytesignedinteger +#defineTINT3214//4-bytesignedinteger +#defineTINT6418//8-bytesignedinteger(note-csupportdependsuponplatform) +#defineTUINT821//1-byteunsignedinteger(requiresnotecardfirmware>=build14444) +#defineTUINT1622//2-byteunsignedinteger(requiresnotecardfirmware>=build14444) +#defineTUINT2423//3-byteunsignedinteger(requiresnotecardfirmware>=build14444) +#defineTUINT3224//4-byteunsignedinteger(requiresnotecardfirmware>=build14444) +#defineTFLOAT1612.1//2-byteIEEE754floatingpoint +#defineTFLOAT3214.1//4-byteIEEE754floatingpoint(a.k.a."float") +#defineTFLOAT6418.1//8-byteIEEE754floatingpoint(a.k.a."double") +#defineTSTRING(N)_NOTE_C_STRINGIZE(N)//UTF-8textofNbytesmaximum(fixed-lengthreservedbuffer) +#defineTSTRINGV_NOTE_C_STRINGIZE(0)//variable-lengthstring +boolNoteTemplate(constchar*notefileID,J*templateBody); + +//EndofC-callablefunctions +#ifdef__cplusplus +} +#endif + + + + diff --git a/doxygen/xml/struct_j.xml b/doxygen/xml/struct_j.xml new file mode 100644 index 00000000..35d2d86d --- /dev/null +++ b/doxygen/xml/struct_j.xml @@ -0,0 +1,141 @@ + + + + J + n_cjson.h + + + struct J * + struct J* J::next + + next + + + + + + + + + + struct J * + struct J* J::prev + + prev + + + + + + + + + + struct J * + struct J* J::child + + child + + + + + + + + + + int + int J::type + + type + + + + + + + + + + char * + char* J::valuestring + + valuestring + + + + + + + + + + JINTEGER + JINTEGER J::valueint + + valueint + + + + + + + + + + JNUMBER + JNUMBER J::valuenumber + + valuenumber + + + + + + + + + + char * + char* J::string + + string + + + + + + + + + + +The core JSON object type used by note-c. + + +When using note-c, treat this struct as opaque. You should never have to work directly with its members. + + + + + + + child + next + prev + + + + + + Jchild + Jnext + Jprev + Jstring + Jtype + Jvalueint + Jvaluenumber + Jvaluestring + + + diff --git a/doxygen/xml/struct_j_hooks.xml b/doxygen/xml/struct_j_hooks.xml new file mode 100644 index 00000000..697dd074 --- /dev/null +++ b/doxygen/xml/struct_j_hooks.xml @@ -0,0 +1,44 @@ + + + + JHooks + n_cjson.h + + + void *(* + void*(* JHooks::malloc_fn) (size_t sz) + )(size_t sz) + malloc_fn + + + + + + + + + + void(* + void(* JHooks::free_fn) (void *ptr) + )(void *ptr) + free_fn + + + + + + + + + + + + + + + + JHooksfree_fn + JHooksmalloc_fn + + + diff --git a/doxygen/xml/struct_note_m_d5_context.xml b/doxygen/xml/struct_note_m_d5_context.xml new file mode 100644 index 00000000..2c8de4ae --- /dev/null +++ b/doxygen/xml/struct_note_m_d5_context.xml @@ -0,0 +1,58 @@ + + + + NoteMD5Context + note.h + + + unsigned long + unsigned long NoteMD5Context::buf[4] + [4] + buf + + + + + + + + + + unsigned long + unsigned long NoteMD5Context::bits[2] + [2] + bits + + + + + + + + + + unsigned char + unsigned char NoteMD5Context::in[64] + [64] + in + + + + + + + + + + + + + + + + NoteMD5Contextbits + NoteMD5Contextbuf + NoteMD5Contextin + + + diff --git a/doxygen/xml/struct_note_payload_desc.xml b/doxygen/xml/struct_note_payload_desc.xml new file mode 100644 index 00000000..d329b806 --- /dev/null +++ b/doxygen/xml/struct_note_payload_desc.xml @@ -0,0 +1,58 @@ + + + + NotePayloadDesc + note.h + + + uint8_t * + uint8_t* NotePayloadDesc::data + + data + + + + + + + + + + uint32_t + uint32_t NotePayloadDesc::alloc + + alloc + + + + + + + + + + uint32_t + uint32_t NotePayloadDesc::length + + length + + + + + + + + + + + + + + + + NotePayloadDescalloc + NotePayloadDescdata + NotePayloadDesclength + + + diff --git a/doxygen/xml/structerror.xml b/doxygen/xml/structerror.xml new file mode 100644 index 00000000..47a60164 --- /dev/null +++ b/doxygen/xml/structerror.xml @@ -0,0 +1,43 @@ + + + + error + + + const unsigned char * + const unsigned char* error::json + + json + + + + + + + + + + size_t + size_t error::position + + position + + + + + + + + + + + + + + + + errorjson + errorposition + + + diff --git a/doxygen/xml/structparse__buffer.xml b/doxygen/xml/structparse__buffer.xml new file mode 100644 index 00000000..de0d22d4 --- /dev/null +++ b/doxygen/xml/structparse__buffer.xml @@ -0,0 +1,71 @@ + + + + parse_buffer + + + const unsigned char * + const unsigned char* parse_buffer::content + + content + + + + + + + + + + size_t + size_t parse_buffer::length + + length + + + + + + + + + + size_t + size_t parse_buffer::offset + + offset + + + + + + + + + + size_t + size_t parse_buffer::depth + + depth + + + + + + + + + + + + + + + + parse_buffercontent + parse_bufferdepth + parse_bufferlength + parse_bufferoffset + + + diff --git a/doxygen/xml/structprintbuffer.xml b/doxygen/xml/structprintbuffer.xml new file mode 100644 index 00000000..31bd3140 --- /dev/null +++ b/doxygen/xml/structprintbuffer.xml @@ -0,0 +1,113 @@ + + + + printbuffer + + + unsigned char * + unsigned char* printbuffer::buffer + + buffer + + + + + + + + + + size_t + size_t printbuffer::length + + length + + + + + + + + + + size_t + size_t printbuffer::offset + + offset + + + + + + + + + + size_t + size_t printbuffer::depth + + depth + + + + + + + + + + Jbool + Jbool printbuffer::noalloc + + noalloc + + + + + + + + + + Jbool + Jbool printbuffer::format + + format + + + + + + + + + + Jbool + Jbool printbuffer::omitempty + + omitempty + + + + + + + + + + + + + + + + printbufferbuffer + printbufferdepth + printbufferformat + printbufferlength + printbuffernoalloc + printbufferoffset + printbufferomitempty + + + diff --git a/doxygen/xml/xml.xsd b/doxygen/xml/xml.xsd new file mode 100644 index 00000000..9f80fe15 --- /dev/null +++ b/doxygen/xml/xml.xsd @@ -0,0 +1,23 @@ + + + + + + + + + + + + + + + + + + + + + diff --git a/genindex.html b/genindex.html new file mode 100644 index 00000000..46a60144 --- /dev/null +++ b/genindex.html @@ -0,0 +1,281 @@ + + + + + + Index — note-c documentation + + + + + + + + + + + + + + + + + +
    + + +
    + +
    +
    +
    +
      +
    • + +
    • +
    • +
    +
    +
    +
    +
    + + +

    Index

    + +
    + D + | F + | G + | I + | J + | M + | N + | S + +
    +

    D

    + + +
    + +

    F

    + + +
    + +

    G

    + + +
    + +

    I

    + + + +
    + +

    J

    + + + +
    + +

    M

    + + + +
    + +

    N

    + + + +
    + +

    S

    + + + +
    + + + +
    +
    + +
    +
    +
    +
    + + + + \ No newline at end of file diff --git a/getting_started.html b/getting_started.html new file mode 100644 index 00000000..7b35cb63 --- /dev/null +++ b/getting_started.html @@ -0,0 +1,133 @@ + + + + + + + Getting Started — note-c documentation + + + + + + + + + + + + + + + + + + + +
    + + +
    + +
    +
    +
    + +
    +
    +
    +
    + +
    +

    Getting Started

    +
    +

    Notecard Background

    +

    Before using note-c, it’s essential to understand the fundamentals of communicating with a Notecard. Read the Notecard Overview on the Blues developer site to familiarize yourself with the communications protocol. The protocol is JSON-based and supports serial and I2C connections.

    +
    +
    +

    Getting the Source Code

    +

    To use note-c in your project, you can download or clone the git repository from GitHub. The library is composed of all the .c and .h files prefixed with “n_” in the root directory of the repository. Simply add the .c files alongside your other source files and make sure the .h files are on an include path visible to your compiler.

    +
    +
    +

    Using the Library

    +

    The pages below cover how to use note-c in your project.

    + +
    +
    + + +
    +
    + +
    +
    +
    +
    + + + + \ No newline at end of file diff --git a/index.html b/index.html new file mode 100644 index 00000000..03b6c7de --- /dev/null +++ b/index.html @@ -0,0 +1,121 @@ + + + + + + + note-c — note-c documentation + + + + + + + + + + + + + + + + + + +
    + + +
    + +
    +
    +
    + +
    +
    +
    +
    + +
    +

    note-c

    +

    note-c is the official C library for communicating with a Blues Notecard. The source code is open source and available on GitHub under the MIT license.

    + +
    + + +
    +
    + +
    +
    +
    +
    + + + + \ No newline at end of file diff --git a/library_initialization.html b/library_initialization.html new file mode 100644 index 00000000..61163d1b --- /dev/null +++ b/library_initialization.html @@ -0,0 +1,442 @@ + + + + + + + Library Initialization — note-c documentation + + + + + + + + + + + + + + + + + + + +
    + + +
    + +
    +
    +
    + +
    +
    +
    +
    + +
    +

    Library Initialization

    + +

    In order to send and receive data to and from the Notecard, note-c requires several hooks (i.e. callbacks) to be set. The implementations of the hooks are platform-specific and hence cannot be provided by note-c itself.

    +

    Blues develops several open source ports of these hooks for different platforms to accelerate getting started with note-c. The level of abstraction of these ports varies. For example, note-stm32l4 implements these hooks for the STM32L4 series of MCUs using the STM32L4 HAL, while note-arduino is a more generic port that allows you to use note-c with essentially any Arduino-compatible board.

    +

    For a comprehensive listing of note-c ports, go to Ports.

    +

    For an example and detailed breakdown of implementing the hooks for a specific platform, go to Example: note-c Hooks for STM32L4.

    +
    +

    Dynamic Memory and Timing Hooks

    +

    A port must set the dynamic memory and timing hooks using NoteSetFn() for:

    +
      +
    • Allocating memory

    • +
    • Freeing memory

    • +
    • Millisecond delay

    • +
    • Millisecond counter

    • +
    +
    +
    +

    I/O Hooks

    +

    note-c maintains one active Notecard I/O interface (serial or I2C) at a time. Calling NoteSetFnSerial() sets the active interface to serial, and calling NoteSetFnI2C() sets the active interface to I2C.

    +
    +

    Serial

    +

    NoteSetFnSerial() sets the serial hooks for:

    +
      +
    • Resetting the serial peripheral

    • +
    • Transmitting bytes

    • +
    • Checking if there’s a byte available to receive

    • +
    • Receiving a single byte

    • +
    +
    +
    +

    I2C

    +

    NoteSetFnI2C() sets the I2C hooks for:

    +
      +
    • Resetting the I2C peripheral

    • +
    • Transmitting bytes

    • +
    • Receiving bytes

    • +
    +

    NoteSetFnI2C() also requires two additional parameters: the I2C address of the Notecard and the maximum number of bytes to send to the Notecard in a single I2C chunk. To use the defaults for these two values, use the macros NOTE_I2C_ADDR_DEFAULT and NOTE_I2C_MAX_DEFAULT, respectively.

    +

    The I2C hooks are slightly more complex than the serial hooks. The transmit and receive hooks must implement the Notecard’s serial-over-I2C protocol:

    +
    +

    Unlike many fixed-length and register-based I2C protocols, the Notecard defines a variable-length, serial-over-I2C protocol that allows developers to handle JSON requests and responses in a similar manner as a direct serial connection.

    +
    +

    Familiarize yourself with the protocol using this guide from the Blues developer site. Example: note-c Hooks for STM32L4 provides a detailed breakdown of implementing the protocol for STM32L4. While this example uses the STM32L4 HAL, the overall approach is generalizable to other platforms.

    +
    +
    +
    +

    Mutex Hooks

    +
    +

    Notecard Mutex

    +

    A port must set the Notecard mutex hooks using NoteSetFnNoteMutex() if it intends to support multiple concurrent tasks that communicate with the Notecard. Specifically, the port must set lock and unlock hooks. Internally, note-c will call the lock hook before every transaction with the Notecard begins, and it will call the unlock hook after every transaction ends. This ensures that one task doesn’t interrupt another task in the middle of a transaction.

    +

    The simplest implementation of these hooks relies on a flag indicating if access to the Notecard is locked by some other task. The lock hook sleeps/yields until the flag indicates the Notecard is unlocked and then acquires the lock itself:

    +
    void lockNotecard(void)
    +{
    +    while (notecardLocked) {
    +        NoteDelayMs(10); // sleep 10 ms between checks
    +    }
    +
    +    notecardLocked = true;
    +}
    +
    +
    +

    The unlock hook simply clears the flag:

    +
    void unlockNotecard(void)
    +{
    +    notecardLocked = false;
    +}
    +
    +
    +
    +
    +

    I2C Mutex

    +

    A port must set the I2C mutex hooks using NoteSetFnI2CMutex() if it intends to support multiple concurrent tasks that drive the same I2C bus that the Notecard is on. Specifically, the port must set lock and unlock hooks. The simple lock-unlock implementation described previously in Notecard Mutex can be used for these hooks, too. Internally, note-c will call the lock hook before every I2C transaction with the Notecard begins, and it will call the unlock hook after every I2C transaction ends. The other tasks using I2C must be amended to do the same.

    +
    +
    +
    +

    Example: note-c Hooks for STM32L4

    +

    note-stm32l4 is the note-c port for the STM32L4 series of MCUs. This section walks through how the various note-c hooks are implemented for this platform. Notecard and I2C mutex hooks are not covered.

    +
    +

    Dynamic Memory and Timing Hooks

    +

    This line in Src/main.c sets the dynamic memory and timing hooks:

    +
    NoteSetFn(malloc, free, delay, millis);
    +
    +
    +
    +

    malloc

    +

    The memory allocation hook is set to malloc from libc.

    +
    +
    +

    free

    +

    The memory freeing hook is set to free from libc.

    +
    +
    +

    delay

    +
    void delay(uint32_t ms) {
    +   HAL_Delay(ms);
    +}
    +
    +
    +

    delay calls into the STM32 HAL to delay for the specified number of milliseconds.

    +
    +
    +

    millis

    +
    long unsigned int millis() {
    +   return (long unsigned int) HAL_GetTick();
    +}
    +
    +
    +

    millis uses the HAL to get the value of a continuously running millisecond counter.

    +
    +
    +
    +

    I/O Hooks

    +

    The code below from Src/main.c determines which I/O interface gets used, depending on the value of the NOTECARD_USE_I2C macro.

    +
    #if NOTECARD_USE_I2C
    +   NoteSetFnI2C(NOTE_I2C_ADDR_DEFAULT, NOTE_I2C_MAX_DEFAULT, noteI2CReset, noteI2CTransmit, noteI2CReceive);
    +#else
    +   NoteSetFnSerial(noteSerialReset, noteSerialTransmit, noteSerialAvailable, noteSerialReceive);
    +#endif
    +
    +
    +
    +

    noteSerialReset

    +
    bool noteSerialReset() {
    +   MX_USART1_UART_DeInit();
    +   MX_USART1_UART_Init();
    +
    +   return true;
    +}
    +
    +
    +

    The serial reset hook reinitializes the serial peripheral connected to the Notecard.

    +
    +
    +

    noteSerialTransmit

    +
    void noteSerialTransmit(uint8_t *text, size_t len, bool flush) {
    +    HAL_UART_Transmit(&huart1, text, len, 5000);
    +}
    +
    +
    +

    The serial transmit hook uses the HAL to write the data in the buffer to the serial peripheral connected to the Notecard.

    +
    +
    +

    noteSerialAvailable

    +
    bool noteSerialAvailable() {
    +   return (serialFillIndex != serialDrainIndex);
    +}
    +
    +
    +

    For receiving serial data from the Notecard, note-stm32l4 uses a circular buffer. In the receive interrupt handler for the UART peripheral, this buffer gets populated with the received data. serialFillIndex is the write index into that buffer, and serialDrainIndex is the read index. If the two indices are equal, there’s nothing new to read. If they aren’t equal, there is something to read.

    +
    +
    +

    noteSerialReceive

    +
    char noteSerialReceive() {
    +    char data;
    +    while (!noteSerialAvailable()) ;
    +    if (serialDrainIndex < sizeof(serialBuffer))
    +        data = serialBuffer[serialDrainIndex++];
    +    else {
    +        data = serialBuffer[0];
    +        serialDrainIndex = 1;
    +    }
    +    return data;
    +}
    +
    +
    +

    The serial receive hook returns the byte from the circular receive buffer at the read index, handling the case where the index wraps around to 0.

    +
    +
    +

    noteI2CReset

    +
    bool noteI2CReset(uint16_t DevAddress) {
    +    MX_I2C1_DeInit();
    +    MX_I2C1_Init();
    +
    +    return true;
    +}
    +
    +
    +

    The I2C reset hook reinitializes the I2C peripheral used to communicate with the Notecard.

    +
    +
    +

    noteI2CTransmit

    +
    const char *noteI2CTransmit(uint16_t DevAddress, uint8_t* pBuffer, uint16_t Size) {
    +    char *errstr = NULL;
    +    int writelen = sizeof(uint8_t) + Size;
    +    uint8_t *writebuf = malloc(writelen);
    +    if (writebuf == NULL) {
    +        errstr = "i2c: insufficient memory (write)";
    +    } else {
    +        writebuf[0] = Size;
    +        memcpy(&writebuf[1], pBuffer, Size);
    +        HAL_StatusTypeDef err_code = HAL_I2C_Master_Transmit(&hi2c1, DevAddress<<1, writebuf, writelen, 250);
    +        free(writebuf);
    +        if (err_code != HAL_OK) {
    +            errstr = "i2c: HAL_I2C_Master_Transmit error";
    +        }
    +    }
    +    return errstr;
    +}
    +
    +
    +

    To frame the data to transmit to the Notecard using the serial-over-I2C protocol, the host first adds a byte indicating the number of bytes in the payload, which is Size:

    +
    writebuf[0] = Size;
    +
    +
    +

    Then, it adds on the payload of Size bytes, which is pointed to by pBuffer:

    +
    memcpy(&writebuf[1], pBuffer, Size);
    +
    +
    +

    Then the host calls the platform-specific method to send those bytes over I2C, which is HAL_I2C_Master_Transmit in this case.

    +
    +
    +

    noteI2CReceive

    +
    const char *noteI2CReceive(uint16_t DevAddress, uint8_t* pBuffer, uint16_t Size, uint32_t *available) {
    +    const char *errstr = NULL;
    +    HAL_StatusTypeDef err_code;
    +
    +    // Retry transmit errors several times, because it's harmless to do so
    +    for (int i=0; i<3; i++) {
    +        uint8_t hdr[2];
    +        hdr[0] = (uint8_t) 0;
    +        hdr[1] = (uint8_t) Size;
    +        HAL_StatusTypeDef err_code = HAL_I2C_Master_Transmit(&hi2c1, DevAddress<<1, hdr, sizeof(hdr), 250);
    +        if (err_code == HAL_OK) {
    +            errstr = NULL;
    +            break;
    +        }
    +        errstr = "i2c: HAL_I2C_Master_Transmit error";
    +    }
    +
    +    // Only receive if we successfully began transmission
    +    if (errstr == NULL) {
    +
    +        int readlen = Size + (sizeof(uint8_t)*2);
    +        uint8_t *readbuf = malloc(readlen);
    +        if (readbuf == NULL) {
    +            errstr = "i2c: insufficient memory (read)";
    +        } else {
    +            err_code = HAL_I2C_Master_Receive(&hi2c1, DevAddress<<1, readbuf, readlen, 10);
    +            if (err_code != HAL_OK) {
    +                errstr = "i2c: HAL_I2C_Master_Receive error";
    +            } else {
    +                uint8_t availbyte = readbuf[0];
    +                uint8_t goodbyte = readbuf[1];
    +                if (goodbyte != Size) {
    +                    errstr = "i2c: incorrect amount of data";
    +                } else {
    +                    *available = availbyte;
    +                    memcpy(pBuffer, &readbuf[2], Size);
    +                }
    +            }
    +            free(readbuf);
    +        }
    +    }
    +
    +    // Done
    +    return errstr;
    +
    +}
    +
    +
    +

    Setting aside the retry logic at the start and the error checking, the above code is simpler than it initially appears. To initiate a read with the Notecard, the serial-over-I2C protocol specifies that the host first send a 2-byte packet: a 0 followed by a byte indicating the max amount of data the host is prepared to receive. That’s Size in this case, which is the available space in the receive buffer pBuffer.

    +
    hdr[0] = (uint8_t) 0;
    +hdr[1] = (uint8_t) Size;
    +
    +
    +

    Then, the host calls the platform-specific method to send those bytes over I2C.

    +

    Now, to read the data from the Notecard, the host calls the platform-specific method for an I2C read (HAL_I2C_Master_Receive). The packet it receives from the Notecard has a 2-byte header. The first byte indicates the number of bytes still available to read from the Notecard after this packet:

    +
    uint8_t availbyte = readbuf[0];
    +
    +
    +

    The second byte is the number of bytes in the current packet:

    +
    uint8_t goodbyte = readbuf[1];
    +
    +
    +

    The rest of the packet is the payload:

    +
    memcpy(pBuffer, &readbuf[2], Size);
    +
    +
    +

    Note that the number of bytes still available is returned to the caller via the available parameter:

    +
    *available = availbyte;
    +
    +
    +

    This lets note-c know if it should call this hook again to keep reading.

    +
    +
    +
    +
    + + +
    +
    + +
    +
    +
    +
    + + + + \ No newline at end of file diff --git a/objects.inv b/objects.inv new file mode 100644 index 00000000..cfb485af Binary files /dev/null and b/objects.inv differ diff --git a/ports.html b/ports.html new file mode 100644 index 00000000..cedd7d38 --- /dev/null +++ b/ports.html @@ -0,0 +1,149 @@ + + + + + + + Ports — note-c documentation + + + + + + + + + + + + + + + + + + + +
    + + +
    + +
    +
    +
    + +
    +
    +
    +
    + +
    +

    Ports

    +

    This is a listing of all the open source note-c ports developed by Blues.

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

    Name

    Description

    note-arduino

    Arduino library wrapper.

    note-zephyr

    Port for the Zephyr RTOS.

    note-mbed

    Port for the Mbed RTOS.

    note-stm32g0

    Port for STM32G0.

    note-stm32f1

    Port for STM32F1.

    note-stm32l0

    Port for STM32L0.

    note-stm32l4

    Port for STM32L4.

    note-msp430

    Port for TI MSP430.

    note-nrf52

    Port for nRF52.

    +
    + + +
    +
    + +
    +
    +
    +
    + + + + \ No newline at end of file diff --git a/search.html b/search.html new file mode 100644 index 00000000..d03c4b8a --- /dev/null +++ b/search.html @@ -0,0 +1,126 @@ + + + + + + Search — note-c documentation + + + + + + + + + + + + + + + + + + + + +
    + + +
    + +
    +
    +
    +
      +
    • + +
    • +
    • +
    +
    +
    +
    +
    + + + + +
    + +
    + +
    +
    + +
    +
    +
    +
    + + + + + + + + + \ No newline at end of file diff --git a/searchindex.js b/searchindex.js new file mode 100644 index 00000000..e4f0ade2 --- /dev/null +++ b/searchindex.js @@ -0,0 +1 @@ +Search.setIndex({"alltitles": {"API Reference": [[0, "api-reference"]], "Calling the Notecard API": [[1, "calling-the-notecard-api"]], "Dynamic Memory and Timing Hooks": [[0, "dynamic-memory-and-timing-hooks"], [4, "dynamic-memory-and-timing-hooks"], [4, "id2"]], "Example: note-c Hooks for STM32L4": [[4, "example-note-c-hooks-for-stm32l4"]], "Examples": [[1, "examples"]], "Functions": [[0, "functions"], [0, "id1"], [0, "id3"], [0, "id5"], [0, "id7"], [0, "id9"], [0, "id10"]], "Getting Started": [[2, "getting-started"]], "Getting the Source Code": [[2, "getting-the-source-code"]], "I/O Hooks": [[0, "i-o-hooks"], [4, "i-o-hooks"], [4, "id3"]], "I2C": [[0, "i2c"], [4, "i2c"]], "I2C Mutex": [[0, "i2c-mutex"], [4, "i2c-mutex"]], "JSON Manipulation": [[0, "json-manipulation"]], "Library Initialization": [[4, "library-initialization"]], "Macros": [[0, "macros"], [0, "id12"]], "Mutex Hooks": [[0, "mutex-hooks"], [4, "mutex-hooks"]], "Notecard API Calls": [[0, "notecard-api-calls"]], "Notecard Background": [[2, "notecard-background"]], "Notecard Mutex": [[0, "notecard-mutex"], [4, "notecard-mutex"]], "Ports": [[5, "ports"]], "Serial": [[4, "serial"]], "Serial Hooks": [[0, "serial-hooks"]], "Table of Contents": [[0, "table-of-contents"], [4, "table-of-contents"]], "Types": [[0, "types"], [0, "id2"], [0, "id4"], [0, "id6"], [0, "id8"], [0, "id11"]], "Using the Library": [[2, "using-the-library"]], "delay": [[4, "delay"]], "free": [[4, "free"]], "malloc": [[4, "malloc"]], "millis": [[4, "millis"]], "note-c": [[3, "note-c"]], "noteI2CReceive": [[4, "notei2creceive"]], "noteI2CReset": [[4, "notei2creset"]], "noteI2CTransmit": [[4, "notei2ctransmit"]], "noteSerialAvailable": [[4, "noteserialavailable"]], "noteSerialReceive": [[4, "noteserialreceive"]], "noteSerialReset": [[4, "noteserialreset"]], "noteSerialTransmit": [[4, "noteserialtransmit"]]}, "docnames": ["api_reference", "calling_the_notecard_api", "getting_started", "index", "library_initialization", "ports"], "envversion": {"sphinx": 61, "sphinx.domains.c": 3, "sphinx.domains.changeset": 1, "sphinx.domains.citation": 1, "sphinx.domains.cpp": 9, "sphinx.domains.index": 1, "sphinx.domains.javascript": 3, "sphinx.domains.math": 2, "sphinx.domains.python": 4, "sphinx.domains.rst": 2, "sphinx.domains.std": 2}, "filenames": ["api_reference.rst", "calling_the_notecard_api.rst", "getting_started.rst", "index.rst", "library_initialization.rst", "ports.rst"], "indexentries": {"delaymsfn (c type)": [[0, "c.delayMsFn", false]], "freefn (c type)": [[0, "c.freeFn", false]], "getmsfn (c type)": [[0, "c.getMsFn", false]], "i2creceivefn (c type)": [[0, "c.i2cReceiveFn", false]], "i2cresetfn (c type)": [[0, "c.i2cResetFn", false]], "i2ctransmitfn (c type)": [[0, "c.i2cTransmitFn", false]], "j (c struct)": [[0, "c.J", false]], "jaddarraytoobject (c function)": [[0, "c.JAddArrayToObject", false]], "jaddbinarytoobject (c function)": [[0, "c.JAddBinaryToObject", false]], "jaddbooltoobject (c function)": [[0, "c.JAddBoolToObject", false]], "jaddnumbertoobject (c function)": [[0, "c.JAddNumberToObject", false]], "jaddobjecttoobject (c function)": [[0, "c.JAddObjectToObject", false]], "jaddstringtoobject (c function)": [[0, "c.JAddStringToObject", false]], "jcreateobject (c function)": [[0, "c.JCreateObject", false]], "jdelete (c function)": [[0, "c.JDelete", false]], "jfree (c function)": [[0, "c.JFree", false]], "jgetarray (c function)": [[0, "c.JGetArray", false]], "jgetbinaryfromobject (c function)": [[0, "c.JGetBinaryFromObject", false]], "jgetbool (c function)": [[0, "c.JGetBool", false]], "jgetint (c function)": [[0, "c.JGetInt", false]], "jgetnumber (c function)": [[0, "c.JGetNumber", false]], "jgetobject (c function)": [[0, "c.JGetObject", false]], "jgetstring (c function)": [[0, "c.JGetString", false]], "jinteger (c type)": [[0, "c.JINTEGER", false]], "jispresent (c function)": [[0, "c.JIsPresent", false]], "jmalloc (c function)": [[0, "c.JMalloc", false]], "jnumber (c type)": [[0, "c.JNUMBER", false]], "jparse (c function)": [[0, "c.JParse", false]], "jprintunformatted (c function)": [[0, "c.JPrintUnformatted", false]], "juinteger (c type)": [[0, "c.JUINTEGER", false]], "mallocfn (c type)": [[0, "c.mallocFn", false]], "mutexfn (c type)": [[0, "c.mutexFn", false]], "n_cjson_nesting_limit (c macro)": [[0, "c.N_CJSON_NESTING_LIMIT", false]], "note_i2c_addr_default (c macro)": [[0, "c.NOTE_I2C_ADDR_DEFAULT", false]], "note_i2c_max_default (c macro)": [[0, "c.NOTE_I2C_MAX_DEFAULT", false]], "notedeleteresponse (c macro)": [[0, "c.NoteDeleteResponse", false]], "notenewrequest (c function)": [[0, "c.NoteNewRequest", false]], "noterequest (c function)": [[0, "c.NoteRequest", false]], "noterequestresponse (c function)": [[0, "c.NoteRequestResponse", false]], "noterequestresponsejson (c function)": [[0, "c.NoteRequestResponseJSON", false]], "noterequestresponsewithretry (c function)": [[0, "c.NoteRequestResponseWithRetry", false]], "noterequestwithretry (c function)": [[0, "c.NoteRequestWithRetry", false]], "noteresponseerror (c macro)": [[0, "c.NoteResponseError", false]], "notesetfn (c function)": [[0, "c.NoteSetFn", false]], "notesetfni2c (c function)": [[0, "c.NoteSetFnI2C", false]], "notesetfni2cmutex (c function)": [[0, "c.NoteSetFnI2CMutex", false]], "notesetfnnotemutex (c function)": [[0, "c.NoteSetFnNoteMutex", false]], "notesetfnserial (c function)": [[0, "c.NoteSetFnSerial", false]], "serialavailablefn (c type)": [[0, "c.serialAvailableFn", false]], "serialreceivefn (c type)": [[0, "c.serialReceiveFn", false]], "serialresetfn (c type)": [[0, "c.serialResetFn", false]], "serialtransmitfn (c type)": [[0, "c.serialTransmitFn", false]]}, "objects": {"": [[0, 0, 1, "c.J", "J"], [0, 1, 1, "c.JAddArrayToObject", "JAddArrayToObject"], [0, 1, 1, "c.JAddBinaryToObject", "JAddBinaryToObject"], [0, 1, 1, "c.JAddBoolToObject", "JAddBoolToObject"], [0, 1, 1, "c.JAddNumberToObject", "JAddNumberToObject"], [0, 1, 1, "c.JAddObjectToObject", "JAddObjectToObject"], [0, 1, 1, "c.JAddStringToObject", "JAddStringToObject"], [0, 1, 1, "c.JCreateObject", "JCreateObject"], [0, 1, 1, "c.JDelete", "JDelete"], [0, 1, 1, "c.JFree", "JFree"], [0, 1, 1, "c.JGetArray", "JGetArray"], [0, 1, 1, "c.JGetBinaryFromObject", "JGetBinaryFromObject"], [0, 1, 1, "c.JGetBool", "JGetBool"], [0, 1, 1, "c.JGetInt", "JGetInt"], [0, 1, 1, "c.JGetNumber", "JGetNumber"], [0, 1, 1, "c.JGetObject", "JGetObject"], [0, 1, 1, "c.JGetString", "JGetString"], [0, 3, 1, "c.JINTEGER", "JINTEGER"], [0, 1, 1, "c.JIsPresent", "JIsPresent"], [0, 1, 1, "c.JMalloc", "JMalloc"], [0, 3, 1, "c.JNUMBER", "JNUMBER"], [0, 1, 1, "c.JParse", "JParse"], [0, 1, 1, "c.JPrintUnformatted", "JPrintUnformatted"], [0, 3, 1, "c.JUINTEGER", "JUINTEGER"], [0, 4, 1, "c.NOTE_I2C_ADDR_DEFAULT", "NOTE_I2C_ADDR_DEFAULT"], [0, 4, 1, "c.NOTE_I2C_MAX_DEFAULT", "NOTE_I2C_MAX_DEFAULT"], [0, 4, 1, "c.N_CJSON_NESTING_LIMIT", "N_CJSON_NESTING_LIMIT"], [0, 4, 1, "c.NoteDeleteResponse", "NoteDeleteResponse"], [0, 1, 1, "c.NoteNewRequest", "NoteNewRequest"], [0, 1, 1, "c.NoteRequest", "NoteRequest"], [0, 1, 1, "c.NoteRequestResponse", "NoteRequestResponse"], [0, 1, 1, "c.NoteRequestResponseJSON", "NoteRequestResponseJSON"], [0, 1, 1, "c.NoteRequestResponseWithRetry", "NoteRequestResponseWithRetry"], [0, 1, 1, "c.NoteRequestWithRetry", "NoteRequestWithRetry"], [0, 4, 1, "c.NoteResponseError", "NoteResponseError"], [0, 1, 1, "c.NoteSetFn", "NoteSetFn"], [0, 1, 1, "c.NoteSetFnI2C", "NoteSetFnI2C"], [0, 1, 1, "c.NoteSetFnI2CMutex", "NoteSetFnI2CMutex"], [0, 1, 1, "c.NoteSetFnNoteMutex", "NoteSetFnNoteMutex"], [0, 1, 1, "c.NoteSetFnSerial", "NoteSetFnSerial"], [0, 3, 1, "c.delayMsFn", "delayMsFn"], [0, 3, 1, "c.freeFn", "freeFn"], [0, 3, 1, "c.getMsFn", "getMsFn"], [0, 3, 1, "c.i2cReceiveFn", "i2cReceiveFn"], [0, 3, 1, "c.i2cResetFn", "i2cResetFn"], [0, 3, 1, "c.i2cTransmitFn", "i2cTransmitFn"], [0, 3, 1, "c.mallocFn", "mallocFn"], [0, 3, 1, "c.mutexFn", "mutexFn"], [0, 3, 1, "c.serialAvailableFn", "serialAvailableFn"], [0, 3, 1, "c.serialReceiveFn", "serialReceiveFn"], [0, 3, 1, "c.serialResetFn", "serialResetFn"], [0, 3, 1, "c.serialTransmitFn", "serialTransmitFn"]], "JAddArrayToObject": [[0, 2, 1, "c.JAddArrayToObject", "name"], [0, 2, 1, "c.JAddArrayToObject", "object"]], "JAddBinaryToObject": [[0, 2, 1, "c.JAddBinaryToObject", "binaryData"], [0, 2, 1, "c.JAddBinaryToObject", "binaryDataLen"], [0, 2, 1, "c.JAddBinaryToObject", "fieldName"], [0, 2, 1, "c.JAddBinaryToObject", "json"]], "JAddBoolToObject": [[0, 2, 1, "c.JAddBoolToObject", "boolean"], [0, 2, 1, "c.JAddBoolToObject", "name"], [0, 2, 1, "c.JAddBoolToObject", "object"]], "JAddNumberToObject": [[0, 2, 1, "c.JAddNumberToObject", "name"], [0, 2, 1, "c.JAddNumberToObject", "number"], [0, 2, 1, "c.JAddNumberToObject", "object"]], "JAddObjectToObject": [[0, 2, 1, "c.JAddObjectToObject", "name"], [0, 2, 1, "c.JAddObjectToObject", "object"]], "JAddStringToObject": [[0, 2, 1, "c.JAddStringToObject", "name"], [0, 2, 1, "c.JAddStringToObject", "object"], [0, 2, 1, "c.JAddStringToObject", "string"]], "JDelete": [[0, 2, 1, "c.JDelete", "c"]], "JFree": [[0, 2, 1, "c.JFree", "object"]], "JGetArray": [[0, 2, 1, "c.JGetArray", "field"], [0, 2, 1, "c.JGetArray", "json"]], "JGetBinaryFromObject": [[0, 2, 1, "c.JGetBinaryFromObject", "fieldName"], [0, 2, 1, "c.JGetBinaryFromObject", "json"], [0, 2, 1, "c.JGetBinaryFromObject", "retBinaryData"], [0, 2, 1, "c.JGetBinaryFromObject", "retBinaryDataLen"]], "JGetBool": [[0, 2, 1, "c.JGetBool", "field"], [0, 2, 1, "c.JGetBool", "json"]], "JGetInt": [[0, 2, 1, "c.JGetInt", "field"], [0, 2, 1, "c.JGetInt", "json"]], "JGetNumber": [[0, 2, 1, "c.JGetNumber", "field"], [0, 2, 1, "c.JGetNumber", "json"]], "JGetObject": [[0, 2, 1, "c.JGetObject", "field"], [0, 2, 1, "c.JGetObject", "json"]], "JGetString": [[0, 2, 1, "c.JGetString", "field"], [0, 2, 1, "c.JGetString", "json"]], "JIsPresent": [[0, 2, 1, "c.JIsPresent", "field"], [0, 2, 1, "c.JIsPresent", "json"]], "JMalloc": [[0, 2, 1, "c.JMalloc", "size"]], "JParse": [[0, 2, 1, "c.JParse", "value"]], "JPrintUnformatted": [[0, 2, 1, "c.JPrintUnformatted", "item"]], "NoteNewRequest": [[0, 2, 1, "c.NoteNewRequest", "request"]], "NoteRequest": [[0, 2, 1, "c.NoteRequest", "req"]], "NoteRequestResponse": [[0, 2, 1, "c.NoteRequestResponse", "req"]], "NoteRequestResponseJSON": [[0, 2, 1, "c.NoteRequestResponseJSON", "reqJSON"]], "NoteRequestResponseWithRetry": [[0, 2, 1, "c.NoteRequestResponseWithRetry", "req"], [0, 2, 1, "c.NoteRequestResponseWithRetry", "timeoutSeconds"]], "NoteRequestWithRetry": [[0, 2, 1, "c.NoteRequestWithRetry", "req"], [0, 2, 1, "c.NoteRequestWithRetry", "timeoutSeconds"]], "NoteSetFn": [[0, 2, 1, "c.NoteSetFn", "delayMsHook"], [0, 2, 1, "c.NoteSetFn", "freeHook"], [0, 2, 1, "c.NoteSetFn", "getMsHook"], [0, 2, 1, "c.NoteSetFn", "mallocHook"]], "NoteSetFnI2C": [[0, 2, 1, "c.NoteSetFnI2C", "maxTransmitSize"], [0, 2, 1, "c.NoteSetFnI2C", "notecardAddr"], [0, 2, 1, "c.NoteSetFnI2C", "receiveFn"], [0, 2, 1, "c.NoteSetFnI2C", "resetFn"], [0, 2, 1, "c.NoteSetFnI2C", "transmitFn"]], "NoteSetFnI2CMutex": [[0, 2, 1, "c.NoteSetFnI2CMutex", "lockI2Cfn"], [0, 2, 1, "c.NoteSetFnI2CMutex", "unlockI2Cfn"]], "NoteSetFnNoteMutex": [[0, 2, 1, "c.NoteSetFnNoteMutex", "lockFn"], [0, 2, 1, "c.NoteSetFnNoteMutex", "unlockFn"]], "NoteSetFnSerial": [[0, 2, 1, "c.NoteSetFnSerial", "availFn"], [0, 2, 1, "c.NoteSetFnSerial", "receiveFn"], [0, 2, 1, "c.NoteSetFnSerial", "resetFn"], [0, 2, 1, "c.NoteSetFnSerial", "transmitFn"]]}, "objnames": {"0": ["c", "struct", "C struct"], "1": ["c", "function", "C function"], "2": ["c", "functionParam", "C function parameter"], "3": ["c", "type", "C type"], "4": ["c", "macro", "C macro"]}, "objtypes": {"0": "c:struct", "1": "c:function", "2": "c:functionParam", "3": "c:type", "4": "c:macro"}, "terms": {"": [0, 1, 2, 4], "0": [0, 4], "1": 4, "10": 4, "100": 0, "2": 4, "200": 0, "250": 4, "3": 4, "5000": 4, "A": [0, 4], "And": 0, "For": [0, 1, 4], "If": [0, 4], "In": 4, "It": [0, 1], "On": 0, "That": 4, "The": [0, 1, 2, 3, 4], "Then": 4, "These": 0, "To": [0, 1, 2, 4], "about": 1, "abov": 4, "abstract": 4, "acceler": [1, 4], "access": 4, "acquir": 4, "activ": 4, "ad": 0, "add": [0, 1, 2, 4], "addit": [0, 4], "address": [0, 4], "after": 4, "again": 4, "all": [2, 5], "alloc": [0, 4], "allow": 4, "alongsid": 2, "also": 4, "alwai": 0, "amend": 4, "amount": 4, "an": [0, 1, 2, 4], "ani": [0, 4], "anoth": [0, 4], "api": [2, 3], "app": 1, "appear": 4, "applic": 1, "approach": 4, "ar": [1, 2, 4], "arduino": [4, 5], "aren": 4, "around": [0, 4], "arrai": 0, "asid": 4, "avail": [0, 3, 4], "availbyt": 4, "availfn": 0, "base": [1, 2, 4], "base64": 0, "becaus": [0, 4], "been": 1, "befor": [0, 2, 4], "began": 4, "begin": 4, "behavior": 0, "below": [2, 4], "between": 4, "binari": 0, "binarydata": 0, "binarydatalen": 0, "block": 0, "blue": [1, 2, 3, 4, 5], "board": 4, "bool": [0, 4], "boolean": 0, "break": 4, "breakdown": 4, "bu": 4, "buffer": [0, 4], "build": 0, "byte": [0, 4], "c": [0, 1, 2, 5], "call": [2, 3, 4], "callback": 4, "caller": [0, 4], "can": [2, 4], "cannot": 4, "care": 1, "case": 4, "caus": 0, "char": [0, 4], "check": [0, 1, 4], "chunk": [0, 4], "circular": 4, "cjson": [0, 1], "clear": 4, "clone": 2, "cmd": 0, "code": [3, 4], "command": 0, "commun": [0, 2, 3, 4], "compat": 4, "compil": 2, "complex": 4, "compos": 2, "comprehens": 4, "concurr": 4, "connect": [2, 4], "const": [0, 4], "contain": 0, "continu": 4, "control": 1, "copi": 0, "core": [0, 1], "counter": [0, 4], "cover": [0, 2, 4], "creat": [0, 1], "current": 4, "data": [0, 1, 4], "decod": 0, "default": [0, 4], "defin": 4, "delai": 0, "delaymsfn": 0, "delaymshook": 0, "depend": 4, "describ": 4, "descript": 5, "detail": [1, 4], "determin": [0, 4], "devaddress": 4, "develop": [2, 4, 5], "differ": 4, "direct": 4, "directli": 0, "directori": 2, "dn_cjson_nesting_limit": 0, "do": 4, "doe": 0, "doesn": 4, "don": 1, "done": 4, "doubl": 0, "download": 2, "drive": 4, "e": [0, 1, 4], "els": [1, 4], "empti": 0, "encod": 0, "end": 4, "endif": 4, "ensur": 4, "equal": 4, "err": 0, "err_cod": 4, "error": [0, 1, 4], "errstr": 4, "essenti": [2, 4], "ever": 1, "everi": 4, "exampl": 0, "exce": 0, "exist": 0, "expect": 0, "failur": 0, "fals": [0, 1, 4], "familiar": [2, 4], "field": [0, 1], "fieldnam": 0, "file": [1, 2], "find": 0, "first": [0, 1, 4], "fix": 4, "flag": 4, "float": 0, "flush": [0, 4], "follow": 4, "frame": 4, "free": [0, 1], "freed": 0, "freefn": 0, "freehook": 0, "from": [0, 1, 2, 4], "function": 1, "fundament": 2, "g": 0, "gener": 4, "generaliz": 4, "get": [0, 3, 4], "getmsfn": 0, "getmshook": 0, "git": 2, "github": [2, 3], "given": 0, "go": 4, "goodbyt": 4, "guarante": 0, "guid": 4, "h": 2, "ha": [0, 1, 4], "hal": 4, "hal_delai": 4, "hal_gettick": 4, "hal_i2c_master_rec": 4, "hal_i2c_master_transmit": 4, "hal_ok": 4, "hal_statustypedef": 4, "hal_uart_transmit": 4, "handl": [0, 1, 4], "handler": 4, "harmless": 4, "have": [0, 1], "hdr": 4, "header": 4, "henc": 4, "hi2c1": 4, "hold": [0, 1], "host": 4, "how": [2, 4], "howev": 0, "huart1": 4, "hub": 0, "humid": 1, "i": [1, 2, 3, 5], "i2c": 2, "i2creceivefn": 0, "i2cresetfn": 0, "i2ctransmitfn": 0, "implement": 4, "includ": 2, "incorrect": 4, "increas": 0, "index": 4, "indic": [0, 4], "initi": [2, 3], "instead": 0, "insuffici": 4, "int": 4, "int64_t": 0, "integ": 0, "intend": 4, "interfac": [1, 4], "intern": [1, 4], "interrupt": 4, "invalid": 0, "item": 0, "its": 0, "itself": [0, 4], "j": [0, 1], "jadd": 1, "jaddarraytoobject": [0, 1], "jaddbinarytoobject": 0, "jaddbooltoobject": [0, 1], "jaddnumbertoobject": [0, 1], "jaddobjecttoobject": [0, 1], "jaddstringtoobject": [0, 1], "jbool": 0, "jcreateobject": 0, "jdelet": 0, "jfree": 0, "jgetarrai": 0, "jgetbinaryfromobject": 0, "jgetbool": 0, "jgetint": 0, "jgetnumb": 0, "jgetobject": 0, "jgetstr": 0, "jinteg": 0, "jispres": 0, "jmalloc": 0, "jnumber": 0, "jpars": 0, "jprintunformat": 0, "json": [1, 2, 4], "juinteg": 0, "just": 1, "keep": 4, "know": 4, "len": 4, "length": [0, 4], "let": 4, "level": [0, 4], "libc": 4, "librari": [1, 3, 5], "licens": 3, "like": [0, 1], "limit": 0, "line": 4, "list": [4, 5], "lock": [0, 4], "lockfn": 0, "locki2cfn": 0, "locknotecard": 4, "logic": 4, "long": 4, "longer": 0, "look": 1, "m": [0, 4], "macro": 4, "mai": 0, "main": 4, "maintain": 4, "make": [0, 1, 2], "malloc": 0, "mallocfn": 0, "mallochook": 0, "mani": 4, "manner": 4, "max": [0, 4], "maximum": [0, 4], "maxtransmits": 0, "mbed": 5, "mcu": 4, "mean": 0, "mem": 0, "member": 0, "memcpi": 4, "method": 4, "middl": 4, "millisecond": [0, 4], "minimum": 0, "mit": 3, "modifi": 1, "monitor": 1, "more": 4, "msp430": 5, "multipl": [0, 4], "must": [0, 1, 4], "mutexfn": 0, "mx_i2c1_deinit": 4, "mx_i2c1_init": 4, "mx_usart1_uart_deinit": 4, "mx_usart1_uart_init": 4, "n_": 2, "n_cjson_nesting_limit": 0, "name": [0, 5], "need": [0, 1], "nest": 0, "never": 0, "new": [0, 4], "newli": 0, "newlin": 0, "note": [0, 1, 2, 5], "note_i2c_addr_default": [0, 4], "note_i2c_max_default": [0, 4], "notecard": 3, "notecard_use_i2c": 4, "notecardaddr": 0, "notecardlock": 4, "notedelaym": 4, "notedeleterespons": [0, 1], "notenewrequest": [0, 1], "noterequest": [0, 1], "noterequestrespons": [0, 1], "noterequestresponsejson": [0, 1], "noterequestresponsewithretri": 0, "noterequestwithretri": 0, "noteresponseerror": [0, 1], "notesetfn": [0, 4], "notesetfni2c": [0, 4], "notesetfni2cmutex": [0, 4], "notesetfnnotemutex": [0, 4], "notesetfnseri": [0, 4], "noth": 4, "now": [1, 4], "nrf52": 5, "null": [0, 1, 4], "number": [0, 1, 4], "object": [0, 1], "occur": 0, "offici": 3, "onc": [0, 1], "one": [0, 4], "onli": [1, 4], "opaqu": [0, 1], "open": [3, 4, 5], "order": 4, "other": [2, 4], "otherwis": 0, "out": [0, 1], "over": [0, 4], "overal": 4, "overflow": 0, "overrid": 0, "overview": 2, "p": 0, "packet": 4, "page": [0, 2], "param": 0, "paramet": [0, 4], "parent": 0, "pars": 0, "parser": 0, "pass": [0, 1], "path": 2, "payload": 4, "pbuffer": 4, "peripher": [0, 4], "plain": 1, "platform": [0, 4], "point": [0, 4], "pointer": 0, "popul": [0, 4], "port": [3, 4], "possibl": 0, "prefix": 2, "prepar": [1, 4], "present": 0, "prevent": 0, "previous": 4, "process": 0, "produc": 0, "project": 2, "protocol": [2, 4], "provid": [0, 4], "qo": 1, "queri": 0, "rather": [0, 1], "read": [0, 2, 4], "readbuf": 4, "readlen": 4, "real": 1, "receiv": [0, 4], "receivefn": 0, "reduc": 0, "refer": 3, "regardless": 0, "regist": 4, "reiniti": 4, "reli": 4, "remain": 0, "repositori": 2, "repres": 0, "represent": 0, "req": [0, 1], "reqjson": 0, "request": [0, 1, 4], "requir": 4, "reset": [0, 4], "resetfn": 0, "respect": [0, 4], "respons": [0, 1, 4], "rest": 4, "retbinarydata": 0, "retbinarydatalen": 0, "retir": 0, "retri": [0, 4], "return": [0, 1, 4], "root": 2, "rsp": [0, 1], "rto": 5, "run": 4, "rxbuf": 0, "rxbufsiz": 0, "same": 4, "second": [0, 4], "section": 4, "see": 0, "segment": 0, "send": [0, 1, 4], "sent": 0, "seri": 4, "serial": [1, 2], "serialavailablefn": 0, "serialbuff": 4, "serialdrainindex": 4, "serialfillindex": 4, "serialreceivefn": 0, "serialresetfn": 0, "serialtransmitfn": 0, "set": [0, 4], "sever": 4, "shall": 0, "should": [0, 1, 4], "sign": 0, "similar": 4, "simpl": 4, "simpler": 4, "simplest": 4, "simpli": [0, 2, 4], "sinc": 0, "singl": [0, 4], "site": [2, 4], "size": [0, 4], "size_t": [0, 4], "sizeof": 4, "sleep": 4, "slightli": 4, "so": [0, 4], "some": [1, 4], "someth": 4, "sourc": [3, 4, 5], "space": 4, "specif": [0, 4], "specifi": 4, "src": 4, "stack": 0, "start": [3, 4], "still": 4, "stm32": 4, "stm32f1": 5, "stm32g0": 5, "stm32l0": 5, "stm32l4": 5, "string": [0, 1], "struct": [0, 1], "succe": 0, "success": [0, 1], "successfulli": [0, 4], "support": [2, 4], "sure": 2, "t": [1, 4], "take": 1, "task": 4, "temperatur": 1, "termin": 0, "text": 4, "than": [0, 1, 4], "thei": 4, "thi": [0, 1, 4, 5], "those": 4, "through": 4, "ti": 5, "timeoutsecond": 0, "too": 4, "transact": 4, "transmiss": [0, 4], "transmit": [0, 4], "transmitfn": 0, "treat": [0, 1], "true": [0, 1, 4], "two": 4, "txbuf": 0, "txbufsiz": 0, "type": 1, "typedef": 0, "uart": 4, "uint16_t": [0, 4], "uint32_t": [0, 4], "uint64_t": 0, "uint8_t": [0, 4], "undefin": 0, "under": 3, "understand": 2, "unformat": 0, "unlik": [0, 4], "unlock": [0, 4], "unlockfn": 0, "unlocki2cfn": 0, "unlocknotecard": 4, "unsign": [0, 4], "until": [0, 4], "up": 0, "us": [0, 1, 4], "user": 0, "valid": 0, "valu": [0, 4], "valv": 1, "vari": 4, "variabl": 4, "variou": [0, 4], "verbatim": 0, "version": 1, "via": [0, 4], "visibl": 2, "void": [0, 4], "wa": [0, 1], "walk": 4, "we": 4, "well": 0, "what": 0, "when": [0, 1], "where": 4, "whether": 1, "which": [0, 4], "while": 4, "whitespac": 0, "whose": 0, "without": 0, "work": [0, 1], "wrap": 4, "wrapper": [0, 5], "write": 4, "writebuf": 4, "writelen": 4, "x": 0, "yield": 4, "you": [0, 1, 2, 4], "your": 2, "yourself": [2, 4], "zephyr": [1, 5], "zero": 0}, "titles": ["API Reference", "Calling the Notecard API", "Getting Started", "note-c", "Library Initialization", "Ports"], "titleterms": {"api": [0, 1], "background": 2, "c": [3, 4], "call": [0, 1], "code": 2, "content": [0, 4], "delai": 4, "dynam": [0, 4], "exampl": [1, 4], "free": 4, "function": 0, "get": 2, "hook": [0, 4], "i": [0, 4], "i2c": [0, 4], "initi": 4, "json": 0, "librari": [2, 4], "macro": 0, "malloc": 4, "manipul": 0, "memori": [0, 4], "milli": 4, "mutex": [0, 4], "note": [3, 4], "notecard": [0, 1, 2, 4], "notei2crec": 4, "notei2creset": 4, "notei2ctransmit": 4, "noteserialavail": 4, "noteserialrec": 4, "noteserialreset": 4, "noteserialtransmit": 4, "o": [0, 4], "port": 5, "refer": 0, "serial": [0, 4], "sourc": 2, "start": 2, "stm32l4": 4, "tabl": [0, 4], "time": [0, 4], "type": 0, "us": 2}}) \ No newline at end of file