From def5c50960eea4c112647f88361a3ae7155901a8 Mon Sep 17 00:00:00 2001 From: egor-tensin Date: Tue, 4 Jul 2023 00:48:00 +0000 Subject: =?UTF-8?q?Deploying=20to=20gh-pages=20from=20@=20egor-tensin/wina?= =?UTF-8?q?pi-common@0c196cbe8b4927c78c02b2c7312fc69a507db845=20?= =?UTF-8?q?=F0=9F=9A=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- annotated.html | 104 ++ bc_s.png | Bin 0 -> 676 bytes bdwn.png | Bin 0 -> 147 bytes buffer_8hpp_source.html | 160 ++ classes.html | 104 ++ classwinapi_1_1Buffer-members.html | 92 + classwinapi_1_1Buffer.html | 414 +++++ classwinapi_1_1Buffer.png | Bin 0 -> 678 bytes classwinapi_1_1CanonicalPath-members.html | 85 + classwinapi_1_1CanonicalPath.html | 141 ++ classwinapi_1_1CommandLine-members.html | 96 ++ classwinapi_1_1CommandLine.html | 536 ++++++ classwinapi_1_1File-members.html | 112 ++ classwinapi_1_1File.html | 495 ++++++ classwinapi_1_1File.png | Bin 0 -> 479 bytes classwinapi_1_1Handle-members.html | 101 ++ classwinapi_1_1Handle.html | 434 +++++ classwinapi_1_1Handle.png | Bin 0 -> 486 bytes classwinapi_1_1Pipe-members.html | 86 + classwinapi_1_1Pipe.html | 240 +++ classwinapi_1_1Process-members.html | 102 ++ classwinapi_1_1Process.html | 697 ++++++++ classwinapi_1_1SharedMemory-members.html | 85 + classwinapi_1_1SharedMemory.html | 245 +++ classwinapi_1_1SharedObject-members.html | 92 + classwinapi_1_1SharedObject.html | 279 +++ classwinapi_1_1Sid-members.html | 89 + classwinapi_1_1Sid.html | 128 ++ ...winapi_1_1error_1_1CategoryWindows-members.html | 84 + classwinapi_1_1error_1_1CategoryWindows.html | 104 ++ classwinapi_1_1error_1_1CategoryWindows.png | Bin 0 -> 715 bytes closed.png | Bin 0 -> 132 bytes cmd__line_8cpp_source.html | 249 +++ cmd__line_8hpp_source.html | 152 ++ dir_68267d1309a1af8e8297ef4c3efbcdba.html | 78 + dir_d44c64559bbebec7f509842c48db8b23.html | 82 + dir_f1714771db42b7b5a0cd2ebe6e9736ed.html | 85 + doc.png | Bin 0 -> 746 bytes doxygen.css | 1793 ++++++++++++++++++++ doxygen.svg | 26 + dynsections.js | 128 ++ error_8cpp_source.html | 148 ++ error_8hpp.html | 146 ++ error_8hpp_source.html | 122 ++ file_8cpp_source.html | 236 +++ file_8hpp_source.html | 155 ++ files.html | 105 ++ folderclosed.png | Bin 0 -> 616 bytes folderopen.png | Bin 0 -> 597 bytes functions.html | 305 ++++ functions_func.html | 305 ++++ handle_8cpp_source.html | 225 +++ handle_8hpp_source.html | 152 ++ hierarchy.html | 102 ++ index.html | 91 + jquery.js | 35 + menu.js | 51 + menudata.js | 65 + nav_f.png | Bin 0 -> 153 bytes nav_g.png | Bin 0 -> 95 bytes nav_h.png | Bin 0 -> 98 bytes open.png | Bin 0 -> 123 bytes path_8cpp_source.html | 135 ++ path_8hpp_source.html | 105 ++ pipe_8cpp_source.html | 125 ++ pipe_8hpp_source.html | 113 ++ process_8cpp_source.html | 503 ++++++ process_8hpp_source.html | 193 +++ process__io_8cpp_source.html | 143 ++ process__io_8hpp_source.html | 145 ++ resource_8hpp_source.html | 108 ++ search/all_0.html | 37 + search/all_0.js | 7 + search/all_1.html | 37 + search/all_1.js | 4 + search/all_10.html | 37 + search/all_10.js | 8 + search/all_2.html | 37 + search/all_2.js | 11 + search/all_3.html | 37 + search/all_3.js | 4 + search/all_4.html | 37 + search/all_4.js | 4 + search/all_5.html | 37 + search/all_5.js | 5 + search/all_6.html | 37 + search/all_6.js | 14 + search/all_7.html | 37 + search/all_7.js | 6 + search/all_8.html | 37 + search/all_8.js | 7 + search/all_9.html | 37 + search/all_9.js | 4 + search/all_a.html | 37 + search/all_a.js | 7 + search/all_b.html | 37 + search/all_b.js | 8 + search/all_c.html | 37 + search/all_c.js | 5 + search/all_d.html | 37 + search/all_d.js | 9 + search/all_e.html | 37 + search/all_e.js | 17 + search/all_f.html | 37 + search/all_f.js | 5 + search/classes_0.html | 37 + search/classes_0.js | 4 + search/classes_1.html | 37 + search/classes_1.js | 6 + search/classes_2.html | 37 + search/classes_2.js | 4 + search/classes_3.html | 37 + search/classes_3.js | 5 + search/classes_4.html | 37 + search/classes_4.js | 5 + search/classes_5.html | 37 + search/classes_5.js | 4 + search/classes_6.html | 37 + search/classes_6.js | 6 + search/classes_7.html | 37 + search/classes_7.js | 4 + search/classes_8.html | 37 + search/classes_8.js | 11 + search/close.svg | 31 + search/files_0.html | 37 + search/files_0.js | 4 + search/functions_0.html | 37 + search/functions_0.js | 7 + search/functions_1.html | 37 + search/functions_1.js | 4 + search/functions_2.html | 37 + search/functions_2.js | 9 + search/functions_3.html | 37 + search/functions_3.js | 4 + search/functions_4.html | 37 + search/functions_4.js | 5 + search/functions_5.html | 37 + search/functions_5.js | 14 + search/functions_6.html | 37 + search/functions_6.js | 4 + search/functions_7.html | 37 + search/functions_7.js | 5 + search/functions_8.html | 37 + search/functions_8.js | 7 + search/functions_9.html | 37 + search/functions_9.js | 6 + search/functions_a.html | 37 + search/functions_a.js | 5 + search/functions_b.html | 37 + search/functions_b.js | 8 + search/functions_c.html | 37 + search/functions_c.js | 12 + search/functions_d.html | 37 + search/functions_d.js | 5 + search/functions_e.html | 37 + search/functions_e.js | 7 + search/mag_sel.svg | 74 + search/nomatches.html | 13 + search/pages_0.html | 37 + search/pages_0.js | 4 + search/search.css | 257 +++ search/search.js | 816 +++++++++ search/search_l.png | Bin 0 -> 567 bytes search/search_m.png | Bin 0 -> 158 bytes search/search_r.png | Bin 0 -> 553 bytes search/searchdata.js | 27 + shmem_8cpp_source.html | 154 ++ shmem_8hpp_source.html | 169 ++ sid_8cpp_source.html | 127 ++ sid_8hpp_source.html | 121 ++ splitbar.png | Bin 0 -> 314 bytes ...hash_3_01winapi_1_1File_1_1ID_01_4-members.html | 82 + ...tstd_1_1hash_3_01winapi_1_1File_1_1ID_01_4.html | 94 + structwinapi_1_1File_1_1ID-members.html | 83 + structwinapi_1_1File_1_1ID.html | 101 ++ structwinapi_1_1LocalDelete-members.html | 82 + structwinapi_1_1LocalDelete.html | 94 + structwinapi_1_1ProcessParameters-members.html | 89 + structwinapi_1_1ProcessParameters.html | 129 ++ structwinapi_1_1ProcessParameters.png | Bin 0 -> 724 bytes structwinapi_1_1Resource-members.html | 86 + structwinapi_1_1Resource.html | 139 ++ structwinapi_1_1ShellParameters-members.html | 92 + structwinapi_1_1ShellParameters.html | 144 ++ structwinapi_1_1ShellParameters.png | Bin 0 -> 722 bytes structwinapi_1_1process_1_1IO-members.html | 86 + structwinapi_1_1process_1_1IO.html | 112 ++ structwinapi_1_1process_1_1Stderr-members.html | 87 + structwinapi_1_1process_1_1Stderr.html | 232 +++ structwinapi_1_1process_1_1Stderr.png | Bin 0 -> 644 bytes structwinapi_1_1process_1_1Stdin-members.html | 87 + structwinapi_1_1process_1_1Stdin.html | 232 +++ structwinapi_1_1process_1_1Stdin.png | Bin 0 -> 634 bytes structwinapi_1_1process_1_1Stdout-members.html | 87 + structwinapi_1_1process_1_1Stdout.html | 232 +++ structwinapi_1_1process_1_1Stdout.png | Bin 0 -> 644 bytes structwinapi_1_1process_1_1Stream-members.html | 83 + structwinapi_1_1process_1_1Stream.html | 112 ++ structwinapi_1_1process_1_1Stream.png | Bin 0 -> 1070 bytes sync_off.png | Bin 0 -> 853 bytes sync_on.png | Bin 0 -> 845 bytes tab_a.png | Bin 0 -> 142 bytes tab_b.png | Bin 0 -> 169 bytes tab_h.png | Bin 0 -> 177 bytes tab_s.png | Bin 0 -> 184 bytes tabs.css | 1 + utils_8hpp_source.html | 103 ++ window__style_8hpp_source.html | 105 ++ 208 files changed, 17949 insertions(+) create mode 100644 annotated.html create mode 100644 bc_s.png create mode 100644 bdwn.png create mode 100644 buffer_8hpp_source.html create mode 100644 classes.html create mode 100644 classwinapi_1_1Buffer-members.html create mode 100644 classwinapi_1_1Buffer.html create mode 100644 classwinapi_1_1Buffer.png create mode 100644 classwinapi_1_1CanonicalPath-members.html create mode 100644 classwinapi_1_1CanonicalPath.html create mode 100644 classwinapi_1_1CommandLine-members.html create mode 100644 classwinapi_1_1CommandLine.html create mode 100644 classwinapi_1_1File-members.html create mode 100644 classwinapi_1_1File.html create mode 100644 classwinapi_1_1File.png create mode 100644 classwinapi_1_1Handle-members.html create mode 100644 classwinapi_1_1Handle.html create mode 100644 classwinapi_1_1Handle.png create mode 100644 classwinapi_1_1Pipe-members.html create mode 100644 classwinapi_1_1Pipe.html create mode 100644 classwinapi_1_1Process-members.html create mode 100644 classwinapi_1_1Process.html create mode 100644 classwinapi_1_1SharedMemory-members.html create mode 100644 classwinapi_1_1SharedMemory.html create mode 100644 classwinapi_1_1SharedObject-members.html create mode 100644 classwinapi_1_1SharedObject.html create mode 100644 classwinapi_1_1Sid-members.html create mode 100644 classwinapi_1_1Sid.html create mode 100644 classwinapi_1_1error_1_1CategoryWindows-members.html create mode 100644 classwinapi_1_1error_1_1CategoryWindows.html create mode 100644 classwinapi_1_1error_1_1CategoryWindows.png create mode 100644 closed.png create mode 100644 cmd__line_8cpp_source.html create mode 100644 cmd__line_8hpp_source.html create mode 100644 dir_68267d1309a1af8e8297ef4c3efbcdba.html create mode 100644 dir_d44c64559bbebec7f509842c48db8b23.html create mode 100644 dir_f1714771db42b7b5a0cd2ebe6e9736ed.html create mode 100644 doc.png create mode 100644 doxygen.css create mode 100644 doxygen.svg create mode 100644 dynsections.js create mode 100644 error_8cpp_source.html create mode 100644 error_8hpp.html create mode 100644 error_8hpp_source.html create mode 100644 file_8cpp_source.html create mode 100644 file_8hpp_source.html create mode 100644 files.html create mode 100644 folderclosed.png create mode 100644 folderopen.png create mode 100644 functions.html create mode 100644 functions_func.html create mode 100644 handle_8cpp_source.html create mode 100644 handle_8hpp_source.html create mode 100644 hierarchy.html create mode 100644 index.html create mode 100644 jquery.js create mode 100644 menu.js create mode 100644 menudata.js create mode 100644 nav_f.png create mode 100644 nav_g.png create mode 100644 nav_h.png create mode 100644 open.png create mode 100644 path_8cpp_source.html create mode 100644 path_8hpp_source.html create mode 100644 pipe_8cpp_source.html create mode 100644 pipe_8hpp_source.html create mode 100644 process_8cpp_source.html create mode 100644 process_8hpp_source.html create mode 100644 process__io_8cpp_source.html create mode 100644 process__io_8hpp_source.html create mode 100644 resource_8hpp_source.html create mode 100644 search/all_0.html create mode 100644 search/all_0.js create mode 100644 search/all_1.html create mode 100644 search/all_1.js create mode 100644 search/all_10.html create mode 100644 search/all_10.js create mode 100644 search/all_2.html create mode 100644 search/all_2.js create mode 100644 search/all_3.html create mode 100644 search/all_3.js create mode 100644 search/all_4.html create mode 100644 search/all_4.js create mode 100644 search/all_5.html create mode 100644 search/all_5.js create mode 100644 search/all_6.html create mode 100644 search/all_6.js create mode 100644 search/all_7.html create mode 100644 search/all_7.js create mode 100644 search/all_8.html create mode 100644 search/all_8.js create mode 100644 search/all_9.html create mode 100644 search/all_9.js create mode 100644 search/all_a.html create mode 100644 search/all_a.js create mode 100644 search/all_b.html create mode 100644 search/all_b.js create mode 100644 search/all_c.html create mode 100644 search/all_c.js create mode 100644 search/all_d.html create mode 100644 search/all_d.js create mode 100644 search/all_e.html create mode 100644 search/all_e.js create mode 100644 search/all_f.html create mode 100644 search/all_f.js create mode 100644 search/classes_0.html create mode 100644 search/classes_0.js create mode 100644 search/classes_1.html create mode 100644 search/classes_1.js create mode 100644 search/classes_2.html create mode 100644 search/classes_2.js create mode 100644 search/classes_3.html create mode 100644 search/classes_3.js create mode 100644 search/classes_4.html create mode 100644 search/classes_4.js create mode 100644 search/classes_5.html create mode 100644 search/classes_5.js create mode 100644 search/classes_6.html create mode 100644 search/classes_6.js create mode 100644 search/classes_7.html create mode 100644 search/classes_7.js create mode 100644 search/classes_8.html create mode 100644 search/classes_8.js create mode 100644 search/close.svg create mode 100644 search/files_0.html create mode 100644 search/files_0.js create mode 100644 search/functions_0.html create mode 100644 search/functions_0.js create mode 100644 search/functions_1.html create mode 100644 search/functions_1.js create mode 100644 search/functions_2.html create mode 100644 search/functions_2.js create mode 100644 search/functions_3.html create mode 100644 search/functions_3.js create mode 100644 search/functions_4.html create mode 100644 search/functions_4.js create mode 100644 search/functions_5.html create mode 100644 search/functions_5.js create mode 100644 search/functions_6.html create mode 100644 search/functions_6.js create mode 100644 search/functions_7.html create mode 100644 search/functions_7.js create mode 100644 search/functions_8.html create mode 100644 search/functions_8.js create mode 100644 search/functions_9.html create mode 100644 search/functions_9.js create mode 100644 search/functions_a.html create mode 100644 search/functions_a.js create mode 100644 search/functions_b.html create mode 100644 search/functions_b.js create mode 100644 search/functions_c.html create mode 100644 search/functions_c.js create mode 100644 search/functions_d.html create mode 100644 search/functions_d.js create mode 100644 search/functions_e.html create mode 100644 search/functions_e.js create mode 100644 search/mag_sel.svg create mode 100644 search/nomatches.html create mode 100644 search/pages_0.html create mode 100644 search/pages_0.js create mode 100644 search/search.css create mode 100644 search/search.js create mode 100644 search/search_l.png create mode 100644 search/search_m.png create mode 100644 search/search_r.png create mode 100644 search/searchdata.js create mode 100644 shmem_8cpp_source.html create mode 100644 shmem_8hpp_source.html create mode 100644 sid_8cpp_source.html create mode 100644 sid_8hpp_source.html create mode 100644 splitbar.png create mode 100644 structstd_1_1hash_3_01winapi_1_1File_1_1ID_01_4-members.html create mode 100644 structstd_1_1hash_3_01winapi_1_1File_1_1ID_01_4.html create mode 100644 structwinapi_1_1File_1_1ID-members.html create mode 100644 structwinapi_1_1File_1_1ID.html create mode 100644 structwinapi_1_1LocalDelete-members.html create mode 100644 structwinapi_1_1LocalDelete.html create mode 100644 structwinapi_1_1ProcessParameters-members.html create mode 100644 structwinapi_1_1ProcessParameters.html create mode 100644 structwinapi_1_1ProcessParameters.png create mode 100644 structwinapi_1_1Resource-members.html create mode 100644 structwinapi_1_1Resource.html create mode 100644 structwinapi_1_1ShellParameters-members.html create mode 100644 structwinapi_1_1ShellParameters.html create mode 100644 structwinapi_1_1ShellParameters.png create mode 100644 structwinapi_1_1process_1_1IO-members.html create mode 100644 structwinapi_1_1process_1_1IO.html create mode 100644 structwinapi_1_1process_1_1Stderr-members.html create mode 100644 structwinapi_1_1process_1_1Stderr.html create mode 100644 structwinapi_1_1process_1_1Stderr.png create mode 100644 structwinapi_1_1process_1_1Stdin-members.html create mode 100644 structwinapi_1_1process_1_1Stdin.html create mode 100644 structwinapi_1_1process_1_1Stdin.png create mode 100644 structwinapi_1_1process_1_1Stdout-members.html create mode 100644 structwinapi_1_1process_1_1Stdout.html create mode 100644 structwinapi_1_1process_1_1Stdout.png create mode 100644 structwinapi_1_1process_1_1Stream-members.html create mode 100644 structwinapi_1_1process_1_1Stream.html create mode 100644 structwinapi_1_1process_1_1Stream.png create mode 100644 sync_off.png create mode 100644 sync_on.png create mode 100644 tab_a.png create mode 100644 tab_b.png create mode 100644 tab_h.png create mode 100644 tab_s.png create mode 100644 tabs.css create mode 100644 utils_8hpp_source.html create mode 100644 window__style_8hpp_source.html diff --git a/annotated.html b/annotated.html new file mode 100644 index 0000000..63a6c30 --- /dev/null +++ b/annotated.html @@ -0,0 +1,104 @@ + + + + + + + +winapi_common: Class List + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
+
Class List
+
+
+
Here are the classes, structs, unions and interfaces with brief descriptions:
+
[detail level 123]
+ + + + + + + + + + + + + + + + + + + + + + + + + + +
 Nstd
 Chash< winapi::File::ID >
 Nwinapi
 Nerror
 CCategoryWindows
 Nprocess
 CStream
 CStdinRedirect child process's stdin
 CStdoutRedirect child process's stdout
 CStderrRedirect child process's stderr
 CIOChild process IO settings
 CBufferBinary data container
 CCommandLineCommand line for the current process or for launching new processes
 CFileFile I/O
 CID
 CHandleHANDLE wrapper
 CCanonicalPathAbsolute, canonical path
 CPipeAnonymous pipe wrapper
 CProcessParametersProcess parameters for Process::create()
 CShellParametersProcess parameters for Process::shell()
 CProcessCreate a new process or open an existing process
 CResourceResources embedded in a PE (Portable Executable)
 CSharedMemoryNamed shared memory region
 CSharedObjectEasy way to represent a C++ object as a shared memory region
 CSid
 CLocalDelete
+
+
+ + + + diff --git a/bc_s.png b/bc_s.png new file mode 100644 index 0000000..224b29a Binary files /dev/null and b/bc_s.png differ diff --git a/bdwn.png b/bdwn.png new file mode 100644 index 0000000..940a0b9 Binary files /dev/null and b/bdwn.png differ diff --git a/buffer_8hpp_source.html b/buffer_8hpp_source.html new file mode 100644 index 0000000..81c5b54 --- /dev/null +++ b/buffer_8hpp_source.html @@ -0,0 +1,160 @@ + + + + + + + +winapi_common: include/winapi/buffer.hpp Source File + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+
buffer.hpp
+
+
+
1 // Copyright (c) 2020 Egor Tensin <Egor.Tensin@gmail.com>
+
2 // This file is part of the "winapi-common" project.
+
3 // For details, see https://github.com/egor-tensin/winapi-common.
+
4 // Distributed under the MIT License.
+
5 
+
6 #pragma once
+
7 
+
8 #include <cstddef>
+
9 #include <cstring>
+
10 #include <initializer_list>
+
11 #include <sstream>
+
12 #include <stdexcept>
+
13 #include <string>
+
14 #include <utility>
+
15 #include <vector>
+
16 
+
17 namespace winapi {
+
18 
+
24 class Buffer : public std::vector<unsigned char> {
+
25 public:
+
26  typedef std::vector<unsigned char> Parent;
+
27 
+
28  Buffer() = default;
+
29 
+
31  Buffer(std::initializer_list<unsigned char> lst) : Parent{lst} {}
+
32 
+
34  explicit Buffer(Parent&& src) : Parent{std::move(src)} {}
+
35 
+
37  template <typename CharT>
+
38  explicit Buffer(const std::basic_string<CharT>& src) {
+
39  set(src);
+
40  }
+
41 
+
43  Buffer(const void* src, std::size_t nb) { set(src, nb); }
+
44 
+
46  template <typename CharT>
+
47  void set(const std::basic_string<CharT>& src) {
+
48  set(src.c_str(), src.length() * sizeof(std::basic_string<CharT>::char_type));
+
49  }
+
50 
+
52  void set(const void* src, std::size_t nb) {
+
53  resize(nb);
+
54  std::memcpy(data(), src, nb);
+
55  }
+
56 
+
58  std::string as_utf8() const {
+
59  const auto c_str = reinterpret_cast<const char*>(data());
+
60  const auto nb = size();
+
61  const auto nch = nb;
+
62  return {c_str, nch};
+
63  }
+
64 
+
66  std::wstring as_utf16() const {
+
67  const auto c_str = reinterpret_cast<const wchar_t*>(data());
+
68  const auto nb = size();
+
69  if (nb % 2 != 0) {
+
70  std::ostringstream oss;
+
71  oss << "Buffer size invalid at " << nb << " bytes";
+
72  throw std::runtime_error{oss.str()};
+
73  }
+
74  const auto nch = nb / 2;
+
75  return {c_str, nch};
+
76  }
+
77 
+
79  void add(const Buffer& src) {
+
80  const auto nb = size();
+
81  resize(nb + src.size());
+
82  std::memcpy(data() + nb, src.data(), src.size());
+
83  }
+
84 };
+
85 
+
86 } // namespace winapi
+
Binary data container.
Definition: buffer.hpp:24
+
void set(const std::basic_string< CharT > &src)
Definition: buffer.hpp:47
+
void add(const Buffer &src)
Definition: buffer.hpp:79
+
Buffer(Parent &&src)
Definition: buffer.hpp:34
+
Buffer(const std::basic_string< CharT > &src)
Definition: buffer.hpp:38
+
void set(const void *src, std::size_t nb)
Definition: buffer.hpp:52
+
Buffer(const void *src, std::size_t nb)
Definition: buffer.hpp:43
+
Buffer(std::initializer_list< unsigned char > lst)
Definition: buffer.hpp:31
+
std::wstring as_utf16() const
Definition: buffer.hpp:66
+
std::string as_utf8() const
Definition: buffer.hpp:58
+
+ + + + diff --git a/classes.html b/classes.html new file mode 100644 index 0000000..fed0b2a --- /dev/null +++ b/classes.html @@ -0,0 +1,104 @@ + + + + + + + +winapi_common: Class Index + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
+
Class Index
+
+
+
B | C | F | H | I | L | P | R | S
+
+
+
B
+
Buffer (winapi)
+
+
C
+
CanonicalPath (winapi)
CategoryWindows (winapi::error)
CommandLine (winapi)
+
+
F
+
File (winapi)
+
+
H
+
Handle (winapi)
hash< winapi::File::ID > (std)
+
+
I
+
File::ID (winapi)
IO (winapi::process)
+
+
L
+
LocalDelete (winapi)
+
+
P
+
Pipe (winapi)
Process (winapi)
ProcessParameters (winapi)
+
+
R
+
Resource (winapi)
+
+
S
+
SharedMemory (winapi)
SharedObject (winapi)
ShellParameters (winapi)
Sid (winapi)
Stderr (winapi::process)
Stdin (winapi::process)
Stdout (winapi::process)
Stream (winapi::process)
+
+
+ + + + diff --git a/classwinapi_1_1Buffer-members.html b/classwinapi_1_1Buffer-members.html new file mode 100644 index 0000000..d743a20 --- /dev/null +++ b/classwinapi_1_1Buffer-members.html @@ -0,0 +1,92 @@ + + + + + + + +winapi_common: Member List + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+
winapi::Buffer Member List
+
+
+ +

This is the complete list of members for winapi::Buffer, including all inherited members.

+ + + + + + + + + + + + +
add(const Buffer &src)winapi::Bufferinline
as_utf16() constwinapi::Bufferinline
as_utf8() constwinapi::Bufferinline
Buffer()=default (defined in winapi::Buffer)winapi::Buffer
Buffer(std::initializer_list< unsigned char > lst)winapi::Bufferinline
Buffer(Parent &&src)winapi::Bufferinlineexplicit
Buffer(const std::basic_string< CharT > &src)winapi::Bufferinlineexplicit
Buffer(const void *src, std::size_t nb)winapi::Bufferinline
Parent typedef (defined in winapi::Buffer)winapi::Buffer
set(const std::basic_string< CharT > &src)winapi::Bufferinline
set(const void *src, std::size_t nb)winapi::Bufferinline
+ + + + diff --git a/classwinapi_1_1Buffer.html b/classwinapi_1_1Buffer.html new file mode 100644 index 0000000..8c03e9c --- /dev/null +++ b/classwinapi_1_1Buffer.html @@ -0,0 +1,414 @@ + + + + + + + +winapi_common: winapi::Buffer Class Reference + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+ +
+
winapi::Buffer Class Reference
+
+
+ +

Binary data container. + More...

+
+Inheritance diagram for winapi::Buffer:
+
+
+ +
+ + + + +

+Public Types

+typedef std::vector< unsigned char > Parent
 
+ + + + + + + + + + + + + + + + + + + + + +

+Public Member Functions

 Buffer (std::initializer_list< unsigned char > lst)
 
 Buffer (Parent &&src)
 
template<typename CharT >
 Buffer (const std::basic_string< CharT > &src)
 
 Buffer (const void *src, std::size_t nb)
 
template<typename CharT >
void set (const std::basic_string< CharT > &src)
 
void set (const void *src, std::size_t nb)
 
std::string as_utf8 () const
 
std::wstring as_utf16 () const
 
void add (const Buffer &src)
 
+

Detailed Description

+

Binary data container.

+

This class wraps a blob of binary data.

+ +

Definition at line 24 of file buffer.hpp.

+

Constructor & Destructor Documentation

+ +

◆ Buffer() [1/4]

+ +
+
+ + + + + +
+ + + + + + + + +
winapi::Buffer::Buffer (std::initializer_list< unsigned char > lst)
+
+inline
+
+

Construct a buffer from an explicit list of byte values.

+ +

Definition at line 31 of file buffer.hpp.

+ +
+
+ +

◆ Buffer() [2/4]

+ +
+
+ + + + + +
+ + + + + + + + +
winapi::Buffer::Buffer (Parent && src)
+
+inlineexplicit
+
+

Construct a buffer from an instance of std::vector<unsigned char>.

+ +

Definition at line 34 of file buffer.hpp.

+ +
+
+ +

◆ Buffer() [3/4]

+ +
+
+
+template<typename CharT >
+ + + + + +
+ + + + + + + + +
winapi::Buffer::Buffer (const std::basic_string< CharT > & src)
+
+inlineexplicit
+
+

Construct a buffer from an instance of std::basic_string.

+ +

Definition at line 38 of file buffer.hpp.

+ +
+
+ +

◆ Buffer() [4/4]

+ +
+
+ + + + + +
+ + + + + + + + + + + + + + + + + + +
winapi::Buffer::Buffer (const void * src,
std::size_t nb 
)
+
+inline
+
+

Construct a buffer from a memory region.

+ +

Definition at line 43 of file buffer.hpp.

+ +
+
+

Member Function Documentation

+ +

◆ set() [1/2]

+ +
+
+
+template<typename CharT >
+ + + + + +
+ + + + + + + + +
void winapi::Buffer::set (const std::basic_string< CharT > & src)
+
+inline
+
+

Replace the buffer's contents with the data from std::basic_string.

+ +

Definition at line 47 of file buffer.hpp.

+ +
+
+ +

◆ set() [2/2]

+ +
+
+ + + + + +
+ + + + + + + + + + + + + + + + + + +
void winapi::Buffer::set (const void * src,
std::size_t nb 
)
+
+inline
+
+

Replace the buffer's contents with the data from a memory region.

+ +

Definition at line 52 of file buffer.hpp.

+ +
+
+ +

◆ as_utf8()

+ +
+
+ + + + + +
+ + + + + + + +
std::string winapi::Buffer::as_utf8 () const
+
+inline
+
+

Interpret the buffer's contents as a std::string.

+ +

Definition at line 58 of file buffer.hpp.

+ +
+
+ +

◆ as_utf16()

+ +
+
+ + + + + +
+ + + + + + + +
std::wstring winapi::Buffer::as_utf16 () const
+
+inline
+
+

Interpret the buffer's contents as a std::wstring.

+ +

Definition at line 66 of file buffer.hpp.

+ +
+
+ +

◆ add()

+ +
+
+ + + + + +
+ + + + + + + + +
void winapi::Buffer::add (const Buffersrc)
+
+inline
+
+

Append another buffer to the end of this one.

+ +

Definition at line 79 of file buffer.hpp.

+ +
+
+
The documentation for this class was generated from the following file: +
+ + + + diff --git a/classwinapi_1_1Buffer.png b/classwinapi_1_1Buffer.png new file mode 100644 index 0000000..7573e6f Binary files /dev/null and b/classwinapi_1_1Buffer.png differ diff --git a/classwinapi_1_1CanonicalPath-members.html b/classwinapi_1_1CanonicalPath-members.html new file mode 100644 index 0000000..f800668 --- /dev/null +++ b/classwinapi_1_1CanonicalPath-members.html @@ -0,0 +1,85 @@ + + + + + + + +winapi_common: Member List + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+
winapi::CanonicalPath Member List
+
+
+ +

This is the complete list of members for winapi::CanonicalPath, including all inherited members.

+ + + + + +
canonicalize(const std::string &)winapi::CanonicalPathstatic
CanonicalPath(const std::string &) (defined in winapi::CanonicalPath)winapi::CanonicalPathexplicit
get() const (defined in winapi::CanonicalPath)winapi::CanonicalPathinline
path() const (defined in winapi::CanonicalPath)winapi::CanonicalPathinline
+ + + + diff --git a/classwinapi_1_1CanonicalPath.html b/classwinapi_1_1CanonicalPath.html new file mode 100644 index 0000000..de994f0 --- /dev/null +++ b/classwinapi_1_1CanonicalPath.html @@ -0,0 +1,141 @@ + + + + + + + +winapi_common: winapi::CanonicalPath Class Reference + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+ +
+
winapi::CanonicalPath Class Reference
+
+
+ +

Absolute, canonical path. + More...

+ + + + + + + + +

+Public Member Functions

CanonicalPath (const std::string &)
 
+std::string get () const
 
+std::string path () const
 
+ + + +

+Static Public Member Functions

static std::string canonicalize (const std::string &)
 
+

Detailed Description

+

Absolute, canonical path.

+ +

Definition at line 13 of file path.hpp.

+

Member Function Documentation

+ +

◆ canonicalize()

+ +
+
+ + + + + +
+ + + + + + + + +
std::string winapi::CanonicalPath::canonicalize (const std::string & path)
+
+static
+
+

