Skip to main content

apple_log/
lib.rs

1#![doc = include_str!("../README.md")]
2#![cfg_attr(docsrs, feature(doc_cfg))]
3#![allow(clippy::module_name_repetitions)]
4
5#[cfg(feature = "async")]
6#[cfg_attr(docsrs, doc(cfg(feature = "async")))]
7pub mod async_api;
8pub mod error;
9pub mod ffi;
10pub mod log;
11pub mod logger;
12pub mod os_activity;
13pub mod os_atomic;
14pub mod os_log;
15pub mod os_log_entry_activity;
16pub mod os_log_entry_boundary;
17pub mod os_log_entry_log;
18pub mod os_log_entry_signpost;
19pub mod os_log_store;
20pub mod os_signpost_id;
21pub mod os_signposter;
22
23mod bridge_support;
24
25pub use error::LogError;
26pub use log::{
27    active_activity_id, active_activity_ids, log, log_enabled, log_with_privacy, ActivityIds,
28};
29pub use logger::{Logger, Privacy};
30pub use os_activity::{OSActivity, OSActivityFlags, OSActivityScope};
31pub use os_atomic::{OSAtomicFifoQueue, OSAtomicI32, OSAtomicI64, OSAtomicQueue};
32pub use os_log::{
33    Level, OSLog, CATEGORY_DYNAMIC_STACK_TRACING, CATEGORY_DYNAMIC_TRACING,
34    CATEGORY_POINTS_OF_INTEREST,
35};
36pub use os_log_entry_activity::OSLogEntryActivity;
37pub use os_log_entry_boundary::OSLogEntryBoundary;
38pub use os_log_entry_log::{OSLogEntryLog, OSLogEntryLogLevel};
39pub use os_log_entry_signpost::{OSLogEntrySignpost, OSLogEntrySignpostType};
40pub use os_log_store::{
41    OSLogEntryCommon, OSLogEntryFromProcess, OSLogEntryWithPayload, OSLogEnumeratorOptions,
42    OSLogMessageArgument, OSLogMessageArgumentCategory, OSLogMessageComponent, OSLogPosition,
43    OSLogStore, OSLogStoreCategory, OSLogStoreEntry, OSLogStoreScope,
44};
45pub use os_signpost_id::{OSSignpostId, SignpostId};
46pub use os_signposter::{OSSignpostInterval, OSSignposter};
47
48/// Common imports.
49pub mod prelude {
50    pub use crate::error::LogError;
51    pub use crate::log::{
52        active_activity_id, active_activity_ids, log, log_enabled, log_with_privacy, ActivityIds,
53    };
54    pub use crate::logger::{Logger, Privacy};
55    pub use crate::os_activity::{OSActivity, OSActivityFlags, OSActivityScope};
56    pub use crate::os_atomic::{OSAtomicFifoQueue, OSAtomicI32, OSAtomicI64, OSAtomicQueue};
57    pub use crate::os_log::{
58        Level, OSLog, CATEGORY_DYNAMIC_STACK_TRACING, CATEGORY_DYNAMIC_TRACING,
59        CATEGORY_POINTS_OF_INTEREST,
60    };
61    pub use crate::os_log_entry_activity::OSLogEntryActivity;
62    pub use crate::os_log_entry_boundary::OSLogEntryBoundary;
63    pub use crate::os_log_entry_log::{OSLogEntryLog, OSLogEntryLogLevel};
64    pub use crate::os_log_entry_signpost::{OSLogEntrySignpost, OSLogEntrySignpostType};
65    pub use crate::os_log_store::{
66        OSLogEntryCommon, OSLogEntryFromProcess, OSLogEntryWithPayload, OSLogEnumeratorOptions,
67        OSLogMessageArgument, OSLogMessageArgumentCategory, OSLogMessageComponent, OSLogPosition,
68        OSLogStore, OSLogStoreCategory, OSLogStoreEntry, OSLogStoreScope,
69    };
70    pub use crate::os_signpost_id::{OSSignpostId, SignpostId};
71    pub use crate::os_signposter::{OSSignpostInterval, OSSignposter};
72}