basic_socket_acceptor
move constructor as noexcept
.
gcc
10's coroutine
support.
windows::overlapped_ptr
.
execution::receiver_of
concept.
execution::executor
,
execution::operation_state
,execution::sender
,
execution::receiver
, execution::receiver_of
,
and execution::scheduler
concepts and the corresponding traits.
These now test first for well-formed CPO expressions (or, in the case of
senders, a specialised sender_traits
template) and, if not
valid, short-circuit the remainder of the evaluation. This helps prevent
recursive template instantiations that can occur in some contexts.
strand
template's constructor, to
prevent template instantiation recursion.
execution::any_executor
template's
converting constructors, as per the specification.
execution::sender_traits
specialisation and
connect()
member function to the thread_pool
executor, as per the specification.
execution::blocking_t::always_t::is_preferable
to
be false as per the specification.
shape_type
and index_type
to thread_pool
executors, as per the specification.
execution::is_executor
)
work with void
.
async_compose
support for standard executors.
any_io_executor
in asio/ts/netfwd.hpp
.
use_future
compatibility with older compilers.
gcc
.
clang-cl
on Windows.
io_context
executors, thread_pool
executors,
system_executor
, and strand<>
.
io_context::executor_type
, thread_pool::executor_type
,
system_executor
, and strand
executors now
meet the requirements for the proposed standard executors. These
classes also continue to meet the existing requirements for the Networking
TS model of executors.
dispatch
, post
, defer
, get_associated_executor
,
bind_executor
, make_work_guard
, spawn
,
co_spawn
, async_compose
, use_future
,
etc., can interoperate with both new proposed standard executors,
and with existing Networking TS executors. The implementation determines
at compile time which model a particular executor meets; the proposed
standard executor model is used in preference if both are detected.
any_io_executor
type alias has been introduced as
the new default runtime-polymorphic executor for all I/O objects.
This type alias points to the execution::any_executor<>
template with a set of supportable properties specified for use with
I/O. This change may break existing code that directly uses the old
polymorphic wrapper, executor
. If required for backward
compatibility, ASIO_USE_TS_EXECUTOR_AS_DEFAULT
can be
defined, which changes the any_io_executor
type alias
to instead point to the executor
polymorphic wrapper.
ASIO_NO_TS_EXECUTORS
.
basic_waitable_timer
.
This enables move construction and assignment between different timer types,
provided the executor types are convertible. For example:basic_waitable_timer< clock_type, traits_type, io_context::executor_type > timer1(my_io_context); basic_waitable_timer< clock_type, traits_type, any_io_executor // polymorphic wrapper > timer2(std::move(timer1));
gcc
10.
co_spawn
that launch an awaitable. This
change allows us to write:co_spawn(executor, echo(std::move(socket)), detached);
co_spawn(executor, [socket = std::move(socket)]() mutable { return echo(std::move(socket)); }, detached);
use_awaitable_t
's default
executor adapter, to enable conversion between executor types.
detached_t
as a default completion
token, by adding members as_default_on()
and as_default_on_t<>
.
ssl::stream<>
.
ssl::stream<>
write operations to linearise
gather-write buffer sequences.
asio_handler_invoke
hook. This hook was deprecated with the introduction of the Networking
TS trait associated_executor
and function get_associated_executor()
.
Compiling an application with ASIO_NO_DEPRECATED
will now
trigger a compile error if any handler implements the asio_handler_invoke
hook.
asio_handler_allocate
and asio_handle_deallocate
hooks. These hooks were deprecated
with the introduction of the Networking TS trait associated_allocator
and function get_associated_allocator()
. Compiling an application
with ASIO_NO_DEPRECATED
will now trigger a compile error if
any handler implements the asio_handler_allocate
or asio_handler_deallocate
hooks.
recv
rather
than recvmsg
, send
rather than sendmsg
,
read
rather than readv
, and write
rather than writev
.
executor
.
errno
and error codes when on an
error path.
io_context::exeutor_type
) is detected.
ASIO_HANDLER_LOCATION((file_name,
line, function_name))
macro may be used to inform the handler tracking
mechanism of a source location. This macro declares an object that is placed
on the stack. Then, when an asynchronous operation is launched with location
information, it outputs lines using the <action>
n^m
, prior to the n*m
line that signifies
the beginning of the asynchronous operation. For example:
@asio|1589423304.861944|>7|ec=system:0,bytes_transferred=5 @asio|1589423304.861952|7^8|in 'async_write' (./../../../include/asio/impl/write.hpp:330) @asio|1589423304.861952|7^8|called from 'do_write' (handler_tracking/async_tcp_echo_server.cpp:62) @asio|1589423304.861952|7^8|called from 'operator()' (handler_tracking/async_tcp_echo_server.cpp:51<EMAIL_ADDRESS>@asio|1589423304.861975|.8|non_blocking_send,ec=system:0,bytes_transferred=5 @asio|1589423304.861980|<7|
std::source_location
or std::experimental::source_location
are available, the use_awaitable_t
token (when default-constructed
or used as a default completion token) will also cause handler tracking
to output a source location for each newly created asynchronous operation.
A use_awaitable_t
object may also be explicitly constructed
with location information.
handlerviz.pl
tool.
handlerlive.pl
tool, which processes handler
tracking output to produce a list of "live" handlers. Live handlers
are those that are associated with pending asynchronous operations, as
well as handlers that are currently executing. For example:
cat output.txt | perl handlerlive.plor:
perl handerlive.pl < output.txtor:
perl handlerlive.pl output.txt
handlertree.pl
tool, which filters handler
tracking output to include only those events in the tree that produced
the nominated handlers. For example, to filter the output to include only
the events associated with handlers 123
, 456
,
and their predecessors:
cat output.txt | perl handlertree.pl 123 456or:
perl handlertree.pl 123 456 < output.txt
cat output.txt | \ perl handlertree.pl `perl handlerlive.pl output.txt` | \ perl handlerviz.pl | \ dot -Tsvg > output.svg
async_compose
to work with copyable handlers when passed
by lvalue.
co_spawn
.
Executor
base class from the executor_binder
implementation.
noexcept
.
ssl::host_name_verification
class, which is a drop-in
replacement for ssl::rfc2818_verification
. The ssl::rfc2818_verification
class has been marked as deprecated. As a consequence of this change, SSL
support now depends on functions that were introduced in OpenSSL 1.0.2.
ssl::context
constructor to take ownership of a native
handle.
gcc
to use
__cplusplus
macro.
strand<>
converting constructors and assignment
operators.
async_read
overloads.
ssl::context
class to propagate non-EOF errors
from the add_certificate_authority
function.
thread_pool
destructor hang that
occurred when the pool had an associated I/O object.
select
reactor to recreate the "self
pipe trick" sockets on error. This addresses an issue on some versions
of Windows, where these sockets are discconected after a system sleep.
priority_scheduler
example to demonstrate calls
to shutdown()
and destroy()
.
use_awaitable_t::as_default_on
function.
boost::placeholders
namespace.
async_compose
implementation
due to incorrect overload selection.
async_initiate
helper function to automatically
deduce its return type. This is enabled for C++11 or later.
return_type
.
async_initiate
.
completion_signature<T>
: Checks if T
is a signature of the form R(Args...)
.
completion_handler_for<T, Signature>
: Checks if
T
is usable as a completion handler with the specified
signature.
completion_token_for<T, Signature>
: Checks if
T
is a completion token that can be used with async_initiate
and the specified signature.
(BOOST_)ASIO_COMPLETION_SIGNATURE
,
(BOOST_)ASIO_COMPLETION_HANDLER_FOR
, and (BOOST_)ASIO_COMPLETION_TOKEN_FOR
are provided. These macros expand to typename
when concepts
are unsupported.
rebind_executor
to all I/O
object types, as a way to generically rebind them to use alternative I/O
executors. For example:
using my_socket_type = tcp::socket::rebind_executor<my_executor_type>::other;
executor_type
and member function get_executor()
. Note that the presence
of executor_type
and get_executor()
should be
treated as optional, and consequently it may be preferable to access them
via the associated_executor
trait and the get_associated_executor()
helper function.
default_completion_token
trait, so that every I/O
executor type now has an associated default completion token type. This
trait may be used in asynchronous operation declarations as follows:
template < typename IoObject, typename CompletionToken = typename default_completion_token< typename IoObject::executor_type >::type > auto async_xyz( IoObject& io_object, CompletionToken&& token = typename default_completion_token< typename IoObject::executor_type >::type{} );
void
, meaning
no default completion token type is available for the given I/O executor.
default_completion_token
trait for the use_awaitable
completion token, so that it may be used as shown in the following example:
auto socket = use_awaitable.as_default_on(tcp::socket(my_context)); // ... co_await socket.async_connect(my_endpoint); // Defaults to use_awaitable.
socket
object is transformed
from tcp::socket
to have an I/O executor with the default
completion token set to use_awaitable
. Alternatively, the
socket type may be computed directly:
using tcp_socket = use_awaitable_t<>::as_default_on_t<tcp::socket>; tcp_socket socket(my_context); // ... co_await socket.async_connect(my_endpoint); // Defaults to use_awaitable.
async_initiate
to the Windows-specific I/O objects'
asynchronous operations.
basic_socket_acceptor<ip::tcp, my_executor_type>
basic_stream_socket<ip::tcp, my_executor_type>
Protocol
copy and move operations
never throw.
Endpoint
default constructor and move
operations never throw.
noexcept
qualifier to protocol accessors.
noexcept
qualifier to socket move constructors.
case
fall-through
in the free function connect()
implementation.
is_*_buffer_sequence
detection traits for user-defined
sequence types.
CancelIoEx
entry point.
get_option()
member function to be
const.
shutdown
function.
is_dynamic_buffer
.
async_accept
between sockets with different
executor types.
Executor
template
parameter. This template parameter defaults to the asio::executor
type (the polymorphic executor wrapper) but can be used to specify
a user-defined executor type.
asio::io_context&
now accept either an Executor
or a reference to a concrete ExecutionContext
(such
as asio::io_context
or asio::thread_pool
).
io_context
for constructing
another I/O object, as in:
asio::steady_timer my_timer(my_socket.get_executor().context());
asio::steady_timer my_timer(my_socket.get_executor());
io_context
:asio::steady_timer my_timer(my_io_context);
get_io_context
and get_io_service
member functions have now been removed.
async_result
form with an initiate
static member function.
async_result
template now supports a new form:
template <typename CompletionToken, typename Signature> struct async_result { typedef /* ... */ return_type; template <typename Initiation, typename RawCompletionToken, typename... Args> static return_type initiate( Initiation&& initiation, RawCompletionToken&& token, Args&&... args); };
initiate
member function must: (a) transform the
token into a completion handler object handler
; (b)
cause the invocation of the function object initiation
as if by calling std::forward<Initiation>(initiation)(std::move(handler),
std::forward<Args>(args)...)
. Note that the invocation
of initiation
may be deferred (e.g. lazily evaluated),
in which case initiation
and args
must
be decay-copied and moved as required.
async_initiate
has also been
added as a wrapper for the invocation of async_result<>::initiate
.
For backward compatibility, this function supports both the old and
new async_result
forms.
async_initiate
.
handler_type
trait and single-argument
form of async_result
have now been removed.
asio
namespace.
awaitable<>
, co_spawn
, this_coro
,
detached
, and redirect_error
facilities
have been moved from the asio::experimental
namespace
to namespace asio
. As part of this change, the this_coro::token()
awaitable has been superseded by the asio::use_awaitable
completion token.
use_awaitable
and redirect_error
completion tokens work only with asynchronous operations that use
the new form of async_result
with member function initiate
.
Furthermore, when using use_awaitable
, please be aware
that the asynchronous operation is not initiated until co_await
is applied to the awaitable<>
.
DynamicBuffer_v2
concept which is CopyConstructible.
DynamicBuffer_v2
, which supports copy construction.
These new type requirements enable dynamic buffers to be used as
arguments to user-defined composed operations, where the same dynamic
buffer object is used repeatedly for multiple underlying operations.
For example:template <typename DynamicBuffer> void echo_line(tcp::socket& sock, DynamicBuffer buf) { n = asio::read_until(sock, buf, '\n'); asio::write(sock, buf, asio::transfer_exactly(n)); }
DynamicBuffer
type requirements have been
renamed to DynamicBuffer_v1
. These requirements continue
to be compatible with the Networking TS.
is_dynamic_buffer_v1
and is_dynamic_buffer_v2
have been added to test for conformance to DynamicBuffer_v1
and DynamicBuffer_v2
respectively. The existing is_dynamic_buffer
trait has been retained and delegates to is_dynamic_buffer_v1
(unless ASIO_NO_DYNAMIC_BUFFER_V1
is explicitly defined,
in which case it delegates to is_dynamic_buffer_v2
).
dynamic_string_buffer
and dynamic_vector_buffer
classes conform to both DynamicBuffer_v1
and DynamicBuffer_v2
requirements.
ASIO_NO_DYNAMIC_BUFFER_V1
is defined, all support
for DynamicBuffer_v1
types and functions is #ifdef-ed
out. Support for using basic_streambuf
with the read
,
async_read
, read_until
, async_read_until
,
write
, and async_write
functions is also
disabled as a consequence.
async_compose
function that simplifies the implementation
of user-defined asynchronous operations.
make_strand
function, which creates a strand
with a deduced Executor
template argument.
local::basic_endpoint
that takes a
string_view
.
ip::address
,
ip::address_v4
, ip::address_v6
, ip::basic_endpoint
,
and executor_work_guard
classes.
buffer_sequence_begin
and buffer_sequence_end
functions.
ASIO_DISABLE_VISIBILITY
configuration #define
that allows visibility pragmas to be disabled. (Note: If symbols are hidden,
extra care must be taken to ensure that Asio types are not passed across
shared library API boundaries.)
ASIO_STANDALONE
automatically if C++11 or later is detected.
ASIO_ENABLE_BOOST
to explicitly
disable standalone mode when compiling with C++11 or later.
configure
script now defaults to a standalone build
unless Boost is specified or detected.
error::message_size
) occurs on a datagram-oriented
socket.
SO_REUSEPORT
when the reuse_address
option is set.
unistd.h
when targeting Haiku OS, to fix
feature detection.
network_v[46].hpp
headers to the top-level convenience
header.
pthread_cond_timedwait
.
EndpointSequence
iterator type rather than assume the presence of a const_iterator
typedef.
buffer_sequence_begin
and buffer_sequence_end
to prevent implicit conversion. This change addresses an issue where a
call to buffer_sequence_begin
or buffer_sequence_end
could trigger an implicit conversion to const_buffer
or mutable_buffer
.
Whenever this implicit conversion occurred, the return value of buffer_sequence_begin
or buffer_sequence_end
would point to a temporary object.
eof
error on SSL shutdown as it actually indicates
success.
SSL_ERROR_SYSCALL
result without an associated error.
<atomic>
when targeting apple/clang/libc++
with recent Xcode versions, even for C++03. This fixes a warning about
the deprecation of OSMemoryBarrier
.
decltype
support for
that compiler.
_WIN32_WINNT
to 0x0601
(Windows 7).
dispatch
documentation to note that it may call the
supplied function object in the current thread.
post
and defer
documentation to clarify
the the distinction between them.
std::future
availability
with libstdc++.
read_until
.
std::experimental::string_view
and std::string_view
with newer clang/libc++.
std::invoke_result
.
decltype
is available.
size()
, max_size()
or
empty()
on default-constructed resolver results.
std::string_view
detection issue when using clang-cl.
io_context::executor_type::dispatch
.
basic_socket_acceptor::get_option
.
experimental::detached
completion token.
experimental::redirect_error
completion token.
experimental::co_spawn
facility for integration
with the coroutines technical specification.
asio::steady_timer
rather than asio::deadline_timer
.
asio::dynamic_buffer
rather than asio::streambuf
.
asio::io_context::run_for()
function for
blocking clients.
(BOOST_)ASIO_NO_DEPRECATED
is defined.
(BOOST_)ASIO_USE_BOOST_DATE_TIME_FOR_SOCKET_IOSTREAM
to enable the old Boost.Date_Time interface in basic_socket_streambuf
and basic_socket_iostream
.
is_dynamic_buffer
trait.
async_result
incompatibility with deprecated handler_type
.
basic_resolver_results::value_type
typedef.
SSL_OP_NO_COMPRESSION
is defined.
add_certificate_authority
to process multiple certificates
in a bundle.
std::invoke_result
rather than std::result_of
.
std::string_view
for C++17 or later, and std::experimental::string_view
for C++14. Define the preprocessor macro (BOOST_)ASIO_DISABLE_STD_STRING_VIEW
to force the use of std::experimental::string_view (assuming it is available)
when compiling in C++17 mode.
DynamicBuffer
template arguments are decayed before
using in enable_if
tests.
basic_yield_context
to work with completion signatures
containing reference parameters.
spawn()
correctly
store decayed copies of their function and handler arguments.
basic_socket<Protocol,
SocketService>
we now have simply basic_socket<Protocol>
.
The old interface can be enabled by defining the (BOOST_)ASIO_ENABLE_OLD_SERVICES
macro.
io_context
basis.
ssl::stream<>
constructor argument.
Executor
type requirements and classes to support
an executor framework, including the execution_context
base class, the executor_work
class for tracking outstanding
work, and the executor
polymorphic wrapper. Free functions
dispatch()
, post()
and defer()
have been added and are used to submit function objects to executors.
wrap()
is used to associate
an executor with a handler or other object. The handler hooks for
allocation, invocation and continuation have been deprecated.
system_executor
class has been added as a default
executor.
io_service
class is now derived from execution_context
and implements the executor type requirements in its nested executor_type
class. The member functions dispatch()
, post()
,
defer()
and wrap()
have been deprecated.
The io_service::work
class has been deprecated.
io_service
member function reset()
has been renamed to restart()
. The old name is retained
for backward compatibility but has been deprecated.
make_service<>()
function is now used to add
a new service to an execution context such as an io_service
.
The add_service()
function has been deprecated.
strand<>
template has been added to allow
strand functionality to be used with generic executor types.
io_service
via a context()
member
function. The get_io_service()
member function is deprecated.
io_service::post()
,
io_service::dispatch()
, io_service::strand::post()
and io_service::strand::dispatch()
functions still require
copyable handlers.
expiry()
member function for obtaining the expiry
time. The accessors expires_at()
and expires_after()
have been deprecated, though those names are retained for the mutating
members.
std::packaged_task
class template is now supported
as a completion handler. The initiating operation automatically returns
the future associated with the task. The package()
function
has been added as a convenient factory for packaged tasks.
wait()
and async_wait()
operations that may be used to wait
for readiness. The null_buffers
type has been deprecated.
address_cast<>()
,
make_address()
, make_address_v4()
and
make_address_v6()
free functions. The from_string()
,
to_v4()
, to_v6()
and v4_mapped()
member functions have been deprecated.
ip::address
now represents an
invalid address value that is neither IPv4 nor IPv6.
buffer()
overloads that generate mutable buffers
for non-const string
objects.
asio::streambuf
class.
This support includes:
dynamic_string_buffer
and dynamic_vector_buffer
adapter classes that meet the DynamicBufferSequence
type requirements.
dynamic_buffer()
factory functions for creating
a dynamic buffer adapter for a vector
or string
.
read()
, async_read()
,
write()
and async_write()
, read_until()
and async_read_until()
free functions that directly
support dynamic buffer sequences.
address_iterator_v4
for iterating across IPv4
addresses
address_iterator_v6
for iterating across IPv6
addresses
address_range_v4
to represent a range of IPv4
addresses
address_range_v6
to represent a range of IPv6
addresses
network_v4
for manipulating IPv4 CIDR addresses,
e.g. <IP_ADDRESS>/24
network_v6
for manipulating IPv6 CIDR addresses,
e.g. ffe0:/120
<asio/ts/*.hpp>
that correspond to the headers in the proposal.
thread_pool
class.
spawn()
to be executor-aware.
spawn()
overload that takes only a function object.
spawn()
and yield_context
to permit nested
calls to the completion handler.
std::endl
to ensure output is
flushed.
ssl::stream<>
bug that may result in spurious
'short read' errors.
ssl::stream<>
constructor argument.
yield_context
object with asynchronous operations.
ConnectEx
function are
mapped to their portable equivalents.
join_group
failures
as non-fatal.
kqueue
reactor so that it works on FreeBSD.
kqueue
reactor which resulted
in spinning when using serial ports on Mac OS.
kqueue
reactor support for read-only file descriptors.
/dev/poll
reactor.
WSASocketW
, as WSASocketA
has been deprecated.
use_future
and spawn()
are not made available when including the asio.hpp
convenience
header.
asio::strand
as deprecated. Use asio::io_service::strand
instead.
kqueue
backend that was introduced
in Asio 1.10.2.
gcc
on AIX.
gcc
problem to do with anonymous enums.
HANDLE
backend change to ignore ERROR_MORE_DATA
.
Instead, the error will be propagated as with any other (i.e. in an error_code
or thrown as a system_error
), and the number of bytes transferred
will be returned. For code that needs to handle partial messages, the
error_code
overload should be used.
signal_set
implementation's
signal number check.
SO_UPDATE_CONNECT_CONTEXT
is defined.
VerifyVersionInfo
rather than GetVersionEx
, as GetVersionEx
has
been deprecated.
asio::spawn()
to work correctly with new Boost.Coroutine
interface.
asio::spawn()
coroutines are correctly
unwound when cleaned up by the io_service
destructor.
io_service::wrap()
and strand::wrap()
.
ConnectEx
,
if available, for connection-oriented IP sockets.
io_service
backend for non-Windows (and non-IOCP
Windows) platforms to use a single condition variable per io_service
instance. This addresses a potential race condition when run_one()
is used from multiple threads.
boost::chrono
and std::chrono
clocks.
EV_CLEAR
handling in the kqueue backend,
to address other cases where the close()
system call may hang
on Mac OS X.
resolver_query_base::flags::operator~
.
select
reactor more efficient on Windows for large
numbers of sockets.
gcc
.
GetQueuedCompletionStatus
timeout workaround
on recent versions of Windows.
FormatMessageW
rather than FormatMessageA
, as the Windows store does not
permit the latter.
io_service
, strand
,
buffers, composed operations, timers, etc., should all work as normal.
cancel()
function is not supported for sockets.
Asynchronous operations may only be cancelled by closing the socket.
null_buffers
are not supported.
tcp::no_delay
and socket_base::keep_alive
options are supported.
ASIO_STANDALONE
on your compiler command
line or as part of the project options. This standalone configuration has
been tested for the following platforms and compilers:
-std=c++11
)
-std=c++11 -stdlib=libc++
)
async_connect
were not correctly propagated through to
the completion handler.
io_service
. When the
bug occurs, the result of an asynchronous operation (error and bytes tranferred)
is incorrectly discarded and zero values used instead. For TCP sockets
this results in spurious end-of-file notifications.
async_wait
on a signal that is already raised.
async_write_at
operations.
HANDLE
backend to treat ERROR_MORE_DATA
as a non-fatal error when returned by GetOverlappedResult
for a synchronous read.
generic
as a keyword. Added
a workaround that renames the namespace to cpp_generic
when
those language extensions are in effect.
async_result
support in 1.10.0. In particular, the buffered stream templates have been
updated so that they adhere to current handler patterns.
use_future
support for Microsoft Visual Studio 2012.
std::min
in the Windows IOCP backend to avoid
a dependency on the <algorithm>
header.
SSL_CTX_clear_options
function.
handler_type
and async_result
,
that allow the customisation of the return type of an initiating function.
asio::spawn()
function, a high-level wrapper for
running stackful coroutines, based on the Boost.Coroutine library. The
spawn()
function enables programs to implement asynchronous
logic in a synchronous manner. For example: size_t n = my_socket.async_read_some(my_buffer,
yield);
. For further information, see Stackful
Coroutines.
asio::use_future
special value, which provides first-class
support for returning a C++11 std::future
from an asynchronous
operation's initiating function. For example: future<size_t>
= my_socket.async_read_some(my_buffer, asio::use_future);
. For further
information, see C++ 2011
Support - Futures.
asio_handler_is_continuation
.
Asynchronous operations may represent a continuation of the asynchronous
control flow associated with the current executing handler. The asio_handler_is_continuation
hook can be customised to return true
if this is the case,
and Asio's implementation can use this knowledge to optimise scheduling
of the new handler. To cover common cases, Asio customises the hook for
strands, spawn()
and composed asynchronous operations.
generic::datagram_protocol
,
generic::raw_protocol
, generic::seq_packet_protocol
and generic::stream_protocol
, which implement the Protocol
type requirements, but allow the user to specify the address family (e.g.
AF_INET
) and protocol type (e.g. IPPROTO_TCP
)
at runtime. For further information, see Support
for Other Protocols.
ip::tcp::socket
can be converted into a generic::stream_protocol::socket
via
move construction. For further information, see Support
for Other Protocols.
basic_socket_acceptor<>
's accept()
and async_accept()
functions to allow a new connection to
be accepted directly into a socket of a more generic type. For example,
an ip::tcp::acceptor
can be used to accept into a generic::stream_protocol::socket
object. For further information, see Support
for Other Protocols.
ASIO_STANDALONE
on your compiler command line or as part of the project options. This standalone
configuration has currently been tested for the following platforms and
compilers:
-std=c++11
)
-std=c++11 -stdlib=libc++
)
ssl::stream<>
class's handshake()
and async_handshake()
functions have been added. These accept a ConstBufferSequence
to be used as initial input to the ssl engine for the handshake procedure.
ssl::context
objects.
set_verify_depth()
function to the ssl::context
and ssl::stream<>
classes.
add_certificate_authority()
,
use_certificate()
, use_certificate_chain()
,
use_private_key()
, use_rsa_private_key()
and use_tmp_dh()
, have been added to the ssl::context
class.
ssl::context
to automatically disable SSL compression
by default. To enable, use the new ssl::context::clear_options()
function, as in my_context.clear_options(ssl::context::no_compression)
.
signal_set
implementation.
#warning
directive.
epoll
implementation.
error_code
with an invalid (i.e. NULL
) error_category
.
basic_waitable_timer
's underlying implementation so
that it can handle any time_point
value without overflowing
the intermediate duration objects.
run()
and poll()
on the same io_service
object.
ssl::rfc2818_verification
class.
asio/detail/winsock_init.hpp
for details.
basic_socket::get_option
's
documentation.
long
rather than int
for SSL_CTX
options, to match OpenSSL.
_snwprintf
to address a compile error due to
the changed swprintf
signature in recent versions of MinGW.
io_service
threads due to running out of work.
accept
as non-fatal.
ip::tcp::iostream
and C++11.
#include <cctype>
, needed for some versions
of MinGW.
gcc
's atomic builtins on ARM CPUs, when
available.
io_service
has been destroyed.
epoll_create1()
function but always fail with ENOSYS.
buffered_write_stream
.
epoll_reactor
backend to do lazy registration
for EPOLLOUT
events.
epoll_reactor
handling of out-of-band data, which
was broken by an incomplete fix in the last release.
OPENSSL_NO_ENGINE
feature test #define
.
windows::object_handle
so that it works with Windows
compilers that support C++11 move semantics (such as g++
).
g++
4.7 when compiling in C++11 mode.
signal_set
handlers were not being delivered
when the io_service
was constructed with a concurrency_hint
of 1.
basic_waitable_timer
based around
the C++11 clock type requirements. It may be used with the clocks from
the C++11 <chrono>
library facility or, if those are
not available, Boost.Chrono. The typedefs high_resolution_timer
,
steady_timer
and system_timer
may be used to
create timer objects for the standard clock types.
windows::object_handle
class for performing waits
on Windows kernel objects. Thanks go to Boris Schaeling for contributing
substantially to the development of this feature.
connect()
can return EAGAIN in certain circumstances.
Remapped this to another error so that it doesn't look like a non-blocking
operation.
buffered_write_stream
.
io_service
is repeatedly run without anything to do.
concurrency_hint
is 1) to eliminate a lock/unlock
pair.
epoll_reactor
speculative operations to
be performed without holding the lock.
epoll_reactor
's
I/O operation immediately before the corresponding handler is called.
This also improves scalability across CPUs when multiple threads
are running the io_service
.
boost::array
or std::array
)
of exactly two buffers.
async_read_until
.
signal()
function from the global namespace.
deadline_timer
implementation so that it does
not read the clock unless the timer heap is non-empty.
null_buffers
operations
so that they obey the user's non-blocking setting.
fd_set
at runtime when
using Windows.
epoll_reactor
initialisation.
(BOOST_)ASIO_STRAND_IMPLEMENTATIONS
to the desired number.
(BOOST_)ASIO_ENABLE_SEQUENTIAL_STRAND_ALLOCATION
flag which switches the allocation of strand implementations to use a round-robin
approach rather than hashing.
strand.post()
is used.
-std=c++0x
mode on g++ 4.5 or higher.
signal()
or sigaction()
.
errno
is preserved across the implementation's
signal handler.
io_service
destructor).
OPENSSL_NO_SSL2
is defined.
tick_count_timer
example by making
the duration type signed. Previously, a wait on an already-passed deadline
would not return for a very long time.
(BOOST_)ASIO_ENABLE_OLD_SSL
.
asio::buffer()
overloads for std::array
,
when available. The support is automatically enabled when compiling in
-std=c++0x
mode on g++ 4.3 or higher, or when using
MSVC 10. The support may be explicitly enabled by defining (BOOST_)ASIO_HAS_STD_ARRAY
,
or disabled by defining (BOOST_)ASIO_DISABLE_STD_ARRAY
.
array
,
shared_ptr
, weak_ptr
and atomic
when they are available, rather than the Boost equivalents.
std::error_code
and std::system_error
is no longer enabled by default for g++ 4.5, as that compiler's standard
library does not implement std::system_error::what()
correctly.
fork()
system call. Programs that use
fork()
must call io_service.notify_fork()
at
the appropriate times. Two new examples have been added showing how to
use this feature.
close()
system call. In particular, assume that most operating systems won't have
close()
fail with EWOULDBLOCK
, but if it does
then set the blocking mode and restart the call. If any other error occurs,
assume the descriptor is closed.
EV_ONESHOT
seems to cause problems on some
versions of Mac OS X, with the io_service
destructor getting
stuck inside the close()
system call. Changed the kqueue backend
to use EV_CLEAR
instead.
what()
messages.
shutdown_service()
member functions to be private.
signal_set_service::cancel()
.
SignalHandler
example.
signal_set_service.hpp
so that constants like NSIG
may be used.
signal_set_service
implementation so that it doesn't
assume that SIGRTMAX
is a compile-time constant.
signal_set
.
Programs may add one or more signals to the set, and then perform an async_wait()
operation. The specified handler will be called when one of the signals
occurs. The same signal number may registered with multiple signal_set
objects, however the signal number must be used only with Asio.
(BOOST_)ASIO_ENABLE_HANDLER_TRACKING
, Asio writes debugging
output to the standard error stream. The output records asynchronous operations
and the relationships between their handlers. It may be post-processed
using the included handlerviz.pl
tool to create a visual
representation of the handlers (requires GraphViz).
asio::streambuf
where the consume()
function did not always update the internal buffer pointers correctly.
The problem may occur when the asio::streambuf
is filled with
data using the standard C++ member functions such as sputn()
.
(Note: the problem does not manifest when the streambuf is populated by
the Asio free functions read()
, async_read()
,
read_until()
or async_read_until()
.)
perform()
function are not correctly
re-registered with kqueue.
std::error_code
and std::system_error
is no longer enabled by default for MSVC10, as that compiler's standard
library does not implement std::system_error::what()
correctly.
buffers_iterator<>
and ip::basic_resolver_iterator
classes so that the value_type typedefs are non-const byte types.
ip::tcp::iostream
.
A timeout is set by calling expires_at()
or expires_from_now()
to establish a deadline. Any socket operations which occur past the deadline
will put the iostream into a bad state.
error()
member function to socket iostreams, for
retrieving the error code from the most recent system call.
basic_deadline_timer::cancel_one()
function. This
function lets you cancel a single waiting handler on a timer. Handlers
are cancelled in FIFO order.
transfer_exactly()
completion condition. This
can be used to send or receive a specified number of bytes even if the
total size of the buffer (or buffer sequence) is larger.
connect()
and async_connect()
.
These operations try each endpoint in a list until the socket is successfully
connected.
buffer_size()
function so that it works for buffer
sequences in addition to individual buffers.
buffer_copy()
function that can be used to copy
the raw bytes between individual buffers and buffer sequences.
read()
, read_at()
,
write()
and write_at()
that do not require a
completion condition.
static_assert
is also used to generate an informative error message. This checking may
be disabled by defining (BOOST_)ASIO_DISABLE_HANDLER_TYPE_REQUIREMENTS
.
std::error_code
and std::system_error
,
when available. The support is automatically enabled when compiling in
-std=c++0x
mode on g++ 4.5 or higher, or when using
MSVC 10. The support may be explicitly enabled by defining ASIO_HAS_STD_SYSTEM_ERROR
,
or disabled by defining ASIO_DISABLE_STD_SYSTEM_ERROR
. (Available
in non-Boost version of Asio only.)
is_loopback()
, is_unspecified()
and
is_multicast()
functions consistently available across the
ip::address
, ip::address_v4
and ip::address_v6
classes.
non_blocking()
functions for managing the non-blocking
behaviour of a socket or descriptor. The io_control()
commands
named non_blocking_io
are now deprecated in favour of these
new functions.
native_non_blocking()
functions for managing the
non-blocking mode of the underlying socket or descriptor. These functions
are intended to allow the encapsulation of arbitrary non-blocking system
calls as asynchronous operations, in a way that is transparent to the user
of the socket object. The functions have no effect on the behaviour of
the synchronous operations of the socket or descriptor.
io_control()
member function for socket acceptors.
native_type
typedefs in favour of native_handle_type
, and the native()
member functions in favour of native_handle()
.
release()
member function to posix descriptors. This
function releases ownership of the underlying native descriptor to the
caller.
SOCK_SEQPACKET
).
io_service::stopped()
function that can be used
to determine whether the io_service
has stopped (i.e. a reset()
call is needed prior to any further calls to run()
, run_one()
,
poll()
or poll_one()
).
-std=c++0x
mode on g++ 4.5 or higher, or when using MSVC10.
ip::basic_endpoint<>
objects (such
as ip::tcp::endpoint
and ip::udp::endpoint
).
assign()
may have been dup()
-ed,
and so require explicit deregistration from the reactor.
io_service()
.
The get_io_service()
member functions should be used instead.
resolver_query
and resolver_iterator
from the ip::tcp
, ip::udp
and ip::icmp
classes.
FIONBIO
constant to int to suppress
a compiler warning on some platforms.
-Wshadow
compiler option.
ip::address_v4::broadcast()
is used on 64-bit platforms.
timerfd
support) that prevents timely delivery of deadline_timer
handlers,
after the program has been running for some time.
deadline_timer
may never fire if the io_service
is running in a background
thread.
has_service<>
from compiling.
close()
/closesocket()
failures are correctly
propagated.
InitializeCriticalSectionAndSpinCount
.
pselect()
on HP-UX, if it is available.
deadline_timer
objects
with expiry times set more than 5 minutes in the future may never expire.
0
, as per the documentation.
const_buffers_1
.
Protocol
and id
to avoid clashing with
Objective-C++ keywords.
vector
reallocation performance issue that can occur
when there are many active deadline_timer
objects.
io_control()
implementation on 64-bit Mac
OS X and BSD platforms.
accept()
are incorrectly treated as successes.
asio/impl/src.cpp
in favour of asio/impl/src.hpp
.
#include
s, e.g. if the program uses boost::array but does
not explicitly include <boost/array.hpp>
.)
deadline_timer
implementation to improve performance.
asio::streambuf
with async_read()
and async_read_until()
. These read operations now use the
existing capacity of the streambuf
when reading, rather than
limiting the read to 512 bytes.
asio/impl/src.cpp
in one source file in a program, then build the program with (BOOST_)ASIO_SEPARATE_COMPILATION
defined in the project/compiler settings. Alternatively, (BOOST_)ASIO_DYN_LINK
may be defined to build a separately-compiled Asio as part of a shared
library.
(BOOST_)ASIO_DISABLE_FENCED_BLOCK
to permit
the disabling of memory fences around completion handlers, even if thread
support is enabled.
null_buffers
variant of
async_send_to
.
isdigit
in getaddrinfo
emulation.
buffers_iterator
.
null_buffers
operations on Windows.
timerfd
for dispatching timers on Linux, when
available.
ip::resolver_query_base::flags
as per
the TR2 proposal. This type prevents implicit conversion from int
to flags
, allowing the compiler to catch cases where users
incorrectly pass a numeric port number as the service name.
#define NOMINMAX
for all Windows compilers. Users can
define (BOOST_)ASIO_NO_NOMINMAX
to suppress this definition.
error::eof
result to the completion handler.
io_control()
member functions to always call
ioctl
on the underlying descriptor when modifying blocking
mode.
InternetProtocol::resolver_query
and InternetProtocol::resolver_iterator
,
as neither typedef is part of the documented InternetProtocol
requirements. The corresponding typedefs in the ip::tcp
,
ip::udp
and ip::icmp
classes have been deprecated.
select()
.
(BOOST_)ASIO_DISABLE_THREADS
macro that allows Asio's
threading support to be independently disabled.
boost::addressof
to get the address of handler objects, rather than applying operator&
directly.
OVERLAPPED
structure to be valid until both the initiating
function call has returned and the completion packet has been delivered.
boost_
prefix to the extern "C"
thread entry point function.
getaddrinfo
emulation, only check the socket type (SOCK_STREAM
or SOCK_DGRAM
) if a service name has been specified. This
should allow the emulation to work with raw sockets.
buffered*_stream<>
templates to treat 0-byte
reads and writes as no-ops, to comply with the documented type requirements
for SyncReadStream
, AsyncReadStream
, SyncWriteStream
and AsyncWriteStream
.
throw
keyword to boost::throw_exception()
to allow Asio to be used when exception support is disabled. Note that
the SSL wrappers still require exception support.
HANDLE
fails.
_GLIBCXX_DEBUG
is defined.
(BOOST_)ASIO_HASH_MAP_BUCKETS
may be used to tweak the sizes used for the bucket arrays. (N.B. this feature
introduced a bug which was fixed in Asio 1.4.3 / Boost 1.40.)
io_control()
so that it adheres
to the documented type requirements for IoControlCommand.
ReadFile
call fails with ERROR_MORE_DATA
. This enables a hack where
a windows::stream_handle
can be used with a message-oriented
named pipe.
(BOOST_)ASIO_DISABLE_SERIAL_PORT
is defined.
windows::overlapped_ptr::complete()
are
correctly passed to the completion handler.
size_t CompletionCondition(error_code
ec, size_t total)
, where the return value indicates the maximum
number of bytes to be transferred on the next read or write operation.
(The old CompletionCondition signature is still supported for backwards
compatibility).
windows::overlapped_ptr
class to allow arbitrary overlapped
I/O functions (such as TransmitFile
) to be used with Asio.
eventfd
descriptor is now
used (rather than a pipe) to interrupt a blocked select/epoll reactor.
lowest_layer()
.
io_service
implementations now use lazy initialisation
to reduce the memory usage of an io_service
object used only
as a message queue.
HANDLE
s such as
named pipes (requires HANDLE
s that work with I/O completion
ports).
HANDLE
s such as files
(requires HANDLE
s that work with I/O completion ports).
null_buffers
type.
read_until()
and async_read_until()
overloads that take a user-defined function object for locating message
boundaries.
(BOOST_)ASIO_ENABLE_TWO_LOCK_QUEUE
)
that may provide better io_service
scalability across many
processors.
First stable release of Asio.


--- layout: post title: Get Previously Saved Changes in Rails date: '2012-07-31T15:05:45-05:00' tags: - rails - tips permalink: /post/28425724540/get-previously-saved-changes-in-rails ---
Some times you need to see what fields changed in an object in Rails. I’ve known for awhile that you could do this before an object saved:
user = User.last
user.name = "schneems"
puts user.name_changed?
# => true
puts user.changes
# => {"name"=>["richard", "schneems"]}
but as soon as you save the object to the database you lose all that goodness.
user.save
puts user.name_changed?
# => false
puts user.changes
# => {}
What if we wanted to get the changes before those values were committed? We can use the previous_changes
method!
user.save
puts user.name_changed?
# => false
puts user.previous_changes
# => {"name"=>["richard", "schneems"], "updated_at"=>[Tue, 31 Jul 2012 18:53:12 UTC +00:00, Tue, 31 Jul 2012 18:56:49 UTC +00:00]}
It’s that simple. Go forth and make changes with impunity! Your previous results will be available when you need them.
(This only works when the object is still in memory, if you pull a user from the database changes
and previous_changes
will both be blank).


Installation
Welcome to Tectonic! This guide will walk you through installing Tectonic in your redux app. It shouldn’t take more than 20 minutes for you to get started with making your first request. Installation happens over a few steps:
- Write out your models and add some default values to them.
- Add the tectonic reducer to your store
- Set up the manager by specifying drivers and your redux store
- Specify your API endpoints as source definitions
- Add the manager to the root of your project
Let’s get started!
1. Define some models
One of the core aspects of tectonic are models. Similar to models in frameworks such as rails, a model defines a particular resource in your app - such as a user.
You can define a model by extending tectonic’s base model class and adding the model’s fields:
import { Model } from 'tectonic';
export class User extends Model {
// 'modelName' is a required field and must be unique among all models
static modelName = 'user';
// 'fields' define the attributes that this model can hold, along with
// any default values for a new, empty model. These default vaues are
// also passed to a component when data is pending.
static fields = {
id: undefined,
name: 'Anonymoose',
email: '',
}
getObfuscatedEmail() {
if (this.email.indexOf('@') < 0) {
return '';
}
return `${this.email[0]}...${this.email.substr('@')}`
}
}
Models are immutable by default; internally these models extend ImmutableJS records.
You can also define functions for each model, as demonstrated above. This helps co-locate all model related code without repetition, keeping your components free from data logic.
For more information about the model API view API-MODEL.md.
2. Add the tectonic reducer to your store
Add the tectonic reducer using the tectonic key within combineReducers. This is important: the manager always expects it to be named tectonic.
// within store.js
import {
applyMiddleware,
createStore,
combineReducers,
} from 'redux';
import { reducer as tectonicReducer } from 'tectonic';
// tectonic *must* be added under the "tectonic" namespace
const reducers = combineReducers({
tectonic: tectonicReducer,
...
});
// create a store with your optional middleware
const store = createStore(reducers);
export default store;
Awesome stuff - the reducer is added! Now we can set up the manager.
3. Set up the manager
The MANAGER joins all tectonic components together, and specifies all of the options of Tectonic. Let’s add a manager to our project:
// manager.js
import { Manager, Resolver } from 'tectonic';
import TectonicSuperagent from 'tectonic-superagent'; // superagent driver
// your store with the tectonic middleware added
import store from './store.js';
// create a new manager with all of the options provided
const manager = new Manager({
// the resolver matches queries against your source definitions (API endpoints)
// and invokes them.
resolver: new Resolver(),
// drivers specifies all of the drivers for use when data loading. each
// source definition must use one of these drivers.
drivers: {
// install the superagent driver with default options. For more options
// such as global request modifiers (eg. to add headers to every request)
// see the tectonic-superagent documentation.
fromSuperagent: new TectonicSuperagent(),
},
// give the manager access to your redux store so we can save data within
// the tectonic reducer
store: store,
});
export default manager;
That’s literally it. Generally the only thing you’re going to customize here are the drivers. Now that you’ve got a manager instance we can specify some source definitions for loading data (eg. your API endpoints).
For more information on the manager API head to MANAGER-API
4. Specify API endpoints
Now we need to define some sources for our data so that tectonic can make requests. These SOURCE DEFINITIONS are important in tectonic; each QUERY that you make to load or update data is matched against every SOURCE DEFINITION to find the correct API endpoint to hit.
For example, when you ask to load a single user item with an ID of “1” we look through all of your sources for an API endpoint that will return a user item, and ensure that the API endpoint accepts “id” as a parameter.
Before you begin make sure that you have some drivers defined in your manager. Now, let’s get started:
// Import the models that you've defined within your project so that we
// can associate sources with the models they refer to
import UserModel from './models/user.js';
import PostModel from './models/post.js';
// Define a manager with some drivers
const manager = new Manager({
// ...prior setup
drivers: {
fromSuperagent: new TectonicSuperagent(),
foo: new FooDriver(),
},
});
// Define the API endpoints for the project as a source. Each source needs
// to be associated with a driver; the drivers we set up above are installed
// in `manager.drivers` to be used via the object key names.
//
// In the above setup we have `manager.drivers.fromSuperagent` as the
// superagent drier and `manager.drivers.foo` as the foo driver.
//
// Let's define some API endpoints that use our superagent driver to make
// AJAX requests. Each object defines a single source, so each API endpoint
// needs to be defined separately.
manager.drivers.fromSuperagent([
// this API endpoint returns a list of users
{
meta: {
url: '/api/v1/users',
method: 'GET',
},
returns: UserModel.list(),
},
// this API endpoint returns a single user given the user ID as a
// parameter
{
// 'meta' holds driver-specific data
meta: {
url: '/api/v1/users/:id',
method: 'GET',
},
params: ['id'],
returns: UserModel.item(),
},
// this API endpoint creates a new user
{
// 'meta' holds driver-specific data
meta: {
url: '/api/v1/users',
method: 'POST',
},
// queryType dictates whether this creates, updates or deletes a model.
// The default is 'GET', which returns data from a source without side
// effects.
//
// If you mark this as 'CREATE', this source will only be considered for
// queries which create models; any other query will not use this endpoint.
// Valid options are 'GET', 'CREATE', 'UPDATE', and 'DELETE'.
queryType: 'CREATE',
returns: UserModel.item(),
},
// this API endpoint deletes a user
{
// 'meta' holds driver-specific data
meta: {
url: '/api/v1/users',
method: 'DELETE',
},
queryType: 'DELETE',
// The API returns no data so we leave 'returns' as undefined, but we
// still need to associate this source with the user model. We do this via
// the 'model' key.
model: UserModel,
},
]);
The full API for source definitions is listed in API-MANAGER.md; be sure to check this out for more information on each option to use when defining a source.
Also, for more information on how queries are matched to source definitioons see INTERNALS-RESOLVER.md.
Now, let’s get started on the last quick step before we can load data.
5. Add the manager to the root of your project
Finally, lets make the manager accessible to the @load
decorator so that we
can make queries. To do that we need to add the manager to the root of your
project:
// in your base JSX which is added via react's `render`:
import { Loader } from 'tectonic';
// your manager with all sources defined
import manager from './manager.js';
const App = () => (
{ /* Just below Redux Provider component add Tectonic's loader */ }
<Provider store={ store }>
<Loader manager={ manager }>
{ /* Your app, eg. redux router or your base component */ }
</Loader>
</Provider>
);
export default App;
The Loader
component from tectonic adds manager
to React’s context. This
is how the @load decorator adds queries and fetches data/loading statuses from
your store.
That’s it! You’re ready to use tectonic to manage all of your API data. Let’s make some queries!