Make an absolute, canonical path.

+ +

Definition at line 52 of file path.cpp.

+ +
+
+
The documentation for this class was generated from the following files: +
+ + + + diff --git a/classwinapi_1_1CommandLine-members.html b/classwinapi_1_1CommandLine-members.html new file mode 100644 index 0000000..625afc1 --- /dev/null +++ b/classwinapi_1_1CommandLine-members.html @@ -0,0 +1,96 @@ + + + + + + + +winapi_common: Member List + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+
winapi::CommandLine Member List
+
+
+ +

This is the complete list of members for winapi::CommandLine, including all inherited members.

+ + + + + + + + + + + + + + + + +
args_to_string() constwinapi::CommandLine
CommandLine()=defaultwinapi::CommandLine
CommandLine(const std::string &argv0, const std::vector< std::string > &args={})winapi::CommandLineinlineexplicit
CommandLine(std::string &&argv0, std::vector< std::string > &&args={})winapi::CommandLineinlineexplicit
CommandLine(std::vector< std::string > argv)winapi::CommandLineexplicit
escape(const std::string &) (defined in winapi::CommandLine)winapi::CommandLinestatic
escape_cmd(const std::string &) (defined in winapi::CommandLine)winapi::CommandLinestatic
from_main(int argc, wchar_t *argv[])winapi::CommandLinestatic
get_args() constwinapi::CommandLineinline
get_argv() constwinapi::CommandLine
get_argv0() constwinapi::CommandLineinline
has_args() constwinapi::CommandLineinline
parse(const std::string &src)winapi::CommandLinestatic
query()winapi::CommandLinestatic
to_string() constwinapi::CommandLine
+ + + + diff --git a/classwinapi_1_1CommandLine.html b/classwinapi_1_1CommandLine.html new file mode 100644 index 0000000..5c00301 --- /dev/null +++ b/classwinapi_1_1CommandLine.html @@ -0,0 +1,536 @@ + + + + + + + +winapi_common: winapi::CommandLine Class Reference + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+ +
+
winapi::CommandLine Class Reference
+
+
+ +

Command line for the current process or for launching new processes. + More...

+ + + + + + + + + + + + + + + + + + + + + + +

+Public Member Functions

 CommandLine ()=default
 
 CommandLine (const std::string &argv0, const std::vector< std::string > &args={})
 
 CommandLine (std::string &&argv0, std::vector< std::string > &&args={})
 
 CommandLine (std::vector< std::string > argv)
 
std::string to_string () const
 
std::string args_to_string () const
 
std::string get_argv0 () const
 
bool has_args () const
 
const std::vector< std::string > & get_args () const
 
std::vector< std::string > get_argv () const
 
+ + + + + + + + + + + +

+Static Public Member Functions

static CommandLine query ()
 
static CommandLine parse (const std::string &src)
 
static CommandLine from_main (int argc, wchar_t *argv[])
 
+static std::string escape (const std::string &)
 
+static std::string escape_cmd (const std::string &)
 
+

Detailed Description

+

Command line for the current process or for launching new processes.

+

This class takes care of proper parsing and stringifying command line arguments so that they are safe to use with CreateProcess, ShellExecute, etc.

+ +

Definition at line 21 of file cmd_line.hpp.

+

Constructor & Destructor Documentation

+ +

◆ CommandLine() [1/4]

+ +
+
+ + + + + +
+ + + + + + + +
winapi::CommandLine::CommandLine ()
+
+default
+
+

Build an empty command line. It won't have neither argv[0], nor any other args.

+ +
+
+ +

◆ CommandLine() [2/4]

+ +
+
+ + + + + +
+ + + + + + + + + + + + + + + + + + +
winapi::CommandLine::CommandLine (const std::string & argv0,
const std::vector< std::string > & args = {} 
)
+
+inlineexplicit
+
+

Build a command line.

Parameters
+ + + +
argv0UTF-8 string, argv[0].
argsList of UTF-8 strings, other arguments.
+
+
+ +

Definition at line 50 of file cmd_line.hpp.

+ +
+
+ +

◆ CommandLine() [3/4]

+ +
+
+ + + + + +
+ + + + + + + + + + + + + + + + + + +
winapi::CommandLine::CommandLine (std::string && argv0,
std::vector< std::string > && args = {} 
)
+
+inlineexplicit
+
+

Build a command line.

Parameters
+ + + +
argv0UTF-8 string, argv[0].
argsList of UTF-8 strings, other arguments.
+
+
+ +

Definition at line 58 of file cmd_line.hpp.

+ +
+
+ +

◆ CommandLine() [4/4]

+ +
+
+ + + + + +
+ + + + + + + + +
winapi::CommandLine::CommandLine (std::vector< std::string > argv)
+
+explicit
+
+

Build a command line.

Parameters
+ + +
argvList of UTF-8 strings, including argv[0].
+
+
+ +

Definition at line 89 of file cmd_line.cpp.

+ +
+
+

Member Function Documentation

+ +

◆ query()

+ +
+
+ + + + + +
+ + + + + + + +
CommandLine winapi::CommandLine::query ()
+
+static
+
+

Get the command line used to launch this process.

+ +

Definition at line 75 of file cmd_line.cpp.

+ +
+
+ +

◆ parse()

+ +
+
+ + + + + +
+ + + + + + + + +
CommandLine winapi::CommandLine::parse (const std::string & src)
+
+static
+
+

Parse a command line from a string.

Parameters
+ + +
srcUTF-8 encoded string.
+
+
+ +

Definition at line 79 of file cmd_line.cpp.

+ +
+
+ +

◆ from_main()

+ +
+
+ + + + + +
+ + + + + + + + + + + + + + + + + + +
CommandLine winapi::CommandLine::from_main (int argc,
wchar_t * argv[] 
)
+
+static
+
+

Build a command line from main() arguments.

Parameters
+ + + +
argcLength of the argv array.
argvUTF-16 encoded strings.
+
+
+ +

Definition at line 83 of file cmd_line.cpp.

+ +
+
+ +

◆ to_string()

+ +
+
+ + + + + + + +
std::string winapi::CommandLine::to_string () const
+
+

Build a string that represents this command line.

Returns
UTF-8 string.
+ +

Definition at line 138 of file cmd_line.cpp.

+ +
+
+ +

◆ args_to_string()

+ +
+
+ + + + + + + +
std::string winapi::CommandLine::args_to_string () const
+
+

Build a string that represents this command line, but omit argv[0].

Returns
UTF-8 string.
+ +

Definition at line 142 of file cmd_line.cpp.

+ +
+
+ +

◆ get_argv0()

+ +
+
+ + + + + +
+ + + + + + + +
std::string winapi::CommandLine::get_argv0 () const
+
+inline
+
+

Get argv[0] for this command line.

Returns
UTF-8 string.
+ +

Definition at line 87 of file cmd_line.hpp.

+ +
+
+ +

◆ has_args()

+ +
+
+ + + + + +
+ + + + + + + +
bool winapi::CommandLine::has_args () const
+
+inline
+
+

Test if this command line has any additional arguments besides argv[0].

+ +

Definition at line 90 of file cmd_line.hpp.

+ +
+
+ +

◆ get_args()

+ +
+
+ + + + + +
+ + + + + + + +
const std::vector<std::string>& winapi::CommandLine::get_args () const
+
+inline
+
+

Get list of arguments for this command line beyond argv[0].

Returns
List of UTF-8 strings.
+ +

Definition at line 96 of file cmd_line.hpp.

+ +
+
+ +

◆ get_argv()

+ +
+
+ + + + + + + +
std::vector< std::string > winapi::CommandLine::get_argv () const
+
+

Get list of arguments for this command line.

Returns
List of UTF-8 strings.
+ +

Definition at line 146 of file cmd_line.cpp.

+ +
+
+
The documentation for this class was generated from the following files: +
+ + + + diff --git a/classwinapi_1_1File-members.html b/classwinapi_1_1File-members.html new file mode 100644 index 0000000..e6509a0 --- /dev/null +++ b/classwinapi_1_1File-members.html @@ -0,0 +1,112 @@ + + + + + + + +winapi_common: Member List + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+
winapi::File Member List
+
+
+ +

This is the complete list of members for winapi::File, including all inherited members.

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
close()winapi::Handle
dont_inherit() const (defined in winapi::Handle)winapi::Handleinline
File(Handle &&handle)winapi::Fileinlineexplicit
get() const (defined in winapi::Handle)winapi::Handleinline
get_size() constwinapi::File
Handle()=default (defined in winapi::Handle)winapi::Handle
Handle(HANDLE) (defined in winapi::Handle)winapi::Handleexplicit
inherit(bool yes=true) const (defined in winapi::Handle)winapi::Handle
is_std() constwinapi::Handle
is_valid() const (defined in winapi::Handle)winapi::Handle
is_valid(HANDLE) (defined in winapi::Handle)winapi::Handlestatic
max_chunk_size (defined in winapi::Handle)winapi::Handlestatic
open_r(const std::string &)winapi::Filestatic
open_r(const CanonicalPath &)winapi::Filestatic
open_read_attributes(const std::string &)winapi::Filestatic
open_read_attributes(const CanonicalPath &)winapi::Filestatic
open_w(const std::string &)winapi::Filestatic
open_w(const CanonicalPath &)winapi::Filestatic
operator HANDLE() const (defined in winapi::Handle)winapi::Handleinlineexplicit
ptr() const (defined in winapi::Handle)winapi::Handleinline
query_id() constwinapi::File
read() constwinapi::Handle
read_chunk(Buffer &read_chunk) constwinapi::Handle
remove(const std::string &)winapi::Filestatic
remove(const CanonicalPath &)winapi::Filestatic
std_err()winapi::Handlestatic
std_in()winapi::Handlestatic
std_out()winapi::Handlestatic
write(const void *data, std::size_t nb) constwinapi::Handle
write(const Buffer &buffer) constwinapi::Handle
write(const std::basic_string< CharT > &src) constwinapi::Handleinline
+ + + + diff --git a/classwinapi_1_1File.html b/classwinapi_1_1File.html new file mode 100644 index 0000000..49e9415 --- /dev/null +++ b/classwinapi_1_1File.html @@ -0,0 +1,495 @@ + + + + + + + +winapi_common: winapi::File Class Reference + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+ +
+
winapi::File Class Reference
+
+
+ +

File I/O. + More...

+
+Inheritance diagram for winapi::File:
+
+
+ + +winapi::Handle + +
+ + + + +

+Classes

struct  ID
 
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

+Public Member Functions

 File (Handle &&handle)
 
std::size_t get_size () const
 
ID query_id () const
 
- Public Member Functions inherited from winapi::Handle
Handle (HANDLE)
 
+HANDLE get () const
 
+HANDLE ptr () const
 
operator HANDLE () const
 
+bool is_valid () const
 
void close ()
 
bool is_std () const
 
Buffer read () const
 
bool read_chunk (Buffer &read_chunk) const
 
void write (const void *data, std::size_t nb) const
 
void write (const Buffer &buffer) const
 
template<typename CharT >
void write (const std::basic_string< CharT > &src) const
 
+void inherit (bool yes=true) const
 
+void dont_inherit () const
 
+ + + + + + + + + + + + + + + + + + + + + + + + + + +

+Static Public Member Functions

static File open_r (const std::string &)
 
static File open_r (const CanonicalPath &)
 
static File open_read_attributes (const std::string &)
 
static File open_read_attributes (const CanonicalPath &)
 
static File open_w (const std::string &)
 
static File open_w (const CanonicalPath &)
 
static void remove (const std::string &)
 
static void remove (const CanonicalPath &)
 
- Static Public Member Functions inherited from winapi::Handle
+static bool is_valid (HANDLE)
 
static Handle std_in ()
 
static Handle std_out ()
 
static Handle std_err ()
 
+ + + + +

+Additional Inherited Members

- Static Public Attributes inherited from winapi::Handle
+static constexpr std::size_t max_chunk_size = 16 * 1024
 
+

Detailed Description

+

File I/O.

+

Easily open, read & write files.

+ +

Definition at line 29 of file file.hpp.

+

Constructor & Destructor Documentation

+ +

◆ File()

+ +
+
+ + + + + +
+ + + + + + + + +
winapi::File::File (Handle && handle)
+
+inlineexplicit
+
+

Make a File instance from an open handle.

+ +

Definition at line 59 of file file.hpp.

+ +
+
+

Member Function Documentation

+ +

◆ open_r() [1/2]

+ +
+
+ + + + + +
+ + + + + + + + +
File winapi::File::open_r (const std::string & path)
+
+static
+
+

Open file for reading.

+ +

Definition at line 92 of file file.cpp.

+ +
+
+ +

◆ open_r() [2/2]

+ +
+
+ + + + + +
+ + + + + + + + +
File winapi::File::open_r (const CanonicalPathpath)
+
+static
+
+

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

+ +

Definition at line 96 of file file.cpp.

+ +
+
+ +

◆ open_read_attributes() [1/2]

+ +
+
+ + + + + +
+ + + + + + + + +
File winapi::File::open_read_attributes (const std::string & path)
+
+static
+
+

Open file for reading (inc. ability to read its attributes).

+ +

Definition at line 100 of file file.cpp.

+ +
+
+ +

◆ open_read_attributes() [2/2]

+ +
+
+ + + + + +
+ + + + + + + + +
File winapi::File::open_read_attributes (const CanonicalPathpath)
+
+static
+
+

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

+ +

Definition at line 104 of file file.cpp.

+ +
+
+ +

◆ open_w() [1/2]

+ +
+
+ + + + + +
+ + + + + + + + +
File winapi::File::open_w (const std::string & path)
+
+static
+
+

Open file for writing.

+ +

Definition at line 108 of file file.cpp.

+ +
+
+ +

◆ open_w() [2/2]

+ +
+
+ + + + + +
+ + + + + + + + +
File winapi::File::open_w (const CanonicalPathpath)
+
+static
+
+

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

+ +

Definition at line 112 of file file.cpp.

+ +
+
+ +

◆ remove() [1/2]

+ +
+
+ + + + + +
+ + + + + + + + +
void winapi::File::remove (const std::string & path)
+
+static
+
+

Delete a file.

+ +

Definition at line 116 of file file.cpp.

+ +
+
+ +

◆ remove() [2/2]

+ +
+
+ + + + + +
+ + + + + + + + +
void winapi::File::remove (const CanonicalPathpath)
+
+static
+
+

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

+ +

Definition at line 120 of file file.cpp.

+ +
+
+ +

◆ get_size()

+ +
+
+ + + + + + + +
std::size_t winapi::File::get_size () const
+
+

Get file size.

Returns
File size, bytes.
+ +

Definition at line 124 of file file.cpp.

+ +
+
+ +

◆ query_id()

+ +
+
+ + + + + + + +
File::ID winapi::File::query_id () const
+
+

Get file ID. File ID is a unique representation of a file, suitable for hashing.

+ +

Definition at line 139 of file file.cpp.

+ +
+
+
The documentation for this class was generated from the following files: +
+ + + + diff --git a/classwinapi_1_1File.png b/classwinapi_1_1File.png new file mode 100644 index 0000000..4c14f92 Binary files /dev/null and b/classwinapi_1_1File.png differ diff --git a/classwinapi_1_1Handle-members.html b/classwinapi_1_1Handle-members.html new file mode 100644 index 0000000..e3e2a16 --- /dev/null +++ b/classwinapi_1_1Handle-members.html @@ -0,0 +1,101 @@ + + + + + + + +winapi_common: Member List + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+
winapi::Handle Member List
+
+
+ +

This is the complete list of members for winapi::Handle, including all inherited members.

+ + + + + + + + + + + + + + + + + + + + + +
close()winapi::Handle
dont_inherit() const (defined in winapi::Handle)winapi::Handleinline
get() const (defined in winapi::Handle)winapi::Handleinline
Handle()=default (defined in winapi::Handle)winapi::Handle
Handle(HANDLE) (defined in winapi::Handle)winapi::Handleexplicit
inherit(bool yes=true) const (defined in winapi::Handle)winapi::Handle
is_std() constwinapi::Handle
is_valid() const (defined in winapi::Handle)winapi::Handle
is_valid(HANDLE) (defined in winapi::Handle)winapi::Handlestatic
max_chunk_size (defined in winapi::Handle)winapi::Handlestatic
operator HANDLE() const (defined in winapi::Handle)winapi::Handleinlineexplicit
ptr() const (defined in winapi::Handle)winapi::Handleinline
read() constwinapi::Handle
read_chunk(Buffer &read_chunk) constwinapi::Handle
std_err()winapi::Handlestatic
std_in()winapi::Handlestatic
std_out()winapi::Handlestatic
write(const void *data, std::size_t nb) constwinapi::Handle
write(const Buffer &buffer) constwinapi::Handle
write(const std::basic_string< CharT > &src) constwinapi::Handleinline
+ + + + diff --git a/classwinapi_1_1Handle.html b/classwinapi_1_1Handle.html new file mode 100644 index 0000000..1bea063 --- /dev/null +++ b/classwinapi_1_1Handle.html @@ -0,0 +1,434 @@ + + + + + + + +winapi_common: winapi::Handle Class Reference + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+ +
+
winapi::Handle Class Reference
+
+
+ +

HANDLE wrapper. + More...

+
+Inheritance diagram for winapi::Handle:
+
+
+ + +winapi::File + +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

+Public Member Functions

Handle (HANDLE)
 
+HANDLE get () const
 
+HANDLE ptr () const
 
operator HANDLE () const
 
+bool is_valid () const
 
void close ()
 
bool is_std () const
 
Buffer read () const
 
bool read_chunk (Buffer &read_chunk) const
 
void write (const void *data, std::size_t nb) const
 
void write (const Buffer &buffer) const
 
template<typename CharT >
void write (const std::basic_string< CharT > &src) const
 
+void inherit (bool yes=true) const
 
+void dont_inherit () const
 
+ + + + + + + + + +

+Static Public Member Functions

+static bool is_valid (HANDLE)
 
static Handle std_in ()
 
static Handle std_out ()
 
static Handle std_err ()
 
+ + + +

+Static Public Attributes

+static constexpr std::size_t max_chunk_size = 16 * 1024
 
+

Detailed Description

+

HANDLE wrapper.

+

This class wraps HANDLE, allowing for painless reads and writes from a random handle.

+ +

Definition at line 25 of file handle.hpp.

+

Member Function Documentation

+ +

◆ close()

+ +
+
+ + + + + + + +
void winapi::Handle::close ()
+
+

Close this handle.

+ +

Definition at line 47 of file handle.cpp.

+ +
+
+ +

◆ is_std()

+ +
+
+ + + + + + + +
bool winapi::Handle::is_std () const
+
+

Check if this is a standard console handle.

+ +

Definition at line 51 of file handle.cpp.

+ +
+
+ +

◆ std_in()

+ +
+
+ + + + + +
+ + + + + + + +
Handle winapi::Handle::std_in ()
+
+static
+
+

Check if this is the stdin handle.

+ +

Definition at line 55 of file handle.cpp.

+ +
+
+ +

◆ std_out()

+ +
+
+ + + + + +
+ + + + + + + +
Handle winapi::Handle::std_out ()
+
+static
+
+

Check if this is the stdout handle.

+ +

Definition at line 59 of file handle.cpp.

+ +
+
+ +

◆ std_err()

+ +
+
+ + + + + +
+ + + + + + + +
Handle winapi::Handle::std_err ()
+
+static
+
+

Check if this is the stderr handle.

+ +

Definition at line 63 of file handle.cpp.

+ +
+
+ +

◆ read()

+ +
+
+ + + + + + + +
Buffer winapi::Handle::read () const
+
+

Read everything from this handle.

+ +

Definition at line 93 of file handle.cpp.

+ +
+
+ +

◆ read_chunk()

+ +
+
+ + + + + + + + +
bool winapi::Handle::read_chunk (Bufferread_chunk) const
+
+

Read a chunk from this handle.

Parameters
+ + +
read_chunkReceives the data read.
+
+
+
Returns
true if there's more data, false otherwise.
+ +

Definition at line 67 of file handle.cpp.

+ +
+
+ +

◆ write() [1/3]

+ +
+
+ + + + + + + + + + + + + + + + + + +
void winapi::Handle::write (const void * data,
std::size_t nb 
) const
+
+

Write data to this handle.

Parameters
+ + + +
dataPointer to binary data.
nbData size.
+
+
+ +

Definition at line 109 of file handle.cpp.

+ +
+
+ +

◆ write() [2/3]

+ +
+
+ + + + + + + + +
void winapi::Handle::write (const Bufferbuffer) const
+
+

Write data to this handle.

Parameters
+ + +
bufferBinary data to write.
+
+
+ +

Definition at line 125 of file handle.cpp.

+ +
+
+ +

◆ write() [3/3]

+ +
+
+
+template<typename CharT >
+ + + + + +
+ + + + + + + + +
void winapi::Handle::write (const std::basic_string< CharT > & src) const
+
+inline
+
+

Write data to this handle.

Parameters
+ + +
srcBinary data to write.
+
+
+ +

Definition at line 78 of file handle.hpp.

+ +
+
+
The documentation for this class was generated from the following files: +
+ + + + diff --git a/classwinapi_1_1Handle.png b/classwinapi_1_1Handle.png new file mode 100644 index 0000000..bb6aaf2 Binary files /dev/null and b/classwinapi_1_1Handle.png differ diff --git a/classwinapi_1_1Pipe-members.html b/classwinapi_1_1Pipe-members.html new file mode 100644 index 0000000..3fc8d48 --- /dev/null +++ b/classwinapi_1_1Pipe-members.html @@ -0,0 +1,86 @@ + + + + + + + +winapi_common: Member List + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+
winapi::Pipe Member List
+
+
+ +

This is the complete list of members for winapi::Pipe, including all inherited members.

+ + + + + + +
Pipe()winapi::Pipe
read_end()winapi::Pipeinline
read_end() constwinapi::Pipeinline
write_end()winapi::Pipeinline
write_end() constwinapi::Pipeinline
+ + + + diff --git a/classwinapi_1_1Pipe.html b/classwinapi_1_1Pipe.html new file mode 100644 index 0000000..d966bdf --- /dev/null +++ b/classwinapi_1_1Pipe.html @@ -0,0 +1,240 @@ + + + + + + + +winapi_common: winapi::Pipe Class Reference + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+ +
+
winapi::Pipe Class Reference
+
+
+ +

Anonymous pipe wrapper. + More...

+ + + + + + + + + + + + +

+Public Member Functions

 Pipe ()
 
Handleread_end ()
 
const Handleread_end () const
 
Handlewrite_end ()
 
const Handlewrite_end () const
 
+

Detailed Description

+

Anonymous pipe wrapper.

+ +

Definition at line 15 of file pipe.hpp.

+

Constructor & Destructor Documentation

+ +

◆ Pipe()

+ +
+
+ + + + + + + +
winapi::Pipe::Pipe ()
+
+

Create a new pipe.

+ +

Definition at line 41 of file pipe.cpp.

+ +
+
+

Member Function Documentation

+ +

◆ read_end() [1/2]

+ +
+
+ + + + + +
+ + + + + + + +
Handle& winapi::Pipe::read_end ()
+
+inline
+
+

Get the read end of the pipe.

+ +

Definition at line 21 of file pipe.hpp.

+ +
+
+ +

◆ read_end() [2/2]

+ +
+
+ + + + + +
+ + + + + + + +
const Handle& winapi::Pipe::read_end () const
+
+inline
+
+

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

+ +

Definition at line 23 of file pipe.hpp.

+ +
+
+ +

◆ write_end() [1/2]

+ +
+
+ + + + + +
+ + + + + + + +
Handle& winapi::Pipe::write_end ()
+
+inline
+
+

Get the write end of the pipe.

+ +

Definition at line 25 of file pipe.hpp.

+ +
+
+ +

◆ write_end() [2/2]

+ +
+
+ + + + + +
+ + + + + + + +
const Handle& winapi::Pipe::write_end () const
+
+inline
+
+

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

+ +

Definition at line 27 of file pipe.hpp.

+ +
+
+
The documentation for this class was generated from the following files: +
+ + + + diff --git a/classwinapi_1_1Process-members.html b/classwinapi_1_1Process-members.html new file mode 100644 index 0000000..7956a37 --- /dev/null +++ b/classwinapi_1_1Process-members.html @@ -0,0 +1,102 @@ + + + + + + + +winapi_common: Member List + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+
winapi::Process Member List
+
+
+ +

This is the complete list of members for winapi::Process, including all inherited members.

+ + + + + + + + + + + + + + + + + + + + + + +
create(ProcessParameters)winapi::Processstatic
create(const CommandLine &)winapi::Processstatic
create(const CommandLine &, process::IO)winapi::Processstatic
current()winapi::Processstatic
default_permissions()winapi::Processstatic
get_exe_path() constwinapi::Process
get_exit_code() constwinapi::Process
get_handle() constwinapi::Processinline
get_id() constwinapi::Processinline
get_resource(uint32_t id)winapi::Processstatic
get_resource_string(uint32_t id)winapi::Processstatic
ID typedef (defined in winapi::Process)winapi::Process
is_running() constwinapi::Process
open(ID id, DWORD permissions=default_permissions())winapi::Processstatic
open_r(ID)winapi::Processstatic
read_permissions()winapi::Processstatic
shell(const ShellParameters &)winapi::Processstatic
shell(const CommandLine &)winapi::Processstatic
shut_down(int ec=0) constwinapi::Process
terminate(int ec=0) constwinapi::Process
wait() constwinapi::Process
+ + + + diff --git a/classwinapi_1_1Process.html b/classwinapi_1_1Process.html new file mode 100644 index 0000000..94d60f9 --- /dev/null +++ b/classwinapi_1_1Process.html @@ -0,0 +1,697 @@ + + + + + + + +winapi_common: winapi::Process Class Reference + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+ +
+
winapi::Process Class Reference
+
+
+ +

Create a new process or open an existing process. + More...

+ + + + +

+Public Types

+using ID = DWORD
 
+ + + + + + + + + + + + + + + + + +

+Public Member Functions

ID get_id () const
 
const Handleget_handle () const
 
bool is_running () const
 
void wait () const
 
void terminate (int ec=0) const
 
void shut_down (int ec=0) const
 
int get_exit_code () const
 
std::string get_exe_path () const
 
+ + + + + + + + + + + + + + + + + + + + + + + + + +

+Static Public Member Functions

static Process create (ProcessParameters)
 
static Process create (const CommandLine &)
 
static Process create (const CommandLine &, process::IO)
 
static Process shell (const ShellParameters &)
 
static Process shell (const CommandLine &)
 
static Process current ()
 
static Process open (ID id, DWORD permissions=default_permissions())
 
static Process open_r (ID)
 
static DWORD default_permissions ()
 
static DWORD read_permissions ()
 
static Resource get_resource (uint32_t id)
 
static std::string get_resource_string (uint32_t id)
 
+

Detailed Description

+

Create a new process or open an existing process.

+ +

Definition at line 54 of file process.hpp.

+

Member Function Documentation

+ +

◆ create() [1/3]

+ +
+
+ + + + + +
+ + + + + + + + +
Process winapi::Process::create (ProcessParameters params)
+
+static
+
+

Create a new process using ProcessParameters.

+ +

Definition at line 241 of file process.cpp.

+ +
+
+ +

◆ create() [2/3]

+ +
+
+ + + + + +
+ + + + + + + + +
Process winapi::Process::create (const CommandLinecmd_line)
+
+static
+
+

Create a new process using the given command line.

+ +

Definition at line 245 of file process.cpp.

+ +
+
+ +

◆ create() [3/3]

+ +
+
+ + + + + +
+ + + + + + + + + + + + + + + + + + +
Process winapi::Process::create (const CommandLinecmd_line,
process::IO io 
)
+
+static
+
+

Create a new process using the given command line and IO settings.

+ +

Definition at line 250 of file process.cpp.

+ +
+
+ +

◆ shell() [1/2]

+ +
+
+ + + + + +
+ + + + + + + + +
Process winapi::Process::shell (const ShellParametersparams)
+
+static
+
+

Create a new shell process using ShellParameters.

+ +

Definition at line 256 of file process.cpp.

+ +
+
+ +

◆ shell() [2/2]

+ +
+
+ + + + + +
+ + + + + + + + +
Process winapi::Process::shell (const CommandLinecmd_line)
+
+static
+
+

Create a new shell process using the given command line.

+ +

Definition at line 260 of file process.cpp.

+ +
+
+ +

◆ current()

+ +
+
+ + + + + +
+ + + + + + + +
Process winapi::Process::current ()
+
+static
+
+

Open the current process.

+ +

Definition at line 265 of file process.cpp.

+ +
+
+ +

◆ open()

+ +
+
+ + + + + +
+ + + + + + + + + + + + + + + + + + +
Process winapi::Process::open (ID id,
DWORD permissions = default_permissions() 
)
+
+static
+
+

Open an existing process.

Parameters
+ + + +
idProcess ID.
permissionsRequired permissions.
+
+
+ +

Definition at line 269 of file process.cpp.

+ +
+
+ +

◆ open_r()

+ +
+
+ + + + + +
+ + + + + + + + +
Process winapi::Process::open_r (ID id)
+
+static
+
+

Open an existing process with read permissions.

+ +

Definition at line 273 of file process.cpp.

+ +
+
+ +

◆ default_permissions()

+ +
+
+ + + + + +
+ + + + + + + +
DWORD winapi::Process::default_permissions ()
+
+static
+
+

Permissions that allow to query process's status.

+ +

Definition at line 277 of file process.cpp.

+ +
+
+ +

◆ read_permissions()

+ +
+
+ + + + + +
+ + + + + + + +
DWORD winapi::Process::read_permissions ()
+
+static
+
+

Permissions that allows to read process's memory.

+ +

Definition at line 281 of file process.cpp.

+ +
+
+ +

◆ get_id()

+ +
+
+ + + + + +
+ + + + + + + +
ID winapi::Process::get_id () const
+
+inline
+
+

Get this process's ID.

+ +

Definition at line 87 of file process.hpp.

+ +
+
+ +

◆ get_handle()

+ +
+
+ + + + + +
+ + + + + + + +
const Handle& winapi::Process::get_handle () const
+
+inline
+
+

Get this process's handle.

+ +

Definition at line 89 of file process.hpp.

+ +
+
+ +

◆ is_running()

+ +
+
+ + + + + + + +
bool winapi::Process::is_running () const
+
+

Check if this process is running (i.e. not terminated).

+ +

Definition at line 285 of file process.cpp.

+ +
+
+ +

◆ wait()

+ +
+
+ + + + + + + +
void winapi::Process::wait () const
+
+

Wait for the process to terminate.

+ +

Definition at line 301 of file process.cpp.

+ +
+
+ +

◆ terminate()

+ +
+
+ + + + + + + + +
void winapi::Process::terminate (int ec = 0) const
+
+

Make this process terminate with an exit code.

+ +

Definition at line 315 of file process.cpp.

+ +
+
+ +

◆ shut_down()

+ +
+
+ + + + + + + + +
void winapi::Process::shut_down (int ec = 0) const
+
+

Same as calling terminate() and wait().

+ +

Definition at line 321 of file process.cpp.

+ +
+
+ +

◆ get_exit_code()

+ +
+
+ + + + + + + +
int winapi::Process::get_exit_code () const
+
+

Get terminated process's exit code.

+ +

Definition at line 326 of file process.cpp.

+ +
+
+ +

◆ get_exe_path()

+ +
+
+ + + + + + + +
std::string winapi::Process::get_exe_path () const
+
+

Get this process's executable path.

+ +

Definition at line 342 of file process.cpp.

+ +
+
+ +

◆ get_resource()

+ +
+
+ + + + + +
+ + + + + + + + +
Resource winapi::Process::get_resource (uint32_t id)
+
+static
+
+

Get a binary resource from the process's executable.

+ +

Definition at line 370 of file process.cpp.

+ +
+
+ +

◆ get_resource_string()

+ +
+
+ + + + + +
+ + + + + + + + +
std::string winapi::Process::get_resource_string (uint32_t id)
+
+static
+
+

Get a string resource from the process's executable.

Returns
UTF-8 string.
+ +

Definition at line 358 of file process.cpp.

