//! This file has been automatically generated by `objc2`'s `header-translator`.
//! DO NOT EDIT
use core::ffi::*;
use core::ptr::NonNull;
use objc2::__framework_prelude::*;
use objc2_foundation::*;

use crate::*;

/// [Apple's documentation](https://developer.apple.com/documentation/webkit/dom_css_inherit?language=objc)
#[deprecated]
pub const DOM_CSS_INHERIT: c_uint = 0;
/// [Apple's documentation](https://developer.apple.com/documentation/webkit/dom_css_primitive_value?language=objc)
#[deprecated]
pub const DOM_CSS_PRIMITIVE_VALUE: c_uint = 1;
/// [Apple's documentation](https://developer.apple.com/documentation/webkit/dom_css_value_list?language=objc)
#[deprecated]
pub const DOM_CSS_VALUE_LIST: c_uint = 2;
/// [Apple's documentation](https://developer.apple.com/documentation/webkit/dom_css_custom?language=objc)
#[deprecated]
pub const DOM_CSS_CUSTOM: c_uint = 3;

extern_class!(
    /// [Apple's documentation](https://developer.apple.com/documentation/webkit/domcssvalue?language=objc)
    #[unsafe(super(DOMObject, WebScriptObject, NSObject))]
    #[derive(Debug, PartialEq, Eq, Hash)]
    #[cfg(all(feature = "DOMObject", feature = "WebScriptObject"))]
    #[deprecated]
    pub struct DOMCSSValue;
);

#[cfg(all(feature = "DOMObject", feature = "WebScriptObject"))]
extern_conformance!(
    unsafe impl NSCopying for DOMCSSValue {}
);

#[cfg(all(feature = "DOMObject", feature = "WebScriptObject"))]
unsafe impl CopyingHelper for DOMCSSValue {
    type Result = Self;
}

#[cfg(all(feature = "DOMObject", feature = "WebScriptObject"))]
extern_conformance!(
    unsafe impl NSObjectProtocol for DOMCSSValue {}
);

#[cfg(all(feature = "DOMObject", feature = "WebScriptObject"))]
impl DOMCSSValue {
    extern_methods!(
        #[deprecated]
        #[unsafe(method(cssText))]
        #[unsafe(method_family = none)]
        pub unsafe fn cssText(&self) -> Retained<NSString>;

        /// Setter for [`cssText`][Self::cssText].
        ///
        /// This is [copied][objc2_foundation::NSCopying::copy] when set.
        #[deprecated]
        #[unsafe(method(setCssText:))]
        #[unsafe(method_family = none)]
        pub unsafe fn setCssText(&self, css_text: Option<&NSString>);

        #[deprecated]
        #[unsafe(method(cssValueType))]
        #[unsafe(method_family = none)]
        pub unsafe fn cssValueType(&self) -> c_ushort;
    );
}

/// Methods declared on superclass `DOMObject`.
#[cfg(all(feature = "DOMObject", feature = "WebScriptObject"))]
impl DOMCSSValue {
    extern_methods!(
        #[deprecated]
        #[unsafe(method(init))]
        #[unsafe(method_family = init)]
        pub unsafe fn init(this: Allocated<Self>) -> Retained<Self>;
    );
}

/// Methods declared on superclass `NSObject`.
#[cfg(all(feature = "DOMObject", feature = "WebScriptObject"))]
impl DOMCSSValue {
    extern_methods!(
        #[unsafe(method(new))]
        #[unsafe(method_family = new)]
        pub unsafe fn new() -> Retained<Self>;
    );
}