WONDER BOYS A film review by Christopher Null Copyright 2000 filmcritic.com filmcritic.com
I have no idea what "wonder boys" are. I assume it's one of many questions that are answered in the novel but which go ignored in this film adaptation.
As it turns out, it doesn't really matter who the WONDER BOYS are. The film has enough substance and, especially, ribald and dark, dark humor to carry it despite a few minor flaws like this.
A very deep character study, WONDER BOYS revolves around Pittsburgh professor and novelist Grady Tripp (Douglas), now struggling with his second novel, which has stretched into 2,600 pages and years in the making. Daytime, he teaches writing to the likes of James (Maguire) and Hannah (Holmes), while attempting to hide his affair with the (married) University Chancellor (McDormand) and keeping his unfinished novel from the grubby hands of his editor (Downey).
Grady's relationship with the talented (yet nearly sociopathic) James becomes the focus of the picture, is Grady tries to coax the hidden writing talent out of James, all while they take a wild ride together through a Pittsburgh winter storm.
The depth of character development in WONDER BOYS defies any hack film critic's two-paragraph description of them. Suffice it to say that WONDER BOYS is often deep and invariably quite funny, especially if you're a fan of black comedy. Case in point: The film really gets going when James kills the blind dog that is attacking Grady's leg. I never knew a dog's carcass could be so funny, and I'm something of an animal lover.
That said, WONDER BOYS is no KINGPIN. This is a sophisticated movie for a sophisticated audience. The cast is universally outstanding. It's especially good to see McDormand in a good role again, and Douglas and Maguire turn in very memorable performances, redeeming them both for some recent, lackluster pictures.
Go. Laugh. Enjoy a little intelligence at the movies for once.
RATING: ****
|------------------------------| \ ***** Perfection \ \ **** Good, memorable film \ \ *** Average, hits and misses \ \ ** Sub-par on many levels \ \ * Unquestionably awful \ |------------------------------|
MPAA Rating: R
Director: Curtis Hanson Producer: Curtis Hanson, Scott Rudin Writer: Steven Kloves Starring: Michael Douglas, Robert Downey Jr., Katie Holmes, Tobey Maguire, Frances McDormand, Richard Thomas, Rip Torn
http://www.wonderboysmovie.com/
--- Christopher Null -<EMAIL_ADDRESS>- http://www.filmcritic.com
The review above was posted to the
rec.arts.movies.reviews newsgroup (de.rec.film.kritiken for German reviews).
The Internet Movie Database accepts no responsibility for the contents of the
review and has no editorial control. Unless stated otherwise, the copyright
belongs to the author.
Please direct comments/criticisms of the review to relevant newsgroups.
Broken URLs inthe reviews are the responsibility of the author.
The formatting of the review is likely to differ from the original due
to ASCII to HTML conversion.
Related links: index of all rec.arts.movies.reviews reviews