+ +
+
+
The documentation for this class was generated from the following files: +
+ + + + diff --git a/classwinapi_1_1SharedMemory-members.html b/classwinapi_1_1SharedMemory-members.html new file mode 100644 index 0000000..921d82f --- /dev/null +++ b/classwinapi_1_1SharedMemory-members.html @@ -0,0 +1,85 @@ + + + + + + + +winapi_common: Member List + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+
winapi::SharedMemory Member List
+
+
+ +

This is the complete list of members for winapi::SharedMemory, including all inherited members.

+ + + + + +
create(const std::string &name, std::size_t nb)winapi::SharedMemorystatic
get() constwinapi::SharedMemoryinline
open(const std::string &name)winapi::SharedMemorystatic
ptr() constwinapi::SharedMemoryinline
+ + + + diff --git a/classwinapi_1_1SharedMemory.html b/classwinapi_1_1SharedMemory.html new file mode 100644 index 0000000..e638368 --- /dev/null +++ b/classwinapi_1_1SharedMemory.html @@ -0,0 +1,245 @@ + + + + + + + +winapi_common: winapi::SharedMemory Class Reference + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+ +
+
winapi::SharedMemory Class Reference
+
+
+ +

Named shared memory region. + More...

+ + + + + + +

+Public Member Functions

void * get () const
 
void * ptr () const
 
+ + + + + +

+Static Public Member Functions

static SharedMemory create (const std::string &name, std::size_t nb)
 
static SharedMemory open (const std::string &name)
 
+

Detailed Description

+

Named shared memory region.

+ +

Definition at line 19 of file shmem.hpp.

+

Member Function Documentation

+ +

◆ create()

+ +
+
+ + + + + +
+ + + + + + + + + + + + + + + + + + +
SharedMemory winapi::SharedMemory::create (const std::string & name,
std::size_t nb 
)
+
+static
+
+

Creates a shared memory region.

Parameters
+ + + +
nameUTF-8 string.
nbNumber of bytes.
+
+
+ +

Definition at line 40 of file shmem.cpp.

+ +
+
+ +

◆ open()

+ +
+
+ + + + + +
+ + + + + + + + +
SharedMemory winapi::SharedMemory::open (const std::string & name)
+
+static
+
+

Opens a shared memory region.

Parameters
+ + +
nameUTF-8 string.
+
+
+ +

Definition at line 59 of file shmem.cpp.

+ +
+
+ +

◆ get()

+ +
+
+ + + + + +
+ + + + + + + +
void* winapi::SharedMemory::get () const
+
+inline
+
+

Get pointer to the data.

+ +

Definition at line 34 of file shmem.hpp.

+ +
+
+ +

◆ ptr()

+ +
+
+ + + + + +
+ + + + + + + +
void* winapi::SharedMemory::ptr () const
+
+inline
+
+

This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

+ +

Definition at line 36 of file shmem.hpp.

+ +
+
+
The documentation for this class was generated from the following files: +
+ + + + diff --git a/classwinapi_1_1SharedObject-members.html b/classwinapi_1_1SharedObject-members.html new file mode 100644 index 0000000..280061b --- /dev/null +++ b/classwinapi_1_1SharedObject-members.html @@ -0,0 +1,92 @@ + + + + + + + +winapi_common: Member List + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+
winapi::SharedObject< T > Member List
+
+
+ +

This is the complete list of members for winapi::SharedObject< T >, including all inherited members.

+ + + + + + + + + + + + +
AlignedType typedef (defined in winapi::SharedObject< T >)winapi::SharedObject< T >
create(const std::string &name, Args &&... args)winapi::SharedObject< T >inlinestatic
get() constwinapi::SharedObject< T >inline
open(const std::string &name)winapi::SharedObject< T >inlinestatic
operator*() const (defined in winapi::SharedObject< T >)winapi::SharedObject< T >inline
operator->() const (defined in winapi::SharedObject< T >)winapi::SharedObject< T >inline
operator=(const SharedObject &other) noexcept=default (defined in winapi::SharedObject< T >)winapi::SharedObject< T >
ptr() constwinapi::SharedObject< T >inline
SharedObject(SharedObject &&other) noexcept=default (defined in winapi::SharedObject< T >)winapi::SharedObject< T >
SharedObject(const SharedObject &)=delete (defined in winapi::SharedObject< T >)winapi::SharedObject< T >
~SharedObject() (defined in winapi::SharedObject< T >)winapi::SharedObject< T >inline
+ + + + diff --git a/classwinapi_1_1SharedObject.html b/classwinapi_1_1SharedObject.html new file mode 100644 index 0000000..786f40d --- /dev/null +++ b/classwinapi_1_1SharedObject.html @@ -0,0 +1,279 @@ + + + + + + + +winapi_common: winapi::SharedObject< T > Class Template Reference + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+ +
+
winapi::SharedObject< T > Class Template Reference
+
+
+ +

Easy way to represent a C++ object as a shared memory region. + More...

+ + + + +

+Public Types

+typedef std::aligned_storage< sizeof(T), __alignof(T)>::type AlignedType
 
+ + + + + + + + + + + + + + + +

+Public Member Functions

SharedObject (SharedObject &&other) noexcept=default
 
+SharedObjectoperator= (const SharedObject &other) noexcept=default
 
SharedObject (const SharedObject &)=delete
 
T * ptr () const
 
T & get () const
 
+T * operator-> () const
 
+T & operator* () const
 
+ + + + + + +

+Static Public Member Functions

template<typename... Args>
static SharedObject create (const std::string &name, Args &&... args)
 
static SharedObject open (const std::string &name)
 
+

Detailed Description

+

template<typename T>
+class winapi::SharedObject< T >

+ +

Easy way to represent a C++ object as a shared memory region.

+ +

Definition at line 53 of file shmem.hpp.

+

Member Function Documentation

+ +

◆ create()

+ +
+
+
+template<typename T >
+
+template<typename... Args>
+ + + + + +
+ + + + + + + + + + + + + + + + + + +
static SharedObject winapi::SharedObject< T >::create (const std::string & name,
Args &&... args 
)
+
+inlinestatic
+
+

Create the object & construct a shared memory region to store it.

Parameters
+ + + +
nameUTF-8 string, name of the shared memory region.
argsArguments to construct the object.
+
+
+ +

Definition at line 63 of file shmem.hpp.

+ +
+
+ +

◆ open()

+ +
+
+
+template<typename T >
+ + + + + +
+ + + + + + + + +
static SharedObject winapi::SharedObject< T >::open (const std::string & name)
+
+inlinestatic
+
+

Open a shared memory region that stores the object.

Parameters
+ + +
nameUTF-8 string, name of the shared memory region.
+
+
+ +

Definition at line 74 of file shmem.hpp.

+ +
+
+ +

◆ ptr()

+ +
+
+
+template<typename T >
+ + + + + +
+ + + + + + + +
T* winapi::SharedObject< T >::ptr () const
+
+inline
+
+

Get pointer to the object.

+ +

Definition at line 90 of file shmem.hpp.

+ +
+
+ +

◆ get()

+ +
+
+
+template<typename T >
+ + + + + +
+ + + + + + + +
T& winapi::SharedObject< T >::get () const
+
+inline
+
+

Get reference to the object.

+ +

Definition at line 92 of file shmem.hpp.

+ +
+
+
The documentation for this class was generated from the following file: +
+ + + + diff --git a/classwinapi_1_1Sid-members.html b/classwinapi_1_1Sid-members.html new file mode 100644 index 0000000..eab5337 --- /dev/null +++ b/classwinapi_1_1Sid-members.html @@ -0,0 +1,89 @@ + + + + + + + +winapi_common: Member List + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+
winapi::Sid Member List
+
+
+ +

This is the complete list of members for winapi::Sid, including all inherited members.

+ + + + + + + + + +
builtin_administrators() (defined in winapi::Sid)winapi::Sidstatic
Impl typedef (defined in winapi::Sid)winapi::Sid
MAX_SID_SIZE (defined in winapi::Sid)winapi::Sidstatic
operator const SID &() const (defined in winapi::Sid)winapi::Sidinlineexplicit
operator SID &() (defined in winapi::Sid)winapi::Sidinlineexplicit
Sid(const Buffer &buffer) (defined in winapi::Sid)winapi::Sidinlineexplicit
to_string() const (defined in winapi::Sid)winapi::Sid
well_known(WELL_KNOWN_SID_TYPE type) (defined in winapi::Sid)winapi::Sidstatic
+ + + + diff --git a/classwinapi_1_1Sid.html b/classwinapi_1_1Sid.html new file mode 100644 index 0000000..cdfba00 --- /dev/null +++ b/classwinapi_1_1Sid.html @@ -0,0 +1,128 @@ + + + + + + + +winapi_common: winapi::Sid Class Reference + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+ +
+
winapi::Sid Class Reference
+
+
+ + + + +

+Public Types

+typedef SID Impl
 
+ + + + + + + + + +

+Public Member Functions

Sid (const Buffer &buffer)
 
operator SID & ()
 
operator const SID & () const
 
+std::string to_string () const
 
+ + + + + +

+Static Public Member Functions

+static Sid well_known (WELL_KNOWN_SID_TYPE type)
 
+static Sid builtin_administrators ()
 
+ + + +

+Static Public Attributes

+static constexpr std::size_t MAX_SID_SIZE = SECURITY_MAX_SID_SIZE
 
+

Detailed Description

+
+

Definition at line 17 of file sid.hpp.

+

The documentation for this class was generated from the following files: +
+ + + + diff --git a/classwinapi_1_1error_1_1CategoryWindows-members.html b/classwinapi_1_1error_1_1CategoryWindows-members.html new file mode 100644 index 0000000..cbc7e8b --- /dev/null +++ b/classwinapi_1_1error_1_1CategoryWindows-members.html @@ -0,0 +1,84 @@ + + + + + + + +winapi_common: Member List + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+
winapi::error::CategoryWindows Member List
+
+
+ +

This is the complete list of members for winapi::error::CategoryWindows, including all inherited members.

+ + + + +
CategoryWindows()=default (defined in winapi::error::CategoryWindows)winapi::error::CategoryWindows
message(int32_t) const (defined in winapi::error::CategoryWindows)winapi::error::CategoryWindows
name() const noexcept (defined in winapi::error::CategoryWindows)winapi::error::CategoryWindowsinline
+ + + + diff --git a/classwinapi_1_1error_1_1CategoryWindows.html b/classwinapi_1_1error_1_1CategoryWindows.html new file mode 100644 index 0000000..6df65d2 --- /dev/null +++ b/classwinapi_1_1error_1_1CategoryWindows.html @@ -0,0 +1,104 @@ + + + + + + + +winapi_common: winapi::error::CategoryWindows Class Reference + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+ +
+
winapi::error::CategoryWindows Class Reference
+
+
+
+Inheritance diagram for winapi::error::CategoryWindows:
+
+
+ +
+ + + + + + +

+Public Member Functions

+const char * name () const noexcept
 
+std::string message (int32_t) const
 
+

Detailed Description

+
+

Definition at line 24 of file error.hpp.

+

The documentation for this class was generated from the following files: +
+ + + + diff --git a/classwinapi_1_1error_1_1CategoryWindows.png b/classwinapi_1_1error_1_1CategoryWindows.png new file mode 100644 index 0000000..d69f8f5 Binary files /dev/null and b/classwinapi_1_1error_1_1CategoryWindows.png differ diff --git a/closed.png b/closed.png new file mode 100644 index 0000000..98cc2c9 Binary files /dev/null and b/closed.png differ diff --git a/cmd__line_8cpp_source.html b/cmd__line_8cpp_source.html new file mode 100644 index 0000000..6192ded --- /dev/null +++ b/cmd__line_8cpp_source.html @@ -0,0 +1,249 @@ + + + + + + + +winapi_common: src/cmd_line.cpp Source File + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+
cmd_line.cpp
+
+
+
1 // Copyright (c) 2020 Egor Tensin <Egor.Tensin@gmail.com>
+
2 // This file is part of the "winapi-common" project.
+
3 // For details, see https://github.com/egor-tensin/winapi-common.
+
4 // Distributed under the MIT License.
+
5 
+
6 #include <winapi/cmd_line.hpp>
+
7 #include <winapi/error.hpp>
+
8 #include <winapi/utf8.hpp>
+
9 #include <winapi/utils.hpp>
+
10 
+
11 #include <boost/algorithm/string.hpp>
+
12 
+
13 // clang-format off
+
14 #include <windows.h>
+
15 #include <shellapi.h>
+
16 // clang-format on
+
17 
+
18 #include <cstddef>
+
19 #include <memory>
+
20 #include <sstream>
+
21 #include <stdexcept>
+
22 #include <string>
+
23 #include <utility>
+
24 #include <vector>
+
25 
+
26 namespace winapi {
+
27 namespace {
+
28 
+
29 std::vector<std::string> narrow_all(int argc, wchar_t** argv) {
+
30  std::vector<std::string> utf;
+
31  utf.reserve(argc);
+
32  for (int i = 0; i < argc; ++i)
+
33  utf.emplace_back(narrow(argv[i]));
+
34  return utf;
+
35 }
+
36 
+
37 CommandLine do_parse(std::wstring src) {
+
38  boost::trim(src);
+
39  if (src.empty()) {
+
40  throw std::runtime_error{"Command line cannot be an empty string"};
+
41  }
+
42 
+
43  int argc = 0;
+
44  std::unique_ptr<wchar_t*, LocalDelete> argv{::CommandLineToArgvW(src.c_str(), &argc)};
+
45 
+
46  if (argv.get() == NULL) {
+
47  throw error::windows(GetLastError(), "CommandLineToArgvW");
+
48  }
+
49  if (argc == 0) {
+
50  throw std::runtime_error{"Command line must contain at least one token"};
+
51  }
+
52 
+
53  return CommandLine{narrow_all(argc, argv.get())};
+
54 }
+
55 
+
56 std::string split_argv0(std::vector<std::string>& argv) {
+
57  if (argv.empty()) {
+
58  throw std::range_error{"argv must contain at least one element"};
+
59  }
+
60  auto argv0 = argv[0];
+
61  argv.erase(argv.begin());
+
62  return argv0;
+
63 }
+
64 
+
65 std::vector<std::string> escape_all(const std::vector<std::string>& xs) {
+
66  std::vector<std::string> escaped;
+
67  escaped.reserve(xs.size());
+
68  for (const auto& x : xs)
+
69  escaped.emplace_back(CommandLine::escape(x));
+
70  return escaped;
+
71 }
+
72 
+
73 } // namespace
+
74 
+ +
76  return do_parse(::GetCommandLineW());
+
77 }
+
78 
+
79 CommandLine CommandLine::parse(const std::string& src) {
+
80  return do_parse(widen(src));
+
81 }
+
82 
+
83 CommandLine CommandLine::from_main(int argc, wchar_t* argv[]) {
+
84  if (argc < 1)
+
85  throw std::range_error{"argc must be a positive number"};
+
86  return CommandLine{narrow_all(argc, argv)};
+
87 }
+
88 
+
89 CommandLine::CommandLine(std::vector<std::string> argv) : m_args{std::move(argv)} {
+
90  m_argv0 = split_argv0(m_args);
+
91 }
+
92 
+
93 std::string CommandLine::escape(const std::string& arg) {
+
94  std::ostringstream safe;
+
95  safe << '"';
+
96 
+
97  for (auto it = arg.cbegin(); it != arg.cend(); ++it) {
+
98  std::size_t numof_backslashes = 0;
+
99 
+
100  for (; it != arg.cend() && *it == '\\'; ++it)
+
101  ++numof_backslashes;
+
102 
+
103  if (it == arg.cend()) {
+
104  safe << std::string(2 * numof_backslashes, '\\');
+
105  break;
+
106  }
+
107 
+
108  switch (*it) {
+
109  case L'"':
+
110  safe << std::string(2 * numof_backslashes + 1, '\\');
+
111  break;
+
112 
+
113  default:
+
114  safe << std::string(numof_backslashes, '\\');
+
115  break;
+
116  }
+
117 
+
118  safe << *it;
+
119  }
+
120 
+
121  safe << '"';
+
122  return safe.str();
+
123 }
+
124 
+
125 std::string CommandLine::escape_cmd(const std::string& arg) {
+
126  static constexpr auto escape_symbol = '^';
+
127  static const std::string dangerous_symbols{"^!\"%&()<>|"};
+
128 
+
129  auto safe = escape(arg);
+
130  for (const auto danger : dangerous_symbols) {
+
131  std::ostringstream replacement;
+
132  replacement << escape_symbol << danger;
+
133  boost::replace_all(safe, std::string{danger}, replacement.str());
+
134  }
+
135  return safe;
+
136 }
+
137 
+
138 std::string CommandLine::to_string() const {
+
139  return boost::algorithm::join(escape_argv(), std::string{token_sep()});
+
140 }
+
141 
+
142 std::string CommandLine::args_to_string() const {
+
143  return boost::algorithm::join(escape_args(), std::string{token_sep()});
+
144 }
+
145 
+
146 std::vector<std::string> CommandLine::get_argv() const {
+
147  auto argv = get_args();
+
148  argv.emplace(argv.begin(), get_argv0());
+
149  return argv;
+
150 }
+
151 
+
152 std::vector<std::string> CommandLine::escape_args() const {
+
153  return escape_all(get_args());
+
154 }
+
155 
+
156 std::vector<std::string> CommandLine::escape_argv() const {
+
157  return escape_all(get_argv());
+
158 }
+
159 
+
160 } // namespace winapi
+
Command line for the current process or for launching new processes.
Definition: cmd_line.hpp:21
+
static CommandLine from_main(int argc, wchar_t *argv[])
Definition: cmd_line.cpp:83
+
std::string get_argv0() const
Definition: cmd_line.hpp:87
+
static CommandLine query()
Definition: cmd_line.cpp:75
+
static CommandLine parse(const std::string &src)
Definition: cmd_line.cpp:79
+
std::vector< std::string > get_argv() const
Definition: cmd_line.cpp:146
+
std::string to_string() const
Definition: cmd_line.cpp:138
+ +
const std::vector< std::string > & get_args() const
Definition: cmd_line.hpp:96
+
std::string args_to_string() const
Definition: cmd_line.cpp:142
+
Make std::system_error work with GetLastError().
+
+ + + + diff --git a/cmd__line_8hpp_source.html b/cmd__line_8hpp_source.html new file mode 100644 index 0000000..0daf3a8 --- /dev/null +++ b/cmd__line_8hpp_source.html @@ -0,0 +1,152 @@ + + + + + + + +winapi_common: include/winapi/cmd_line.hpp Source File + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+
cmd_line.hpp
+
+
+
1 // Copyright (c) 2020 Egor Tensin <Egor.Tensin@gmail.com>
+
2 // This file is part of the "winapi-common" project.
+
3 // For details, see https://github.com/egor-tensin/winapi-common.
+
4 // Distributed under the MIT License.
+
5 
+
6 #pragma once
+
7 
+
8 #include <string>
+
9 #include <utility>
+
10 #include <vector>
+
11 
+
12 namespace winapi {
+
13 
+
21 class CommandLine {
+
22 public:
+
24  static CommandLine query();
+
25 
+
30  static CommandLine parse(const std::string& src);
+
31 
+
37  static CommandLine from_main(int argc, wchar_t* argv[]);
+
38 
+
43  CommandLine() = default;
+
44 
+
50  explicit CommandLine(const std::string& argv0, const std::vector<std::string>& args = {})
+
51  : m_argv0{argv0}, m_args{args} {}
+
52 
+
58  explicit CommandLine(std::string&& argv0, std::vector<std::string>&& args = {})
+
59  : m_argv0{std::move(argv0)}, m_args{std::move(args)} {}
+
60 
+
65  explicit CommandLine(std::vector<std::string> argv);
+
66 
+
67  static std::string escape(const std::string&);
+
68 
+
69  static std::string escape_cmd(const std::string&);
+
70 
+
75  std::string to_string() const;
+
76 
+
81  std::string args_to_string() const;
+
82 
+
87  std::string get_argv0() const { return m_argv0; }
+
88 
+
90  bool has_args() const { return !get_args().empty(); }
+
91 
+
96  const std::vector<std::string>& get_args() const { return m_args; }
+
97 
+
102  std::vector<std::string> get_argv() const;
+
103 
+
104 private:
+
105  static constexpr char token_sep() { return ' '; }
+
106 
+
107  std::string escape_argv0() const { return escape(get_argv0()); }
+
108 
+
109  std::vector<std::string> escape_args() const;
+
110 
+
111  std::vector<std::string> escape_argv() const;
+
112 
+
113  std::string m_argv0;
+
114  std::vector<std::string> m_args;
+
115 };
+
116 
+
117 } // namespace winapi
+
Command line for the current process or for launching new processes.
Definition: cmd_line.hpp:21
+
static CommandLine from_main(int argc, wchar_t *argv[])
Definition: cmd_line.cpp:83
+
std::string get_argv0() const
Definition: cmd_line.hpp:87
+
CommandLine(const std::string &argv0, const std::vector< std::string > &args={})
Definition: cmd_line.hpp:50
+
static CommandLine query()
Definition: cmd_line.cpp:75
+
static CommandLine parse(const std::string &src)
Definition: cmd_line.cpp:79
+
CommandLine(std::string &&argv0, std::vector< std::string > &&args={})
Definition: cmd_line.hpp:58
+
std::vector< std::string > get_argv() const
Definition: cmd_line.cpp:146
+
std::string to_string() const
Definition: cmd_line.cpp:138
+ +
bool has_args() const
Definition: cmd_line.hpp:90
+
const std::vector< std::string > & get_args() const
Definition: cmd_line.hpp:96
+
std::string args_to_string() const
Definition: cmd_line.cpp:142
+
+ + + + diff --git a/dir_68267d1309a1af8e8297ef4c3efbcdba.html b/dir_68267d1309a1af8e8297ef4c3efbcdba.html new file mode 100644 index 0000000..36cca7c --- /dev/null +++ b/dir_68267d1309a1af8e8297ef4c3efbcdba.html @@ -0,0 +1,78 @@ + + + + + + + +winapi_common: src Directory Reference + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+
src Directory Reference
+
+
+
+ + + + diff --git a/dir_d44c64559bbebec7f509842c48db8b23.html b/dir_d44c64559bbebec7f509842c48db8b23.html new file mode 100644 index 0000000..90554ff --- /dev/null +++ b/dir_d44c64559bbebec7f509842c48db8b23.html @@ -0,0 +1,82 @@ + + + + + + + +winapi_common: include Directory Reference + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+
include Directory Reference
+
+
+ + +

+Directories

+
+ + + + diff --git a/dir_f1714771db42b7b5a0cd2ebe6e9736ed.html b/dir_f1714771db42b7b5a0cd2ebe6e9736ed.html new file mode 100644 index 0000000..1734f7a --- /dev/null +++ b/dir_f1714771db42b7b5a0cd2ebe6e9736ed.html @@ -0,0 +1,85 @@ + + + + + + + +winapi_common: include/winapi Directory Reference + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+
winapi Directory Reference
+
+
+ + + + + +

+Files

file  error.hpp [code]
 Make std::system_error work with GetLastError().
 
+
+ + + + diff --git a/doc.png b/doc.png new file mode 100644 index 0000000..17edabf Binary files /dev/null and b/doc.png differ diff --git a/doxygen.css b/doxygen.css new file mode 100644 index 0000000..ffbff02 --- /dev/null +++ b/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.svg b/doxygen.svg new file mode 100644 index 0000000..d42dad5 --- /dev/null +++ b/doxygen.svg @@ -0,0 +1,26 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/dynsections.js b/dynsections.js new file mode 100644 index 0000000..88f2c27 --- /dev/null +++ b/dynsections.js @@ -0,0 +1,128 @@ +/* + @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 + + + + + + +winapi_common: src/error.cpp Source File + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+
error.cpp
+
+
+
1 // Copyright (c) 2020 Egor Tensin <Egor.Tensin@gmail.com>
+
2 // This file is part of the "winapi-common" project.
+
3 // For details, see https://github.com/egor-tensin/winapi-common.
+
4 // Distributed under the MIT License.
+
5 
+
6 #include <winapi/error.hpp>
+
7 #include <winapi/utf8.hpp>
+
8 
+
9 #include <windows.h>
+
10 
+
11 #include <cstdint>
+
12 #include <sstream>
+
13 #include <string>
+
14 #include <system_error>
+
15 
+
16 namespace winapi {
+
17 namespace error {
+
18 namespace {
+
19 
+
20 std::wstring trim_trailing_newline(const std::wstring& s) {
+
21  const auto last_pos = s.find_last_not_of(L"\r\n");
+
22  if (std::wstring::npos == last_pos)
+
23  return {};
+
24  return s.substr(0, last_pos + 1);
+
25 }
+
26 
+
27 std::string build_what(DWORD code, const char* function) {
+
28  std::ostringstream what;
+
29  what << "Function " << function << " failed with error code " << code;
+
30  return what.str();
+
31 }
+
32 
+
33 std::string format_message(int32_t code) {
+
34  wchar_t* buf;
+
35 
+
36  const auto len = ::FormatMessageW(
+
37  FORMAT_MESSAGE_ALLOCATE_BUFFER | FORMAT_MESSAGE_FROM_SYSTEM | FORMAT_MESSAGE_IGNORE_INSERTS,
+
38  NULL,
+
39  code,
+
40  MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT),
+
41  reinterpret_cast<wchar_t*>(&buf),
+
42  0,
+
43  NULL);
+
44 
+
45  if (0 == len) {
+
46  ::LocalFree(buf);
+
47  return "Couldn't format the error message";
+
48  }
+
49 
+
50  std::wstring msg{buf, len};
+
51  ::LocalFree(buf);
+
52  return narrow(trim_trailing_newline(msg));
+
53 }
+
54 
+
55 } // namespace
+
56 
+
57 std::string CategoryWindows::message(int32_t code) const {
+
58  return format_message(code);
+
59 }
+
60 
+
61 std::system_error windows(DWORD code, const char* function) {
+
62  static_assert(sizeof(DWORD) == sizeof(int32_t), "Aren't DWORDs the same size as ints?");
+
63  return std::system_error{
+
64  static_cast<int32_t>(code), category_windows(), build_what(code, function)};
+
65 }
+
66 
+
67 } // namespace error
+
68 } // namespace winapi
+
Make std::system_error work with GetLastError().
+
std::system_error windows(DWORD code, const char *function)
Definition: error.cpp:61
+
+ + + + diff --git a/error_8hpp.html b/error_8hpp.html new file mode 100644 index 0000000..bd24502 --- /dev/null +++ b/error_8hpp.html @@ -0,0 +1,146 @@ + + + + + + + +winapi_common: include/winapi/error.hpp File Reference + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+ +
+
error.hpp File Reference
+
+
+ +

Make std::system_error work with GetLastError(). +More...

+ +

Go to the source code of this file.

+ + + + +

+Classes

class  winapi::error::CategoryWindows
 
+ + + + + + + + +

+Functions

+const CategoryWindows & winapi::error::category_windows ()
 
std::system_error winapi::error::windows (DWORD code, const char *function)
 
+template<typename Ret >
std::runtime_error winapi::error::custom (Ret ret, const char *function)
 
+

Detailed Description

+

Make std::system_error work with GetLastError().

+ +

Definition in file error.hpp.

+

Function Documentation

+ +

◆ windows()

+ +
+
+ + + + + + + + + + + + + + + + + + +
std::system_error winapi::error::windows (DWORD code,
const char * function 
)
+
+

Build a std::system_error from the value of GetLastError().

Parameters
+ + + +
codeValue of GetLastError().
functionName of the function that failed, like "CreateFile".
+
+
+ +

Definition at line 61 of file error.cpp.

+ +
+
+
+ + + + diff --git a/error_8hpp_source.html b/error_8hpp_source.html new file mode 100644 index 0000000..3eff8c1 --- /dev/null +++ b/error_8hpp_source.html @@ -0,0 +1,122 @@ + + + + + + + +winapi_common: include/winapi/error.hpp Source File + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+
error.hpp
+
+
+Go to the documentation of this file.
1 // Copyright (c) 2020 Egor Tensin <Egor.Tensin@gmail.com>
+
2 // This file is part of the "winapi-common" project.
+
3 // For details, see https://github.com/egor-tensin/winapi-common.
+
4 // Distributed under the MIT License.
+
5 
+
11 #pragma once
+
12 
+
13 #include <windows.h>
+
14 
+
15 #include <cstdint>
+
16 #include <sstream>
+
17 #include <stdexcept>
+
18 #include <string>
+
19 #include <system_error>
+
20 
+
21 namespace winapi {
+
22 namespace error {
+
23 
+
24 class CategoryWindows : public std::error_category {
+
25 public:
+
26  CategoryWindows() = default;
+
27 
+
28  const char* name() const noexcept { return "Windows"; }
+
29 
+
30  std::string message(int32_t) const;
+
31 };
+
32 
+
33 inline const CategoryWindows& category_windows() {
+
34  static const CategoryWindows instance;
+
35  return instance;
+
36 }
+
37 
+
43 std::system_error windows(DWORD code, const char* function);
+
44 
+
45 template <typename Ret>
+
46 std::runtime_error custom(Ret ret, const char* function) {
+
47  std::ostringstream oss;
+
48  oss << "Function " << function << " failed with error code " << ret;
+
49  return std::runtime_error{oss.str()};
+
50 }
+
51 
+
52 } // namespace error
+
53 } // namespace winapi
+ +
+ + + + diff --git a/file_8cpp_source.html b/file_8cpp_source.html new file mode 100644 index 0000000..781d593 --- /dev/null +++ b/file_8cpp_source.html @@ -0,0 +1,236 @@ + + + + + + + +winapi_common: src/file.cpp Source File + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+
file.cpp
+
+
+
1 // Copyright (c) 2020 Egor Tensin <Egor.Tensin@gmail.com>
+
2 // This file is part of the "winapi-common" project.
+
3 // For details, see https://github.com/egor-tensin/winapi-common.
+
4 // Distributed under the MIT License.
+
5 
+
6 #include <winapi/error.hpp>
+
7 #include <winapi/file.hpp>
+
8 #include <winapi/handle.hpp>
+
9 #include <winapi/path.hpp>
+
10 #include <winapi/utf8.hpp>
+
11 
+
12 #include <cstddef>
+
13 #include <cstdint>
+
14 #include <cstring>
+
15 #include <stdexcept>
+
16 #include <string>
+
17 
+
18 namespace winapi {
+
19 namespace {
+
20 
+
21 std::wstring to_system_path(const std::string& path) {
+
22  return widen(path);
+
23 }
+
24 
+
25 std::wstring to_system_path(const CanonicalPath& path) {
+
26  return widen(R"(\\?\)" + path.get());
+
27 }
+
28 
+
29 struct CreateFileParams {
+
30  static CreateFileParams read() {
+
31  CreateFileParams params;
+
32  params.dwDesiredAccess = GENERIC_READ;
+
33  params.dwShareMode = FILE_SHARE_READ;
+
34  params.dwCreationDisposition = OPEN_EXISTING;
+
35  return params;
+
36  }
+
37 
+
38  static CreateFileParams read_attributes() {
+
39  auto params = read();
+
40  params.dwDesiredAccess = FILE_READ_ATTRIBUTES;
+
41  params.dwShareMode = FILE_SHARE_READ | FILE_SHARE_WRITE;
+
42  return params;
+
43  }
+
44 
+
45  static CreateFileParams write() {
+
46  CreateFileParams params;
+
47  params.dwDesiredAccess = GENERIC_WRITE;
+
48  params.dwShareMode = FILE_SHARE_READ;
+
49  params.dwCreationDisposition = OPEN_ALWAYS;
+
50  return params;
+
51  }
+
52 
+
53  DWORD dwDesiredAccess = 0;
+
54  DWORD dwShareMode = 0;
+
55  DWORD dwCreationDisposition = 0;
+
56 
+
57 private:
+
58  CreateFileParams() = default;
+
59 };
+
60 
+
61 File open_file(const std::wstring& path, const CreateFileParams& params) {
+
62  SECURITY_ATTRIBUTES attributes;
+
63  std::memset(&attributes, 0, sizeof(attributes));
+
64  attributes.nLength = sizeof(attributes);
+
65  attributes.bInheritHandle = TRUE;
+
66 
+
67  const auto handle = ::CreateFileW(path.c_str(),
+
68  params.dwDesiredAccess,
+
69  params.dwShareMode,
+
70  &attributes,
+
71  params.dwCreationDisposition,
+
72  FILE_ATTRIBUTE_NORMAL,
+
73  NULL);
+
74 
+
75  if (handle == INVALID_HANDLE_VALUE) {
+
76  throw error::windows(GetLastError(), "CreateFileW");
+
77  }
+
78 
+
79  return File{Handle{handle}};
+
80 }
+
81 
+
82 void remove_file(const std::wstring& path) {
+
83  const auto ret = ::DeleteFileW(path.c_str());
+
84 
+
85  if (!ret) {
+
86  throw error::windows(GetLastError(), "DeleteFileW");
+
87  }
+
88 }
+
89 
+
90 } // namespace
+
91 
+
92 File File::open_r(const std::string& path) {
+
93  return open_file(to_system_path(path), CreateFileParams::read());
+
94 }
+
95 
+ +
97  return open_file(to_system_path(path), CreateFileParams::read());
+
98 }
+
99 
+
100 File File::open_read_attributes(const std::string& path) {
+
101  return open_file(to_system_path(path), CreateFileParams::read_attributes());
+
102 }
+
103 
+ +
105  return open_file(to_system_path(path), CreateFileParams::read_attributes());
+
106 }
+
107 
+
108 File File::open_w(const std::string& path) {
+
109  return open_file(to_system_path(path), CreateFileParams::write());
+
110 }
+
111 
+ +
113  return open_file(to_system_path(path), CreateFileParams::write());
+
114 }
+
115 
+
116 void File::remove(const std::string& path) {
+
117  remove_file(to_system_path(path));
+
118 }
+
119 
+
120 void File::remove(const CanonicalPath& path) {
+
121  remove_file(to_system_path(path));
+
122 }
+
123 
+
124 std::size_t File::get_size() const {
+
125  LARGE_INTEGER size;
+
126 
+
127  if (!GetFileSizeEx(get(), &size))
+
128  throw error::windows(GetLastError(), "GetFileSizeEx");
+
129 
+
130  if (size.QuadPart < 0 || size.QuadPart > SIZE_MAX)
+
131  throw std::runtime_error{"invalid file size"};
+
132  return static_cast<std::size_t>(size.QuadPart);
+
133 }
+
134 
+
135 bool operator==(const FILE_ID_128& a, const FILE_ID_128& b) {
+
136  return 0 == std::memcmp(a.Identifier, b.Identifier, sizeof(a.Identifier));
+
137 }
+
138 
+ +
140  FILE_ID_INFO id;
+
141 
+
142  if (!GetFileInformationByHandleEx(get(), FileIdInfo, &id, sizeof(id)))
+
143  throw error::windows(GetLastError(), "GetFileInformationByHandleEx");
+
144 
+
145  return {id};
+
146 }
+
147 
+
148 } // namespace winapi
+
Absolute, canonical path.
Definition: path.hpp:13
+
File I/O.
Definition: file.hpp:29
+
static File open_w(const std::string &)
Definition: file.cpp:108
+
static void remove(const std::string &)
Definition: file.cpp:116
+
static File open_read_attributes(const std::string &)
Definition: file.cpp:100
+
static File open_r(const std::string &)
Definition: file.cpp:92
+
std::size_t get_size() const
Definition: file.cpp:124
+
ID query_id() const
Definition: file.cpp:139
+
Make std::system_error work with GetLastError().
+ +
+ + + + diff --git a/file_8hpp_source.html b/file_8hpp_source.html new file mode 100644 index 0000000..c710d95 --- /dev/null +++ b/file_8hpp_source.html @@ -0,0 +1,155 @@ + + + + + + + +winapi_common: include/winapi/file.hpp Source File + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+
file.hpp
+
+
+
1 // Copyright (c) 2020 Egor Tensin <Egor.Tensin@gmail.com>
+
2 // This file is part of the "winapi-common" project.
+
3 // For details, see https://github.com/egor-tensin/winapi-common.
+
4 // Distributed under the MIT License.
+
5 
+
6 #pragma once
+
7 
+
8 #include "handle.hpp"
+
9 #include "path.hpp"
+
10 
+
11 #include <boost/functional/hash.hpp>
+
12 
+
13 #include <windows.h>
+
14 
+
15 #include <cstddef>
+
16 #include <functional>
+
17 #include <string>
+
18 #include <utility>
+
19 
+
20 namespace winapi {
+
21 
+
22 bool operator==(const FILE_ID_128& a, const FILE_ID_128& b);
+
23 
+
29 class File : public Handle {
+
30 public:
+
31  struct ID {
+
32  const FILE_ID_INFO impl;
+
33 
+
34  bool operator==(const ID& other) const {
+
35  return impl.VolumeSerialNumber == other.impl.VolumeSerialNumber &&
+
36  impl.FileId == other.impl.FileId;
+
37  }
+
38  };
+
39 
+
41  static File open_r(const std::string&);
+
43  static File open_r(const CanonicalPath&);
+
45  static File open_read_attributes(const std::string&);
+ +
49  static File open_w(const std::string&);
+
51  static File open_w(const CanonicalPath&);
+
52 
+
54  static void remove(const std::string&);
+
56  static void remove(const CanonicalPath&);
+
57 
+
59  explicit File(Handle&& handle) : Handle{std::move(handle)} {}
+
60 
+
65  std::size_t get_size() const;
+
66 
+
71  ID query_id() const;
+
72 };
+
73 
+
74 } // namespace winapi
+
75 
+
76 namespace std {
+
77 
+
78 template <>
+
79 struct hash<winapi::File::ID> {
+
80  std::size_t operator()(const winapi::File::ID& id) const {
+
81  std::size_t seed = 0;
+
82  boost::hash_combine(seed, id.impl.VolumeSerialNumber);
+
83  boost::hash_combine(seed, id.impl.FileId.Identifier);
+
84  return seed;
+
85  }
+
86 };
+
87 
+
88 } // namespace std
+
Absolute, canonical path.
Definition: path.hpp:13
+
File I/O.
Definition: file.hpp:29
+
static File open_w(const std::string &)
Definition: file.cpp:108
+
static void remove(const std::string &)
Definition: file.cpp:116
+
File(Handle &&handle)
Definition: file.hpp:59
+
static File open_read_attributes(const std::string &)
Definition: file.cpp:100
+
static File open_r(const std::string &)
Definition: file.cpp:92
+
std::size_t get_size() const
Definition: file.cpp:124
+
ID query_id() const
Definition: file.cpp:139
+
HANDLE wrapper.
Definition: handle.hpp:25
+ +
+ + + + diff --git a/files.html b/files.html new file mode 100644 index 0000000..6498961 --- /dev/null +++ b/files.html @@ -0,0 +1,105 @@ + + + + + + + +winapi_common: File List + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
+
File List
+
+
+
Here is a list of all documented files with brief descriptions:
+
[detail level 123]
+ + + + + + + + + + + + + + + + + + + + + + + + + + + +
  include
  winapi
 buffer.hpp
 cmd_line.hpp
 error.hppMake std::system_error work with GetLastError()
 file.hpp
 handle.hpp
 path.hpp
 pipe.hpp
 process.hpp
 process_io.hpp
 resource.hpp
 shmem.hpp
 sid.hpp
 utils.hpp
 window_style.hpp
  src
 cmd_line.cpp
 error.cpp
 file.cpp
 handle.cpp
 path.cpp
 pipe.cpp
 process.cpp
 process_io.cpp
 shmem.cpp
 sid.cpp
+
+
+ + + + diff --git a/folderclosed.png b/folderclosed.png new file mode 100644 index 0000000..bb8ab35 Binary files /dev/null and b/folderclosed.png differ diff --git a/folderopen.png b/folderopen.png new file mode 100644 index 0000000..d6c7f67 Binary files /dev/null and b/folderopen.png differ diff --git a/functions.html b/functions.html new file mode 100644 index 0000000..28923e4 --- /dev/null +++ b/functions.html @@ -0,0 +1,305 @@ + + + + + + + +winapi_common: Class Members + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
Here is a list of all documented class members with links to the class documentation for each member:
+ +

- a -

+ + +

- b -

+ + +

- c -

+ + +

- d -

+ + +

- f -

+ + +

- g -

+ + +

- h -

+ + +

- i -

+ + +

- o -

+ + +

- p -

+ + +

- q -

+ + +

- r -

+ + +

- s -

+ + +

- t -

+ + +

- w -

+
+ + + + diff --git a/functions_func.html b/functions_func.html new file mode 100644 index 0000000..1f1cfb2 --- /dev/null +++ b/functions_func.html @@ -0,0 +1,305 @@ + + + + + + + +winapi_common: Class Members - Functions + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+  + +

- a -

+ + +

- b -

+ + +

- c -

+ + +

- d -

+ + +

- f -

+ + +

- g -

+ + +

- h -

+ + +

- i -

+ + +

- o -

+ + +

- p -

+ + +

- q -

+ + +

- r -

+ + +

- s -

+ + +

- t -

+ + +

- w -

+
+ + + + diff --git a/handle_8cpp_source.html b/handle_8cpp_source.html new file mode 100644 index 0000000..f27d365 --- /dev/null +++ b/handle_8cpp_source.html @@ -0,0 +1,225 @@ + + + + + + + +winapi_common: src/handle.cpp Source File + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+
handle.cpp
+
+
+
1 // Copyright (c) 2020 Egor Tensin <Egor.Tensin@gmail.com>
+
2 // This file is part of the "winapi-common" project.
+
3 // For details, see https://github.com/egor-tensin/winapi-common.
+
4 // Distributed under the MIT License.
+
5 
+
6 #include <winapi/buffer.hpp>
+
7 #include <winapi/error.hpp>
+
8 #include <winapi/handle.hpp>
+
9 #include <winapi/utils.hpp>
+
10 
+
11 #include <windows.h>
+
12 
+
13 #include <cassert>
+
14 #include <cstddef>
+
15 #include <limits>
+
16 #include <sstream>
+
17 #include <stdexcept>
+
18 #include <utility>
+
19 
+
20 namespace winapi {
+
21 namespace {
+
22 
+
23 std::runtime_error write_file_incomplete(std::size_t expected, std::size_t actual) {
+
24  std::ostringstream oss;
+
25  oss << "WriteFile could only write " << actual << " bytes instead of " << expected;
+
26  return std::runtime_error{oss.str()};
+
27 }
+
28 
+
29 bool is_std_handle(HANDLE handle) {
+
30  return handle == ::GetStdHandle(STD_INPUT_HANDLE) ||
+
31  handle == ::GetStdHandle(STD_OUTPUT_HANDLE) ||
+
32  handle == ::GetStdHandle(STD_ERROR_HANDLE);
+
33 }
+
34 
+
35 } // namespace
+
36 
+
37 Handle::Handle(HANDLE impl) : m_impl{impl} {}
+
38 
+
39 bool Handle::is_valid() const {
+
40  return m_impl && is_valid(m_impl.get());
+
41 }
+
42 
+
43 bool Handle::is_valid(HANDLE handle) {
+
44  return handle != NULL && handle != INVALID_HANDLE_VALUE;
+
45 }
+
46 
+
47 void Handle::close() {
+
48  m_impl.reset();
+
49 }
+
50 
+
51 bool Handle::is_std() const {
+
52  return is_std_handle(m_impl.get());
+
53 }
+
54 
+
55 Handle Handle::std_in() {
+
56  return Handle{::GetStdHandle(STD_INPUT_HANDLE)};
+
57 }
+
58 
+
59 Handle Handle::std_out() {
+
60  return Handle{::GetStdHandle(STD_OUTPUT_HANDLE)};
+
61 }
+
62 
+
63 Handle Handle::std_err() {
+
64  return Handle{::GetStdHandle(STD_ERROR_HANDLE)};
+
65 }
+
66 
+
67 bool Handle::read_chunk(Buffer& buffer) const {
+
68  buffer.resize(max_chunk_size);
+
69  DWORD nb_read = 0;
+
70 
+
71  if (buffer.size() > std::numeric_limits<DWORD>::max())
+
72  throw std::range_error{"Read buffer is too large"};
+
73  const auto ret =
+
74  ::ReadFile(m_impl.get(), buffer.data(), static_cast<DWORD>(buffer.size()), &nb_read, NULL);
+
75 
+
76  buffer.resize(nb_read);
+
77 
+
78  if (ret) {
+
79  return nb_read != 0;
+
80  }
+
81 
+
82  const auto ec = GetLastError();
+
83 
+
84  switch (ec) {
+
85  case ERROR_BROKEN_PIPE:
+
86  // We've been reading from an anonymous pipe, and it's been closed.
+
87  return false;
+
88  default:
+
89  throw error::windows(ec, "ReadFile");
+
90  }
+
91 }
+
92 
+
93 Buffer Handle::read() const {
+
94  Buffer buffer;
+
95 
+
96  while (true) {
+
97  Buffer chunk;
+
98  const auto next = read_chunk(chunk);
+
99  buffer.add(chunk);
+
100 
+
101  if (!next) {
+
102  break;
+
103  }
+
104  }
+
105 
+
106  return buffer;
+
107 }
+
108 
+
109 void Handle::write(const void* data, std::size_t nb) const {
+
110  DWORD nb_written = 0;
+
111 
+
112  if (nb > std::numeric_limits<DWORD>::max())
+
113  throw std::range_error{"Write buffer is too large"};
+
114  const auto ret = ::WriteFile(m_impl.get(), data, static_cast<DWORD>(nb), &nb_written, NULL);
+
115 
+
116  if (!ret) {
+
117  throw error::windows(GetLastError(), "WriteFile");
+
118  }
+
119 
+
120  if (nb != nb_written) {
+
121  throw write_file_incomplete(nb, nb_written);
+
122  }
+
123 }
+
124 
+
125 void Handle::write(const Buffer& buffer) const {
+
126  write(buffer.data(), buffer.size());
+
127 }
+
128 
+
129 void Handle::inherit(bool yes) const {
+
130  if (!::SetHandleInformation(m_impl.get(), HANDLE_FLAG_INHERIT, yes ? 1 : 0)) {
+
131  throw error::windows(GetLastError(), "SetHandleInformation");
+
132  }
+
133 }
+
134 
+
135 void Handle::Close::operator()(HANDLE impl) const {
+
136  if (!is_valid(impl) || is_std_handle(impl))
+
137  return;
+
138  const auto ret = ::CloseHandle(impl);
+
139  assert(ret);
+
140  WINAPI_UNUSED_PARAMETER(ret);
+
141 }
+
142 
+
143 } // namespace winapi
+
Binary data container.
Definition: buffer.hpp:24
+
void add(const Buffer &src)
Definition: buffer.hpp:79
+
HANDLE wrapper.
Definition: handle.hpp:25
+
Make std::system_error work with GetLastError().
+
+ + + + diff --git a/handle_8hpp_source.html b/handle_8hpp_source.html new file mode 100644 index 0000000..179b098 --- /dev/null +++ b/handle_8hpp_source.html @@ -0,0 +1,152 @@ + + + + + + + +winapi_common: include/winapi/handle.hpp Source File + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + + +
+
+ + +
+ +
+ + +
+
+
+
handle.hpp
+
+
+
1 // Copyright (c) 2020 Egor Tensin <Egor.Tensin@gmail.com>
+
2 // This file is part of the "winapi-common" project.
+
3 // For details, see https://github.com/egor-tensin/winapi-common.
+
4 // Distributed under the MIT License.
+
5 
+
6 #pragma once
+
7 
+
8 #include "buffer.hpp"
+
9 
+
10 #include <windows.h>
+
11 
+
12 #include <cstddef>
+
13 #include <memory>
+
14 #include <string>
+
15 #include <utility>
+
16 
+
17 namespace winapi {
+
18 
+
25 class Handle {
+
26 public:
+
27  Handle() = default;
+
28  explicit Handle(HANDLE);
+
29 
+
30  HANDLE get() const { return m_impl.get(); }
+
31  HANDLE ptr() const { return get(); }
+
32 
+
33  explicit operator HANDLE() const { return ptr(); }
+
34 
+
35  bool is_valid() const;
+
36  static bool is_valid(HANDLE);
+
37 
+
39  void close();
+
40 
+
42  bool is_std() const;
+
44  static Handle std_in();
+
46  static Handle std_out();
+
48  static Handle std_err();
+
49 
+
51  Buffer read() const;
+
52 
+
53  static constexpr std::size_t max_chunk_size = 16 * 1024;
+
59  bool read_chunk(Buffer& read_chunk) const;
+
60 
+
66  void write(const void* data, std::size_t nb) const;
+
71  void write(const Buffer& buffer) const;
+
72 
+
77  template <typename CharT>
+
78  void write(const std::basic_string<CharT>& src) const {
+
79  write(src.c_str(), src.size() * sizeof(CharT));
+
80  }
+
81 
+
82  void inherit(bool yes = true) const;
+
83  void dont_inherit() const { inherit(false); }
+
84 
+
85 private:
+
86  struct Close {
+
87  void operator()(HANDLE) const;
+
88  };
+
89 
+
90  std::unique_ptr<void, Close> m_impl;
+
91 };
+
92 
+
93 } // namespace winapi
+
Binary data container.
Definition: buffer.hpp:24
+
HANDLE wrapper.
Definition: handle.hpp:25
+
static Handle std_in()
Definition: handle.cpp:55
+
bool read_chunk(Buffer &read_chunk) const
Definition: handle.cpp:67
+
void close()
Definition: handle.cpp:47
+
static Handle std_out()
Definition: handle.cpp:59
+
static Handle std_err()
Definition: handle.cpp:63
+
void write(const std::basic_string< CharT > &src) const
Definition: handle.hpp:78
+
bool is_std() const
Definition: handle.cpp:51
+
Buffer read() const
Definition: handle.cpp:93
+
void write(const void *data, std::size_t nb) const
Definition: handle.cpp:109
+
+ + + + diff --git a/hierarchy.html b/hierarchy.html new file mode 100644 index 0000000..e4cf3b6 --- /dev/null +++ b/hierarchy.html @@ -0,0 +1,102 @@ + + + + + + + +winapi_common: Class Hierarchy + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
+
Class Hierarchy
+
+
+
This inheritance list is sorted roughly, but not completely, alphabetically:
+
[detail level 12]
+ + + + + + + + + + + + + + + + + + + + + + + + +
 Cwinapi::CanonicalPathAbsolute, canonical path
 Cwinapi::CommandLineCommand line for the current process or for launching new processes
 Cstd::error_category
 Cwinapi::error::CategoryWindows
 Cwinapi::HandleHANDLE wrapper
 Cwinapi::FileFile I/O
 Cstd::hash< winapi::File::ID >
 Cwinapi::File::ID
 Cwinapi::process::IOChild process IO settings
 Cwinapi::LocalDelete
 Cwinapi::PipeAnonymous pipe wrapper
 Cwinapi::ProcessCreate a new process or open an existing process
 Cwinapi::ProcessParametersProcess parameters for Process::create()
 Cwinapi::ShellParametersProcess parameters for Process::shell()
 Cwinapi::ResourceResources embedded in a PE (Portable Executable)
 Cwinapi::SharedMemoryNamed shared memory region
 Cwinapi::SharedObject< T >Easy way to represent a C++ object as a shared memory region
 Cwinapi::Sid
 Cwinapi::process::Stream
 Cwinapi::process::StderrRedirect child process's stderr
 Cwinapi::process::StdinRedirect child process's stdin
 Cwinapi::process::StdoutRedirect child process's stdout
 Cstd::vector
 Cwinapi::BufferBinary data container
+
+
+ + + + diff --git a/index.html b/index.html new file mode 100644 index 0000000..6699400 --- /dev/null +++ b/index.html @@ -0,0 +1,91 @@ + + + + + + + +winapi_common: winapi-common + + + + + + + + + +
+
+ + + + + + +
+
winapi_common +
+
+
+ + + + + + + +
+ +
+
+ + +
+ +
+ +
+
+
winapi-common
+
+
+

+

CI

+

C++ wrappers for various common WinAPI entities I've had to use in various projects over the years.

+

+Development

+

Build using CMake. Depends on Boost.Test and Python 3 for running the tests. The project is Windows-only, so building with either MSVC or MinGW-w64 is required.

+

There's a Makefile with useful shortcuts to build the project in the build/ directory (defaults to building with MinGW-w64):

make deps
+make build
+make test
+

+Documentation

+

Build & display the documentation using

make docs
+

View the online documentation at https://egor-tensin.github.io/winapi-common/.

+

+License

+

Distributed under the MIT License. See LICENSE.txt for details.

+
+
+ + + + diff --git a/jquery.js b/jquery.js new file mode 100644 index 0000000..103c32d --- /dev/null +++ b/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/menu.js b/menu.js new file mode 100644 index 0000000..2fe2214 --- /dev/null +++ b/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/menudata.js b/menudata.js new file mode 100644 index 0000000..a73cd7a --- /dev/null +++ b/menudata.js @@ -0,0 +1,65 @@ +/* + @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:"Classes",url:"annotated.html",children:[ +{text:"Class List",url:"annotated.html"}, +{text:"Class Index",url:"classes.html"}, +{text:"Class Hierarchy",url:"hierarchy.html"}, +{text:"Class Members",url:"functions.html",children:[ +{text:"All",url:"functions.html",children:[ +{text:"a",url:"functions.html#index_a"}, +{text:"b",url:"functions.html#index_b"}, +{text:"c",url:"functions.html#index_c"}, +{text:"d",url:"functions.html#index_d"}, +{text:"f",url:"functions.html#index_f"}, +{text:"g",url:"functions.html#index_g"}, +{text:"h",url:"functions.html#index_h"}, +{text:"i",url:"functions.html#index_i"}, +{text:"o",url:"functions.html#index_o"}, +{text:"p",url:"functions.html#index_p"}, +{text:"q",url:"functions.html#index_q"}, +{text:"r",url:"functions.html#index_r"}, +{text:"s",url:"functions.html#index_s"}, +{text:"t",url:"functions.html#index_t"}, +{text:"w",url:"functions.html#index_w"}]}, +{text:"Functions",url:"functions_func.html",children:[ +{text:"a",url:"functions_func.html#index_a"}, +{text:"b",url:"functions_func.html#index_b"}, +{text:"c",url:"functions_func.html#index_c"}, +{text:"d",url:"functions_func.html#index_d"}, +{text:"f",url:"functions_func.html#index_f"}, +{text:"g",url:"functions_func.html#index_g"}, +{text:"h",url:"functions_func.html#index_h"}, +{text:"i",url:"functions_func.html#index_i"}, +{text:"o",url:"functions_func.html#index_o"}, +{text:"p",url:"functions_func.html#index_p"}, +{text:"q",url:"functions_func.html#index_q"}, +{text:"r",url:"functions_func.html#index_r"}, +{text:"s",url:"functions_func.html#index_s"}, +{text:"t",url:"functions_func.html#index_t"}, +{text:"w",url:"functions_func.html#index_w"}]}]}]}, +{text:"Files",url:"files.html",children:[ +{text:"File List",url:"files.html"}]}]} diff --git a/nav_f.png b/nav_f.png new file mode 100644 index 0000000..72a58a5 Binary files /dev/null and b/nav_f.png differ diff --git a/nav_g.png b/nav_g.png new file mode 100644 index 0000000..2093a23 Binary files /dev/null and b/nav_g.png differ diff --git a/nav_h.png b/nav_h.png new file mode 100644 index 0000000..33389b1 Binary files /dev/null and b/nav_h.png differ diff --git a/open.png b/open.png new file mode 100644 index 0000000..30f75c7 Binary files /dev/null and b/open.png differ diff --git a/path_8cpp_source.html b/path_8cpp_source.html new file mode 100644 index 0000000..5cd7a6c --- /dev/null +++ b/path_8cpp_source.html @@ -0,0 +1,135 @@ + + + + + + + +winapi_common: src/path.cpp Source File + + + + + + + + + +
    +
    + + + + + + +
    +
    winapi_common +
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    +
    +
    path.cpp
    +
    +
    +
    1 // Copyright (c) 2020 Egor Tensin <Egor.Tensin@gmail.com>
    +
    2 // This file is part of the "winapi-common" project.
    +
    3 // For details, see https://github.com/egor-tensin/winapi-common.
    +
    4 // Distributed under the MIT License.
    +
    5 
    +
    6 #include <winapi/error.hpp>
    +
    7 #include <winapi/path.hpp>
    +
    8 #include <winapi/utf8.hpp>
    +
    9 
    +
    10 #include <windows.h>
    +
    11 
    +
    12 #include <cstddef>
    +
    13 #include <limits>
    +
    14 #include <stdexcept>
    +
    15 #include <string>
    +
    16 #include <vector>
    +
    17 
    +
    18 namespace winapi {
    +
    19 namespace {
    +
    20 
    +
    21 std::wstring do_canonicalize(const std::wstring& path) {
    +
    22  static constexpr std::size_t init_buffer_size = MAX_PATH;
    +
    23  static_assert(init_buffer_size > 0, "init_buffer_size must be positive");
    +
    24 
    +
    25  std::vector<wchar_t> buffer;
    +
    26  buffer.resize(init_buffer_size);
    +
    27 
    +
    28  while (true) {
    +
    29  if (buffer.size() > std::numeric_limits<DWORD>::max())
    +
    30  throw std::range_error{"Path buffer is too large"};
    +
    31  const auto nch = ::GetFullPathNameW(
    +
    32  path.c_str(), static_cast<DWORD>(buffer.size()), buffer.data(), NULL);
    +
    33 
    +
    34  if (nch == 0) {
    +
    35  throw error::windows(GetLastError(), "GetFullPathNameW");
    +
    36  }
    +
    37 
    +
    38  if (nch < buffer.size()) {
    +
    39  return {buffer.data(), nch};
    +
    40  }
    +
    41 
    +
    42  if (nch > buffer.size()) {
    +
    43  buffer.resize(2 * buffer.size());
    +
    44  }
    +
    45  }
    +
    46 }
    +
    47 
    +
    48 } // namespace
    +
    49 
    +
    50 CanonicalPath::CanonicalPath(const std::string& path) : m_path(canonicalize(path)) {}
    +
    51 
    +
    52 std::string CanonicalPath::canonicalize(const std::string& path) {
    +
    53  return narrow(do_canonicalize(widen(path)));
    +
    54 }
    +
    55 
    +
    56 } // namespace winapi
    +
    Make std::system_error work with GetLastError().
    +
    + + + + diff --git a/path_8hpp_source.html b/path_8hpp_source.html new file mode 100644 index 0000000..5729fa9 --- /dev/null +++ b/path_8hpp_source.html @@ -0,0 +1,105 @@ + + + + + + + +winapi_common: include/winapi/path.hpp Source File + + + + + + + + + +
    +
    + + + + + + +
    +
    winapi_common +
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    +
    +
    path.hpp
    +
    +
    +
    1 // Copyright (c) 2020 Egor Tensin <Egor.Tensin@gmail.com>
    +
    2 // This file is part of the "winapi-common" project.
    +
    3 // For details, see https://github.com/egor-tensin/winapi-common.
    +
    4 // Distributed under the MIT License.
    +
    5 
    +
    6 #pragma once
    +
    7 
    +
    8 #include <string>
    +
    9 
    +
    10 namespace winapi {
    +
    11 
    + +
    14 public:
    +
    16  static std::string canonicalize(const std::string&);
    +
    17 
    +
    18  explicit CanonicalPath(const std::string&);
    +
    19 
    +
    20  std::string get() const { return m_path; }
    +
    21  std::string path() const { return get(); }
    +
    22 
    +
    23 private:
    +
    24  std::string m_path;
    +
    25 };
    +
    26 
    +
    27 } // namespace winapi
    +
    Absolute, canonical path.
    Definition: path.hpp:13
    +
    static std::string canonicalize(const std::string &)
    Definition: path.cpp:52
    +
    + + + + diff --git a/pipe_8cpp_source.html b/pipe_8cpp_source.html new file mode 100644 index 0000000..0b99a12 --- /dev/null +++ b/pipe_8cpp_source.html @@ -0,0 +1,125 @@ + + + + + + + +winapi_common: src/pipe.cpp Source File + + + + + + + + + +
    +
    + + + + + + +
    +
    winapi_common +
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    +
    +
    pipe.cpp
    +
    +
    +
    1 // Copyright (c) 2020 Egor Tensin <Egor.Tensin@gmail.com>
    +
    2 // This file is part of the "winapi-common" project.
    +
    3 // For details, see https://github.com/egor-tensin/winapi-common.
    +
    4 // Distributed under the MIT License.
    +
    5 
    +
    6 #include <winapi/error.hpp>
    +
    7 #include <winapi/handle.hpp>
    +
    8 #include <winapi/pipe.hpp>
    +
    9 
    +
    10 #include <windows.h>
    +
    11 
    +
    12 #include <cstring>
    +
    13 #include <utility>
    +
    14 
    +
    15 namespace winapi {
    +
    16 namespace {
    +
    17 
    +
    18 void create_pipe(Handle& read_end, Handle& write_end) {
    +
    19  HANDLE read_end_impl = INVALID_HANDLE_VALUE;
    +
    20  HANDLE write_end_impl = INVALID_HANDLE_VALUE;
    +
    21 
    +
    22  SECURITY_ATTRIBUTES attributes;
    +
    23  std::memset(&attributes, 0, sizeof(attributes));
    +
    24  attributes.nLength = sizeof(attributes);
    +
    25  attributes.bInheritHandle = TRUE;
    +
    26 
    +
    27  static constexpr DWORD buffer_size = 16 * 1024;
    +
    28 
    +
    29  const auto ret = ::CreatePipe(&read_end_impl, &write_end_impl, &attributes, buffer_size);
    +
    30 
    +
    31  if (!ret) {
    +
    32  throw error::windows(GetLastError(), "CreatePipe");
    +
    33  }
    +
    34 
    +
    35  read_end = Handle{read_end_impl};
    +
    36  write_end = Handle{write_end_impl};
    +
    37 }
    +
    38 
    +
    39 } // namespace
    +
    40 
    + +
    42  create_pipe(m_read_end, m_write_end);
    +
    43 }
    +
    44 
    +
    45 } // namespace winapi
    + +
    Make std::system_error work with GetLastError().
    +
    + + + + diff --git a/pipe_8hpp_source.html b/pipe_8hpp_source.html new file mode 100644 index 0000000..273c136 --- /dev/null +++ b/pipe_8hpp_source.html @@ -0,0 +1,113 @@ + + + + + + + +winapi_common: include/winapi/pipe.hpp Source File + + + + + + + + + +
    +
    + + + + + + +
    +
    winapi_common +
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    +
    +
    pipe.hpp
    +
    +
    +
    1 // Copyright (c) 2020 Egor Tensin <Egor.Tensin@gmail.com>
    +
    2 // This file is part of the "winapi-common" project.
    +
    3 // For details, see https://github.com/egor-tensin/winapi-common.
    +
    4 // Distributed under the MIT License.
    +
    5 
    +
    6 #pragma once
    +
    7 
    +
    8 #include "handle.hpp"
    +
    9 
    +
    10 #include <utility>
    +
    11 
    +
    12 namespace winapi {
    +
    13 
    +
    15 class Pipe {
    +
    16 public:
    +
    18  Pipe();
    +
    19 
    +
    21  Handle& read_end() { return m_read_end; }
    +
    23  const Handle& read_end() const { return m_read_end; }
    +
    25  Handle& write_end() { return m_write_end; }
    +
    27  const Handle& write_end() const { return m_write_end; }
    +
    28 
    +
    29 private:
    +
    30  Handle m_read_end;
    +
    31  Handle m_write_end;
    +
    32 };
    +
    33 
    +
    34 } // namespace winapi
    +
    HANDLE wrapper.
    Definition: handle.hpp:25
    +
    Anonymous pipe wrapper.
    Definition: pipe.hpp:15
    +
    Handle & read_end()
    Definition: pipe.hpp:21
    +
    Handle & write_end()
    Definition: pipe.hpp:25
    + +
    const Handle & write_end() const
    Definition: pipe.hpp:27
    +
    const Handle & read_end() const
    Definition: pipe.hpp:23
    +
    + + + + diff --git a/process_8cpp_source.html b/process_8cpp_source.html new file mode 100644 index 0000000..575b3c2 --- /dev/null +++ b/process_8cpp_source.html @@ -0,0 +1,503 @@ + + + + + + + +winapi_common: src/process.cpp Source File + + + + + + + + + +
    +
    + + + + + + +
    +
    winapi_common +
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    +
    +
    process.cpp
    +
    +
    +
    1 // Copyright (c) 2020 Egor Tensin <Egor.Tensin@gmail.com>
    +
    2 // This file is part of the "winapi-common" project.
    +
    3 // For details, see https://github.com/egor-tensin/winapi-common.
    +
    4 // Distributed under the MIT License.
    +
    5 
    +
    6 #include <winapi/cmd_line.hpp>
    +
    7 #include <winapi/error.hpp>
    +
    8 #include <winapi/handle.hpp>
    +
    9 #include <winapi/process.hpp>
    +
    10 #include <winapi/process_io.hpp>
    +
    11 #include <winapi/resource.hpp>
    +
    12 #include <winapi/utf8.hpp>
    +
    13 
    +
    14 // clang-format off
    +
    15 #include <windows.h>
    +
    16 #include <shellapi.h>
    +
    17 // clang-format on
    +
    18 
    +
    19 #include <cstddef>
    +
    20 #include <cstring>
    +
    21 #include <limits>
    +
    22 #include <sstream>
    +
    23 #include <stdexcept>
    +
    24 #include <string>
    +
    25 #include <utility>
    +
    26 #include <vector>
    +
    27 
    +
    28 namespace winapi {
    +
    29 namespace {
    +
    30 
    +
    31 using EscapedCommandLine = std::vector<wchar_t>;
    +
    32 
    +
    33 EscapedCommandLine escape_command_line(const CommandLine& cmd_line) {
    +
    34  const auto unicode_cmd_line = widen(cmd_line.to_string());
    +
    35  EscapedCommandLine buffer;
    +
    36  buffer.reserve(unicode_cmd_line.size() + 1);
    +
    37  buffer.assign(unicode_cmd_line.cbegin(), unicode_cmd_line.cend());
    +
    38  buffer.emplace_back(L'\0');
    +
    39  return buffer;
    +
    40 }
    +
    41 
    +
    42 Handle create_process(ProcessParameters& params) {
    +
    43  /*
    +
    44  * When creating a new console process, the options are:
    +
    45  * 1) inherit the parent console (the default),
    +
    46  * 2) CREATE_NO_WINDOW,
    +
    47  * 3) CREATE_NEW_CONSOLE,
    +
    48  * 4) DETACHED_PROCESS.
    +
    49  *
    +
    50  * Child processes can inherit the console.
    +
    51  * By that I mean they will display their output in the same window.
    +
    52  * If both the child process and the parent process read from stdin, there
    +
    53  * is no way to say which process will read any given input byte.
    +
    54  *
    +
    55  * There's an excellent guide into all the intricacies of the CreateProcess
    +
    56  * system call at
    +
    57  *
    +
    58  * https://github.com/rprichard/win32-console-docs/blob/master/README.md
    +
    59  *
    +
    60  * Another useful link is https://ikriv.com/dev/cpp/ConsoleProxy/flags.
    +
    61  */
    +
    62  static constexpr DWORD default_dwCreationFlags = CREATE_UNICODE_ENVIRONMENT;
    +
    63 
    +
    64  STARTUPINFOW startup_info;
    +
    65  std::memset(&startup_info, 0, sizeof(startup_info));
    +
    66  startup_info.cb = sizeof(startup_info);
    +
    67 
    +
    68  if (params.io) {
    +
    69  startup_info.dwFlags |= STARTF_USESTDHANDLES;
    +
    70  startup_info.hStdInput = static_cast<HANDLE>(params.io->std_in.handle);
    +
    71  startup_info.hStdOutput = static_cast<HANDLE>(params.io->std_out.handle);
    +
    72  startup_info.hStdError = static_cast<HANDLE>(params.io->std_err.handle);
    +
    73  }
    +
    74 
    +
    75  auto dwCreationFlags = default_dwCreationFlags;
    +
    76 
    +
    77  switch (params.console_mode) {
    +
    78  case ProcessParameters::ConsoleNone:
    +
    79  dwCreationFlags |= CREATE_NO_WINDOW;
    +
    80  break;
    +
    81  case ProcessParameters::ConsoleInherit:
    +
    82  // This is the default.
    +
    83  break;
    +
    84  case ProcessParameters::ConsoleNew:
    +
    85  dwCreationFlags |= CREATE_NEW_CONSOLE;
    +
    86  break;
    +
    87  }
    +
    88 
    +
    89  PROCESS_INFORMATION child_info;
    +
    90  std::memset(&child_info, 0, sizeof(child_info));
    +
    91 
    +
    92  {
    +
    93  auto cmd_line = escape_command_line(params.cmd_line);
    +
    94 
    +
    95  const auto ret = ::CreateProcessW(NULL,
    +
    96  cmd_line.data(),
    +
    97  NULL,
    +
    98  NULL,
    +
    99  TRUE,
    +
    100  dwCreationFlags,
    +
    101  NULL,
    +
    102  NULL,
    +
    103  &startup_info,
    +
    104  &child_info);
    +
    105 
    +
    106  if (!ret) {
    +
    107  throw error::windows(GetLastError(), "CreateProcessW");
    +
    108  }
    +
    109  }
    +
    110 
    +
    111  if (params.io) {
    +
    112  params.io->close();
    +
    113  }
    +
    114 
    +
    115  Handle process{child_info.hProcess};
    +
    116  Handle thread{child_info.hThread};
    +
    117 
    +
    118  return process;
    +
    119 }
    +
    120 
    +
    121 Handle shell_execute(const ShellParameters& params) {
    +
    122  const auto lpVerb = params.verb ? widen(*params.verb) : L"open";
    +
    123  const auto lpFile = widen(params.cmd_line.get_argv0());
    +
    124  const auto lpParameters = widen(params.cmd_line.args_to_string());
    +
    125 
    +
    126  static constexpr uint32_t default_fMask = SEE_MASK_NOCLOSEPROCESS | SEE_MASK_FLAG_NO_UI;
    +
    127 
    +
    128  auto fMask = default_fMask;
    +
    129  auto nShow = SW_SHOWDEFAULT;
    +
    130 
    +
    131  switch (params.console_mode) {
    +
    132  case ProcessParameters::ConsoleNone:
    +
    133  nShow = SW_HIDE;
    +
    134  break;
    +
    135  case ProcessParameters::ConsoleInherit:
    +
    136  fMask |= SEE_MASK_NO_CONSOLE;
    +
    137  break;
    +
    138  case ProcessParameters::ConsoleNew:
    +
    139  // This is the default.
    +
    140  break;
    +
    141  }
    +
    142 
    +
    143  SHELLEXECUTEINFOW info;
    +
    144  std::memset(&info, 0, sizeof(info));
    +
    145  info.cbSize = sizeof(info);
    +
    146  info.fMask = fMask;
    +
    147  info.lpVerb = lpVerb.c_str();
    +
    148  info.lpFile = lpFile.c_str();
    +
    149  if (!lpParameters.empty())
    +
    150  info.lpParameters = lpParameters.c_str();
    +
    151  info.nShow = nShow;
    +
    152 
    +
    153  if (!::ShellExecuteExW(&info)) {
    +
    154  throw error::windows(GetLastError(), "ShellExecuteExW");
    +
    155  }
    +
    156 
    +
    157  return Handle{info.hProcess};
    +
    158 }
    +
    159 
    +
    160 Handle open_process(DWORD id, DWORD permissions) {
    +
    161  Handle process{OpenProcess(permissions, FALSE, id)};
    +
    162  if (!process.is_valid()) {
    +
    163  throw error::windows(GetLastError(), "OpenProcess");
    +
    164  }
    +
    165  return process;
    +
    166 }
    +
    167 
    +
    168 class PathBuffer {
    +
    169 public:
    +
    170  PathBuffer() : m_size{min_size} { m_data.resize(m_size); }
    +
    171 
    +
    172  DWORD get_size() const { return m_size; }
    +
    173 
    +
    174  wchar_t* get_data() { return m_data.data(); }
    +
    175 
    +
    176  void grow() {
    +
    177  if (m_size < min_size) {
    +
    178  m_size = min_size;
    +
    179  } else {
    +
    180  // Check if we can still multiply by two.
    +
    181  if (std::numeric_limits<decltype(m_size)>::max() - m_size < m_size)
    +
    182  throw std::range_error{"Path buffer is too large"};
    +
    183  m_size *= 2;
    +
    184  }
    +
    185  m_data.resize(m_size);
    +
    186  }
    +
    187 
    +
    188 private:
    +
    189  static constexpr DWORD min_size = MAX_PATH;
    +
    190 
    +
    191  DWORD m_size;
    +
    192  std::vector<wchar_t> m_data;
    +
    193 };
    +
    194 
    +
    195 std::string get_current_exe_path(PathBuffer& buffer) {
    +
    196  SetLastError(ERROR_SUCCESS);
    +
    197 
    +
    198  const auto ec = ::GetModuleFileNameW(NULL, buffer.get_data(), buffer.get_size());
    +
    199 
    +
    200  if (ec == 0) {
    +
    201  throw error::windows(GetLastError(), "GetModuleFileNameW");
    +
    202  }
    +
    203 
    +
    204  if (ec == buffer.get_size() && GetLastError() == ERROR_INSUFFICIENT_BUFFER) {
    +
    205  buffer.grow();
    +
    206  return get_current_exe_path(buffer);
    +
    207  }
    +
    208 
    +
    209  return narrow(buffer.get_data());
    +
    210 }
    +
    211 
    +
    212 std::string get_current_exe_path() {
    +
    213  PathBuffer buffer;
    +
    214  return get_current_exe_path(buffer);
    +
    215 }
    +
    216 
    +
    217 std::string get_exe_path(const Handle& process, PathBuffer& buffer) {
    +
    218  auto size = buffer.get_size();
    +
    219 
    +
    220  const auto ec = ::QueryFullProcessImageNameW(process.get(), 0, buffer.get_data(), &size);
    +
    221 
    +
    222  if (ec != 0) {
    +
    223  return narrow(buffer.get_data());
    +
    224  }
    +
    225 
    +
    226  if (GetLastError() == ERROR_INSUFFICIENT_BUFFER) {
    +
    227  buffer.grow();
    +
    228  return get_exe_path(process, buffer);
    +
    229  }
    +
    230 
    +
    231  throw error::windows(GetLastError(), "QueryFullProcessImageNameW");
    +
    232 }
    +
    233 
    +
    234 std::string get_exe_path(const Handle& process) {
    +
    235  PathBuffer buffer;
    +
    236  return get_exe_path(process, buffer);
    +
    237 }
    +
    238 
    +
    239 } // namespace
    +
    240 
    + +
    242  return Process{create_process(params)};
    +
    243 }
    +
    244 
    + +
    246  ProcessParameters params{cmd_line};
    +
    247  return create(std::move(params));
    +
    248 }
    +
    249 
    + +
    251  ProcessParameters params{cmd_line};
    +
    252  params.io = std::move(io);
    +
    253  return create(std::move(params));
    +
    254 }
    +
    255 
    + +
    257  return Process{shell_execute(params)};
    +
    258 }
    +
    259 
    + +
    261  ShellParameters params{cmd_line};
    +
    262  return shell(params);
    +
    263 }
    +
    264 
    + +
    266  return Process{::GetCurrentProcessId(), Handle{::GetCurrentProcess()}};
    +
    267 }
    +
    268 
    +
    269 Process Process::open(DWORD id, DWORD permissions) {
    +
    270  return Process{id, open_process(id, permissions)};
    +
    271 }
    +
    272 
    + +
    274  return open(id, read_permissions());
    +
    275 }
    +
    276 
    + +
    278  return PROCESS_QUERY_INFORMATION;
    +
    279 }
    +
    280 
    + +
    282  return default_permissions() | PROCESS_VM_READ;
    +
    283 }
    +
    284 
    +
    285 bool Process::is_running() const {
    +
    286  const auto ret = ::WaitForSingleObject(static_cast<HANDLE>(m_handle), 0);
    +
    287 
    +
    288  switch (ret) {
    +
    289  case WAIT_OBJECT_0:
    +
    290  return false;
    +
    291  case WAIT_TIMEOUT:
    +
    292  return true;
    +
    293  case WAIT_FAILED:
    +
    294  throw error::windows(GetLastError(), "WaitForSingleObject");
    +
    295  default:
    +
    296  // Shouldn't happen.
    +
    297  throw error::custom(ret, "WaitForSingleObject");
    +
    298  }
    +
    299 }
    +
    300 
    +
    301 void Process::wait() const {
    +
    302  const auto ret = ::WaitForSingleObject(static_cast<HANDLE>(m_handle), INFINITE);
    +
    303 
    +
    304  switch (ret) {
    +
    305  case WAIT_OBJECT_0:
    +
    306  return;
    +
    307  case WAIT_FAILED:
    +
    308  throw error::windows(GetLastError(), "WaitForSingleObject");
    +
    309  default:
    +
    310  // Shouldn't happen.
    +
    311  throw error::custom(ret, "WaitForSingleObject");
    +
    312  }
    +
    313 }
    +
    314 
    +
    315 void Process::terminate(int ec) const {
    +
    316  if (!::TerminateProcess(static_cast<HANDLE>(m_handle), static_cast<UINT>(ec))) {
    +
    317  throw error::windows(GetLastError(), "TerminateProcess");
    +
    318  }
    +
    319 }
    +
    320 
    +
    321 void Process::shut_down(int ec) const {
    +
    322  terminate(ec);
    +
    323  wait();
    +
    324 }
    +
    325 
    + +
    327  DWORD ec = 0;
    +
    328 
    +
    329  const auto ret = ::GetExitCodeProcess(static_cast<HANDLE>(m_handle), &ec);
    +
    330 
    +
    331  if (!ret) {
    +
    332  throw error::windows(GetLastError(), "GetExitCodeProcess");
    +
    333  }
    +
    334 
    +
    335  if (ec == STILL_ACTIVE) {
    +
    336  throw std::runtime_error{"Attempted to query the exit code of a running process"};
    +
    337  }
    +
    338 
    +
    339  return static_cast<int>(ec);
    +
    340 }
    +
    341 
    +
    342 std::string Process::get_exe_path() const {
    +
    343  if (m_handle.get() == ::GetCurrentProcess()) {
    +
    344  return get_current_exe_path();
    +
    345  } else {
    +
    346  return winapi::get_exe_path(m_handle);
    +
    347  }
    +
    348 }
    +
    349 
    +
    350 HMODULE Process::get_exe_module() {
    +
    351  const auto module = ::GetModuleHandleW(NULL);
    +
    352  if (module == NULL) {
    +
    353  throw error::windows(GetLastError(), "GetModuleHandleW");
    +
    354  }
    +
    355  return module;
    +
    356 }
    +
    357 
    +
    358 std::string Process::get_resource_string(uint32_t id) {
    +
    359  wchar_t* s = nullptr;
    +
    360 
    +
    361  const auto nch = ::LoadStringW(get_exe_module(), id, reinterpret_cast<wchar_t*>(&s), 0);
    +
    362 
    +
    363  if (nch <= 0) {
    +
    364  throw error::windows(GetLastError(), "LoadStringW");
    +
    365  }
    +
    366 
    +
    367  return narrow(s, nch * sizeof(wchar_t));
    +
    368 }
    +
    369 
    + +
    371  const auto module = get_exe_module();
    +
    372 
    +
    373  const auto src = ::FindResourceA(module, MAKEINTRESOURCEA(id), RT_RCDATA);
    +
    374 
    +
    375  if (src == NULL) {
    +
    376  throw error::windows(GetLastError(), "FindResourceA");
    +
    377  }
    +
    378 
    +
    379  const auto resource = ::LoadResource(module, src);
    +
    380 
    +
    381  if (resource == NULL) {
    +
    382  throw error::windows(GetLastError(), "LoadResource");
    +
    383  }
    +
    384 
    +
    385  const auto data = ::LockResource(resource);
    +
    386 
    +
    387  if (data == NULL) {
    +
    388  std::ostringstream oss;
    +
    389  oss << "Couldn't get data pointer for resource with ID " << id;
    +
    390  throw std::runtime_error{oss.str()};
    +
    391  }
    +
    392 
    +
    393  const auto nb = ::SizeofResource(module, src);
    +
    394 
    +
    395  return {data, nb};
    +
    396 }
    +
    397 
    +
    398 Process::Process(Handle&& handle) : Process{::GetProcessId(handle.get()), std::move(handle)} {}
    +
    399 
    +
    400 Process::Process(ID id, Handle&& handle) : m_id{id}, m_handle{std::move(handle)} {}
    +
    401 
    +
    402 } // namespace winapi
    +
    Command line for the current process or for launching new processes.
    Definition: cmd_line.hpp:21
    +
    HANDLE wrapper.
    Definition: handle.hpp:25
    +
    Create a new process or open an existing process.
    Definition: process.hpp:54
    +
    void terminate(int ec=0) const
    Definition: process.cpp:315
    +
    void shut_down(int ec=0) const
    Definition: process.cpp:321
    +
    void wait() const
    Definition: process.cpp:301
    +
    int get_exit_code() const
    Definition: process.cpp:326
    +
    static Process open(ID id, DWORD permissions=default_permissions())
    Definition: process.cpp:269
    +
    static Resource get_resource(uint32_t id)
    Definition: process.cpp:370
    +
    static Process current()
    Definition: process.cpp:265
    +
    static DWORD read_permissions()
    Definition: process.cpp:281
    +
    static DWORD default_permissions()
    Definition: process.cpp:277
    +
    bool is_running() const
    Definition: process.cpp:285
    +
    static Process create(ProcessParameters)
    Definition: process.cpp:241
    +
    std::string get_exe_path() const
    Definition: process.cpp:342
    +
    static Process shell(const ShellParameters &)
    Definition: process.cpp:256
    +
    static std::string get_resource_string(uint32_t id)
    Definition: process.cpp:358
    +
    static Process open_r(ID)
    Definition: process.cpp:273
    +
    Make std::system_error work with GetLastError().
    +
    Process parameters for Process::create().
    Definition: process.hpp:24
    +
    Resources embedded in a PE (Portable Executable).
    Definition: resource.hpp:15
    +
    Process parameters for Process::shell().
    Definition: process.hpp:39
    +
    Child process IO settings.
    Definition: process_io.hpp:61
    +
    + + + + diff --git a/process_8hpp_source.html b/process_8hpp_source.html new file mode 100644 index 0000000..a7e9a14 --- /dev/null +++ b/process_8hpp_source.html @@ -0,0 +1,193 @@ + + + + + + + +winapi_common: include/winapi/process.hpp Source File + + + + + + + + + +
    +
    + + + + + + +
    +
    winapi_common +
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    +
    +
    process.hpp
    +
    +
    +
    1 // Copyright (c) 2020 Egor Tensin <Egor.Tensin@gmail.com>
    +
    2 // This file is part of the "winapi-common" project.
    +
    3 // For details, see https://github.com/egor-tensin/winapi-common.
    +
    4 // Distributed under the MIT License.
    +
    5 
    +
    6 #pragma once
    +
    7 
    +
    8 #include "cmd_line.hpp"
    +
    9 #include "handle.hpp"
    +
    10 #include "process_io.hpp"
    +
    11 #include "resource.hpp"
    +
    12 
    +
    13 #include <boost/optional.hpp>
    +
    14 
    +
    15 #include <windows.h>
    +
    16 
    +
    17 #include <cstdint>
    +
    18 #include <string>
    +
    19 #include <utility>
    +
    20 
    +
    21 namespace winapi {
    +
    22 
    + +
    25  enum ConsoleCreationMode {
    +
    26  ConsoleNone,
    +
    27  ConsoleInherit,
    +
    28  ConsoleNew,
    +
    29  };
    +
    30 
    +
    31  explicit ProcessParameters(const CommandLine& cmd_line) : cmd_line{cmd_line} {}
    +
    32 
    +
    33  CommandLine cmd_line;
    +
    34  boost::optional<process::IO> io;
    +
    35  ConsoleCreationMode console_mode = ConsoleNew;
    +
    36 };
    +
    37 
    + +
    40  static ShellParameters runas(const CommandLine& cmd_line) {
    +
    41  ShellParameters params{cmd_line};
    +
    42  params.verb = "runas";
    +
    43  return params;
    +
    44  }
    +
    45 
    +
    46  explicit ShellParameters(const CommandLine& cmd_line) : ProcessParameters{cmd_line} {}
    +
    47 
    +
    48  boost::optional<std::string> verb;
    +
    49 };
    +
    50 
    +
    54 class Process {
    +
    55 public:
    +
    56  using ID = DWORD;
    +
    57 
    + +
    61  static Process create(const CommandLine&);
    +
    63  static Process create(const CommandLine&, process::IO);
    +
    64 
    +
    66  static Process shell(const ShellParameters&);
    +
    68  static Process shell(const CommandLine&);
    +
    69 
    +
    71  static Process current();
    +
    77  static Process open(ID id, DWORD permissions = default_permissions());
    +
    79  static Process open_r(ID);
    +
    80 
    +
    82  static DWORD default_permissions();
    +
    84  static DWORD read_permissions();
    +
    85 
    +
    87  ID get_id() const { return m_id; }
    +
    89  const Handle& get_handle() const { return m_handle; }
    +
    90 
    +
    92  bool is_running() const;
    +
    94  void wait() const;
    +
    96  void terminate(int ec = 0) const;
    +
    98  void shut_down(int ec = 0) const;
    +
    100  int get_exit_code() const;
    +
    101 
    +
    103  std::string get_exe_path() const;
    +
    104 
    +
    106  static Resource get_resource(uint32_t id);
    +
    111  static std::string get_resource_string(uint32_t id);
    +
    112 
    +
    113 private:
    +
    114  explicit Process(Handle&& handle);
    +
    115  Process(ID, Handle&& handle);
    +
    116 
    +
    117  static HMODULE get_exe_module();
    +
    118 
    +
    119  ID m_id;
    +
    120  Handle m_handle;
    +
    121 };
    +
    122 
    +
    123 } // namespace winapi
    +
    Command line for the current process or for launching new processes.
    Definition: cmd_line.hpp:21
    +
    HANDLE wrapper.
    Definition: handle.hpp:25
    +
    Create a new process or open an existing process.
    Definition: process.hpp:54
    +
    void terminate(int ec=0) const
    Definition: process.cpp:315
    +
    void shut_down(int ec=0) const
    Definition: process.cpp:321
    +
    const Handle & get_handle() const
    Definition: process.hpp:89
    +
    void wait() const
    Definition: process.cpp:301
    +
    int get_exit_code() const
    Definition: process.cpp:326
    +
    static Process open(ID id, DWORD permissions=default_permissions())
    Definition: process.cpp:269
    +
    static Resource get_resource(uint32_t id)
    Definition: process.cpp:370
    +
    static Process current()
    Definition: process.cpp:265
    +
    static DWORD read_permissions()
    Definition: process.cpp:281
    +
    static DWORD default_permissions()
    Definition: process.cpp:277
    +
    bool is_running() const
    Definition: process.cpp:285
    +
    static Process create(ProcessParameters)
    Definition: process.cpp:241
    +
    std::string get_exe_path() const
    Definition: process.cpp:342
    +
    ID get_id() const
    Definition: process.hpp:87
    +
    static Process shell(const ShellParameters &)
    Definition: process.cpp:256
    +
    static std::string get_resource_string(uint32_t id)
    Definition: process.cpp:358
    +
    static Process open_r(ID)
    Definition: process.cpp:273
    +
    Process parameters for Process::create().
    Definition: process.hpp:24
    +
    Resources embedded in a PE (Portable Executable).
    Definition: resource.hpp:15
    +
    Process parameters for Process::shell().
    Definition: process.hpp:39
    +
    Child process IO settings.
    Definition: process_io.hpp:61
    +
    + + + + diff --git a/process__io_8cpp_source.html b/process__io_8cpp_source.html new file mode 100644 index 0000000..8890791 --- /dev/null +++ b/process__io_8cpp_source.html @@ -0,0 +1,143 @@ + + + + + + + +winapi_common: src/process_io.cpp Source File + + + + + + + + + +
    +
    + + + + + + +
    +
    winapi_common +
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    +
    +
    process_io.cpp
    +
    +
    +
    1 // Copyright (c) 2020 Egor Tensin <Egor.Tensin@gmail.com>
    +
    2 // This file is part of the "winapi-common" project.
    +
    3 // For details, see https://github.com/egor-tensin/winapi-common.
    +
    4 // Distributed under the MIT License.
    +
    5 
    +
    6 #include <winapi/file.hpp>
    +
    7 #include <winapi/handle.hpp>
    +
    8 #include <winapi/path.hpp>
    +
    9 #include <winapi/process_io.hpp>
    +
    10 
    +
    11 #include <string>
    +
    12 #include <utility>
    +
    13 
    +
    14 namespace winapi {
    +
    15 namespace process {
    +
    16 
    +
    17 Stdin::Stdin() : Stream{Handle::std_in()} {}
    +
    18 
    +
    19 Stdout::Stdout() : Stream{Handle::std_out()} {}
    +
    20 
    +
    21 Stderr::Stderr() : Stream{Handle::std_err()} {}
    +
    22 
    +
    23 Stdin::Stdin(const std::string& path) : Stream{File::open_r(path)} {}
    +
    24 
    +
    25 Stdin::Stdin(const CanonicalPath& path) : Stream{File::open_r(path)} {}
    +
    26 
    +
    27 Stdout::Stdout(const std::string& path) : Stream{File::open_w(path)} {}
    +
    28 
    +
    29 Stdout::Stdout(const CanonicalPath& path) : Stream{File::open_w(path)} {}
    +
    30 
    +
    31 Stderr::Stderr(const std::string& path) : Stream{File::open_w(path)} {}
    +
    32 
    +
    33 Stderr::Stderr(const CanonicalPath& path) : Stream{File::open_w(path)} {}
    +
    34 
    +
    35 Stdin::Stdin(Pipe& pipe) : Stream{std::move(pipe.read_end())} {
    +
    36  pipe.write_end().dont_inherit();
    +
    37 }
    +
    38 
    +
    39 Stdout::Stdout(Pipe& pipe) : Stream{std::move(pipe.write_end())} {
    +
    40  pipe.read_end().dont_inherit();
    +
    41 }
    +
    42 
    +
    43 Stderr::Stderr(Pipe& pipe) : Stream{std::move(pipe.write_end())} {
    +
    44  pipe.read_end().dont_inherit();
    +
    45 }
    +
    46 
    +
    47 void IO::close() {
    +
    48  std_in.handle.close();
    +
    49  std_out.handle.close();
    +
    50  std_err.handle.close();
    +
    51 }
    +
    52 
    +
    53 } // namespace process
    +
    54 } // namespace winapi
    +
    Absolute, canonical path.
    Definition: path.hpp:13
    +
    File I/O.
    Definition: file.hpp:29
    +
    HANDLE wrapper.
    Definition: handle.hpp:25
    +
    void close()
    Definition: handle.cpp:47
    +
    Anonymous pipe wrapper.
    Definition: pipe.hpp:15
    +
    Handle & read_end()
    Definition: pipe.hpp:21
    +
    Handle & write_end()
    Definition: pipe.hpp:25
    + + + + +
    + + + + diff --git a/process__io_8hpp_source.html b/process__io_8hpp_source.html new file mode 100644 index 0000000..a7dc74b --- /dev/null +++ b/process__io_8hpp_source.html @@ -0,0 +1,145 @@ + + + + + + + +winapi_common: include/winapi/process_io.hpp Source File + + + + + + + + + +
    +
    + + + + + + +
    +
    winapi_common +
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    +
    +
    process_io.hpp
    +
    +
    +
    1 // Copyright (c) 2020 Egor Tensin <Egor.Tensin@gmail.com>
    +
    2 // This file is part of the "winapi-common" project.
    +
    3 // For details, see https://github.com/egor-tensin/winapi-common.
    +
    4 // Distributed under the MIT License.
    +
    5 
    +
    6 #pragma once
    +
    7 
    +
    8 #include "handle.hpp"
    +
    9 #include "path.hpp"
    +
    10 #include "pipe.hpp"
    +
    11 
    +
    12 #include <string>
    +
    13 #include <utility>
    +
    14 
    +
    15 namespace winapi {
    +
    16 namespace process {
    +
    17 
    +
    18 struct Stream {
    +
    19  Stream(Handle&& handle) : handle{std::move(handle)} {}
    +
    20 
    +
    21  Handle handle;
    +
    22 };
    +
    23 
    +
    25 struct Stdin : Stream {
    +
    27  Stdin();
    +
    29  explicit Stdin(const std::string& file);
    +
    31  explicit Stdin(const CanonicalPath& file);
    +
    33  explicit Stdin(Pipe&);
    +
    34 };
    +
    35 
    +
    37 struct Stdout : Stream {
    +
    39  Stdout();
    +
    41  explicit Stdout(const std::string& file);
    +
    43  explicit Stdout(const CanonicalPath& file);
    +
    45  explicit Stdout(Pipe&);
    +
    46 };
    +
    47 
    +
    49 struct Stderr : Stream {
    +
    51  Stderr();
    +
    53  explicit Stderr(const std::string& file);
    +
    55  explicit Stderr(const CanonicalPath& file);
    +
    57  explicit Stderr(Pipe&);
    +
    58 };
    +
    59 
    +
    61 struct IO {
    +
    62  IO() = default;
    +
    63 
    +
    64  void close();
    +
    65 
    +
    66  Stdin std_in;
    +
    67  Stdout std_out;
    +
    68  Stderr std_err;
    +
    69 };
    +
    70 
    +
    71 } // namespace process
    +
    72 } // namespace winapi
    +
    Absolute, canonical path.
    Definition: path.hpp:13
    +
    HANDLE wrapper.
    Definition: handle.hpp:25
    +
    Anonymous pipe wrapper.
    Definition: pipe.hpp:15
    +
    Child process IO settings.
    Definition: process_io.hpp:61
    +
    Redirect child process's stderr.
    Definition: process_io.hpp:49
    + +
    Redirect child process's stdin.
    Definition: process_io.hpp:25
    + +
    Redirect child process's stdout.
    Definition: process_io.hpp:37
    + + +
    + + + + diff --git a/resource_8hpp_source.html b/resource_8hpp_source.html new file mode 100644 index 0000000..ca1bcbb --- /dev/null +++ b/resource_8hpp_source.html @@ -0,0 +1,108 @@ + + + + + + + +winapi_common: include/winapi/resource.hpp Source File + + + + + + + + + +
    +
    + + + + + + +
    +
    winapi_common +
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    +
    +
    resource.hpp
    +
    +
    +
    1 // Copyright (c) 2020 Egor Tensin <Egor.Tensin@gmail.com>
    +
    2 // This file is part of the "winapi-common" project.
    +
    3 // For details, see https://github.com/egor-tensin/winapi-common.
    +
    4 // Distributed under the MIT License.
    +
    5 
    +
    6 #pragma once
    +
    7 
    +
    8 #include "buffer.hpp"
    +
    9 
    +
    10 #include <cstddef>
    +
    11 
    +
    12 namespace winapi {
    +
    13 
    +
    15 struct Resource {
    +
    16  // This is just a pointer to static data.
    +
    17 
    +
    18  Resource() = default;
    +
    19 
    +
    20  Resource(const void* data, std::size_t nb) : data{data}, nb{nb} {}
    +
    21 
    +
    23  Buffer copy() const { return {data, nb}; }
    +
    24 
    +
    25  const void* data = nullptr;
    +
    26  std::size_t nb = 0;
    +
    27 };
    +
    28 
    +
    29 } // namespace winapi
    +
    Binary data container.
    Definition: buffer.hpp:24
    +
    Resources embedded in a PE (Portable Executable).
    Definition: resource.hpp:15
    +
    Buffer copy() const
    Definition: resource.hpp:23
    +
    + + + + diff --git a/search/all_0.html b/search/all_0.html new file mode 100644 index 0000000..1ec5b2d --- /dev/null +++ b/search/all_0.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/all_0.js b/search/all_0.js new file mode 100644 index 0000000..985f4a0 --- /dev/null +++ b/search/all_0.js @@ -0,0 +1,7 @@ +var searchData= +[ + ['add_0',['add',['../classwinapi_1_1Buffer.html#a303645b281fb4f1a4d9e84f1d1370182',1,'winapi::Buffer']]], + ['args_5fto_5fstring_1',['args_to_string',['../classwinapi_1_1CommandLine.html#afb35d8d6d2b8b66bd6f21d0adc37017f',1,'winapi::CommandLine']]], + ['as_5futf16_2',['as_utf16',['../classwinapi_1_1Buffer.html#ac5ca93f1935f2259db0d68e1884897d5',1,'winapi::Buffer']]], + ['as_5futf8_3',['as_utf8',['../classwinapi_1_1Buffer.html#afd8abcecacbcc9fdb4e5825068ebf561',1,'winapi::Buffer']]] +]; diff --git a/search/all_1.html b/search/all_1.html new file mode 100644 index 0000000..9f80e90 --- /dev/null +++ b/search/all_1.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/all_1.js b/search/all_1.js new file mode 100644 index 0000000..5a78cb8 --- /dev/null +++ b/search/all_1.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['buffer_4',['Buffer',['../classwinapi_1_1Buffer.html#abb43686e0f2e5798bc7b2c0e47722458',1,'winapi::Buffer::Buffer(std::initializer_list< unsigned char > lst)'],['../classwinapi_1_1Buffer.html#a46241e1fd3443c383c3930329ca9e0dd',1,'winapi::Buffer::Buffer(Parent &&src)'],['../classwinapi_1_1Buffer.html#aa3566a7ac7025a2f88abe116082b55a7',1,'winapi::Buffer::Buffer(const std::basic_string< CharT > &src)'],['../classwinapi_1_1Buffer.html#ab3649ebbd0cbc4b20d02b660a52be89c',1,'winapi::Buffer::Buffer(const void *src, std::size_t nb)'],['../classwinapi_1_1Buffer.html',1,'winapi::Buffer']]] +]; diff --git a/search/all_10.html b/search/all_10.html new file mode 100644 index 0000000..3bf1196 --- /dev/null +++ b/search/all_10.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/all_10.js b/search/all_10.js new file mode 100644 index 0000000..1edfaf2 --- /dev/null +++ b/search/all_10.js @@ -0,0 +1,8 @@ +var searchData= +[ + ['wait_69',['wait',['../classwinapi_1_1Process.html#a273dcbc8cd69539d0f9fd4d1e09e67a7',1,'winapi::Process']]], + ['winapi_2dcommon_70',['winapi-common',['../index.html',1,'']]], + ['windows_71',['windows',['../error_8hpp.html#a70c25be1dfd40860d125203f27e664ce',1,'winapi::error']]], + ['write_72',['write',['../classwinapi_1_1Handle.html#afbfe1b7de229eb5656504e05acf9bbcc',1,'winapi::Handle::write(const void *data, std::size_t nb) const'],['../classwinapi_1_1Handle.html#aee2ff37831d686a8140403c10d7ebadd',1,'winapi::Handle::write(const Buffer &buffer) const'],['../classwinapi_1_1Handle.html#ab78fab4796ef5ec3f9576f19b54cfd04',1,'winapi::Handle::write(const std::basic_string< CharT > &src) const']]], + ['write_5fend_73',['write_end',['../classwinapi_1_1Pipe.html#a19e504588020c68639154ed597151cd6',1,'winapi::Pipe::write_end()'],['../classwinapi_1_1Pipe.html#ad010465685f521c17bd4b6731ed00e00',1,'winapi::Pipe::write_end() const']]] +]; diff --git a/search/all_2.html b/search/all_2.html new file mode 100644 index 0000000..02cfffc --- /dev/null +++ b/search/all_2.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/all_2.js b/search/all_2.js new file mode 100644 index 0000000..7d37183 --- /dev/null +++ b/search/all_2.js @@ -0,0 +1,11 @@ +var searchData= +[ + ['canonicalize_5',['canonicalize',['../classwinapi_1_1CanonicalPath.html#a7072d3b77d4f437246744c9c2a9407db',1,'winapi::CanonicalPath']]], + ['canonicalpath_6',['CanonicalPath',['../classwinapi_1_1CanonicalPath.html',1,'winapi']]], + ['categorywindows_7',['CategoryWindows',['../classwinapi_1_1error_1_1CategoryWindows.html',1,'winapi::error']]], + ['close_8',['close',['../classwinapi_1_1Handle.html#a6f28cc73ae2e3e447251cef0160e3555',1,'winapi::Handle']]], + ['commandline_9',['CommandLine',['../classwinapi_1_1CommandLine.html#ad48bb83391e84db28c3c3c6bdf283003',1,'winapi::CommandLine::CommandLine()=default'],['../classwinapi_1_1CommandLine.html#a90b5d19b9cb4bbad2515c97bd74731c8',1,'winapi::CommandLine::CommandLine(const std::string &argv0, const std::vector< std::string > &args={})'],['../classwinapi_1_1CommandLine.html#ac0d211d82fd55cba2055a9679272a182',1,'winapi::CommandLine::CommandLine(std::string &&argv0, std::vector< std::string > &&args={})'],['../classwinapi_1_1CommandLine.html#a69e5c796f37637e39b2e1d7d95ba922a',1,'winapi::CommandLine::CommandLine(std::vector< std::string > argv)'],['../classwinapi_1_1CommandLine.html',1,'winapi::CommandLine']]], + ['copy_10',['copy',['../structwinapi_1_1Resource.html#ac3bf07d20d3ce6705693ae7a86eb565d',1,'winapi::Resource']]], + ['create_11',['create',['../classwinapi_1_1Process.html#a6ef0ce275ef09ed6ef1e115afeee7e6a',1,'winapi::Process::create(ProcessParameters)'],['../classwinapi_1_1Process.html#ac4eaeb85aa25acec5e4421e1239f315f',1,'winapi::Process::create(const CommandLine &)'],['../classwinapi_1_1Process.html#a16be6c3dc62d500ca8924b359e5193cc',1,'winapi::Process::create(const CommandLine &, process::IO)'],['../classwinapi_1_1SharedMemory.html#a475d4dcdf99d777cb0968d7631cc6f7e',1,'winapi::SharedMemory::create()'],['../classwinapi_1_1SharedObject.html#acb4ef5283256d7463fe81c8b312b6745',1,'winapi::SharedObject::create()']]], + ['current_12',['current',['../classwinapi_1_1Process.html#a4edc58e78ee81e5531af34fc4f806e24',1,'winapi::Process']]] +]; diff --git a/search/all_3.html b/search/all_3.html new file mode 100644 index 0000000..39767b8 --- /dev/null +++ b/search/all_3.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/all_3.js b/search/all_3.js new file mode 100644 index 0000000..a270dc5 --- /dev/null +++ b/search/all_3.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['default_5fpermissions_13',['default_permissions',['../classwinapi_1_1Process.html#a4fffc3755642f3db56902106f1b96040',1,'winapi::Process']]] +]; diff --git a/search/all_4.html b/search/all_4.html new file mode 100644 index 0000000..fc40463 --- /dev/null +++ b/search/all_4.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/all_4.js b/search/all_4.js new file mode 100644 index 0000000..19293a8 --- /dev/null +++ b/search/all_4.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['error_2ehpp_14',['error.hpp',['../error_8hpp.html',1,'']]] +]; diff --git a/search/all_5.html b/search/all_5.html new file mode 100644 index 0000000..9dd9344 --- /dev/null +++ b/search/all_5.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/all_5.js b/search/all_5.js new file mode 100644 index 0000000..bdd029e --- /dev/null +++ b/search/all_5.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['file_15',['File',['../classwinapi_1_1File.html#a4ae67aba44ba64654b888ace9b7dfb36',1,'winapi::File::File()'],['../classwinapi_1_1File.html',1,'winapi::File']]], + ['from_5fmain_16',['from_main',['../classwinapi_1_1CommandLine.html#a7a7bc2a7461f2f275a12c9fda23d312d',1,'winapi::CommandLine']]] +]; diff --git a/search/all_6.html b/search/all_6.html new file mode 100644 index 0000000..f1e516d --- /dev/null +++ b/search/all_6.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/all_6.js b/search/all_6.js new file mode 100644 index 0000000..209259e --- /dev/null +++ b/search/all_6.js @@ -0,0 +1,14 @@ +var searchData= +[ + ['get_17',['get',['../classwinapi_1_1SharedMemory.html#ada3f0075608dd1541f54f004e18a4775',1,'winapi::SharedMemory::get()'],['../classwinapi_1_1SharedObject.html#a85d0943708ab0da78e1a189b1bbbd1eb',1,'winapi::SharedObject::get()']]], + ['get_5fargs_18',['get_args',['../classwinapi_1_1CommandLine.html#aef5ea9b427d975af8e64948802b54af4',1,'winapi::CommandLine']]], + ['get_5fargv_19',['get_argv',['../classwinapi_1_1CommandLine.html#ac21d30a214f529f80b91186e9724cf41',1,'winapi::CommandLine']]], + ['get_5fargv0_20',['get_argv0',['../classwinapi_1_1CommandLine.html#a8f75a5f374397c1c1dcc4900bf44ee32',1,'winapi::CommandLine']]], + ['get_5fexe_5fpath_21',['get_exe_path',['../classwinapi_1_1Process.html#a86cea0dd87e63ef93f6575d601ab31f5',1,'winapi::Process']]], + ['get_5fexit_5fcode_22',['get_exit_code',['../classwinapi_1_1Process.html#a359c11337c7e50370cd5375efa841131',1,'winapi::Process']]], + ['get_5fhandle_23',['get_handle',['../classwinapi_1_1Process.html#a1b65a0f6dc25c1810161f2c5c9648249',1,'winapi::Process']]], + ['get_5fid_24',['get_id',['../classwinapi_1_1Process.html#aa44a8ca82178dfedd68865e4e47f7584',1,'winapi::Process']]], + ['get_5fresource_25',['get_resource',['../classwinapi_1_1Process.html#a4ddbc4be71879ea7f91b05ad7f44435c',1,'winapi::Process']]], + ['get_5fresource_5fstring_26',['get_resource_string',['../classwinapi_1_1Process.html#ac700bc836a720384bed52a032628aaeb',1,'winapi::Process']]], + ['get_5fsize_27',['get_size',['../classwinapi_1_1File.html#ad3c43351e4c032caa78525fc15e64ca7',1,'winapi::File']]] +]; diff --git a/search/all_7.html b/search/all_7.html new file mode 100644 index 0000000..8ddbf6c --- /dev/null +++ b/search/all_7.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/all_7.js b/search/all_7.js new file mode 100644 index 0000000..99b4d91 --- /dev/null +++ b/search/all_7.js @@ -0,0 +1,6 @@ +var searchData= +[ + ['handle_28',['Handle',['../classwinapi_1_1Handle.html',1,'winapi']]], + ['has_5fargs_29',['has_args',['../classwinapi_1_1CommandLine.html#ae87fa727498660661753d2d456873033',1,'winapi::CommandLine']]], + ['hash_3c_20winapi_3a_3afile_3a_3aid_20_3e_30',['hash< winapi::File::ID >',['../structstd_1_1hash_3_01winapi_1_1File_1_1ID_01_4.html',1,'std']]] +]; diff --git a/search/all_8.html b/search/all_8.html new file mode 100644 index 0000000..83c55ae --- /dev/null +++ b/search/all_8.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/all_8.js b/search/all_8.js new file mode 100644 index 0000000..881113a --- /dev/null +++ b/search/all_8.js @@ -0,0 +1,7 @@ +var searchData= +[ + ['id_31',['ID',['../structwinapi_1_1File_1_1ID.html',1,'winapi::File']]], + ['io_32',['IO',['../structwinapi_1_1process_1_1IO.html',1,'winapi::process']]], + ['is_5frunning_33',['is_running',['../classwinapi_1_1Process.html#a5b02393edb57bd902e321037133c40eb',1,'winapi::Process']]], + ['is_5fstd_34',['is_std',['../classwinapi_1_1Handle.html#acc001a0f466d9c92cf7f2ef62896afc5',1,'winapi::Handle']]] +]; diff --git a/search/all_9.html b/search/all_9.html new file mode 100644 index 0000000..1e263c1 --- /dev/null +++ b/search/all_9.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/all_9.js b/search/all_9.js new file mode 100644 index 0000000..6f0715a --- /dev/null +++ b/search/all_9.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['localdelete_35',['LocalDelete',['../structwinapi_1_1LocalDelete.html',1,'winapi']]] +]; diff --git a/search/all_a.html b/search/all_a.html new file mode 100644 index 0000000..3a6cac1 --- /dev/null +++ b/search/all_a.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/all_a.js b/search/all_a.js new file mode 100644 index 0000000..7c63c94 --- /dev/null +++ b/search/all_a.js @@ -0,0 +1,7 @@ +var searchData= +[ + ['open_36',['open',['../classwinapi_1_1Process.html#a48964bbb7968bd7b6796e8a3306d58d9',1,'winapi::Process::open()'],['../classwinapi_1_1SharedMemory.html#a82eafb0e7c2c6b5af1a7ff8945af2027',1,'winapi::SharedMemory::open()'],['../classwinapi_1_1SharedObject.html#a08fda6ddde26e0a10170efaf07232761',1,'winapi::SharedObject::open()']]], + ['open_5fr_37',['open_r',['../classwinapi_1_1File.html#ad3bacd22beea28dcb0a0df846b5c4215',1,'winapi::File::open_r(const std::string &)'],['../classwinapi_1_1File.html#aaa308b06a55f992f71e76f9e7a629647',1,'winapi::File::open_r(const CanonicalPath &)'],['../classwinapi_1_1Process.html#af9d748078299957519ee67fd7f1e49b3',1,'winapi::Process::open_r()']]], + ['open_5fread_5fattributes_38',['open_read_attributes',['../classwinapi_1_1File.html#a7d7eeb56c9f33f6ec1814472c61e51f4',1,'winapi::File::open_read_attributes(const std::string &)'],['../classwinapi_1_1File.html#aecba0e33d05893021f93a2348aeefa34',1,'winapi::File::open_read_attributes(const CanonicalPath &)']]], + ['open_5fw_39',['open_w',['../classwinapi_1_1File.html#a36cda85b326592d7eadca5dc4a6b7981',1,'winapi::File::open_w(const std::string &)'],['../classwinapi_1_1File.html#a53bc6b8de007c630ac84d6519a520111',1,'winapi::File::open_w(const CanonicalPath &)']]] +]; diff --git a/search/all_b.html b/search/all_b.html new file mode 100644 index 0000000..130deb4 --- /dev/null +++ b/search/all_b.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/all_b.js b/search/all_b.js new file mode 100644 index 0000000..ff248a5 --- /dev/null +++ b/search/all_b.js @@ -0,0 +1,8 @@ +var searchData= +[ + ['parse_40',['parse',['../classwinapi_1_1CommandLine.html#aabafd2d1d923c30c3da372909857e87e',1,'winapi::CommandLine']]], + ['pipe_41',['Pipe',['../classwinapi_1_1Pipe.html#aa41a6275dab93f4fc0d2e593aa9b39f0',1,'winapi::Pipe::Pipe()'],['../classwinapi_1_1Pipe.html',1,'winapi::Pipe']]], + ['process_42',['Process',['../classwinapi_1_1Process.html',1,'winapi']]], + ['processparameters_43',['ProcessParameters',['../structwinapi_1_1ProcessParameters.html',1,'winapi']]], + ['ptr_44',['ptr',['../classwinapi_1_1SharedMemory.html#a44e75ba35ae3e470fb521f6274991673',1,'winapi::SharedMemory::ptr()'],['../classwinapi_1_1SharedObject.html#a0dfaad2c143d60af8dc6c010a13d513a',1,'winapi::SharedObject::ptr()']]] +]; diff --git a/search/all_c.html b/search/all_c.html new file mode 100644 index 0000000..3dd5af0 --- /dev/null +++ b/search/all_c.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/all_c.js b/search/all_c.js new file mode 100644 index 0000000..9369c55 --- /dev/null +++ b/search/all_c.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['query_45',['query',['../classwinapi_1_1CommandLine.html#aa07ee7bf5d61658f33e4a7571205ae5c',1,'winapi::CommandLine']]], + ['query_5fid_46',['query_id',['../classwinapi_1_1File.html#aed36137d5b730166cfec4e0f8a5a6fdd',1,'winapi::File']]] +]; diff --git a/search/all_d.html b/search/all_d.html new file mode 100644 index 0000000..af7f2f0 --- /dev/null +++ b/search/all_d.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/all_d.js b/search/all_d.js new file mode 100644 index 0000000..5cba3be --- /dev/null +++ b/search/all_d.js @@ -0,0 +1,9 @@ +var searchData= +[ + ['read_47',['read',['../classwinapi_1_1Handle.html#ae340b095569654f8b709614f23577f2e',1,'winapi::Handle']]], + ['read_5fchunk_48',['read_chunk',['../classwinapi_1_1Handle.html#a31c8440493e29cdd9b6fc40ffe8c06f1',1,'winapi::Handle']]], + ['read_5fend_49',['read_end',['../classwinapi_1_1Pipe.html#a07412b04db253f1c24fe4aeda5db82e1',1,'winapi::Pipe::read_end()'],['../classwinapi_1_1Pipe.html#afc45a1f2a5cdee7bbe4f73dd62d667ac',1,'winapi::Pipe::read_end() const']]], + ['read_5fpermissions_50',['read_permissions',['../classwinapi_1_1Process.html#a4fc3ed404c1cf67dabb7867d0c9f638c',1,'winapi::Process']]], + ['remove_51',['remove',['../classwinapi_1_1File.html#a453828fe42006bc7b6e925c41d1e965e',1,'winapi::File::remove(const std::string &)'],['../classwinapi_1_1File.html#a7aa6987387481fc3b2fc5187b0563e97',1,'winapi::File::remove(const CanonicalPath &)']]], + ['resource_52',['Resource',['../structwinapi_1_1Resource.html',1,'winapi']]] +]; diff --git a/search/all_e.html b/search/all_e.html new file mode 100644 index 0000000..e25df42 --- /dev/null +++ b/search/all_e.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/all_e.js b/search/all_e.js new file mode 100644 index 0000000..7fdaf12 --- /dev/null +++ b/search/all_e.js @@ -0,0 +1,17 @@ +var searchData= +[ + ['set_53',['set',['../classwinapi_1_1Buffer.html#a0b2fad438202fbcfd4946baf3f879f59',1,'winapi::Buffer::set(const std::basic_string< CharT > &src)'],['../classwinapi_1_1Buffer.html#ab09aa9c5075579510da463b4148ee610',1,'winapi::Buffer::set(const void *src, std::size_t nb)']]], + ['sharedmemory_54',['SharedMemory',['../classwinapi_1_1SharedMemory.html',1,'winapi']]], + ['sharedobject_55',['SharedObject',['../classwinapi_1_1SharedObject.html',1,'winapi']]], + ['shell_56',['shell',['../classwinapi_1_1Process.html#a24e1cbd68bc2dda73220b840979a84b0',1,'winapi::Process::shell(const CommandLine &)'],['../classwinapi_1_1Process.html#aa9f7cbc9b0e5530f0746606aacc5584e',1,'winapi::Process::shell(const ShellParameters &)']]], + ['shellparameters_57',['ShellParameters',['../structwinapi_1_1ShellParameters.html',1,'winapi']]], + ['shut_5fdown_58',['shut_down',['../classwinapi_1_1Process.html#a1aedc4814dd9c154b6e03e572d873755',1,'winapi::Process']]], + ['sid_59',['Sid',['../classwinapi_1_1Sid.html',1,'winapi']]], + ['std_5ferr_60',['std_err',['../classwinapi_1_1Handle.html#a894d880e1241c9516889a7a63a0c1750',1,'winapi::Handle']]], + ['std_5fin_61',['std_in',['../classwinapi_1_1Handle.html#a1817fdf127291cf5f47d6429d8f468cd',1,'winapi::Handle']]], + ['std_5fout_62',['std_out',['../classwinapi_1_1Handle.html#a76e96327afd0b943d996c90289f2883e',1,'winapi::Handle']]], + ['stderr_63',['Stderr',['../structwinapi_1_1process_1_1Stderr.html#aefbbae355c05c41f177ed5c3f769809c',1,'winapi::process::Stderr::Stderr()'],['../structwinapi_1_1process_1_1Stderr.html#a9906ac147b47c7e7b8a299e942cb77c5',1,'winapi::process::Stderr::Stderr(const std::string &file)'],['../structwinapi_1_1process_1_1Stderr.html#a1daa6ec6ad6b30d9958b2ee76f086230',1,'winapi::process::Stderr::Stderr(const CanonicalPath &file)'],['../structwinapi_1_1process_1_1Stderr.html#a0fca971e15b205e971a18c206d1c8003',1,'winapi::process::Stderr::Stderr(Pipe &)'],['../structwinapi_1_1process_1_1Stderr.html',1,'winapi::process::Stderr']]], + ['stdin_64',['Stdin',['../structwinapi_1_1process_1_1Stdin.html#ab551f076d049c58b5391847ec0fe8999',1,'winapi::process::Stdin::Stdin()'],['../structwinapi_1_1process_1_1Stdin.html#a68803e010fad2a3634c031bc14a0d857',1,'winapi::process::Stdin::Stdin(const std::string &file)'],['../structwinapi_1_1process_1_1Stdin.html#a77e20c39f33a6b8e8ffffa8972c924a7',1,'winapi::process::Stdin::Stdin(const CanonicalPath &file)'],['../structwinapi_1_1process_1_1Stdin.html#afc350d91445057721b1d87a4e759da4e',1,'winapi::process::Stdin::Stdin(Pipe &)'],['../structwinapi_1_1process_1_1Stdin.html',1,'winapi::process::Stdin']]], + ['stdout_65',['Stdout',['../structwinapi_1_1process_1_1Stdout.html#afa84e724674b234d395c766b3d04582d',1,'winapi::process::Stdout::Stdout(Pipe &)'],['../structwinapi_1_1process_1_1Stdout.html#ab70d4bff6f55c51fec06efdaa4fcdb81',1,'winapi::process::Stdout::Stdout(const CanonicalPath &file)'],['../structwinapi_1_1process_1_1Stdout.html#a7319a44d66f5c109bea89a04ca4c4ba2',1,'winapi::process::Stdout::Stdout(const std::string &file)'],['../structwinapi_1_1process_1_1Stdout.html#a1afc245b79c17e05bee9931f347a34e5',1,'winapi::process::Stdout::Stdout()'],['../structwinapi_1_1process_1_1Stdout.html',1,'winapi::process::Stdout']]], + ['stream_66',['Stream',['../structwinapi_1_1process_1_1Stream.html',1,'winapi::process']]] +]; diff --git a/search/all_f.html b/search/all_f.html new file mode 100644 index 0000000..b23da6c --- /dev/null +++ b/search/all_f.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/all_f.js b/search/all_f.js new file mode 100644 index 0000000..125e527 --- /dev/null +++ b/search/all_f.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['terminate_67',['terminate',['../classwinapi_1_1Process.html#a155aefb272a151126fe2a65d583be880',1,'winapi::Process']]], + ['to_5fstring_68',['to_string',['../classwinapi_1_1CommandLine.html#ac47e738f255a85b3e0605d40c0124b24',1,'winapi::CommandLine']]] +]; diff --git a/search/classes_0.html b/search/classes_0.html new file mode 100644 index 0000000..af8159e --- /dev/null +++ b/search/classes_0.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/classes_0.js b/search/classes_0.js new file mode 100644 index 0000000..934d173 --- /dev/null +++ b/search/classes_0.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['buffer_74',['Buffer',['../classwinapi_1_1Buffer.html',1,'winapi']]] +]; diff --git a/search/classes_1.html b/search/classes_1.html new file mode 100644 index 0000000..576e916 --- /dev/null +++ b/search/classes_1.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/classes_1.js b/search/classes_1.js new file mode 100644 index 0000000..d98081f --- /dev/null +++ b/search/classes_1.js @@ -0,0 +1,6 @@ +var searchData= +[ + ['canonicalpath_75',['CanonicalPath',['../classwinapi_1_1CanonicalPath.html',1,'winapi']]], + ['categorywindows_76',['CategoryWindows',['../classwinapi_1_1error_1_1CategoryWindows.html',1,'winapi::error']]], + ['commandline_77',['CommandLine',['../classwinapi_1_1CommandLine.html',1,'winapi']]] +]; diff --git a/search/classes_2.html b/search/classes_2.html new file mode 100644 index 0000000..956405e --- /dev/null +++ b/search/classes_2.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/classes_2.js b/search/classes_2.js new file mode 100644 index 0000000..d7824b8 --- /dev/null +++ b/search/classes_2.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['file_78',['File',['../classwinapi_1_1File.html',1,'winapi']]] +]; diff --git a/search/classes_3.html b/search/classes_3.html new file mode 100644 index 0000000..d33343b --- /dev/null +++ b/search/classes_3.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/classes_3.js b/search/classes_3.js new file mode 100644 index 0000000..0c23547 --- /dev/null +++ b/search/classes_3.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['handle_79',['Handle',['../classwinapi_1_1Handle.html',1,'winapi']]], + ['hash_3c_20winapi_3a_3afile_3a_3aid_20_3e_80',['hash< winapi::File::ID >',['../structstd_1_1hash_3_01winapi_1_1File_1_1ID_01_4.html',1,'std']]] +]; diff --git a/search/classes_4.html b/search/classes_4.html new file mode 100644 index 0000000..8430b07 --- /dev/null +++ b/search/classes_4.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/classes_4.js b/search/classes_4.js new file mode 100644 index 0000000..31a1fdc --- /dev/null +++ b/search/classes_4.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['id_81',['ID',['../structwinapi_1_1File_1_1ID.html',1,'winapi::File']]], + ['io_82',['IO',['../structwinapi_1_1process_1_1IO.html',1,'winapi::process']]] +]; diff --git a/search/classes_5.html b/search/classes_5.html new file mode 100644 index 0000000..c2f1b76 --- /dev/null +++ b/search/classes_5.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/classes_5.js b/search/classes_5.js new file mode 100644 index 0000000..b61a065 --- /dev/null +++ b/search/classes_5.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['localdelete_83',['LocalDelete',['../structwinapi_1_1LocalDelete.html',1,'winapi']]] +]; diff --git a/search/classes_6.html b/search/classes_6.html new file mode 100644 index 0000000..e39847c --- /dev/null +++ b/search/classes_6.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/classes_6.js b/search/classes_6.js new file mode 100644 index 0000000..ab9a60d --- /dev/null +++ b/search/classes_6.js @@ -0,0 +1,6 @@ +var searchData= +[ + ['pipe_84',['Pipe',['../classwinapi_1_1Pipe.html',1,'winapi']]], + ['process_85',['Process',['../classwinapi_1_1Process.html',1,'winapi']]], + ['processparameters_86',['ProcessParameters',['../structwinapi_1_1ProcessParameters.html',1,'winapi']]] +]; diff --git a/search/classes_7.html b/search/classes_7.html new file mode 100644 index 0000000..a2c4d1a --- /dev/null +++ b/search/classes_7.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/classes_7.js b/search/classes_7.js new file mode 100644 index 0000000..5608448 --- /dev/null +++ b/search/classes_7.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['resource_87',['Resource',['../structwinapi_1_1Resource.html',1,'winapi']]] +]; diff --git a/search/classes_8.html b/search/classes_8.html new file mode 100644 index 0000000..17003e4 --- /dev/null +++ b/search/classes_8.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/classes_8.js b/search/classes_8.js new file mode 100644 index 0000000..2cb4e19 --- /dev/null +++ b/search/classes_8.js @@ -0,0 +1,11 @@ +var searchData= +[ + ['sharedmemory_88',['SharedMemory',['../classwinapi_1_1SharedMemory.html',1,'winapi']]], + ['sharedobject_89',['SharedObject',['../classwinapi_1_1SharedObject.html',1,'winapi']]], + ['shellparameters_90',['ShellParameters',['../structwinapi_1_1ShellParameters.html',1,'winapi']]], + ['sid_91',['Sid',['../classwinapi_1_1Sid.html',1,'winapi']]], + ['stderr_92',['Stderr',['../structwinapi_1_1process_1_1Stderr.html',1,'winapi::process']]], + ['stdin_93',['Stdin',['../structwinapi_1_1process_1_1Stdin.html',1,'winapi::process']]], + ['stdout_94',['Stdout',['../structwinapi_1_1process_1_1Stdout.html',1,'winapi::process']]], + ['stream_95',['Stream',['../structwinapi_1_1process_1_1Stream.html',1,'winapi::process']]] +]; diff --git a/search/close.svg b/search/close.svg new file mode 100644 index 0000000..a933eea --- /dev/null +++ b/search/close.svg @@ -0,0 +1,31 @@ + + + + + + image/svg+xml + + + + + + + + diff --git a/search/files_0.html b/search/files_0.html new file mode 100644 index 0000000..9498842 --- /dev/null +++ b/search/files_0.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/files_0.js b/search/files_0.js new file mode 100644 index 0000000..37bc924 --- /dev/null +++ b/search/files_0.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['error_2ehpp_96',['error.hpp',['../error_8hpp.html',1,'']]] +]; diff --git a/search/functions_0.html b/search/functions_0.html new file mode 100644 index 0000000..eb4c501 --- /dev/null +++ b/search/functions_0.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/functions_0.js b/search/functions_0.js new file mode 100644 index 0000000..c32ce48 --- /dev/null +++ b/search/functions_0.js @@ -0,0 +1,7 @@ +var searchData= +[ + ['add_97',['add',['../classwinapi_1_1Buffer.html#a303645b281fb4f1a4d9e84f1d1370182',1,'winapi::Buffer']]], + ['args_5fto_5fstring_98',['args_to_string',['../classwinapi_1_1CommandLine.html#afb35d8d6d2b8b66bd6f21d0adc37017f',1,'winapi::CommandLine']]], + ['as_5futf16_99',['as_utf16',['../classwinapi_1_1Buffer.html#ac5ca93f1935f2259db0d68e1884897d5',1,'winapi::Buffer']]], + ['as_5futf8_100',['as_utf8',['../classwinapi_1_1Buffer.html#afd8abcecacbcc9fdb4e5825068ebf561',1,'winapi::Buffer']]] +]; diff --git a/search/functions_1.html b/search/functions_1.html new file mode 100644 index 0000000..ef4088b --- /dev/null +++ b/search/functions_1.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/functions_1.js b/search/functions_1.js new file mode 100644 index 0000000..aedb5c3 --- /dev/null +++ b/search/functions_1.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['buffer_101',['Buffer',['../classwinapi_1_1Buffer.html#abb43686e0f2e5798bc7b2c0e47722458',1,'winapi::Buffer::Buffer(std::initializer_list< unsigned char > lst)'],['../classwinapi_1_1Buffer.html#a46241e1fd3443c383c3930329ca9e0dd',1,'winapi::Buffer::Buffer(Parent &&src)'],['../classwinapi_1_1Buffer.html#aa3566a7ac7025a2f88abe116082b55a7',1,'winapi::Buffer::Buffer(const std::basic_string< CharT > &src)'],['../classwinapi_1_1Buffer.html#ab3649ebbd0cbc4b20d02b660a52be89c',1,'winapi::Buffer::Buffer(const void *src, std::size_t nb)']]] +]; diff --git a/search/functions_2.html b/search/functions_2.html new file mode 100644 index 0000000..ca5aa10 --- /dev/null +++ b/search/functions_2.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/functions_2.js b/search/functions_2.js new file mode 100644 index 0000000..462cc29 --- /dev/null +++ b/search/functions_2.js @@ -0,0 +1,9 @@ +var searchData= +[ + ['canonicalize_102',['canonicalize',['../classwinapi_1_1CanonicalPath.html#a7072d3b77d4f437246744c9c2a9407db',1,'winapi::CanonicalPath']]], + ['close_103',['close',['../classwinapi_1_1Handle.html#a6f28cc73ae2e3e447251cef0160e3555',1,'winapi::Handle']]], + ['commandline_104',['CommandLine',['../classwinapi_1_1CommandLine.html#ad48bb83391e84db28c3c3c6bdf283003',1,'winapi::CommandLine::CommandLine()=default'],['../classwinapi_1_1CommandLine.html#a90b5d19b9cb4bbad2515c97bd74731c8',1,'winapi::CommandLine::CommandLine(const std::string &argv0, const std::vector< std::string > &args={})'],['../classwinapi_1_1CommandLine.html#ac0d211d82fd55cba2055a9679272a182',1,'winapi::CommandLine::CommandLine(std::string &&argv0, std::vector< std::string > &&args={})'],['../classwinapi_1_1CommandLine.html#a69e5c796f37637e39b2e1d7d95ba922a',1,'winapi::CommandLine::CommandLine(std::vector< std::string > argv)']]], + ['copy_105',['copy',['../structwinapi_1_1Resource.html#ac3bf07d20d3ce6705693ae7a86eb565d',1,'winapi::Resource']]], + ['create_106',['create',['../classwinapi_1_1Process.html#a6ef0ce275ef09ed6ef1e115afeee7e6a',1,'winapi::Process::create(ProcessParameters)'],['../classwinapi_1_1Process.html#ac4eaeb85aa25acec5e4421e1239f315f',1,'winapi::Process::create(const CommandLine &)'],['../classwinapi_1_1Process.html#a16be6c3dc62d500ca8924b359e5193cc',1,'winapi::Process::create(const CommandLine &, process::IO)'],['../classwinapi_1_1SharedMemory.html#a475d4dcdf99d777cb0968d7631cc6f7e',1,'winapi::SharedMemory::create()'],['../classwinapi_1_1SharedObject.html#acb4ef5283256d7463fe81c8b312b6745',1,'winapi::SharedObject::create()']]], + ['current_107',['current',['../classwinapi_1_1Process.html#a4edc58e78ee81e5531af34fc4f806e24',1,'winapi::Process']]] +]; diff --git a/search/functions_3.html b/search/functions_3.html new file mode 100644 index 0000000..d79f55b --- /dev/null +++ b/search/functions_3.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/functions_3.js b/search/functions_3.js new file mode 100644 index 0000000..90e14d9 --- /dev/null +++ b/search/functions_3.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['default_5fpermissions_108',['default_permissions',['../classwinapi_1_1Process.html#a4fffc3755642f3db56902106f1b96040',1,'winapi::Process']]] +]; diff --git a/search/functions_4.html b/search/functions_4.html new file mode 100644 index 0000000..1657cad --- /dev/null +++ b/search/functions_4.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/functions_4.js b/search/functions_4.js new file mode 100644 index 0000000..9c81509 --- /dev/null +++ b/search/functions_4.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['file_109',['File',['../classwinapi_1_1File.html#a4ae67aba44ba64654b888ace9b7dfb36',1,'winapi::File']]], + ['from_5fmain_110',['from_main',['../classwinapi_1_1CommandLine.html#a7a7bc2a7461f2f275a12c9fda23d312d',1,'winapi::CommandLine']]] +]; diff --git a/search/functions_5.html b/search/functions_5.html new file mode 100644 index 0000000..9301d6b --- /dev/null +++ b/search/functions_5.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/functions_5.js b/search/functions_5.js new file mode 100644 index 0000000..408d8b5 --- /dev/null +++ b/search/functions_5.js @@ -0,0 +1,14 @@ +var searchData= +[ + ['get_111',['get',['../classwinapi_1_1SharedMemory.html#ada3f0075608dd1541f54f004e18a4775',1,'winapi::SharedMemory::get()'],['../classwinapi_1_1SharedObject.html#a85d0943708ab0da78e1a189b1bbbd1eb',1,'winapi::SharedObject::get()']]], + ['get_5fargs_112',['get_args',['../classwinapi_1_1CommandLine.html#aef5ea9b427d975af8e64948802b54af4',1,'winapi::CommandLine']]], + ['get_5fargv_113',['get_argv',['../classwinapi_1_1CommandLine.html#ac21d30a214f529f80b91186e9724cf41',1,'winapi::CommandLine']]], + ['get_5fargv0_114',['get_argv0',['../classwinapi_1_1CommandLine.html#a8f75a5f374397c1c1dcc4900bf44ee32',1,'winapi::CommandLine']]], + ['get_5fexe_5fpath_115',['get_exe_path',['../classwinapi_1_1Process.html#a86cea0dd87e63ef93f6575d601ab31f5',1,'winapi::Process']]], + ['get_5fexit_5fcode_116',['get_exit_code',['../classwinapi_1_1Process.html#a359c11337c7e50370cd5375efa841131',1,'winapi::Process']]], + ['get_5fhandle_117',['get_handle',['../classwinapi_1_1Process.html#a1b65a0f6dc25c1810161f2c5c9648249',1,'winapi::Process']]], + ['get_5fid_118',['get_id',['../classwinapi_1_1Process.html#aa44a8ca82178dfedd68865e4e47f7584',1,'winapi::Process']]], + ['get_5fresource_119',['get_resource',['../classwinapi_1_1Process.html#a4ddbc4be71879ea7f91b05ad7f44435c',1,'winapi::Process']]], + ['get_5fresource_5fstring_120',['get_resource_string',['../classwinapi_1_1Process.html#ac700bc836a720384bed52a032628aaeb',1,'winapi::Process']]], + ['get_5fsize_121',['get_size',['../classwinapi_1_1File.html#ad3c43351e4c032caa78525fc15e64ca7',1,'winapi::File']]] +]; diff --git a/search/functions_6.html b/search/functions_6.html new file mode 100644 index 0000000..9c4f5fc --- /dev/null +++ b/search/functions_6.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/functions_6.js b/search/functions_6.js new file mode 100644 index 0000000..eddb4da --- /dev/null +++ b/search/functions_6.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['has_5fargs_122',['has_args',['../classwinapi_1_1CommandLine.html#ae87fa727498660661753d2d456873033',1,'winapi::CommandLine']]] +]; diff --git a/search/functions_7.html b/search/functions_7.html new file mode 100644 index 0000000..46b5c0f --- /dev/null +++ b/search/functions_7.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/functions_7.js b/search/functions_7.js new file mode 100644 index 0000000..a5698bc --- /dev/null +++ b/search/functions_7.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['is_5frunning_123',['is_running',['../classwinapi_1_1Process.html#a5b02393edb57bd902e321037133c40eb',1,'winapi::Process']]], + ['is_5fstd_124',['is_std',['../classwinapi_1_1Handle.html#acc001a0f466d9c92cf7f2ef62896afc5',1,'winapi::Handle']]] +]; diff --git a/search/functions_8.html b/search/functions_8.html new file mode 100644 index 0000000..31a1d95 --- /dev/null +++ b/search/functions_8.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/functions_8.js b/search/functions_8.js new file mode 100644 index 0000000..ebfa88a --- /dev/null +++ b/search/functions_8.js @@ -0,0 +1,7 @@ +var searchData= +[ + ['open_125',['open',['../classwinapi_1_1Process.html#a48964bbb7968bd7b6796e8a3306d58d9',1,'winapi::Process::open()'],['../classwinapi_1_1SharedMemory.html#a82eafb0e7c2c6b5af1a7ff8945af2027',1,'winapi::SharedMemory::open()'],['../classwinapi_1_1SharedObject.html#a08fda6ddde26e0a10170efaf07232761',1,'winapi::SharedObject::open()']]], + ['open_5fr_126',['open_r',['../classwinapi_1_1File.html#ad3bacd22beea28dcb0a0df846b5c4215',1,'winapi::File::open_r(const std::string &)'],['../classwinapi_1_1File.html#aaa308b06a55f992f71e76f9e7a629647',1,'winapi::File::open_r(const CanonicalPath &)'],['../classwinapi_1_1Process.html#af9d748078299957519ee67fd7f1e49b3',1,'winapi::Process::open_r()']]], + ['open_5fread_5fattributes_127',['open_read_attributes',['../classwinapi_1_1File.html#a7d7eeb56c9f33f6ec1814472c61e51f4',1,'winapi::File::open_read_attributes(const std::string &)'],['../classwinapi_1_1File.html#aecba0e33d05893021f93a2348aeefa34',1,'winapi::File::open_read_attributes(const CanonicalPath &)']]], + ['open_5fw_128',['open_w',['../classwinapi_1_1File.html#a36cda85b326592d7eadca5dc4a6b7981',1,'winapi::File::open_w(const std::string &)'],['../classwinapi_1_1File.html#a53bc6b8de007c630ac84d6519a520111',1,'winapi::File::open_w(const CanonicalPath &)']]] +]; diff --git a/search/functions_9.html b/search/functions_9.html new file mode 100644 index 0000000..9a8e429 --- /dev/null +++ b/search/functions_9.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/functions_9.js b/search/functions_9.js new file mode 100644 index 0000000..8ec2200 --- /dev/null +++ b/search/functions_9.js @@ -0,0 +1,6 @@ +var searchData= +[ + ['parse_129',['parse',['../classwinapi_1_1CommandLine.html#aabafd2d1d923c30c3da372909857e87e',1,'winapi::CommandLine']]], + ['pipe_130',['Pipe',['../classwinapi_1_1Pipe.html#aa41a6275dab93f4fc0d2e593aa9b39f0',1,'winapi::Pipe']]], + ['ptr_131',['ptr',['../classwinapi_1_1SharedMemory.html#a44e75ba35ae3e470fb521f6274991673',1,'winapi::SharedMemory::ptr()'],['../classwinapi_1_1SharedObject.html#a0dfaad2c143d60af8dc6c010a13d513a',1,'winapi::SharedObject::ptr()']]] +]; diff --git a/search/functions_a.html b/search/functions_a.html new file mode 100644 index 0000000..5ecc152 --- /dev/null +++ b/search/functions_a.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/functions_a.js b/search/functions_a.js new file mode 100644 index 0000000..12da348 --- /dev/null +++ b/search/functions_a.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['query_132',['query',['../classwinapi_1_1CommandLine.html#aa07ee7bf5d61658f33e4a7571205ae5c',1,'winapi::CommandLine']]], + ['query_5fid_133',['query_id',['../classwinapi_1_1File.html#aed36137d5b730166cfec4e0f8a5a6fdd',1,'winapi::File']]] +]; diff --git a/search/functions_b.html b/search/functions_b.html new file mode 100644 index 0000000..e301fed --- /dev/null +++ b/search/functions_b.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/functions_b.js b/search/functions_b.js new file mode 100644 index 0000000..e263748 --- /dev/null +++ b/search/functions_b.js @@ -0,0 +1,8 @@ +var searchData= +[ + ['read_134',['read',['../classwinapi_1_1Handle.html#ae340b095569654f8b709614f23577f2e',1,'winapi::Handle']]], + ['read_5fchunk_135',['read_chunk',['../classwinapi_1_1Handle.html#a31c8440493e29cdd9b6fc40ffe8c06f1',1,'winapi::Handle']]], + ['read_5fend_136',['read_end',['../classwinapi_1_1Pipe.html#a07412b04db253f1c24fe4aeda5db82e1',1,'winapi::Pipe::read_end()'],['../classwinapi_1_1Pipe.html#afc45a1f2a5cdee7bbe4f73dd62d667ac',1,'winapi::Pipe::read_end() const']]], + ['read_5fpermissions_137',['read_permissions',['../classwinapi_1_1Process.html#a4fc3ed404c1cf67dabb7867d0c9f638c',1,'winapi::Process']]], + ['remove_138',['remove',['../classwinapi_1_1File.html#a453828fe42006bc7b6e925c41d1e965e',1,'winapi::File::remove(const std::string &)'],['../classwinapi_1_1File.html#a7aa6987387481fc3b2fc5187b0563e97',1,'winapi::File::remove(const CanonicalPath &)']]] +]; diff --git a/search/functions_c.html b/search/functions_c.html new file mode 100644 index 0000000..c4f3268 --- /dev/null +++ b/search/functions_c.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/functions_c.js b/search/functions_c.js new file mode 100644 index 0000000..7e17b46 --- /dev/null +++ b/search/functions_c.js @@ -0,0 +1,12 @@ +var searchData= +[ + ['set_139',['set',['../classwinapi_1_1Buffer.html#ab09aa9c5075579510da463b4148ee610',1,'winapi::Buffer::set(const void *src, std::size_t nb)'],['../classwinapi_1_1Buffer.html#a0b2fad438202fbcfd4946baf3f879f59',1,'winapi::Buffer::set(const std::basic_string< CharT > &src)']]], + ['shell_140',['shell',['../classwinapi_1_1Process.html#aa9f7cbc9b0e5530f0746606aacc5584e',1,'winapi::Process::shell(const ShellParameters &)'],['../classwinapi_1_1Process.html#a24e1cbd68bc2dda73220b840979a84b0',1,'winapi::Process::shell(const CommandLine &)']]], + ['shut_5fdown_141',['shut_down',['../classwinapi_1_1Process.html#a1aedc4814dd9c154b6e03e572d873755',1,'winapi::Process']]], + ['std_5ferr_142',['std_err',['../classwinapi_1_1Handle.html#a894d880e1241c9516889a7a63a0c1750',1,'winapi::Handle']]], + ['std_5fin_143',['std_in',['../classwinapi_1_1Handle.html#a1817fdf127291cf5f47d6429d8f468cd',1,'winapi::Handle']]], + ['std_5fout_144',['std_out',['../classwinapi_1_1Handle.html#a76e96327afd0b943d996c90289f2883e',1,'winapi::Handle']]], + ['stderr_145',['Stderr',['../structwinapi_1_1process_1_1Stderr.html#a1daa6ec6ad6b30d9958b2ee76f086230',1,'winapi::process::Stderr::Stderr(const CanonicalPath &file)'],['../structwinapi_1_1process_1_1Stderr.html#a0fca971e15b205e971a18c206d1c8003',1,'winapi::process::Stderr::Stderr(Pipe &)'],['../structwinapi_1_1process_1_1Stderr.html#a9906ac147b47c7e7b8a299e942cb77c5',1,'winapi::process::Stderr::Stderr(const std::string &file)'],['../structwinapi_1_1process_1_1Stderr.html#aefbbae355c05c41f177ed5c3f769809c',1,'winapi::process::Stderr::Stderr()']]], + ['stdin_146',['Stdin',['../structwinapi_1_1process_1_1Stdin.html#ab551f076d049c58b5391847ec0fe8999',1,'winapi::process::Stdin::Stdin()'],['../structwinapi_1_1process_1_1Stdin.html#a68803e010fad2a3634c031bc14a0d857',1,'winapi::process::Stdin::Stdin(const std::string &file)'],['../structwinapi_1_1process_1_1Stdin.html#a77e20c39f33a6b8e8ffffa8972c924a7',1,'winapi::process::Stdin::Stdin(const CanonicalPath &file)'],['../structwinapi_1_1process_1_1Stdin.html#afc350d91445057721b1d87a4e759da4e',1,'winapi::process::Stdin::Stdin(Pipe &)']]], + ['stdout_147',['Stdout',['../structwinapi_1_1process_1_1Stdout.html#a1afc245b79c17e05bee9931f347a34e5',1,'winapi::process::Stdout::Stdout()'],['../structwinapi_1_1process_1_1Stdout.html#a7319a44d66f5c109bea89a04ca4c4ba2',1,'winapi::process::Stdout::Stdout(const std::string &file)'],['../structwinapi_1_1process_1_1Stdout.html#ab70d4bff6f55c51fec06efdaa4fcdb81',1,'winapi::process::Stdout::Stdout(const CanonicalPath &file)'],['../structwinapi_1_1process_1_1Stdout.html#afa84e724674b234d395c766b3d04582d',1,'winapi::process::Stdout::Stdout(Pipe &)']]] +]; diff --git a/search/functions_d.html b/search/functions_d.html new file mode 100644 index 0000000..7a1ed06 --- /dev/null +++ b/search/functions_d.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/functions_d.js b/search/functions_d.js new file mode 100644 index 0000000..69cba9d --- /dev/null +++ b/search/functions_d.js @@ -0,0 +1,5 @@ +var searchData= +[ + ['terminate_148',['terminate',['../classwinapi_1_1Process.html#a155aefb272a151126fe2a65d583be880',1,'winapi::Process']]], + ['to_5fstring_149',['to_string',['../classwinapi_1_1CommandLine.html#ac47e738f255a85b3e0605d40c0124b24',1,'winapi::CommandLine']]] +]; diff --git a/search/functions_e.html b/search/functions_e.html new file mode 100644 index 0000000..22d2a6b --- /dev/null +++ b/search/functions_e.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/functions_e.js b/search/functions_e.js new file mode 100644 index 0000000..2824e2c --- /dev/null +++ b/search/functions_e.js @@ -0,0 +1,7 @@ +var searchData= +[ + ['wait_150',['wait',['../classwinapi_1_1Process.html#a273dcbc8cd69539d0f9fd4d1e09e67a7',1,'winapi::Process']]], + ['windows_151',['windows',['../error_8hpp.html#a70c25be1dfd40860d125203f27e664ce',1,'winapi::error']]], + ['write_152',['write',['../classwinapi_1_1Handle.html#afbfe1b7de229eb5656504e05acf9bbcc',1,'winapi::Handle::write(const void *data, std::size_t nb) const'],['../classwinapi_1_1Handle.html#aee2ff37831d686a8140403c10d7ebadd',1,'winapi::Handle::write(const Buffer &buffer) const'],['../classwinapi_1_1Handle.html#ab78fab4796ef5ec3f9576f19b54cfd04',1,'winapi::Handle::write(const std::basic_string< CharT > &src) const']]], + ['write_5fend_153',['write_end',['../classwinapi_1_1Pipe.html#a19e504588020c68639154ed597151cd6',1,'winapi::Pipe::write_end()'],['../classwinapi_1_1Pipe.html#ad010465685f521c17bd4b6731ed00e00',1,'winapi::Pipe::write_end() const']]] +]; diff --git a/search/mag_sel.svg b/search/mag_sel.svg new file mode 100644 index 0000000..03626f6 --- /dev/null +++ b/search/mag_sel.svg @@ -0,0 +1,74 @@ + + + + + + + + image/svg+xml + + + + + + + + + + + diff --git a/search/nomatches.html b/search/nomatches.html new file mode 100644 index 0000000..2b9360b --- /dev/null +++ b/search/nomatches.html @@ -0,0 +1,13 @@ + + + + + + + + +
    +
    No Matches
    +
    + + diff --git a/search/pages_0.html b/search/pages_0.html new file mode 100644 index 0000000..8517b48 --- /dev/null +++ b/search/pages_0.html @@ -0,0 +1,37 @@ + + + + + + + + + + +
    +
    Loading...
    +
    + +
    Searching...
    +
    No Matches
    + +
    + + diff --git a/search/pages_0.js b/search/pages_0.js new file mode 100644 index 0000000..262bffa --- /dev/null +++ b/search/pages_0.js @@ -0,0 +1,4 @@ +var searchData= +[ + ['winapi_2dcommon_154',['winapi-common',['../index.html',1,'']]] +]; diff --git a/search/search.css b/search/search.css new file mode 100644 index 0000000..9074198 --- /dev/null +++ b/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/search/search.js b/search/search.js new file mode 100644 index 0000000..fb226f7 --- /dev/null +++ b/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 + + + + + + +winapi_common: src/shmem.cpp Source File + + + + + + + + + +
    +
    + + + + + + +
    +
    winapi_common +
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    +
    +
    shmem.cpp
    +
    +
    +
    1 // Copyright (c) 2020 Egor Tensin <Egor.Tensin@gmail.com>
    +
    2 // This file is part of the "winapi-common" project.
    +
    3 // For details, see https://github.com/egor-tensin/winapi-common.
    +
    4 // Distributed under the MIT License.
    +
    5 
    +
    6 #include <winapi/error.hpp>
    +
    7 #include <winapi/handle.hpp>
    +
    8 #include <winapi/shmem.hpp>
    +
    9 #include <winapi/utf8.hpp>
    +
    10 #include <winapi/utils.hpp>
    +
    11 
    +
    12 #include <windows.h>
    +
    13 
    +
    14 #include <cstddef>
    +
    15 #include <cstdint>
    +
    16 #include <string>
    +
    17 #include <utility>
    +
    18 
    +
    19 namespace winapi {
    +
    20 namespace {
    +
    21 
    +
    22 void* do_map(const Handle& mapping, std::size_t nb = 0) {
    +
    23  const auto addr = ::MapViewOfFile(static_cast<HANDLE>(mapping), FILE_MAP_ALL_ACCESS, 0, 0, nb);
    +
    24 
    +
    25  if (addr == NULL) {
    +
    26  throw error::windows(GetLastError(), "MapViewOfFile");
    +
    27  }
    +
    28 
    +
    29  return addr;
    +
    30 }
    +
    31 
    +
    32 } // namespace
    +
    33 
    +
    34 void SharedMemory::Unmap::operator()(void* ptr) const {
    +
    35  const auto ret = ::UnmapViewOfFile(ptr);
    +
    36  assert(ret);
    +
    37  WINAPI_UNUSED_PARAMETER(ret);
    +
    38 };
    +
    39 
    +
    40 SharedMemory SharedMemory::create(const std::string& name, std::size_t nb) {
    +
    41  const auto nb64 = static_cast<std::uint64_t>(nb);
    +
    42  static_assert(sizeof(nb64) == 2 * sizeof(DWORD), "sizeof(DWORD) != 32");
    +
    43 
    +
    44  const auto nb_low = static_cast<DWORD>(nb64);
    +
    45  const auto nb_high = static_cast<DWORD>(nb64 >> 32);
    +
    46 
    +
    47  const auto mapping_impl = ::CreateFileMappingW(
    +
    48  INVALID_HANDLE_VALUE, NULL, PAGE_READWRITE, nb_high, nb_low, widen(name).c_str());
    +
    49 
    +
    50  if (mapping_impl == NULL) {
    +
    51  throw error::windows(GetLastError(), "CreateFileMappingW");
    +
    52  }
    +
    53 
    +
    54  Handle mapping{mapping_impl};
    +
    55  const auto addr = do_map(mapping);
    +
    56  return {std::move(mapping), addr};
    +
    57 }
    +
    58 
    +
    59 SharedMemory SharedMemory::open(const std::string& name) {
    +
    60  const auto mapping_impl = ::OpenFileMappingW(FILE_MAP_ALL_ACCESS, FALSE, widen(name).c_str());
    +
    61 
    +
    62  if (mapping_impl == NULL) {
    +
    63  throw error::windows(GetLastError(), "OpenFileMappingW");
    +
    64  }
    +
    65 
    +
    66  Handle mapping{mapping_impl};
    +
    67  const auto addr = do_map(mapping);
    +
    68  return {std::move(mapping), addr};
    +
    69 }
    +
    70 
    +
    71 } // namespace winapi
    +
    HANDLE wrapper.
    Definition: handle.hpp:25
    +
    Named shared memory region.
    Definition: shmem.hpp:19
    +
    static SharedMemory create(const std::string &name, std::size_t nb)
    Definition: shmem.cpp:40
    +
    static SharedMemory open(const std::string &name)
    Definition: shmem.cpp:59
    +
    Make std::system_error work with GetLastError().
    +
    + + + + diff --git a/shmem_8hpp_source.html b/shmem_8hpp_source.html new file mode 100644 index 0000000..c885195 --- /dev/null +++ b/shmem_8hpp_source.html @@ -0,0 +1,169 @@ + + + + + + + +winapi_common: include/winapi/shmem.hpp Source File + + + + + + + + + +
    +
    + + + + + + +
    +
    winapi_common +
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    +
    +
    shmem.hpp
    +
    +
    +
    1 // Copyright (c) 2020 Egor Tensin <Egor.Tensin@gmail.com>
    +
    2 // This file is part of the "winapi-common" project.
    +
    3 // For details, see https://github.com/egor-tensin/winapi-common.
    +
    4 // Distributed under the MIT License.
    +
    5 
    +
    6 #pragma once
    +
    7 
    +
    8 #include "handle.hpp"
    +
    9 
    +
    10 #include <cstddef>
    +
    11 #include <memory>
    +
    12 #include <string>
    +
    13 #include <type_traits>
    +
    14 #include <utility>
    +
    15 
    +
    16 namespace winapi {
    +
    17 
    +
    19 class SharedMemory {
    +
    20 public:
    +
    26  static SharedMemory create(const std::string& name, std::size_t nb);
    +
    31  static SharedMemory open(const std::string& name);
    +
    32 
    +
    34  void* get() const { return m_addr.get(); }
    +
    36  void* ptr() const { return get(); }
    +
    37 
    +
    38 private:
    +
    39  struct Unmap {
    +
    40  void operator()(void*) const;
    +
    41  };
    +
    42 
    +
    43  SharedMemory() = default;
    +
    44 
    +
    45  SharedMemory(Handle&& handle, void* addr) : m_handle{std::move(handle)}, m_addr{addr} {}
    +
    46 
    +
    47  Handle m_handle;
    +
    48  std::unique_ptr<void, Unmap> m_addr;
    +
    49 };
    +
    50 
    +
    52 template <typename T>
    +
    53 class SharedObject {
    +
    54 public:
    +
    55  typedef typename std::aligned_storage<sizeof(T), __alignof(T)>::type AlignedType;
    +
    56 
    +
    62  template <typename... Args>
    +
    63  static SharedObject create(const std::string& name, Args&&... args) {
    +
    64  SharedObject obj{SharedMemory::create(name, sizeof(AlignedType))};
    +
    65  new (obj.ptr()) T(std::forward<Args>(args)...);
    +
    66  obj.m_destruct = true;
    +
    67  return obj;
    +
    68  }
    +
    69 
    +
    74  static SharedObject open(const std::string& name) {
    + +
    76  return obj;
    +
    77  }
    +
    78 
    +
    79  SharedObject(SharedObject&& other) noexcept = default;
    +
    80  SharedObject& operator=(const SharedObject& other) noexcept = default;
    +
    81  SharedObject(const SharedObject&) = delete;
    +
    82 
    +
    83  ~SharedObject() {
    +
    84  if (m_destruct && ptr()) {
    +
    85  ptr()->~T();
    +
    86  }
    +
    87  }
    +
    88 
    +
    90  T* ptr() const { return reinterpret_cast<T*>(m_shmem.ptr()); }
    +
    92  T& get() const { return *ptr(); }
    +
    93 
    +
    94  T* operator->() const { return ptr(); }
    +
    95  T& operator*() const { return get(); }
    +
    96 
    +
    97 private:
    +
    98  explicit SharedObject(SharedMemory&& shmem) : m_shmem(std::move(shmem)) {}
    +
    99 
    +
    100  SharedMemory m_shmem;
    +
    101  // Destruct only once, no matter the number of mappings.
    +
    102  bool m_destruct = false;
    +
    103 };
    +
    104 
    +
    105 } // namespace winapi
    +
    Named shared memory region.
    Definition: shmem.hpp:19
    +
    void * ptr() const
    Definition: shmem.hpp:36
    +
    static SharedMemory create(const std::string &name, std::size_t nb)
    Definition: shmem.cpp:40
    +
    static SharedMemory open(const std::string &name)
    Definition: shmem.cpp:59
    +
    void * get() const
    Definition: shmem.hpp:34
    +
    Easy way to represent a C++ object as a shared memory region.
    Definition: shmem.hpp:53
    +
    static SharedObject open(const std::string &name)
    Definition: shmem.hpp:74
    +
    T * ptr() const
    Definition: shmem.hpp:90
    +
    T & get() const
    Definition: shmem.hpp:92
    +
    static SharedObject create(const std::string &name, Args &&... args)
    Definition: shmem.hpp:63
    +
    + + + + diff --git a/sid_8cpp_source.html b/sid_8cpp_source.html new file mode 100644 index 0000000..b3951d7 --- /dev/null +++ b/sid_8cpp_source.html @@ -0,0 +1,127 @@ + + + + + + + +winapi_common: src/sid.cpp Source File + + + + + + + + + +
    +
    + + + + + + +
    +
    winapi_common +
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    +
    +
    sid.cpp
    +
    +
    +
    1 // Copyright (c) 2020 Egor Tensin <Egor.Tensin@gmail.com>
    +
    2 // This file is part of the "winapi-common" project.
    +
    3 // For details, see https://github.com/egor-tensin/winapi-common.
    +
    4 // Distributed under the MIT License.
    +
    5 
    +
    6 #include <winapi/buffer.hpp>
    +
    7 #include <winapi/error.hpp>
    +
    8 #include <winapi/sid.hpp>
    +
    9 #include <winapi/utf8.hpp>
    +
    10 #include <winapi/utils.hpp>
    +
    11 
    +
    12 // clang-format off
    +
    13 #include <windows.h>
    +
    14 #include <sddl.h>
    +
    15 // clang-format on
    +
    16 
    +
    17 #include <memory>
    +
    18 #include <string>
    +
    19 
    +
    20 namespace winapi {
    +
    21 
    +
    22 Sid Sid::well_known(WELL_KNOWN_SID_TYPE type) {
    +
    23  Buffer buffer;
    +
    24  buffer.resize(MAX_SID_SIZE);
    +
    25 
    +
    26  auto cb = static_cast<DWORD>(buffer.size());
    +
    27 
    +
    28  if (!::CreateWellKnownSid(type, NULL, buffer.data(), &cb))
    +
    29  throw error::windows(GetLastError(), "CreateWellKnownSid");
    +
    30 
    +
    31  buffer.resize(cb);
    +
    32  return Sid{buffer};
    +
    33 }
    +
    34 
    +
    35 Sid Sid::builtin_administrators() {
    +
    36  return well_known(WinBuiltinAdministratorsSid);
    +
    37 }
    +
    38 
    +
    39 std::string Sid::to_string() const {
    +
    40  wchar_t* s = nullptr;
    +
    41 
    +
    42  if (!::ConvertSidToStringSidW(const_cast<Impl*>(&get_impl()), &s))
    +
    43  throw error::windows(GetLastError(), "ConvertSidToStringSidW");
    +
    44 
    +
    45  return narrow(std::unique_ptr<wchar_t, LocalDelete>{s}.get());
    +
    46 }
    +
    47 
    +
    48 } // namespace winapi
    +
    Make std::system_error work with GetLastError().
    +
    + + + + diff --git a/sid_8hpp_source.html b/sid_8hpp_source.html new file mode 100644 index 0000000..c37466e --- /dev/null +++ b/sid_8hpp_source.html @@ -0,0 +1,121 @@ + + + + + + + +winapi_common: include/winapi/sid.hpp Source File + + + + + + + + + +
    +
    + + + + + + +
    +
    winapi_common +
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    +
    +
    sid.hpp
    +
    +
    +
    1 // Copyright (c) 2020 Egor Tensin <Egor.Tensin@gmail.com>
    +
    2 // This file is part of the "winapi-common" project.
    +
    3 // For details, see https://github.com/egor-tensin/winapi-common.
    +
    4 // Distributed under the MIT License.
    +
    5 
    +
    6 #pragma once
    +
    7 
    +
    8 #include "buffer.hpp"
    +
    9 
    +
    10 #include <windows.h>
    +
    11 
    +
    12 #include <cstddef>
    +
    13 #include <string>
    +
    14 
    +
    15 namespace winapi {
    +
    16 
    +
    17 class Sid {
    +
    18 public:
    +
    19  static constexpr std::size_t MAX_SID_SIZE = SECURITY_MAX_SID_SIZE;
    +
    20 
    +
    21  typedef SID Impl;
    +
    22 
    +
    23  static Sid well_known(WELL_KNOWN_SID_TYPE type);
    +
    24 
    +
    25  static Sid builtin_administrators();
    +
    26 
    +
    27  explicit Sid(const Buffer& buffer) : m_buffer(buffer) {}
    +
    28 
    +
    29  explicit operator SID&() { return get_impl(); }
    +
    30  explicit operator const SID&() const { return get_impl(); }
    +
    31 
    +
    32  std::string to_string() const;
    +
    33 
    +
    34 private:
    +
    35  Impl& get_impl() { return *reinterpret_cast<SID*>(m_buffer.data()); }
    +
    36  const Impl& get_impl() const { return *reinterpret_cast<const SID*>(m_buffer.data()); }
    +
    37 
    +
    38  Buffer m_buffer;
    +
    39 };
    +
    40 
    +
    41 } // namespace winapi
    +
    Binary data container.
    Definition: buffer.hpp:24
    + +
    + + + + diff --git a/splitbar.png b/splitbar.png new file mode 100644 index 0000000..fe895f2 Binary files /dev/null and b/splitbar.png differ diff --git a/structstd_1_1hash_3_01winapi_1_1File_1_1ID_01_4-members.html b/structstd_1_1hash_3_01winapi_1_1File_1_1ID_01_4-members.html new file mode 100644 index 0000000..04c95c5 --- /dev/null +++ b/structstd_1_1hash_3_01winapi_1_1File_1_1ID_01_4-members.html @@ -0,0 +1,82 @@ + + + + + + + +winapi_common: Member List + + + + + + + + + +
    +
    + + + + + + +
    +
    winapi_common +
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    +
    +
    std::hash< winapi::File::ID > Member List
    +
    +
    + +

    This is the complete list of members for std::hash< winapi::File::ID >, including all inherited members.

    + + +
    operator()(const winapi::File::ID &id) const (defined in std::hash< winapi::File::ID >)std::hash< winapi::File::ID >inline
    + + + + diff --git a/structstd_1_1hash_3_01winapi_1_1File_1_1ID_01_4.html b/structstd_1_1hash_3_01winapi_1_1File_1_1ID_01_4.html new file mode 100644 index 0000000..6addbd0 --- /dev/null +++ b/structstd_1_1hash_3_01winapi_1_1File_1_1ID_01_4.html @@ -0,0 +1,94 @@ + + + + + + + +winapi_common: std::hash< winapi::File::ID > Struct Reference + + + + + + + + + +
    +
    + + + + + + +
    +
    winapi_common +
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    + +
    +
    std::hash< winapi::File::ID > Struct Reference
    +
    +
    + + + + +

    +Public Member Functions

    +std::size_t operator() (const winapi::File::ID &id) const
     
    +

    Detailed Description

    +
    +

    Definition at line 79 of file file.hpp.

    +

    The documentation for this struct was generated from the following file: +
    + + + + diff --git a/structwinapi_1_1File_1_1ID-members.html b/structwinapi_1_1File_1_1ID-members.html new file mode 100644 index 0000000..2cb6ac2 --- /dev/null +++ b/structwinapi_1_1File_1_1ID-members.html @@ -0,0 +1,83 @@ + + + + + + + +winapi_common: Member List + + + + + + + + + +
    +
    + + + + + + +
    +
    winapi_common +
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    +
    +
    winapi::File::ID Member List
    +
    +
    + +

    This is the complete list of members for winapi::File::ID, including all inherited members.

    + + + +
    impl (defined in winapi::File::ID)winapi::File::ID
    operator==(const ID &other) const (defined in winapi::File::ID)winapi::File::IDinline
    + + + + diff --git a/structwinapi_1_1File_1_1ID.html b/structwinapi_1_1File_1_1ID.html new file mode 100644 index 0000000..166cc7c --- /dev/null +++ b/structwinapi_1_1File_1_1ID.html @@ -0,0 +1,101 @@ + + + + + + + +winapi_common: winapi::File::ID Struct Reference + + + + + + + + + +
    +
    + + + + + + +
    +
    winapi_common +
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    + +
    +
    winapi::File::ID Struct Reference
    +
    +
    + + + + +

    +Public Member Functions

    +bool operator== (const ID &other) const
     
    + + + +

    +Public Attributes

    +const FILE_ID_INFO impl
     
    +

    Detailed Description

    +
    +

    Definition at line 31 of file file.hpp.

    +

    The documentation for this struct was generated from the following file: +
    + + + + diff --git a/structwinapi_1_1LocalDelete-members.html b/structwinapi_1_1LocalDelete-members.html new file mode 100644 index 0000000..97678d3 --- /dev/null +++ b/structwinapi_1_1LocalDelete-members.html @@ -0,0 +1,82 @@ + + + + + + + +winapi_common: Member List + + + + + + + + + +
    +
    + + + + + + +
    +
    winapi_common +
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    +
    +
    winapi::LocalDelete Member List
    +
    +
    + +

    This is the complete list of members for winapi::LocalDelete, including all inherited members.

    + + +
    operator()(void *ptr) const (defined in winapi::LocalDelete)winapi::LocalDeleteinline
    + + + + diff --git a/structwinapi_1_1LocalDelete.html b/structwinapi_1_1LocalDelete.html new file mode 100644 index 0000000..7634a4c --- /dev/null +++ b/structwinapi_1_1LocalDelete.html @@ -0,0 +1,94 @@ + + + + + + + +winapi_common: winapi::LocalDelete Struct Reference + + + + + + + + + +
    +
    + + + + + + +
    +
    winapi_common +
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    + +
    +
    winapi::LocalDelete Struct Reference
    +
    +
    + + + + +

    +Public Member Functions

    +void operator() (void *ptr) const
     
    +

    Detailed Description

    +
    +

    Definition at line 16 of file utils.hpp.

    +

    The documentation for this struct was generated from the following file: +
    + + + + diff --git a/structwinapi_1_1ProcessParameters-members.html b/structwinapi_1_1ProcessParameters-members.html new file mode 100644 index 0000000..4fd5cef --- /dev/null +++ b/structwinapi_1_1ProcessParameters-members.html @@ -0,0 +1,89 @@ + + + + + + + +winapi_common: Member List + + + + + + + + + +
    +
    + + + + + + +
    +
    winapi_common +
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    +
    +
    winapi::ProcessParameters Member List
    +
    +
    + +

    This is the complete list of members for winapi::ProcessParameters, including all inherited members.

    + + + + + + + + + +
    cmd_line (defined in winapi::ProcessParameters)winapi::ProcessParameters
    console_mode (defined in winapi::ProcessParameters)winapi::ProcessParameters
    ConsoleCreationMode enum name (defined in winapi::ProcessParameters)winapi::ProcessParameters
    ConsoleInherit enum value (defined in winapi::ProcessParameters)winapi::ProcessParameters
    ConsoleNew enum value (defined in winapi::ProcessParameters)winapi::ProcessParameters
    ConsoleNone enum value (defined in winapi::ProcessParameters)winapi::ProcessParameters
    io (defined in winapi::ProcessParameters)winapi::ProcessParameters
    ProcessParameters(const CommandLine &cmd_line) (defined in winapi::ProcessParameters)winapi::ProcessParametersinlineexplicit
    + + + + diff --git a/structwinapi_1_1ProcessParameters.html b/structwinapi_1_1ProcessParameters.html new file mode 100644 index 0000000..f4cfe6f --- /dev/null +++ b/structwinapi_1_1ProcessParameters.html @@ -0,0 +1,129 @@ + + + + + + + +winapi_common: winapi::ProcessParameters Struct Reference + + + + + + + + + +
    +
    + + + + + + +
    +
    winapi_common +
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    + +
    +
    winapi::ProcessParameters Struct Reference
    +
    +
    + +

    Process parameters for Process::create(). + More...

    +
    +Inheritance diagram for winapi::ProcessParameters:
    +
    +
    + + +winapi::ShellParameters + +
    + + + + +

    +Public Types

    enum  ConsoleCreationMode { ConsoleNone +, ConsoleInherit +, ConsoleNew + }
     
    + + + +

    +Public Member Functions

    ProcessParameters (const CommandLine &cmd_line)
     
    + + + + + + + +

    +Public Attributes

    +CommandLine cmd_line
     
    +boost::optional< process::IOio
     
    +ConsoleCreationMode console_mode = ConsoleNew
     
    +

    Detailed Description

    +

    Process parameters for Process::create().

    + +

    Definition at line 24 of file process.hpp.

    +

    The documentation for this struct was generated from the following file: +
    + + + + diff --git a/structwinapi_1_1ProcessParameters.png b/structwinapi_1_1ProcessParameters.png new file mode 100644 index 0000000..d7c2ad5 Binary files /dev/null and b/structwinapi_1_1ProcessParameters.png differ diff --git a/structwinapi_1_1Resource-members.html b/structwinapi_1_1Resource-members.html new file mode 100644 index 0000000..cbb3a2a --- /dev/null +++ b/structwinapi_1_1Resource-members.html @@ -0,0 +1,86 @@ + + + + + + + +winapi_common: Member List + + + + + + + + + +
    +
    + + + + + + +
    +
    winapi_common +
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    +
    +
    winapi::Resource Member List
    +
    +
    + +

    This is the complete list of members for winapi::Resource, including all inherited members.

    + + + + + + +
    copy() constwinapi::Resourceinline
    data (defined in winapi::Resource)winapi::Resource
    nb (defined in winapi::Resource)winapi::Resource
    Resource()=default (defined in winapi::Resource)winapi::Resource
    Resource(const void *data, std::size_t nb) (defined in winapi::Resource)winapi::Resourceinline
    + + + + diff --git a/structwinapi_1_1Resource.html b/structwinapi_1_1Resource.html new file mode 100644 index 0000000..cb3c58b --- /dev/null +++ b/structwinapi_1_1Resource.html @@ -0,0 +1,139 @@ + + + + + + + +winapi_common: winapi::Resource Struct Reference + + + + + + + + + +
    +
    + + + + + + +
    +
    winapi_common +
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    + +
    +
    winapi::Resource Struct Reference
    +
    +
    + +

    Resources embedded in a PE (Portable Executable). + More...

    + + + + + + +

    +Public Member Functions

    Resource (const void *data, std::size_t nb)
     
    Buffer copy () const
     
    + + + + + +

    +Public Attributes

    +const void * data = nullptr
     
    +std::size_t nb = 0
     
    +

    Detailed Description

    +

    Resources embedded in a PE (Portable Executable).

    + +

    Definition at line 15 of file resource.hpp.

    +

    Member Function Documentation

    + +

    ◆ copy()

    + +
    +
    + + + + + +
    + + + + + + + +
    Buffer winapi::Resource::copy () const
    +
    +inline
    +
    +

    Extract resource data into a Buffer instance.

    + +

    Definition at line 23 of file resource.hpp.

    + +
    +
    +
    The documentation for this struct was generated from the following file: +
    + + + + diff --git a/structwinapi_1_1ShellParameters-members.html b/structwinapi_1_1ShellParameters-members.html new file mode 100644 index 0000000..1dba6f2 --- /dev/null +++ b/structwinapi_1_1ShellParameters-members.html @@ -0,0 +1,92 @@ + + + + + + + +winapi_common: Member List + + + + + + + + + +
    +
    + + + + + + +
    +
    winapi_common +
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    +
    +
    winapi::ShellParameters Member List
    +
    +
    + +

    This is the complete list of members for winapi::ShellParameters, including all inherited members.

    + + + + + + + + + + + + +
    cmd_line (defined in winapi::ProcessParameters)winapi::ProcessParameters
    console_mode (defined in winapi::ProcessParameters)winapi::ProcessParameters
    ConsoleCreationMode enum name (defined in winapi::ProcessParameters)winapi::ProcessParameters
    ConsoleInherit enum value (defined in winapi::ProcessParameters)winapi::ProcessParameters
    ConsoleNew enum value (defined in winapi::ProcessParameters)winapi::ProcessParameters
    ConsoleNone enum value (defined in winapi::ProcessParameters)winapi::ProcessParameters
    io (defined in winapi::ProcessParameters)winapi::ProcessParameters
    ProcessParameters(const CommandLine &cmd_line) (defined in winapi::ProcessParameters)winapi::ProcessParametersinlineexplicit
    runas(const CommandLine &cmd_line) (defined in winapi::ShellParameters)winapi::ShellParametersinlinestatic
    ShellParameters(const CommandLine &cmd_line) (defined in winapi::ShellParameters)winapi::ShellParametersinlineexplicit
    verb (defined in winapi::ShellParameters)winapi::ShellParameters
    + + + + diff --git a/structwinapi_1_1ShellParameters.html b/structwinapi_1_1ShellParameters.html new file mode 100644 index 0000000..888a929 --- /dev/null +++ b/structwinapi_1_1ShellParameters.html @@ -0,0 +1,144 @@ + + + + + + + +winapi_common: winapi::ShellParameters Struct Reference + + + + + + + + + +
    +
    + + + + + + +
    +
    winapi_common +
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    + +
    +
    winapi::ShellParameters Struct Reference
    +
    +
    + +

    Process parameters for Process::shell(). + More...

    +
    +Inheritance diagram for winapi::ShellParameters:
    +
    +
    + + +winapi::ProcessParameters + +
    + + + + + + + +

    +Public Member Functions

    ShellParameters (const CommandLine &cmd_line)
     
    - Public Member Functions inherited from winapi::ProcessParameters
    ProcessParameters (const CommandLine &cmd_line)
     
    + + + +

    +Static Public Member Functions

    +static ShellParameters runas (const CommandLine &cmd_line)
     
    + + + + + + + + + + +

    +Public Attributes

    +boost::optional< std::string > verb
     
    - Public Attributes inherited from winapi::ProcessParameters
    +CommandLine cmd_line
     
    +boost::optional< process::IOio
     
    +ConsoleCreationMode console_mode = ConsoleNew
     
    + + + + +

    +Additional Inherited Members

    - Public Types inherited from winapi::ProcessParameters
    enum  ConsoleCreationMode { ConsoleNone +, ConsoleInherit +, ConsoleNew + }
     
    +

    Detailed Description

    +

    Process parameters for Process::shell().

    + +

    Definition at line 39 of file process.hpp.

    +

    The documentation for this struct was generated from the following file: +
    + + + + diff --git a/structwinapi_1_1ShellParameters.png b/structwinapi_1_1ShellParameters.png new file mode 100644 index 0000000..26a67de Binary files /dev/null and b/structwinapi_1_1ShellParameters.png differ diff --git a/structwinapi_1_1process_1_1IO-members.html b/structwinapi_1_1process_1_1IO-members.html new file mode 100644 index 0000000..d767f25 --- /dev/null +++ b/structwinapi_1_1process_1_1IO-members.html @@ -0,0 +1,86 @@ + + + + + + + +winapi_common: Member List + + + + + + + + + +
    +
    + + + + + + +
    +
    winapi_common +
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    +
    +
    winapi::process::IO Member List
    +
    +
    + +

    This is the complete list of members for winapi::process::IO, including all inherited members.

    + + + + + + +
    close() (defined in winapi::process::IO)winapi::process::IO
    IO()=default (defined in winapi::process::IO)winapi::process::IO
    std_err (defined in winapi::process::IO)winapi::process::IO
    std_in (defined in winapi::process::IO)winapi::process::IO
    std_out (defined in winapi::process::IO)winapi::process::IO
    + + + + diff --git a/structwinapi_1_1process_1_1IO.html b/structwinapi_1_1process_1_1IO.html new file mode 100644 index 0000000..925fd85 --- /dev/null +++ b/structwinapi_1_1process_1_1IO.html @@ -0,0 +1,112 @@ + + + + + + + +winapi_common: winapi::process::IO Struct Reference + + + + + + + + + +
    +
    + + + + + + +
    +
    winapi_common +
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    + +
    +
    winapi::process::IO Struct Reference
    +
    +
    + +

    Child process IO settings. + More...

    + + + + +

    +Public Member Functions

    +void close ()
     
    + + + + + + + +

    +Public Attributes

    +Stdin std_in
     
    +Stdout std_out
     
    +Stderr std_err
     
    +

    Detailed Description

    +

    Child process IO settings.

    + +

    Definition at line 61 of file process_io.hpp.

    +

    The documentation for this struct was generated from the following files: +
    + + + + diff --git a/structwinapi_1_1process_1_1Stderr-members.html b/structwinapi_1_1process_1_1Stderr-members.html new file mode 100644 index 0000000..f0b7788 --- /dev/null +++ b/structwinapi_1_1process_1_1Stderr-members.html @@ -0,0 +1,87 @@ + + + + + + + +winapi_common: Member List + + + + + + + + + +
    +
    + + + + + + +
    +
    winapi_common +
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    +
    +
    winapi::process::Stderr Member List
    +
    +
    + +

    This is the complete list of members for winapi::process::Stderr, including all inherited members.

    + + + + + + + +
    handle (defined in winapi::process::Stream)winapi::process::Stream
    Stderr()winapi::process::Stderr
    Stderr(const std::string &file)winapi::process::Stderrexplicit
    Stderr(const CanonicalPath &file)winapi::process::Stderrexplicit
    Stderr(Pipe &)winapi::process::Stderrexplicit
    Stream(Handle &&handle) (defined in winapi::process::Stream)winapi::process::Streaminline
    + + + + diff --git a/structwinapi_1_1process_1_1Stderr.html b/structwinapi_1_1process_1_1Stderr.html new file mode 100644 index 0000000..981c9a1 --- /dev/null +++ b/structwinapi_1_1process_1_1Stderr.html @@ -0,0 +1,232 @@ + + + + + + + +winapi_common: winapi::process::Stderr Struct Reference + + + + + + + + + +
    +
    + + + + + + +
    +
    winapi_common +
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    + +
    +
    winapi::process::Stderr Struct Reference
    +
    +
    + +

    Redirect child process's stderr. + More...

    +
    +Inheritance diagram for winapi::process::Stderr:
    +
    +
    + + +winapi::process::Stream + +
    + + + + + + + + + + + + + +

    +Public Member Functions

     Stderr ()
     
     Stderr (const std::string &file)
     
     Stderr (const CanonicalPath &file)
     
     Stderr (Pipe &)
     
    - Public Member Functions inherited from winapi::process::Stream
    Stream (Handle &&handle)
     
    + + + + +

    +Additional Inherited Members

    - Public Attributes inherited from winapi::process::Stream
    +Handle handle
     
    +

    Detailed Description

    +

    Redirect child process's stderr.

    + +

    Definition at line 49 of file process_io.hpp.

    +

    Constructor & Destructor Documentation

    + +

    ◆ Stderr() [1/4]

    + +
    +
    + + + + + + + +
    winapi::process::Stderr::Stderr ()
    +
    +

    No redirection.

    + +

    Definition at line 21 of file process_io.cpp.

    + +
    +
    + +

    ◆ Stderr() [2/4]

    + +
    +
    + + + + + +
    + + + + + + + + +
    winapi::process::Stderr::Stderr (const std::string & file)
    +
    +explicit
    +
    +

    Redirect child process's stderr to a file.

    + +

    Definition at line 31 of file process_io.cpp.

    + +
    +
    + +

    ◆ Stderr() [3/4]

    + +
    +
    + + + + + +
    + + + + + + + + +
    winapi::process::Stderr::Stderr (const CanonicalPathfile)
    +
    +explicit
    +
    +

    This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

    + +

    Definition at line 33 of file process_io.cpp.

    + +
    +
    + +

    ◆ Stderr() [4/4]

    + +
    +
    + + + + + +
    + + + + + + + + +
    winapi::process::Stderr::Stderr (Pipepipe)
    +
    +explicit
    +
    +

    Redirect child process's stderr to a pipe.

    + +

    Definition at line 43 of file process_io.cpp.

    + +
    +
    +
    The documentation for this struct was generated from the following files: +
    + + + + diff --git a/structwinapi_1_1process_1_1Stderr.png b/structwinapi_1_1process_1_1Stderr.png new file mode 100644 index 0000000..4afe733 Binary files /dev/null and b/structwinapi_1_1process_1_1Stderr.png differ diff --git a/structwinapi_1_1process_1_1Stdin-members.html b/structwinapi_1_1process_1_1Stdin-members.html new file mode 100644 index 0000000..d697d2c --- /dev/null +++ b/structwinapi_1_1process_1_1Stdin-members.html @@ -0,0 +1,87 @@ + + + + + + + +winapi_common: Member List + + + + + + + + + +
    +
    + + + + + + +
    +
    winapi_common +
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    +
    +
    winapi::process::Stdin Member List
    +
    +
    + +

    This is the complete list of members for winapi::process::Stdin, including all inherited members.

    + + + + + + + +
    handle (defined in winapi::process::Stream)winapi::process::Stream
    Stdin()winapi::process::Stdin
    Stdin(const std::string &file)winapi::process::Stdinexplicit
    Stdin(const CanonicalPath &file)winapi::process::Stdinexplicit
    Stdin(Pipe &)winapi::process::Stdinexplicit
    Stream(Handle &&handle) (defined in winapi::process::Stream)winapi::process::Streaminline
    + + + + diff --git a/structwinapi_1_1process_1_1Stdin.html b/structwinapi_1_1process_1_1Stdin.html new file mode 100644 index 0000000..449e0f2 --- /dev/null +++ b/structwinapi_1_1process_1_1Stdin.html @@ -0,0 +1,232 @@ + + + + + + + +winapi_common: winapi::process::Stdin Struct Reference + + + + + + + + + +
    +
    + + + + + + +
    +
    winapi_common +
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    + +
    +
    winapi::process::Stdin Struct Reference
    +
    +
    + +

    Redirect child process's stdin. + More...

    +
    +Inheritance diagram for winapi::process::Stdin:
    +
    +
    + + +winapi::process::Stream + +
    + + + + + + + + + + + + + +

    +Public Member Functions

     Stdin ()
     
     Stdin (const std::string &file)
     
     Stdin (const CanonicalPath &file)
     
     Stdin (Pipe &)
     
    - Public Member Functions inherited from winapi::process::Stream
    Stream (Handle &&handle)
     
    + + + + +

    +Additional Inherited Members

    - Public Attributes inherited from winapi::process::Stream
    +Handle handle
     
    +

    Detailed Description

    +

    Redirect child process's stdin.

    + +

    Definition at line 25 of file process_io.hpp.

    +

    Constructor & Destructor Documentation

    + +

    ◆ Stdin() [1/4]

    + +
    +
    + + + + + + + +
    winapi::process::Stdin::Stdin ()
    +
    +

    No redirection.

    + +

    Definition at line 17 of file process_io.cpp.

    + +
    +
    + +

    ◆ Stdin() [2/4]

    + +
    +
    + + + + + +
    + + + + + + + + +
    winapi::process::Stdin::Stdin (const std::string & file)
    +
    +explicit
    +
    +

    Make child process read form a file.

    + +

    Definition at line 23 of file process_io.cpp.

    + +
    +
    + +

    ◆ Stdin() [3/4]

    + +
    +
    + + + + + +
    + + + + + + + + +
    winapi::process::Stdin::Stdin (const CanonicalPathfile)
    +
    +explicit
    +
    +

    This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

    + +

    Definition at line 25 of file process_io.cpp.

    + +
    +
    + +

    ◆ Stdin() [4/4]

    + +
    +
    + + + + + +
    + + + + + + + + +
    winapi::process::Stdin::Stdin (Pipepipe)
    +
    +explicit
    +
    +

    Make child process read form a pipe.

    + +

    Definition at line 35 of file process_io.cpp.

    + +
    +
    +
    The documentation for this struct was generated from the following files: +
    + + + + diff --git a/structwinapi_1_1process_1_1Stdin.png b/structwinapi_1_1process_1_1Stdin.png new file mode 100644 index 0000000..a3a7565 Binary files /dev/null and b/structwinapi_1_1process_1_1Stdin.png differ diff --git a/structwinapi_1_1process_1_1Stdout-members.html b/structwinapi_1_1process_1_1Stdout-members.html new file mode 100644 index 0000000..3bd29ef --- /dev/null +++ b/structwinapi_1_1process_1_1Stdout-members.html @@ -0,0 +1,87 @@ + + + + + + + +winapi_common: Member List + + + + + + + + + +
    +
    + + + + + + +
    +
    winapi_common +
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    +
    +
    winapi::process::Stdout Member List
    +
    +
    + +

    This is the complete list of members for winapi::process::Stdout, including all inherited members.

    + + + + + + + +
    handle (defined in winapi::process::Stream)winapi::process::Stream
    Stdout()winapi::process::Stdout
    Stdout(const std::string &file)winapi::process::Stdoutexplicit
    Stdout(const CanonicalPath &file)winapi::process::Stdoutexplicit
    Stdout(Pipe &)winapi::process::Stdoutexplicit
    Stream(Handle &&handle) (defined in winapi::process::Stream)winapi::process::Streaminline
    + + + + diff --git a/structwinapi_1_1process_1_1Stdout.html b/structwinapi_1_1process_1_1Stdout.html new file mode 100644 index 0000000..54f8f1d --- /dev/null +++ b/structwinapi_1_1process_1_1Stdout.html @@ -0,0 +1,232 @@ + + + + + + + +winapi_common: winapi::process::Stdout Struct Reference + + + + + + + + + +
    +
    + + + + + + +
    +
    winapi_common +
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    + +
    +
    winapi::process::Stdout Struct Reference
    +
    +
    + +

    Redirect child process's stdout. + More...

    +
    +Inheritance diagram for winapi::process::Stdout:
    +
    +
    + + +winapi::process::Stream + +
    + + + + + + + + + + + + + +

    +Public Member Functions

     Stdout ()
     
     Stdout (const std::string &file)
     
     Stdout (const CanonicalPath &file)
     
     Stdout (Pipe &)
     
    - Public Member Functions inherited from winapi::process::Stream
    Stream (Handle &&handle)
     
    + + + + +

    +Additional Inherited Members

    - Public Attributes inherited from winapi::process::Stream
    +Handle handle
     
    +

    Detailed Description

    +

    Redirect child process's stdout.

    + +

    Definition at line 37 of file process_io.hpp.

    +

    Constructor & Destructor Documentation

    + +

    ◆ Stdout() [1/4]

    + +
    +
    + + + + + + + +
    winapi::process::Stdout::Stdout ()
    +
    +

    No redirection.

    + +

    Definition at line 19 of file process_io.cpp.

    + +
    +
    + +

    ◆ Stdout() [2/4]

    + +
    +
    + + + + + +
    + + + + + + + + +
    winapi::process::Stdout::Stdout (const std::string & file)
    +
    +explicit
    +
    +

    Redirect child process's stdout to a file.

    + +

    Definition at line 27 of file process_io.cpp.

    + +
    +
    + +

    ◆ Stdout() [3/4]

    + +
    +
    + + + + + +
    + + + + + + + + +
    winapi::process::Stdout::Stdout (const CanonicalPathfile)
    +
    +explicit
    +
    +

    This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

    + +

    Definition at line 29 of file process_io.cpp.

    + +
    +
    + +

    ◆ Stdout() [4/4]

    + +
    +
    + + + + + +
    + + + + + + + + +
    winapi::process::Stdout::Stdout (Pipepipe)
    +
    +explicit
    +
    +

    Redirect child process's stdout to a pipe.

    + +

    Definition at line 39 of file process_io.cpp.

    + +
    +
    +
    The documentation for this struct was generated from the following files: +
    + + + + diff --git a/structwinapi_1_1process_1_1Stdout.png b/structwinapi_1_1process_1_1Stdout.png new file mode 100644 index 0000000..f750620 Binary files /dev/null and b/structwinapi_1_1process_1_1Stdout.png differ diff --git a/structwinapi_1_1process_1_1Stream-members.html b/structwinapi_1_1process_1_1Stream-members.html new file mode 100644 index 0000000..5688eb0 --- /dev/null +++ b/structwinapi_1_1process_1_1Stream-members.html @@ -0,0 +1,83 @@ + + + + + + + +winapi_common: Member List + + + + + + + + + +
    +
    + + + + + + +
    +
    winapi_common +
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    +
    +
    winapi::process::Stream Member List
    +
    +
    + +

    This is the complete list of members for winapi::process::Stream, including all inherited members.

    + + + +
    handle (defined in winapi::process::Stream)winapi::process::Stream
    Stream(Handle &&handle) (defined in winapi::process::Stream)winapi::process::Streaminline
    + + + + diff --git a/structwinapi_1_1process_1_1Stream.html b/structwinapi_1_1process_1_1Stream.html new file mode 100644 index 0000000..d24cacd --- /dev/null +++ b/structwinapi_1_1process_1_1Stream.html @@ -0,0 +1,112 @@ + + + + + + + +winapi_common: winapi::process::Stream Struct Reference + + + + + + + + + +
    +
    + + + + + + +
    +
    winapi_common +
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    + +
    +
    winapi::process::Stream Struct Reference
    +
    +
    +
    +Inheritance diagram for winapi::process::Stream:
    +
    +
    + + +winapi::process::Stderr +winapi::process::Stdin +winapi::process::Stdout + +
    + + + + +

    +Public Member Functions

    Stream (Handle &&handle)
     
    + + + +

    +Public Attributes

    +Handle handle
     
    +

    Detailed Description

    +
    +

    Definition at line 18 of file process_io.hpp.

    +

    The documentation for this struct was generated from the following file: +
    + + + + diff --git a/structwinapi_1_1process_1_1Stream.png b/structwinapi_1_1process_1_1Stream.png new file mode 100644 index 0000000..6c245e9 Binary files /dev/null and b/structwinapi_1_1process_1_1Stream.png differ diff --git a/sync_off.png b/sync_off.png new file mode 100644 index 0000000..3b443fc Binary files /dev/null and b/sync_off.png differ diff --git a/sync_on.png b/sync_on.png new file mode 100644 index 0000000..e08320f Binary files /dev/null and b/sync_on.png differ diff --git a/tab_a.png b/tab_a.png new file mode 100644 index 0000000..3b725c4 Binary files /dev/null and b/tab_a.png differ diff --git a/tab_b.png b/tab_b.png new file mode 100644 index 0000000..e2b4a86 Binary files /dev/null and b/tab_b.png differ diff --git a/tab_h.png b/tab_h.png new file mode 100644 index 0000000..fd5cb70 Binary files /dev/null and b/tab_h.png differ diff --git a/tab_s.png b/tab_s.png new file mode 100644 index 0000000..ab478c9 Binary files /dev/null and b/tab_s.png differ diff --git a/tabs.css b/tabs.css new file mode 100644 index 0000000..7d45d36 --- /dev/null +++ b/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/utils_8hpp_source.html b/utils_8hpp_source.html new file mode 100644 index 0000000..f969662 --- /dev/null +++ b/utils_8hpp_source.html @@ -0,0 +1,103 @@ + + + + + + + +winapi_common: include/winapi/utils.hpp Source File + + + + + + + + + +
    +
    + + + + + + +
    +
    winapi_common +
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    +
    +
    utils.hpp
    +
    +
    +
    1 // Copyright (c) 2020 Egor Tensin <Egor.Tensin@gmail.com>
    +
    2 // This file is part of the "winapi-common" project.
    +
    3 // For details, see https://github.com/egor-tensin/winapi-common.
    +
    4 // Distributed under the MIT License.
    +
    5 
    +
    6 #pragma once
    +
    7 
    +
    8 #include <windows.h>
    +
    9 
    +
    10 #include <cassert>
    +
    11 
    +
    12 #define WINAPI_UNUSED_PARAMETER(...) (void)(__VA_ARGS__)
    +
    13 
    +
    14 namespace winapi {
    +
    15 
    +
    16 struct LocalDelete {
    +
    17  void operator()(void* ptr) const {
    +
    18  const auto ret = ::LocalFree(ptr);
    +
    19  assert(ret == NULL);
    +
    20  WINAPI_UNUSED_PARAMETER(ret);
    +
    21  }
    +
    22 };
    +
    23 
    +
    24 } // namespace winapi
    + +
    + + + + diff --git a/window__style_8hpp_source.html b/window__style_8hpp_source.html new file mode 100644 index 0000000..348ef88 --- /dev/null +++ b/window__style_8hpp_source.html @@ -0,0 +1,105 @@ + + + + + + + +winapi_common: include/winapi/window_style.hpp Source File + + + + + + + + + +
    +
    + + + + + + +
    +
    winapi_common +
    +
    +
    + + + + + + + + +
    +
    + + +
    + +
    + + +
    +
    +
    +
    window_style.hpp
    +
    +
    +
    1 // Copyright (c) 2020 Egor Tensin <Egor.Tensin@gmail.com>
    +
    2 // This file is part of the "winapi-common" project.
    +
    3 // For details, see https://github.com/egor-tensin/winapi-common.
    +
    4 // Distributed under the MIT License.
    +
    5 
    +
    6 #pragma once
    +
    7 
    +
    8 namespace winapi {
    +
    9 
    +
    10 enum class WindowStyle {
    +
    11  // https://docs.microsoft.com/en-us/windows/win32/api/winuser/nf-winuser-showwindow
    +
    12  ForceMinimize = 11,
    +
    13  Hide = 0,
    +
    14  Maximize = 3,
    +
    15  Minimize = 6,
    +
    16  Restore = 9,
    +
    17  Show = 5,
    +
    18  ShowDefault = 10,
    +
    19  ShowMaximized = 3,
    +
    20  ShowMinimized = 2,
    +
    21  ShowMinNoActive = 7,
    +
    22  ShowNA = 8,
    +
    23  ShowNoActivate = 4,
    +
    24  ShowNormal = 1,
    +
    25 };
    +
    26 
    +
    27 } // namespace winapi
    +
    + + + + -- cgit v1.2.3