{# ------------------------------------------------------- #} {# INDIVIDUAL VIEW FOR EACH people #} {# This page can use any data from http:localhost:2000/cms/#/form/people/ #} {# Webhook uses the SWIG.js (like Djagno/Twig) templating system. Their documentation is here: #} {# http://paularmstrong.github.io/swig/docs/tags/ #} {# Learn about calling data into Webhook pages here: #} {# http://www.webhook.com/docs/template-rules-and-filters/ #} {# ------------------------------------------------------- #} {# Confused what extends and blocks do? Watch a primer: #} {# http://www.webhook.com/docs/template-inheritance-blocks/ #} {% extends "templates/partials/base.html" %} {# This sets our page


#include <XSECCryptoKeyDSA.hpp>
Inheritance diagram for XSECCryptoKeyDSA:
The library uses classes derived from this to process DSA keys.
Public Member Functions | |
Constructors and Destructors | |
| XSECCryptoKeyDSA () | |
| virtual | ~XSECCryptoKeyDSA () |
Key Interface methods | |
| virtual XSECCryptoKey::KeyType | getKeyType () |
| Return the type of this key. | |
| virtual XSECCryptoKey * | clone ()=0 |
| Replicate key. | |
Mandatory DSA interface methods | |
These classes are required by the library. | |
| virtual bool | verifyBase64Signature (unsigned char *hashBuf, unsigned int hashLen, char *base64Signature, unsigned int sigLen)=0 |
| Verify a signature. | |
| virtual unsigned int | signBase64Signature (unsigned char *hashBuf, unsigned int hashLen, char *base64SignatureBuf, unsigned int base64SignatureBufLen)=0 |
| Create a signature. | |
Optional Interface methods | |
These functions do not necessarily have to be implmented. They are used by XSECKeyInfoResolverDefault to try to create a key from KeyInfo elements without knowing anything else.
If an interface class does not implement these functions, a simple stub that does nothing should be used. | |
| virtual void | loadPBase64BigNums (const char *b64, unsigned int len)=0 |
| Load P. | |
| virtual void | loadQBase64BigNums (const char *b64, unsigned int len)=0 |
| Load Q. | |
| virtual void | loadGBase64BigNums (const char *b64, unsigned int len)=0 |
| Load G. | |
| virtual void | loadYBase64BigNums (const char *b64, unsigned int len)=0 |
| Load Y. | |
| virtual void | loadJBase64BigNums (const char *b64, unsigned int len)=0 |
| Load J. |
|
|
|
|
|
|
|
|
Replicate key.
Implements XSECCryptoKey. Implemented in OpenSSLCryptoKeyDSA, and WinCAPICryptoKeyDSA. |
|
|
Return the type of this key. For DSA keys, this allows people to determine whether this is a public key, private key or a key pair Reimplemented from XSECCryptoKey. Reimplemented in OpenSSLCryptoKeyDSA, and WinCAPICryptoKeyDSA. |
|
|
Load G.
Implemented in OpenSSLCryptoKeyDSA, and WinCAPICryptoKeyDSA. |
|
|
Load J.
Implemented in OpenSSLCryptoKeyDSA, and WinCAPICryptoKeyDSA. |
|
|
Load P.
Implemented in OpenSSLCryptoKeyDSA, and WinCAPICryptoKeyDSA. |
|
|
Load Q.
Implemented in OpenSSLCryptoKeyDSA, and WinCAPICryptoKeyDSA. |
|
|
Load Y.
Implemented in OpenSSLCryptoKeyDSA, and WinCAPICryptoKeyDSA. |
|
|
Create a signature. The library will call this function to create a signature from a pre-calculated digest. The output signature is required to be Base64 encoded such that it can be placed directly into the XML document
Implemented in OpenSSLCryptoKeyDSA, and WinCAPICryptoKeyDSA. |
|
|
Verify a signature. The library will call this function to validate a signature
Implemented in OpenSSLCryptoKeyDSA, and WinCAPICryptoKeyDSA. |


Columns live inside Rows
Remember when you are creating your layout that all columns must be contained inside a row and that you must add the col
class to your inner divs to make them into columns
Shadows
Tables
| Name | Item Name | Item Price |
|---|---|---|
| Alvin | Eclair | $0.87 |
| Alan | Jellybean | $3.76 |
| Jonathan | Lollipop | $7.00 |
Collections
Buttons
Stuff button button Button Button ButtonCards
I am a very simple card. I am good at containing small bits of information. I am convenient because I require little markup to use effectively.
I am a very simple card. I am good at containing small bits of information. I am convenient because I require little markup to use effectively.
I am a very simple card. I am good at containing small bits of information. I am convenient because I require little markup to use effectively.
Here is some more information about this product that is only revealed once clicked on.
Form
Collapsible
-
First
Lorem ipsum dolor sit amet.
-
Second
Lorem ipsum dolor sit amet.
-
Third
Lorem ipsum dolor sit amet.
-
First
Lorem ipsum dolor sit amet.
-
Second
Lorem ipsum dolor sit amet.
-
Third
Lorem ipsum dolor sit amet.
-
First
Lorem ipsum dolor sit amet.
-
Second
Lorem ipsum dolor sit amet.
-
Third
Lorem ipsum dolor sit amet.
Modals
Tabs
Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat. Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.


Decorators
Decorators were introduced in TypeScript 1.5[1] and are also porposed for ES2016 by Yehuda Katz.[2] The proposal specifies a decorator as a function that makes it possible to annotate and modify classes and their properties at design time.
Implementing the decorator pattern is already possible in current JavaScript versions by passing an object or function to a decorator method. But the proposed syntax uses @
as a prefix for the decorator function which would make applying decorators very declarative.
A look at TypeScript’s core.d.ts
[3] show that there are currently for different types of decorators:
declare type ClassDecorator = <TFunction extends Function>(target: TFunction) => TFunction | void;
declare type PropertyDecorator = (target: Object, propertyKey: string | symbol) => void;
declare type MethodDecorator = <T>(target: Object, propertyKey: string | symbol, descriptor: TypedPropertyDescriptor<T>) => TypedPropertyDescriptor<T> | void;
declare type ParameterDecorator = (target: Object, propertyKey: string | symbol, parameterIndex: number) => void;
You can apply a decorator by prepending it to whatever you want to decorate. A simple example is to make a class method readonly.[4] The following readonly
function implements this by setting the writable
property of the method to false
. The second code snippet shows how the decorator then is applied to the sayHello
method.
export readonly( target, key, descriptor ) {
descriptor.writable = false;
return descriptor;
}
import { readonly } from 'util/decorators';
class Person {
public name:string;
construcotr( name:string ) {
this.name = name;
}
@readonly
sayHello() {
return `{Hello, my name is ${this.name}}!`;
}
}
The spec does not yet include a decorator for functions, because hoisting makes it not possible. TypeScript conforms the current decorator draft.[5] Regular functions can be decorated by wrapping the decorator arround them, like let decorateFn = decorator(myFunction);
.


2010 Breakthrough
- Signed with Rostrum Records
- Released "K.I.D.S." mixtape
2011 Fame
- "Donald Trump" hits US Billboard 100
- Released "K.I.D.S." mixtape
2013 New Highs
- Founded record label REMember Music
- Triple platinum feature on "The Way"
2014-2018 Self Reflection
- Refines personal style, 3 major releases
- Critical acclaim, tops Billboard charts
2018 Death
- Thousands attend vigil in Pittsburgh
- Mac Miller Circles Fund raises $700,000


We buy dogs!
- synergize granular communities
- deploy 24/7 e-services
- cultivate viral schemas
- architect rich markets
- recontextualize visionary bandwidth
- aggregate visionary infomediaries
- monetize 24/7 platforms
- seize ubiquitous ROI
- transform mission-critical models
- utilize plug-and-play networks
- evolve mission-critical vortals
- redefine end-to-end users


BBBCSIO
The PRUEventHandler Class
The PRUEventHandler Class
Provides the storage and handling of the various items associated with a PRU Event
Source Code
The source code for this class is available online for
download
and also in
browseable form.
Example Code
Sample code which demonstrates the use of this class can be found on the PRU Interrupts Host example page.
Syntax
public class PRUEventHandler
Provides the storage and handling of the various items associated with a PRU Event.
Public Constructors
public PRUEventHandler(PRUEventEnum pruEventIn, PRUDriver pruDriverIn)
Constructor.
- Parameters
- pruEventIn - The event we represent.
- pruDriverIn - The PRUDriver object which created this event data object.
Public Methods
public void StartPRUEventMonitor()
Starts the interrupt event thread for a PRU event. There is one thread per interrupt event.
Basically what is happening here is that we are starting a separate thread which will immediately try to read the UIO file and will block on it until an event happens. Once the event happens, a user specified handler is called to process the interrupt data and clear the interrupt.
public void StopPRUEventMonitor()
Stops the pru event monitor thread. Since the worker thread immediately enters into a blocking read we just hard kill the thread.
public UInt32 WaitForEvent()
Waits for the specified event. Will stall with a blocking read until the event is triggered.
- Returns
- the total number of events processed by the uio file (from any source) since boot up.
Public Properties
public int EventFD { get;set }
Gets/sets the PRU event file descriptor. THis is the file descriptor of the open UIO file.
- value
- The PRU event file descriptor.
public int InterruptEventsReceived { get;set }
Gets/Sets the count of events received.
- value
- count of events received.
public int InterruptEventsSent { get;set }
Gets/Sets the count of events sent.
- value
- count of events sent.
public PRUEventEnum PRUEvent { get }
Gets the PRU event. There is no set accessor - this value is fixed when this object is created.
- value
- The PRU event.
public PRUDriver PRUEventDriver { get }
gets the PRUDriver that created this PRU event. There is no set accessor - this value is fixed when this object is created.
- value
- The PRUDriver object.


Examples:
Table names:
census_neighborhood_demographics_2010
traffic_accidents
The viz.json file is the main source of data for CartoDB JavaScript functions (createVis and createLayer) for creating visualizations in the browser.
Either open in a simple text editor or download a JSON viewer extension for Chrome or Firefox to view it in the browser.
layers
array because it explicitly shows the structure of how visualizations are put together
layers[0]
layers[1]
, may consist of multiple sublayers
layer_name
is the also the name of table where data comes from in the account with key user_name
You can open HTML files on your hard drive from a browser. Use CMD+O or CTRL+O like you’d do to open a file in any program.
Copy & paste template from here.
Overview of template:
map
element<script>
tagsCreate basic visualization using createVis (docs here) by copying and pasting the following:
```javascript window.onload = function() { var vizjson_url = ‘’; // <– Paste viz.json URL between quotes
cartodb.createVis(map_id, vizjson_url) // <-- Change map_id to 'map'
.done(function(vis, layers) {
// do stuff
console.log("Map successfully created");
})
.error(function(err) {
// report error
console.log("An error occurred: " + err);
}); } ```
createVis is excellent for creating maps quickly with very little code. There is a lot of customization with it as well. The documentation is here.
* Reload your browser window, your map should work. *
createLayer is the other main method for bring maps to your browser.
The following is the basic createLayer structure (depends on Leaflet.js):
```javascript window.onload = function() { var layerSource = ‘’; // <– same viz.json as before
var sublayerOptions = { sql: “SELECT * FROM census_neighborhood_demographics_2010”, cartocss: “#census_neighborhood_demographics_2010{polygon-fill:#FF6600;}” }
var sublayers;
// Instantiate map object from Leaflet var mapObj = new L.Map(map_id, { // <– Replace map_id with ‘map’ center: [39.7392, -104.9847], // Denver, Colorado zoom: 11 });
// Add basemap tiles L.tileLayer(‘http://{s}.basemaps.cartocdn.com/light_nolabels/{z}/{x}/{y}.png’, { attribution: ‘© OpenStreetMap contributors’ }).addTo(mapObj);
// Add data tile layer cartodb.createLayer(map_object,layerSource) // <– Replace map_object with mapObj .addTo(mapObj) .done(function(layer) { console.log(“Map successfully created.”); sublayers[0] = layer.getSubLayer(0); sublayers[1] = layer.getSubLayer(1); sublayers[0].set(sublayerOptions); // Here we’re altering the SQL and CartoCSS of only the neighborhoods sublayers[1].hide(); // And hiding the traffic data }) .error(function(err) { console.log(“Map not created: “ + err); }); } ```
One big difference here is that we explicitly expose the SQL and CartoCSS, allowing for easy customization.
Reload your browser window, your map should work
New goal: We’ll create an interactive map that allows us to toggle between the basic view and the view of crashes per neighborhood per capita.
To accomplish this, we need to know how many crashes happened per neighborhood, then divide that number by the population of the neighborhood. We could do a simple SQL JOIN if our data tables both contained the neighborhood name. This is less computationally intensive. To have more fun, we can instead use geospatial functions to find out how many points are inside of a shape. The function is called ST_Intersects
(link to documentation) and is part of the PostGIS extension to PostgreSQL.
Going back to the createLayer example we just created:
Copy the following SQL command and place it below the <style>
tags you just created.
sql
<script type='sql/text' id='sql'>
SELECT
cartodb_id, the_geom,
the_geom_webmercator,
nbrhd_name,
(
SELECT
count(*)
FROM
traffic_accidents
WHERE
ST_Intersects(
traffic_accidents.the_geom,
census_neighborhood_demographics_2010.the_geom
)
) / population AS accidents_per_capita
FROM
census_neighborhood_demographics_2010
</script>
Paste the following CartoCSS structure in the <head>
section of your webpage.
This is a pre-configured Choropleth style. You could also create one on the fly by calculating the range in data and creating bins within that range.
```css
```
sql
in the sublayerOptions object withjavascript
$("#sql").text(),
(don’t forget the comma!), and the string after cartocss
with
javascript
$("#choropleth").text()
These two pieces of code are just a jQuery operation that finds the HTML element that has an id
of sql
or cartocss
and extracts the text contained within it.
Reload your browser window, your map should work
To add more interactivity, we’ll create two buttons to toggle between the Simple
map view and the view that gives a choropleth map. We can easily do this in CartoDB by using the sublayer.setSQL()
and sublayer.setCartoCSS()
methods to change the data
Preview lesson product for next CartoDB.js lesson.
First, create another <style type="cartocss/text" id="simple">
tag set with the following CartoCSS style. Make sure the id
is set to simple
```css /** simple visualization */
polygon-fill: #FF6600; polygon-opacity: 0.7; line-color: #FFF; line-width: 1; line-opacity: 1; } ```
div
with an id='map'
.
```htmlVisualization Selector
```
Wire up the buttons with click events: ```javascript // Create layer selector function createSelector(layer) { var cartocss = “”; var $options = $(“.layer_selector”).find(“li”); $options.click(function(e) { var $li = $(e.target); var selected = $li.attr(‘data’);
$options.removeClass('selected');
$li.addClass('selected');
cartocss = $('#'+selected).text();
layer.setCartoCSS(cartocss); }); } ```
Helpful examples + Interactivity tutorial + Advanced example
```html
</script> ```
Then add this to the sublayerOptions
:
javascript
interactivity: 'cartodb_id, nbrhd_name'
After sublayer[0].set(...)
, add this:
javascript
sublayers[0].infowindow.set('template', $('#infowindow_template').html());
sql.execute(SQL command)
to extract data from your account, place into charts, infowindows, etc.
sql.getBounds(SQL command)
to find the bounding box of data returned by SQL command


Architect designers are responsible for designing structures such as buildings, rooms, business, schools, etc. It maybe outdoors, indoors, private or public. are licensed professionals that are trained in the arts and sciences of designing buildings in which we develop concepts for different types of structures. Besides making buildings/structures aesthetically pleasing, we must make sure structures are safe, economical, and functional.


{% extends "horizon/common/_modal_form.html" %} {% load i18n %} {% block modal-body-right %}
{% trans 'Ownership of a volume can be transferred from one project to another. Once a volume transfer is created in a donor project, it then can be "accepted" by a recipient project. This is equivalent to the cinder transfer-create command.' %}
{% endblock %}


index
|
up
|
prev
|
next
DerefNode Class
Definition at line
305
of
Expression.hpp
Constructors
DerefNode
(
const
Span
& span_)
DerefNode
(
const
Span
& span_,
Node
* subject_)
Member Functions
void
Accept
(
Visitor
& visitor)
override
Node
*
Clone
(
CloneContext
& cloneContext)
const override
std::string
ToString
()
const override
Constructor Details
DerefNode Constructor
cmajor::ast::DerefNode::DerefNode(
const
Span
& span_)
Definition at line
684
of
Expression.cpp
:
684
:
UnaryNode
(
NodeType
::
derefNode
,
span_
)
685
{
686
}
Declaration at line
308
of
Expression.hpp
DerefNode Constructor
cmajor::ast::DerefNode::DerefNode(
const
Span
& span_,
Node
* subject_)
Definition at line
688
of
Expression.cpp
:
688
:
UnaryNode
(
NodeType
::
derefNode
,
span_
,
subject_
)
689
{
690
}
Declaration at line
309
of
Expression.hpp
Member Function Details
Accept Member Function
void
cmajor::ast::DerefNode::Accept(
Visitor
& visitor)
override
Definition at line
697
of
Expression.cpp
:
698
{
699
visitor
.
Visit
(
*
this
)
;
700
}
Declaration at line
311
of
Expression.hpp
Base class overridden functions:
cmajor::ast::Node::Accept
Calls:
cmajor::ast::Visitor::Visit
Clone Member Function
Node
* cmajor::ast::DerefNode::Clone(
CloneContext
& cloneContext)
const override
Definition at line
692
of
Expression.cpp
:
693
{
694
return
new
DerefNode
(
GetSpan
(
)
,
Subject
(
)
->
Clone
(
cloneContext
)
)
;
695
}
Declaration at line
310
of
Expression.hpp
Base class overridden functions:
cmajor::ast::Node::Clone
Calls:
cmajor::ast::DerefNode::Clone
Called by:
cmajor::ast::DerefNode::Clone
ToString Member Function
std::string cmajor::ast::DerefNode::ToString()
const override
Definition at line
702
of
Expression.cpp
:
703
{
704
return
"*"
+
Subject
(
)
->
ToString
(
)
;
705
}
Declaration at line
312
of
Expression.hpp
Base class overridden functions:
cmajor::ast::Node::ToString
Calls:
cmajor::ast::DerefNode::ToString
Called by:
cmajor::ast::DerefNode::ToString
index
|
up
|
prev
|
next


Wednesday, Feb 12, 17:33
Hello, I saw that you are looking to exchange Eu for $USD currency.
Are you still looking to trade?
Yeah
I just got off the plane! Do you have $160?
yep!
What do you think about meeting near Terminal C19?
Wednesday, Feb 12, 17:33
Hey? Are we still on?
Wednesday, Feb 13, 18:00
I am boarding in 1 hour.
Are you there?
Hi, I am here -- I had an urgent business call
Thanks for following up!
Are you ready?
sure
Hey, look, cutest kitten ever!
Yep


Six held for vandalising temple
by Staff ReporterNamakkal police arrested six persons for vandalising a temple near Sendamangalam recently.
The Periyasamy Temple at the foothills of Kolli Hills was vandalised by a group of persons on November 10. They also attacked the house of temple priest Raghu.
Police arrested Paramasivam from Nadukombai bus stand on Thursday. He was sent to judicial custody. On inquiry, police found that Paramasivam had issues with Raghu, his nephew, regarding rights to do rituals at the temple. So, he and the gang attacked the temple and Raghu’s house. Sendamangalam police led by Inspector Deepa arrested five other persons and seized weapons including an unlicensed revolver and a country gun used by the gang for the attack. They have been remanded.


Class DurableOrchestrationClient
Client for starting, querying, terminating, and raising events to new or existing orchestration instances.
Inheritance
Inherited Members
Namespace: Microsoft.Azure.WebJobs
Assembly: Microsoft.Azure.WebJobs.Extensions.DurableTask.dll
Syntax
public class DurableOrchestrationClient
Methods
| Improve this Doc View SourceCreateCheckStatusResponse(HttpRequestMessage, String)
Creates an HTTP response for checking the status of the specified instance.
Declaration
public HttpResponseMessage CreateCheckStatusResponse(HttpRequestMessage request, string instanceId)
Parameters
| Type | Name | Description |
|---|---|---|
| System.Net.Http.HttpRequestMessage | request | The HTTP request that triggered the current function. |
| System.String | instanceId | The unique ID of the instance to check. |
Returns
| Type | Description |
|---|---|
| System.Net.Http.HttpResponseMessage | An HTTP response which may include a 202 and locaton header. |
GetStatusAsync(String)
Gets the status of the specified orchestration instance.
Declaration
public Task<DurableOrchestrationStatus> GetStatusAsync(string instanceId)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | instanceId | The ID of the orchestration instance to query. |
Returns
| Type | Description |
|---|---|
| System.Threading.Tasks.Task<DurableOrchestrationStatus> | Returns a task which completes when the status has been fetched. |
RaiseEventAsync(String, String, Object)
Sends an event notification message to a running orchestration instance.
Declaration
public Task RaiseEventAsync(string instanceId, string eventName, object eventData)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | instanceId | The ID of the orchestration instance that will handle the event. |
| System.String | eventName | The name of the event. |
| System.Object | eventData | The JSON-serializeable data associated with the event. |
Returns
| Type | Description |
|---|---|
| System.Threading.Tasks.Task | A task that completes when the event notification message has been enqueued. |
StartNewAsync(String, Object)
Starts a new execution of the specified orchestrator function.
Declaration
public Task<string> StartNewAsync(string orchestratorFunctionName, object input)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | orchestratorFunctionName | The name of the orchestrator function to start. |
| System.Object | input | JSON-serializeable input value for the orchestrator function. |
Returns
| Type | Description |
|---|---|
| System.Threading.Tasks.Task<System.String> | A task that completes when the start message is enqueued. |
Exceptions
| Type | Condition |
|---|---|
| System.ArgumentException | The specified function does not exist, is disabled, or is not an orchestrator function. |
StartNewAsync(String, String, Object)
Starts a new execution of the specified orchestrator function.
Declaration
public Task<string> StartNewAsync(string orchestratorFunctionName, string instanceId, object input)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | orchestratorFunctionName | The name of the orchestrator function to start. |
| System.String | instanceId | A unique ID to use for the new orchestration instance. |
| System.Object | input | JSON-serializeable input value for the orchestrator function. |
Returns
| Type | Description |
|---|---|
| System.Threading.Tasks.Task<System.String> | A task that completes when the start message is enqueued. |
Exceptions
| Type | Condition |
|---|---|
| System.ArgumentException | The specified function does not exist, is disabled, or is not an orchestrator function. |
TerminateAsync(String, String)
Terminates a running orchestration instance.
Declaration
public Task TerminateAsync(string instanceId, string reason)
Parameters
| Type | Name | Description |
|---|---|---|
| System.String | instanceId | The ID of the orchestration instance to terminate. |
| System.String | reason | The reason for terminating the orchestration instance. |
Returns
| Type | Description |
|---|---|
| System.Threading.Tasks.Task | A task that completes when the terminate message is enqueued. |


Please have someone help you with this; it can be hard to measure yourself!
Or, you may also order XSmall, Small, Medium, Large, or XLarge. For pants, please include inseam.
Neck: around neck where a collar would sit
Back Waist: nape of neck to waist
Shoulders: shoulder to shoulder across back
Sleeve length: nape of neck to wrist, or you may hold your arms out straight in a "T" and measure from wrist to wrist. Let me know if you use this measure of measurement.
Chest: fullest part of chest
Waist: where you would wear your pants or where you want your robes to sit on waist
Hips: fullest part of hips
Inseam: inseam
Outseam: where you wear your slacks, or robe waist will sit, to outer ankle


public class MessageHandler
extends java.lang.Object
game
: the game handled by this instance of MessageHandlerboard
: the board of the gameturnManager
: the turn manager of the game, required by the processing of TRNEND messagesmemoryAction
: HashMap which can be used to memorize the status of an action| Modifier and Type | Field and Description |
|---|---|
private Board |
board |
private Game |
game |
private static java.util.logging.Logger |
LOGGER |
private java.util.HashMap<java.util.UUID,Action> |
memoryAction |
private TurnManager |
turnManager |
| Constructor and Description |
|---|
MessageHandler(Game game)
setup the MessageHandler, initializing the memory structures and assigning the game to handle
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
handleASKACT(GameMessage message,
com.eclipsesource.json.JsonObject jsonMessage)
process ASKACT messages, building the action from the message and then passing it to the moveChecker, if the action is valid it is finally applied to the real
state of the game
|
protected void |
handleASKLDRACT(GameMessage message,
com.eclipsesource.json.JsonObject jsonMessage)
process ASKLDRACT messages, appling the correct logic based on the choose of the client
|
void |
handleMessage(GameMessage message)
given a message, based on its opcode, call the correct routine to process that message
|
protected void |
handleTRNEND(GameMessage message)
process TRNEND messages, calling the correct routines of the TurnManager instance.
|
Action |
parseASKACT(java.util.UUID playerID,
com.eclipsesource.json.JsonObject jsonMessage)
given an ASKACT message this routine perform the parsing to build the action from the JSON message recived
|
private static java.util.logging.Logger LOGGER
private Game game
private TurnManager turnManager
private Board board
private java.util.HashMap<java.util.UUID,Action> memoryAction
public MessageHandler(Game game)
game
- the game to handlepublic void handleMessage(GameMessage message)
message
- the message to processprotected void handleASKACT(GameMessage message, com.eclipsesource.json.JsonObject jsonMessage)
message
- the message containing the ASKACT payload, is taken directly from the MessageManagerjsonMessage
- the JsonObject containing the ASKACT messageprotected void handleASKLDRACT(GameMessage message, com.eclipsesource.json.JsonObject jsonMessage)
message
- the message containing the ASKLDRACT payload, is taken directly from the MessageManagerjsonMessage
- the JsonObject containing the ASKLDRACT messageprotected void handleTRNEND(GameMessage message)
message
- the message containing the TRNEND payload, is taken directly from the MessageManagerjsonMessage
- the JsonObject containing the TRNEND messagepublic Action parseASKACT(java.util.UUID playerID, com.eclipsesource.json.JsonObject jsonMessage)
playerID
- the player who has sent the ASKACT messagejsonMessage
- JsonObject containing the ASKACT message information


The following text is intended to provide a sketch of how the whole thing fits together. It is a brief synopsis of DTN2s implementation, taken entirely from this paper by Michael Demmer and others. For more information about DTN2's architecture and role as a platform for experimentation, see this paper.
The major message processing, management and application support modules of the DTN Bundle forwarding system are provided below. The bundle router module requires the most detailed information regarding the state of the system upon which to base routing decisions. Decisions made by the router are passed as a set of instructions (actions) to the forwarder which is responsible for executing the actions.
This separation between policy and function allows for easy extension, modification, and replacement of the potentially complex router module.
The router component implements all the route selection and scheduling policy decision making. It takes as input a large variety of events that could potentially affect routing decisions and issues encoded instructions that are passed to the bundle forwarder, which is in turn charged with the responsibility to execute them. The forwarder executes the router’s decisions by interacting with the Convergence Layers, Registrations, and the Persistent Store. The separation of router from forwarder represents an instance of separating policy from mechanism. Separating the calculation of instructions from their execution helps to isolate the routing code from changes in the other internal APIs.
Convergence Layers are the adapters between the DTN bundling protocols and various underlying transports, similar to drivers within an operating system. At the most basic level, they perform basic data plane functions: a particular layer must be able to transmit and receive bundles over a single hop (in the overlay topology). In some cases they also process signaling information required by the bundle router (e.g. such as failed connections and restarts). Convergence Layers are discussed in more detail in the following section.
Persistent storage is used to hold the contents of bundles during the store-and-forward process. A common abstraction for persistent storage allows a particular system instance to select (at runtime) to use either a relational database model or a simple file model.
The fragmentation module is responsible for fragmenting and reassembling bundle fragments. This module is capable of sending a signal to the bundle router when all the fragments of a subject bundle have been received.
The Contact Manager is responsible for keeping track of which links are currently available, any historical information regarding their connectivity or performance, and any known future schedules of when connectivity may be available. The primary task of the contact manager is to transform the information learned about contacts from environment-specific mechanisms into abstract contact descriptions that can be used by the bundle router.
The management interface is used to signal the bundle router about any special policy constraints or preferences that may affect its data routing decisions. It is implemented as a generic interprocess communication capability so that multiple applications or processes may be supported.
The console/configuration module provides a command line interface and an event loop for testing and debugging of the implementation, as well as a structured method to set initial configuration options. An embedded Tcl interpreter is used to parse and execute user commands and settings.
DTN applications are written to use a thin library that communicates with the router via an inter-process communication channel. Most of this interaction relates to sending and receiving application messages and manipulating message demultiplexing bindings.
| Interface | Function | Returns | Comments |
|---|---|---|---|
| Open a new connection to the router. | extern int dtn_open(dtn_handle_t* handle) | DTN_SUCCESS | dtn_errno error code. | On success, initializes the handle parameter as a new handle to the daemon and returns DTN_SUCCESS. On failure, sets handle to NULL and returns a dtn_errno error code. |
| Close an open dtn handle. | extern int dtn_close(dtn_handle_t handle); | DTN_SUCCESS | Returns DTN_SUCCESS on success. |
| Get the error associated with the given handle. | extern int dtn_errno(dtn_handle_t handle); | TBC | None |
| Set the error associated with the given handle | extern void dtn_set_errno(dtn_handle_t handle, int err); | TBC | None |
| Build a local endpoint id | extern int dtn_build_local_eid(dtn_handle_t handle, dtn_endpoint_id_t* local_eid, const char* service_tag); | TBC | Build an appropriate local endpoint id by appending the specified service tag to the daemon's preferred administrative endpoint id. |
| Create a dtn registration. | extern int dtn_register(dtn_handle_t handle, dtn_reg_info_t* reginfo, dtn_reg_id_t* newregid); | TBC | If the init_passive flag in the reginfo struct is true, the registration is initially in passive state, requiring a call to dtn_bind to activate it. Otherwise, the call to dtn_bind is unnecessary as the registration will be created in the active state and bound to the handle. |
| Remove a dtn registration. | extern int dtn_unregister(dtn_handle_t handle, dtn_reg_id_t regid); | TBC | If the registration is in the passive state (i.e. not bound to any handle), it is immediately removed from the system. If it is in active state and bound to the given handle, the removal is deferred until the handle unbinds the registration or closes. This allows applications to pre-emptively call unregister so they don't leak registrations. |
| Check for an existing registration. | extern int dtn_find_registration(dtn_handle_t handle, dtn_endpoint_id_t* eid, dtn_reg_id_t* newregid); | DTN_SUCCESS | ENOENT | Check for an existing registration on the given endpoint id. Return DTN_SUCCESS and fill in the registration id if it exists, or return ENOENT if it doesn't. |
| Modify an existing registration. | extern int dtn_change_registration(dtn_handle_t handle, dtn_reg_id_t regid, dtn_reg_info_t *reginfo); | TBC | None |
| Associate a registration with the current ipc channel. | extern int dtn_bind(dtn_handle_t handle, dtn_reg_id_t regid); | TBC | Associate a registration with the current ipc channel. This serves to put the registration in "active" mode. |
| Explicitly remove an association from the current ipc handle. | extern int dtn_unbind(dtn_handle_t handle, dtn_reg_id_t regid); | TBC | Note that this is also implicitly done when the handle is closed. This serves to put the registration back in "passive" mode. |
| Send a bundle. | extern int dtn_send(dtn_handle_t handle, dtn_reg_id_t regid, dtn_bundle_spec_t* spec, dtn_bundle_payload_t* payload, dtn_bundle_id_t* id); | TBC | Send a bundle either from memory or from a file. |
| Cancel a bundle transmission. | extern int dtn_cancel(dtn_handle_t handle, dtn_bundle_id_t* id); | TBC | None |
| Blocking receive for a bundle. | extern int dtn_recv(dtn_handle_t handle, dtn_bundle_spec_t* spec, dtn_bundle_payload_location_t location, dtn_bundle_payload_t* payload, dtn_timeval_t timeout); | TBC | Fill in the spec and payload structures with the bundle data.
The location parameter indicates the manner by which the caller
wants to receive payload data (i.e. either in memory or in a file).
The timeout parameter specifies an interval in milliseconds to block
on the server-side (-1 means infinite wait).
Note that it is advisable to call dtn_free_payload on the returned structure, otherwise the XDR routines will memory leak. |
| Blocking query for new subscribers on a session. | extern int dtn_session_update(dtn_handle_t handle, unsigned int* status, dtn_endpoint_id_t* session, dtn_timeval_t timeout); | Indication that a subscriber was added or removed. | One or more registrations must have been bound to the handle with the SESSION_CUSTODY flag set. Returns an indication that the subscription state in the given session has changed |
| Return a file descriptor for the given handle. | extern int dtn_poll_fd(dtn_handle_t handle); | File descriptor. | Return a file descriptor for the given handle. suitable for calling poll() or select() in conjunction with a call to dtn_begin_poll(). |
| Begin a polling period for incoming bundles. | extern int dtn_begin_poll(dtn_handle_t handle, dtn_timeval_t timeout); | File descriptor | Returns a file descriptor suitable for calling poll() or select() on
(similar to dtn_poll_fd). Note that dtn_bind() must have been
previously called at least once on the handle.
If the kernel returns an indication that there is data ready on the file descriptor, a call to dtn_recv will then return the bundle ithout blocking, then dtn_poll must be called again to wait for more bundles. Also, no other API calls besides dtn_recv can be executed during a polling period, so an app must call dtn_cancel_poll before trying to run other API calls. |
| Cancel a polling interval. | extern int dtn_cancel_poll(dtn_handle_t handle); | TBC | None |
| Interface | Function | Returns | Comments |
|---|---|---|---|
| Copy the contents of one eid into another. | extern void dtn_copy_eid(dtn_endpoint_id_t* dst, dtn_endpoint_id_t* src); | TBC | None |
| Parse a string into an endpoint id structure. | extern int dtn_parse_eid_string(dtn_endpoint_id_t* eid, const char* str); | TBC | Parse a string into an endpoint id structure, validating that it is in fact a valid endpoint id (i.e. a URI |
| Set the value of the given payload structure | extern int dtn_set_payload(dtn_bundle_payload_t* payload, dtn_bundle_payload_location_t location, char* val, int len); | 0 | DTN_ESIZE | Set the value of the given payload structure to either a memory buffer or a file location.Returns: 0 on success, DTN_ESIZE if the memory location is selected and the payload is too big. |
| Free dynamic storage. | void dtn_free_payload(dtn_bundle_payload_t* payload); | TBC | Frees dynamic storage allocated by the xdr for a bundle payload in dtn_recv. |
| Return a string version of a status report reason code. | const char* dtn_status_report_reason_to_str(dtn_status_report_reason_t err); | String | None |


--- layout: post permalink: moshells.html Tags: Array NameOfCoupon: Moshell's Cash Back Summary: See our Moshell's Coupon Code, Moshell's Rebate, Moshell's Promo Code, Moshell's Discount, Moshell's Coupon Cash Back Rebate here. MetaKeywords: Moshell's Coupon Code, Moshell's Rebate, Moshell's Promo Code, Moshell's Cash Back Rebate, Moshell's Discount, Moshell's Coupon Image: images/26094.gif LinkURL: http://www.shareasale.com/r.cfm?b=216551&u=412002&m=26094 affiliate_url_link: http://www.icouponblog.com/jane.php?id=1446 thesis_readmore: See the Moshell's Coupon thesis_thumb: http://www.icouponblog.com/tn.php?merchantURL=moshells.com Title: Save 4% - Moshell's Coupon Code for moshells.com. Moshell's Rebate & Discount thesis_description: Our Moshell's Discount Coupon Code for moshells.com. We have the best Moshell's Rebate anywhere. thesis_keywords: Moshell's, Moshell's Coupon Code, Moshell's Discount, Moshell's Rebate product_name: Moshell's hop_url: http://www.icouponblog.com/hop.php?id=1446 ---
If you are moving into your new home or need every day useful products for your home, you must visit www.moshells.com. They are an online company that carries hundreds of household items including designer products from shower curtain to furniture, bedding to bathroom accessories, kitchen products, children’s furniture, backpacks and lots more. Check out the website and find beautiful, useful and inexpensive products from you home on www.moshells.com. Use our discount coupons to save money.
Visit www.moshells.com and choose from a wide array of products from your home. You can get products up to 80% less than retail price. Get beautiful wooden mini blinds or curtains for your home. You can buy Voile sheer curtains, faux silk or suede curtains, grommet curtains. You can also get high quality, durable shower curtains. Get great bedroom items like soft, comfortable throws, contour foam memory pillows, and get bed raisers, three bag laundry sorters and lots more. All items are high quality, attractive and very low priced.
If you are looking for household items like curtains, beddings, children’s furniture, even school uniforms, you can find all these and much more online at www.moshells.com. You can get designer products at very low prices. Beautify your home. There is something for every room. Check it out. Our discount coupons will get you great deals!


1. Action plans created by an
adviser
| Advisor |
Date created |
| Jenny |
13 July 2016 |
View
|
| Helen |
13 July 2016 |
View
|
| Sai |
13 July 2016 |
View
|
2. Skills health checks
| Name |
Date created |
Link to download |
| My Skills Health Check Doctor |
13 July 2016 |
|
Delete
|
| My Skills Health Check Pharmacist |
13 July 2016 |
|
Delete
|
3. Course searches
| Search |
Date created |
| Chemistry |
13 July 2016 |
View
|
4. CVs
| Name |
Date created |
Link to download |
| My CV Becoming a Doctor 2016 |
13 July 2016 |
|
Delete
|
5. Personal action plans
| Name |
Date created |
Link to download |
| My Personal Action Plan Doctor |
13 July 2016 |
|
Delete
|
| My Personal Action Plan Pharmacist |
13 July 2016 |
|
Delete
|


This project is to help with Quran related meta queries.
Answering Questions like:
getAyaCountinSura
)isAyahJuzFirst
)?findJuz
and findJuzByAyaid
findPage
by surah/ayanextAyah
/prevAyah
)[surah,aya]
to ayaId
and vice-verse ( findSurahByAyaid
and findAyaidBySurah
) In a browser:
<script src="quran-meta.js"></script>
Also modern browsers allow
<script type="module">
import quranMeta from "quran-meta.esm.js"
</script>
The library is available from various CDNs
Using npm:
$ npm i --save quran-meta
In Node.js:
var quranMeta = require('quran-meta');
See here for API documentation
You can find some examples here and souce code for them here
Here you can find the following
| Source code in typescript | TS |
| Javascript code autotranspiled from TS as ES Next | ESNext |
| Javascript code autotranspiled from TS as CJS | ES5+CommonJS |
| distributions of library as | |
UMD/ UMD minified builds can be used directly in the browser via a <script> (see here about UMD format) |
ES5+UMD |
| CommonJS for use with older bundlers like browserify or webpack | ES5+CommonJS |
| ESM for use with modern bundlers like webpack 2 or Rollup | ES5+ESM |
ESM Browser/ESM Browser minified for direct imports in modern browsers via <script type="module"> |
ESNext+ESM |
Generated using TypeDoc


ADD REVIEW
To report a sugar daddy and create a blacklist, all you need is their mobile number. Enter it below and click button. It is, however, reccomended that you enter as much information about the offending sugar daddy as possible.
All the fields below this line are optional. The only mandatory field is the accused sugar daddy's mobile number
Your Rating:
Lies about Relationship Status
Lies about Income
Rude
Physically Abusive
Flaky
Lies about financiaL help
Broke
Lies about Age
Fake Profile Photos