text
stringlengths
8
4.13M
//! //! //! use crate::populations::{AdjacentFarms, Cattle, FarmId, HerdSize}; use crate::prelude::*; #[cfg(feature = "serialize")] pub fn deserialize_generated_farm_id<'de, D: serde::Deserializer<'de>>( deserializer: D, ) -> Result<FarmId, D::Error> { // let n: usize = usize::deserialize(deserializer)?; let n: usize = serde::Deserialize::deserialize(deserializer)?; Ok(FarmId::new_single_population(n)) } #[cfg(feature = "serialize")] pub fn deserialize_generated_herd_size<'de, D: serde::Deserializer<'de>>( deserializer: D, ) -> Result<HerdSize, D::Error> { // let n: usize = usize::deserialize(deserializer)?; let n: usize = serde::Deserialize::deserialize(deserializer)?; Ok(HerdSize::new_single_population(n)) } #[cfg(feature = "serialize")] pub fn deserialize_generated_adjacent_farms<'de, D: serde::Deserializer<'de>>( deserializer: D, ) -> Result<AdjacentFarms, D::Error> { // let n: usize = usize::deserialize(deserializer)?; let n: Vec<usize> = serde::Deserialize::deserialize(deserializer)?; // dbg!(&n); Ok(AdjacentFarms::new_single_population( n.into_iter().map(FarmId::new_single_population).collect(), )) } #[readonly::make] #[cfg_attr(feature = "serialize", derive(Serialize, Deserialize))] #[derive(Debug, Clone, Bundle)] pub struct CattleFarmBundle { cattle_farm: Cattle, #[serde(deserialize_with = "deserialize_generated_farm_id")] pub farm_id: FarmId, #[serde(deserialize_with = "deserialize_generated_herd_size")] pub herd_size: HerdSize, adjacent_farms: AdjacentFarms, } #[cfg(feature = "serialize")] pub fn load_ring_population() -> impl Iterator<Item = CattleFarmBundle> + Clone { #[cfg_attr(feature = "serialize", derive(Serialize, Deserialize))] #[derive(Debug, Clone)] struct PopulationRecord { #[serde(deserialize_with = "deserialize_generated_farm_id")] farm_id: FarmId, #[serde(deserialize_with = "deserialize_generated_herd_size")] herd_size: HerdSize, } let population_info_file = std::fs::File::open("assets/population_info.json").unwrap(); let population_info_reader = std::io::BufReader::with_capacity(100_000_000, population_info_file); let pop_record: Vec<PopulationRecord> = serde_json::from_reader(population_info_reader).unwrap(); // dbg!(pop_record.iter().take(10).collect_vec()); #[cfg_attr(feature = "serialize", derive(Serialize, Deserialize))] #[derive(Debug, Clone)] struct AdjacencyRecord { #[serde(deserialize_with = "deserialize_generated_farm_id")] farm_id: FarmId, #[serde(rename(deserialize = "adjacent"))] #[serde(deserialize_with = "deserialize_generated_adjacent_farms")] adjacent_farms: AdjacentFarms, } let adjacency = std::fs::File::open("assets/ring_adjacency.json").unwrap(); let adjacency_file_buffer = std::io::BufReader::with_capacity(100_000_000, adjacency); let adjacency: Vec<AdjacencyRecord> = serde_json::from_reader(adjacency_file_buffer).unwrap(); // dbg!(adjacency.iter().take(10).collect_vec()); pop_record.into_iter().zip_eq(adjacency).map(|(info, adj)| { let PopulationRecord { farm_id: pop_farm_id, herd_size, } = info; let AdjacencyRecord { farm_id, adjacent_farms, } = adj; assert_eq!( pop_farm_id, farm_id, "farm id from adjacency and from population info should match" ); CattleFarmBundle { cattle_farm: Cattle, farm_id, herd_size, adjacent_farms, } }) } #[cfg(test)] mod tests { use super::*; #[test] #[cfg(feature = "serialize")] fn test_loading_ring_population() { let iter_cattle_farm_bundle = load_ring_population(); info!("{:#?}", iter_cattle_farm_bundle.take(10).collect_vec()); } }
use std::fs; fn total_mass(size: i32) -> i32 { let mut needed_fuel = size / 3 - 2; let mut fuel_sum = 0; while needed_fuel >= 0 { fuel_sum += needed_fuel; needed_fuel = needed_fuel / 3 - 2; } fuel_sum } fn main() { let input = fs::read_to_string("input.txt") .expect(":("); let sizes = input.lines() .map(|x| x.parse::<i32>().unwrap()); let total_size: i32 = sizes .clone() .map(|x| x / 3 - 2) .sum(); let real_sizes: i32 = sizes .clone() .map(total_mass) .sum(); println!("{}", total_size); println!("{}", real_sizes); }
use glob::glob; use metric; use seahash::SeaHasher; use source::Source; use source::internal::report_full_telemetry; use std::collections::HashMap; use std::fs; use std::hash::BuildHasherDefault; use std::io; use std::io::prelude::*; use std::os::unix::fs::MetadataExt; use std::path::PathBuf; use std::str; use std::time::Duration; use std::time::Instant; use time; use util; use util::send; type HashMapFnv<K, V> = HashMap<K, V, BuildHasherDefault<SeaHasher>>; /// `FileServer` is a Source which cooperatively schedules reads over files, /// converting the lines of said files into `LogLine` structures. As /// `FileServer` is intended to be useful across multiple operating systems with /// POSIX filesystem semantics `FileServer` must poll for changes. That is, no /// event notification is used by `FileServer`. /// /// `FileServer` is configured on a path to watch. The files do _not_ need to /// exist at cernan startup. `FileServer` will discover new files which match /// its path in at most 60 seconds. pub struct FileServer { chans: util::Channel, path: PathBuf, max_read_lines: usize, tags: metric::TagMap, } /// The configuration struct for `FileServer`. #[derive(Debug, Deserialize)] pub struct FileServerConfig { /// The path that `FileServer` will watch. Globs are allowed and /// `FileServer` will watch multiple files. pub path: Option<PathBuf>, /// The maximum number of lines to read from a file before switching to a /// new file. pub max_read_lines: usize, /// The default tags to apply to each discovered LogLine. pub tags: metric::TagMap, /// The forwards which `FileServer` will obey. pub forwards: Vec<String>, /// The configured name of FileServer. pub config_path: Option<String>, } impl Default for FileServerConfig { fn default() -> Self { FileServerConfig { path: None, max_read_lines: 10_000, tags: metric::TagMap::default(), forwards: Vec::default(), config_path: None, } } } impl FileServer { /// Make a FileServer /// pub fn new(chans: util::Channel, config: FileServerConfig) -> FileServer { FileServer { chans: chans, path: config.path.expect("must specify a 'path' for FileServer"), tags: config.tags, max_read_lines: config.max_read_lines, } } } /// The `FileWatcher` struct defines the polling based state machine which reads /// from a file path, transparently updating the underlying file descriptor when /// the file has been rolled over, as is common for logs. /// /// The `FileWatcher` is expected to live for the lifetime of the file /// path. `FileServer` is responsible for clearing away `FileWatchers` which no /// longer exist. struct FileWatcher { pub path: PathBuf, reader: io::BufReader<fs::File>, offset: u64, file_id: (u64, u64), // (dev, ino) } impl FileWatcher { /// Create a new `FileWatcher` /// /// The input path will be used by `FileWatcher` to prime its state /// machine. A `FileWatcher` tracks _only one_ file. This function returns /// None if the path does not exist or is not readable by cernan. pub fn new(path: PathBuf) -> Option<FileWatcher> { match fs::File::open(&path) { Ok(f) => { let mut rdr = io::BufReader::new(f); assert!(rdr.seek(io::SeekFrom::End(0)).is_ok()); let offset = rdr.get_ref().seek(io::SeekFrom::Current(0)).unwrap(); let metadata = fs::metadata(&path).expect("no metadata"); let dev = metadata.dev(); let ino = metadata.ino(); Some(FileWatcher { path: path, reader: rdr, offset: offset, file_id: (dev, ino), }) } Err(_) => None, } } fn reset_from_md(&mut self) -> bool { if let Ok(metadata) = fs::metadata(&self.path) { let dev = metadata.dev(); let ino = metadata.ino(); if (dev, ino) != self.file_id { report_full_telemetry( "cernan.sources.file.switch", 1.0, None, Some(vec![ ( "file_path", &self.path.to_str().expect("could not make path"), ), ]), ); if let Ok(f) = fs::File::open(&self.path) { self.file_id = (dev, ino); self.reader = io::BufReader::new(f); self.offset = 0; return true; } } } false } /// Read a single line from the underlying file /// /// This function will attempt to read a new line from its file, blocking, /// up to some maximum but unspecified amount of time. `read_line` will open /// a new file handler at need, transparently to the caller. pub fn read_line(&mut self, mut buffer: &mut String) -> io::Result<usize> { // This assert doesn't check for equality. Why? The BufReader may jump // way ahead of our current offset but we need to track where we _know_ // we are based on lines because when we seek back to reset the inner // buffer of BufReader will get dumped. assert!( self.offset <= self.reader.get_ref().seek(io::SeekFrom::Current(0)).unwrap() ); let mut attempts = 0; while attempts < 3 { time::delay(attempts); match self.reader.read_line(&mut buffer) { Ok(0) => { // In some situations BufReader will return a read of // zero. That's not success for our purposes and so we // potentially reset from metadata and, if no, go ahead and // back up to the last known good offset. if !self.reset_from_md() { let seek: bool = self.reader.seek(io::SeekFrom::Start(self.offset)).is_ok(); assert!(seek); } } Ok(sz) => { // Success! We've read a line out of the underlying file. We // pull the newline off the end and return the size of the // buffer read without the newline. self.offset += sz as u64; assert_ne!(sz, 0); buffer.truncate(sz - 1); return Ok(sz - 1); } Err(_) => { // Similar situation to Ok(0) above excepting that there's a // real, honest IO error to bubble up to the glob loop. if !self.reset_from_md() { return Err(io::Error::last_os_error()); } } } attempts += 1; } // We've polled too many times to no good effect and have run out of // time. We'll signal this with TimedOut -- which might also come from // BufReader -- so it's hard for the caller to know where this came // from. Doesn't seem to be a pain in practice. Err(io::Error::new( io::ErrorKind::TimedOut, "read_line hit max delay", )) } } /// `FileServer` as Source /// /// The 'run' of `FileServer` performs the cooperative scheduling of reads over /// `FileServer`'s configured files. Much care has been taking to make this /// scheduling 'fair', meaning busy files do not drown out quiet files or vice /// versa but there's no one perfect approach. Very fast files _will_ be lost if /// your system aggressively rolls log files. `FileServer` will keep a file /// handler open but should your system move so quickly that a file disappears /// before cernan is able to open it the contents will be lost. This should be a /// rare occurence. /// /// Specific operating systems support evented interfaces that correct this /// problem but your intrepid authors know of no generic solution. impl Source for FileServer { fn run(&mut self) { let mut fp_map: HashMapFnv<PathBuf, FileWatcher> = HashMapFnv::default(); let glob_delay = Duration::from_secs(60); let mut buffer = String::new(); let mut lines = Vec::new(); // Alright friends, how does this work? // // There's two loops, the outer one we'll call the 'glob poll' loop. The // inner one we'll call the 'file poll' loop. The glob poll resets at // least every 60 seconds, finding new files to create FileWatchers out // of and then enters the file poll. The file poll loops through all // existing FileWatchers and reads at most max_read_lines lines out of a // file. // // The glob poll enforces a delay between files. This is done to // minimize the CPU impact of this polling approach. If a file has no // lines to read an attempt counter will go up and we'll wait // time::delay(attempts). If a line is read out of the file we'll reset // attempts to 0. loop { // glob poll for entry in glob(self.path.to_str().expect("no ability to glob")) .expect("Failed to read glob pattern") { match entry { Ok(path) => { let entry = fp_map.entry(path.clone()); if let Some(fw) = FileWatcher::new(path) { entry.or_insert(fw); }; } Err(e) => { debug!("glob error: {}", e); } } } let start = Instant::now(); let mut attempts: u32 = 0; loop { // file poll if fp_map.is_empty() { time::delay(9); break; } else { time::delay(attempts); } for file in fp_map.values_mut() { loop { let mut lines_read = 0; match file.read_line(&mut buffer) { Ok(sz) => { attempts = (attempts + 1) % 10; if sz > 0 { lines_read += 1; buffer.pop(); let path_name = file.path .to_str() .expect("could not make path_name"); report_full_telemetry( "cernan.sources.file.lines_read", 1.0, None, Some(vec![("file_path", path_name)]), ); trace!("{} | {}", path_name, buffer); lines.push( metric::LogLine::new(path_name, &buffer) .overlay_tags_from_map(&self.tags), ); buffer.clear(); if lines_read > self.max_read_lines { break; } } } Err(e) => { match e.kind() { io::ErrorKind::TimedOut => {} _ => trace!("read-line error: {}", e), } attempts = (attempts + 1) % 10; break; } } } for l in lines.drain(..) { send(&mut self.chans, metric::Event::new_log(l)); } } if start.elapsed() >= glob_delay { break; } } } } } #[cfg(test)] mod test { extern crate tempdir; use super::*; use quickcheck::{Arbitrary, Gen, QuickCheck, TestResult}; use std::fs; // actions that apply to a single FileWatcher #[derive(Clone, Debug)] enum FWAction { WriteLine(String), RotateFile, DeleteFile, Pause(u32), Exit, } impl Arbitrary for FWAction { fn arbitrary<G>(g: &mut G) -> FWAction where G: Gen, { let i: usize = g.gen_range(0, 100); let ln_sz = g.gen_range(0, 256); let pause = g.gen_range(1, 3); match i { 0...50 => { FWAction::WriteLine(g.gen_ascii_chars().take(ln_sz).collect()) } 51...75 => FWAction::Pause(pause), 76...85 => FWAction::RotateFile, 86...95 => FWAction::DeleteFile, _ => FWAction::Exit, } } } #[test] fn test_file_watcher() { fn inner(actions: Vec<FWAction>) -> TestResult { let dir = tempdir::TempDir::new("file_watcher_qc").unwrap(); let path = dir.path().join("a_file.log"); let mut fp = fs::File::create(&path).expect("could not create"); let mut fw = FileWatcher::new(path.clone()).expect("must be able to create"); let mut expected_read = Vec::new(); for action in actions.iter() { match *action { FWAction::DeleteFile => { let _ = fs::remove_file(&path); assert!(!path.exists()); assert!(expected_read.is_empty()); break; } FWAction::Pause(ps) => time::delay(ps), FWAction::Exit => break, FWAction::WriteLine(ref s) => { assert!(fp.write(s.as_bytes()).is_ok()); expected_read.push(s); assert!(fp.write("\n".as_bytes()).is_ok()); assert!(fp.flush().is_ok()); } FWAction::RotateFile => { let mut new_path = path.clone(); new_path.set_extension("log.1"); match fs::rename(&path, &new_path) { Ok(_) => {} Err(e) => { println!("ERROR: {:?}", e); assert!(false); } } fp = fs::File::create(&path).expect("could not create"); } } let mut buf = String::new(); while !expected_read.is_empty() { match fw.read_line(&mut buf) { Ok(sz) => { let exp = expected_read.pop().expect("must be a read here"); assert_eq!(buf, *exp); assert_eq!(sz, buf.len()); buf.clear(); } Err(_) => break, } } assert!(expected_read.is_empty()); } TestResult::passed() } QuickCheck::new() .tests(10000) .max_tests(100000) .quickcheck(inner as fn(Vec<FWAction>) -> TestResult); } }
//! This crate provides cross-platform information about batteries. //! //! Gives access to a system independent battery state, capacity, charge and voltage values //! recalculated as necessary to be returned in [SI measurement units](https://www.bipm.org/en/measurement-units/). //! //! ## Supported platforms //! //! * Linux 2.6.39+ //! * MacOS 10.10+ //! * Windows 7+ //! * FreeBSD //! * DragonFlyBSD //! //! ## Examples //! //! For a quick example see the [Manager](struct.Manager.html) type documentation //! or [`simple.rs`](https://github.com/svartalf/rust-battery/blob/master/battery/examples/simple.rs) //! file in the `examples/` folder. //! //! [battop](https://crates.io/crates/battop) crate is using this library as a knowledge source, //! so check it out too for a real-life example. #![deny(unused)] #![deny(unstable_features)] #![deny(bare_trait_objects)] #![allow(clippy::manual_non_exhaustive)] // MSRV is 1.36 #![doc(html_root_url = "https://docs.rs/battery/0.7.8")] #[macro_use] extern crate cfg_if; #[cfg(target_os = "windows")] #[macro_use] extern crate winapi; #[cfg(any(target_os = "dragonfly", target_os = "freebsd"))] #[macro_use] extern crate nix; mod types; #[macro_use] pub mod units; pub mod errors; mod platform; pub use self::errors::{Error, Result}; pub use self::types::{Batteries, Battery, Manager, State, Technology};
use openvr::{ compositor::texture::vulkan::Texture as OpenVRVulkanTexture, compositor::texture::ColorSpace, compositor::texture::Handle, compositor::texture::Texture, compositor::WaitPoses, Compositor, Eye as OpenVREye, System, TrackedDeviceClass, TrackedDevicePose, }; use cgmath::{vec4, Matrix4, SquareMatrix}; use utilities::prelude::*; use vulkan_rs::prelude::*; use super::openvrintegration::OpenVRIntegration; use crate::{p_try, prelude::*, renderbackend::RenderBackend, RenderCoreCreateInfo}; use std::mem::transmute; use std::sync::{Arc, Mutex, RwLock}; use std::time::Duration; pub struct OpenVRRenderCore { compositor: Arc<Compositor>, system: Arc<System>, render_backend: RenderBackend, render_fence: Arc<Fence>, format: VkFormat, current_image_indices: TargetMode<usize>, images: TargetMode<Vec<Arc<Image>>>, transformations: RwLock<(VRTransformations, VRTransformations)>, width: u32, height: u32, } impl OpenVRRenderCore { pub fn new( vri: &OpenVRIntegration, device: &Arc<Device>, queue: &Arc<Mutex<Queue>>, create_info: RenderCoreCreateInfo, ) -> VerboseResult<(Self, TargetMode<()>)> { let sample_count = VK_SAMPLE_COUNT_1_BIT; let (width, height) = vri.image_size(); let usage = create_info.usage | RenderBackend::required_image_usage(); let (left_image, right_image) = Self::create_target_images( width, height, sample_count, usage, create_info.format, device, queue, )?; let images = TargetMode::Stereo(vec![left_image], vec![right_image]); let render_backend = RenderBackend::new(device, queue, images.clone())?; let openvr_render_core = OpenVRRenderCore { compositor: vri.compositor().clone(), system: vri.system().clone(), render_backend, render_fence: Fence::builder().build(device.clone())?, format: create_info.format, current_image_indices: TargetMode::Stereo(0, 0), images, transformations: RwLock::new(( VRTransformations::default(), VRTransformations::default(), )), width, height, }; let post_process = PostRenderLayoutBarrier::new(&openvr_render_core)?; openvr_render_core .render_backend .add_post_processing_routine(post_process)?; Ok((openvr_render_core, TargetMode::Stereo((), ()))) } #[inline] fn create_target_images( width: u32, height: u32, sample_count: VkSampleCountFlags, usage: VkImageUsageFlagBits, format: VkFormat, device: &Arc<Device>, queue: &Arc<Mutex<Queue>>, ) -> VerboseResult<(Arc<Image>, Arc<Image>)> { // OpenVR requires the image to be transfer_src and sampled let image_usage = usage | VK_IMAGE_USAGE_SAMPLED_BIT | VK_IMAGE_USAGE_TRANSFER_SRC_BIT; if !Image::check_configuration(device, VK_IMAGE_TILING_OPTIMAL, format, image_usage) { create_error!(format!( "wrong config: {:?}, {:?}, {:?}", VK_IMAGE_TILING_OPTIMAL, format, image_usage )); } let left_image = Image::empty(width, height, image_usage, sample_count) .attach_sampler(Sampler::nearest_sampler().build(device)?) .format(format) .build(device, queue)?; left_image.convert_layout(VK_IMAGE_LAYOUT_PRESENT_SRC_KHR)?; let right_image = Image::empty(width, height, image_usage, sample_count) .attach_sampler(Sampler::nearest_sampler().build(device)?) .format(format) .build(device, queue)?; right_image.convert_layout(VK_IMAGE_LAYOUT_PRESENT_SRC_KHR)?; Ok((left_image, right_image)) } #[inline] fn submit_left(&self, image: &Arc<Image>) -> VerboseResult<()> { self.submit(image, OpenVREye::Left) } #[inline] fn submit_right(&self, image: &Arc<Image>) -> VerboseResult<()> { self.submit(image, OpenVREye::Right) } #[inline] fn submit(&self, image: &Arc<Image>, eye: OpenVREye) -> VerboseResult<()> { let queue_lock = image.queue().lock()?; let vulkan_texture = OpenVRVulkanTexture { image: unsafe { transmute::<VkImage, u64>(image.vk_handle()) }, device: unsafe { transmute(image.device().vk_handle()) }, physical_device: unsafe { transmute(image.device().physical_device().vk_handle()) }, instance: unsafe { transmute(image.device().physical_device().instance().vk_handle()) }, queue: unsafe { transmute(queue_lock.vk_handle()) }, queue_family_index: queue_lock.family_index(), width: image.width(), height: image.height(), format: image.vk_format() as u32, sample_count: image.sample_count().into(), }; let texture = Texture { handle: Handle::Vulkan(vulkan_texture), color_space: ColorSpace::Auto, }; if let Err(err) = unsafe { self.compositor.submit(eye, &texture, None, None) } { create_error!(format!( "image ({:#?}) failed submission for {:?} eye with error {:?}", image, eye, err )); } Ok(()) } #[inline] fn find_tracked_hmd( system: &System, poses: [TrackedDevicePose; 64], ) -> Option<TrackedDevicePose> { for (i, pose) in poses.iter().enumerate() { if system.tracked_device_class(i as u32) == TrackedDeviceClass::HMD && pose.pose_is_valid() && pose.device_is_connected() { return Some(*pose); } } None } #[inline] fn setup_transformations( system: &System, wait_poses: WaitPoses, ) -> (VRTransformations, VRTransformations) { let pose = Self::find_tracked_hmd(system, wait_poses.render); let left = Self::vr_transform(system, OpenVREye::Left, pose); let right = Self::vr_transform(system, OpenVREye::Right, pose); (left, right) } #[inline] fn vr_transform( system: &System, eye: OpenVREye, pose: Option<TrackedDevicePose>, ) -> VRTransformations { let proj = system.projection_matrix(eye, 0.1, 1000.0); let eye = system.eye_to_head_transform(eye); let view = match pose { Some(pose) => Self::openvr43_to_matrix4(*pose.device_to_absolute_tracking()) .invert() .expect("failed to invert OpenVR View Matrix"), None => Matrix4::identity(), }; VRTransformations { proj: Self::openvr44_to_matrix4(proj), view: Self::openvr43_to_matrix4(eye) * view, } } #[inline] fn openvr44_to_matrix4(m: [[f32; 4]; 4]) -> Matrix4<f32> { let col_0 = vec4(m[0][0], m[1][0], m[2][0], m[3][0]); let col_1 = vec4(m[0][1], -m[1][1], m[2][1], m[3][1]); let col_2 = vec4(m[0][2], m[1][2], m[2][2], m[3][2]); let col_3 = vec4(m[0][3], m[1][3], m[2][3], m[3][3]); Matrix4::from_cols(col_0, col_1, col_2, col_3) } #[inline] fn openvr43_to_matrix4(m: [[f32; 4]; 3]) -> Matrix4<f32> { let col_0 = vec4(m[0][0], m[1][0], m[2][0], 0.0); let col_1 = vec4(m[0][1], m[1][1], m[2][1], 0.0); let col_2 = vec4(m[0][2], m[1][2], m[2][2], 0.0); let col_3 = vec4(m[0][3], m[1][3], m[2][3], 1.0); Matrix4::from_cols(col_0, col_1, col_2, col_3) } } impl RenderCore for OpenVRRenderCore { fn format(&self) -> VkFormat { self.format } fn next_frame(&self) -> VerboseResult<bool> { let wait_poses = p_try!(self.compositor.wait_get_poses()); *self.transformations.write()? = Self::setup_transformations(&self.system, wait_poses); let command_buffer = self .render_backend .render(self.current_image_indices.clone())?; let submits = &[SubmitInfo::default().add_command_buffer(&command_buffer)]; { let queue_lock = self.render_backend.queue().lock()?; queue_lock.submit(Some(&self.render_fence), submits)?; } // make sure command_buffer is ready self.render_backend.device().wait_for_fences( &[&self.render_fence], true, Duration::from_secs(10), )?; self.render_fence.reset(); let (left_images, right_images) = self.images.stereo()?; let (left_index, right_index) = self.current_image_indices.stereo()?; self.submit_left(&left_images[*left_index])?; self.submit_right(&right_images[*right_index])?; Ok(true) } fn set_clear_color(&self, color: [f32; 4]) -> VerboseResult<()> { self.render_backend.set_clear_color(color) } // scene handling fn add_scene(&self, scene: Arc<dyn TScene + Send + Sync>) -> VerboseResult<()> { self.render_backend.add_scene(scene) } fn remove_scene(&self, scene: &Arc<dyn TScene + Send + Sync>) -> VerboseResult<()> { self.render_backend.remove_scene(scene) } fn clear_scenes(&self) -> VerboseResult<()> { self.render_backend.clear_scenes() } // post process handling fn add_post_processing_routine( &self, post_process: Arc<dyn PostProcess + Send + Sync>, ) -> VerboseResult<()> { self.render_backend .add_post_processing_routine(post_process) } fn remove_post_processing_routine( &self, post_process: &Arc<dyn PostProcess + Send + Sync>, ) -> VerboseResult<()> { self.render_backend .remove_post_processing_routine(post_process) } fn clear_post_processing_routines(&self) -> VerboseResult<()> { self.render_backend.clear_post_processing_routines() } // getter fn image_count(&self) -> usize { self.render_backend.image_count() } fn images(&self) -> VerboseResult<TargetMode<Vec<Arc<Image>>>> { self.render_backend.images() } fn allocate_primary_buffer(&self) -> VerboseResult<Arc<CommandBuffer>> { self.render_backend.allocate_primary_buffer() } fn allocate_secondary_buffer(&self) -> VerboseResult<Arc<CommandBuffer>> { self.render_backend.allocate_secondary_buffer() } fn width(&self) -> u32 { self.width } fn height(&self) -> u32 { self.height } fn transformations(&self) -> VerboseResult<Option<(VRTransformations, VRTransformations)>> { Ok(Some(self.transformations.read()?.clone())) } } impl std::fmt::Debug for OpenVRRenderCore { fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> std::fmt::Result { write!(f, "OpenVRRenderCore {{ }}") } } struct PostRenderLayoutBarrier { left_images: Vec<Arc<Image>>, right_images: Vec<Arc<Image>>, } impl PostRenderLayoutBarrier { fn new(render_core: &OpenVRRenderCore) -> VerboseResult<Arc<Self>> { let (left_images, right_images) = render_core.images.stereo()?; Ok(Arc::new(PostRenderLayoutBarrier { left_images: left_images.clone(), right_images: right_images.clone(), })) } } impl PostProcess for PostRenderLayoutBarrier { fn priority(&self) -> u32 { // priority == 0 means that is executed lastly 0 } fn process( &self, command_buffer: &Arc<CommandBuffer>, indices: &TargetMode<usize>, ) -> VerboseResult<()> { let (left_index, right_index) = indices.stereo()?; command_buffer.set_full_image_layout( &self.left_images[*left_index], VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL, )?; command_buffer.set_full_image_layout( &self.right_images[*right_index], VK_IMAGE_LAYOUT_TRANSFER_SRC_OPTIMAL, )?; Ok(()) } fn resize(&self, _: u32, _: u32) -> VerboseResult<()> { Ok(()) } }
use super::*; #[inline] pub fn parse_use(s :&Mem, pivot :usize)->Result<String, &'static str> { Ok(format!("{}([&](){{\n{}\n}});\n\n", &verb_parse(&split(&s[pivot].code)[1]), transpile(s, pivot) )) }
#[doc = r"Value read from the register"] pub struct R { bits: u32, } #[doc = r"Value to write to the register"] pub struct W { bits: u32, } impl super::CTRL { #[doc = r"Modifies the contents of the register"] #[inline(always)] pub fn modify<F>(&self, f: F) where for<'w> F: FnOnce(&R, &'w mut W) -> &'w mut W, { let bits = self.register.get(); self.register.set(f(&R { bits }, &mut W { bits }).bits); } #[doc = r"Reads the contents of the register"] #[inline(always)] pub fn read(&self) -> R { R { bits: self.register.get(), } } #[doc = r"Writes to the register"] #[inline(always)] pub fn write<F>(&self, f: F) where F: FnOnce(&mut W) -> &mut W, { self.register.set( f(&mut W { bits: Self::reset_value(), }) .bits, ); } #[doc = r"Reset value of the register"] #[inline(always)] pub const fn reset_value() -> u32 { 0 } #[doc = r"Writes the reset value to the register"] #[inline(always)] pub fn reset(&self) { self.register.set(Self::reset_value()) } } #[doc = r"Value of the field"] pub struct DES_CTRL_OUTPUT_READYR { bits: bool, } impl DES_CTRL_OUTPUT_READYR { #[doc = r"Value of the field as raw bits"] #[inline(always)] pub fn bit(&self) -> bool { self.bits } #[doc = r"Returns `true` if the bit is clear (0)"] #[inline(always)] pub fn bit_is_clear(&self) -> bool { !self.bit() } #[doc = r"Returns `true` if the bit is set (1)"] #[inline(always)] pub fn bit_is_set(&self) -> bool { self.bit() } } #[doc = r"Proxy"] pub struct _DES_CTRL_OUTPUT_READYW<'a> { w: &'a mut W, } impl<'a> _DES_CTRL_OUTPUT_READYW<'a> { #[doc = r"Sets the field bit"] #[inline(always)] pub fn set_bit(self) -> &'a mut W { self.bit(true) } #[doc = r"Clears the field bit"] #[inline(always)] pub fn clear_bit(self) -> &'a mut W { self.bit(false) } #[doc = r"Writes raw bits to the field"] #[inline(always)] pub fn bit(self, value: bool) -> &'a mut W { self.w.bits &= !(1 << 0); self.w.bits |= ((value as u32) & 1) << 0; self.w } } #[doc = r"Value of the field"] pub struct DES_CTRL_INPUT_READYR { bits: bool, } impl DES_CTRL_INPUT_READYR { #[doc = r"Value of the field as raw bits"] #[inline(always)] pub fn bit(&self) -> bool { self.bits } #[doc = r"Returns `true` if the bit is clear (0)"] #[inline(always)] pub fn bit_is_clear(&self) -> bool { !self.bit() } #[doc = r"Returns `true` if the bit is set (1)"] #[inline(always)] pub fn bit_is_set(&self) -> bool { self.bit() } } #[doc = r"Proxy"] pub struct _DES_CTRL_INPUT_READYW<'a> { w: &'a mut W, } impl<'a> _DES_CTRL_INPUT_READYW<'a> { #[doc = r"Sets the field bit"] #[inline(always)] pub fn set_bit(self) -> &'a mut W { self.bit(true) } #[doc = r"Clears the field bit"] #[inline(always)] pub fn clear_bit(self) -> &'a mut W { self.bit(false) } #[doc = r"Writes raw bits to the field"] #[inline(always)] pub fn bit(self, value: bool) -> &'a mut W { self.w.bits &= !(1 << 1); self.w.bits |= ((value as u32) & 1) << 1; self.w } } #[doc = r"Value of the field"] pub struct DES_CTRL_DIRECTIONR { bits: bool, } impl DES_CTRL_DIRECTIONR { #[doc = r"Value of the field as raw bits"] #[inline(always)] pub fn bit(&self) -> bool { self.bits } #[doc = r"Returns `true` if the bit is clear (0)"] #[inline(always)] pub fn bit_is_clear(&self) -> bool { !self.bit() } #[doc = r"Returns `true` if the bit is set (1)"] #[inline(always)] pub fn bit_is_set(&self) -> bool { self.bit() } } #[doc = r"Proxy"] pub struct _DES_CTRL_DIRECTIONW<'a> { w: &'a mut W, } impl<'a> _DES_CTRL_DIRECTIONW<'a> { #[doc = r"Sets the field bit"] #[inline(always)] pub fn set_bit(self) -> &'a mut W { self.bit(true) } #[doc = r"Clears the field bit"] #[inline(always)] pub fn clear_bit(self) -> &'a mut W { self.bit(false) } #[doc = r"Writes raw bits to the field"] #[inline(always)] pub fn bit(self, value: bool) -> &'a mut W { self.w.bits &= !(1 << 2); self.w.bits |= ((value as u32) & 1) << 2; self.w } } #[doc = r"Value of the field"] pub struct DES_CTRL_TDESR { bits: bool, } impl DES_CTRL_TDESR { #[doc = r"Value of the field as raw bits"] #[inline(always)] pub fn bit(&self) -> bool { self.bits } #[doc = r"Returns `true` if the bit is clear (0)"] #[inline(always)] pub fn bit_is_clear(&self) -> bool { !self.bit() } #[doc = r"Returns `true` if the bit is set (1)"] #[inline(always)] pub fn bit_is_set(&self) -> bool { self.bit() } } #[doc = r"Proxy"] pub struct _DES_CTRL_TDESW<'a> { w: &'a mut W, } impl<'a> _DES_CTRL_TDESW<'a> { #[doc = r"Sets the field bit"] #[inline(always)] pub fn set_bit(self) -> &'a mut W { self.bit(true) } #[doc = r"Clears the field bit"] #[inline(always)] pub fn clear_bit(self) -> &'a mut W { self.bit(false) } #[doc = r"Writes raw bits to the field"] #[inline(always)] pub fn bit(self, value: bool) -> &'a mut W { self.w.bits &= !(1 << 3); self.w.bits |= ((value as u32) & 1) << 3; self.w } } #[doc = r"Value of the field"] pub struct DES_CTRL_MODER { bits: u8, } impl DES_CTRL_MODER { #[doc = r"Value of the field as raw bits"] #[inline(always)] pub fn bits(&self) -> u8 { self.bits } } #[doc = r"Proxy"] pub struct _DES_CTRL_MODEW<'a> { w: &'a mut W, } impl<'a> _DES_CTRL_MODEW<'a> { #[doc = r"Writes raw bits to the field"] #[inline(always)] pub unsafe fn bits(self, value: u8) -> &'a mut W { self.w.bits &= !(3 << 4); self.w.bits |= ((value as u32) & 3) << 4; self.w } } #[doc = r"Value of the field"] pub struct DES_CTRL_CONTEXTR { bits: bool, } impl DES_CTRL_CONTEXTR { #[doc = r"Value of the field as raw bits"] #[inline(always)] pub fn bit(&self) -> bool { self.bits } #[doc = r"Returns `true` if the bit is clear (0)"] #[inline(always)] pub fn bit_is_clear(&self) -> bool { !self.bit() } #[doc = r"Returns `true` if the bit is set (1)"] #[inline(always)] pub fn bit_is_set(&self) -> bool { self.bit() } } #[doc = r"Proxy"] pub struct _DES_CTRL_CONTEXTW<'a> { w: &'a mut W, } impl<'a> _DES_CTRL_CONTEXTW<'a> { #[doc = r"Sets the field bit"] #[inline(always)] pub fn set_bit(self) -> &'a mut W { self.bit(true) } #[doc = r"Clears the field bit"] #[inline(always)] pub fn clear_bit(self) -> &'a mut W { self.bit(false) } #[doc = r"Writes raw bits to the field"] #[inline(always)] pub fn bit(self, value: bool) -> &'a mut W { self.w.bits &= !(1 << 31); self.w.bits |= ((value as u32) & 1) << 31; self.w } } impl R { #[doc = r"Value of the register as raw bits"] #[inline(always)] pub fn bits(&self) -> u32 { self.bits } #[doc = "Bit 0 - When 1, Data decrypted/encrypted ready"] #[inline(always)] pub fn des_ctrl_output_ready(&self) -> DES_CTRL_OUTPUT_READYR { let bits = ((self.bits >> 0) & 1) != 0; DES_CTRL_OUTPUT_READYR { bits } } #[doc = "Bit 1 - When 1, ready to encrypt/decrypt data"] #[inline(always)] pub fn des_ctrl_input_ready(&self) -> DES_CTRL_INPUT_READYR { let bits = ((self.bits >> 1) & 1) != 0; DES_CTRL_INPUT_READYR { bits } } #[doc = "Bit 2 - Select encryption/decryption 0x0: decryption is selected0x1: Encryption is selected"] #[inline(always)] pub fn des_ctrl_direction(&self) -> DES_CTRL_DIRECTIONR { let bits = ((self.bits >> 2) & 1) != 0; DES_CTRL_DIRECTIONR { bits } } #[doc = "Bit 3 - Select DES or triple DES encryption/decryption"] #[inline(always)] pub fn des_ctrl_tdes(&self) -> DES_CTRL_TDESR { let bits = ((self.bits >> 3) & 1) != 0; DES_CTRL_TDESR { bits } } #[doc = "Bits 4:5 - Select CBC, ECB or CFB mode0x0: ECB mode0x1: CBC mode0x2: CFB mode0x3: reserved"] #[inline(always)] pub fn des_ctrl_mode(&self) -> DES_CTRL_MODER { let bits = ((self.bits >> 4) & 3) as u8; DES_CTRL_MODER { bits } } #[doc = "Bit 31 - If 1, this read-only status bit indicates that the context data registers can be overwritten and the host is permitted to write the next context"] #[inline(always)] pub fn des_ctrl_context(&self) -> DES_CTRL_CONTEXTR { let bits = ((self.bits >> 31) & 1) != 0; DES_CTRL_CONTEXTR { bits } } } impl W { #[doc = r"Writes raw bits to the register"] #[inline(always)] pub unsafe fn bits(&mut self, bits: u32) -> &mut Self { self.bits = bits; self } #[doc = "Bit 0 - When 1, Data decrypted/encrypted ready"] #[inline(always)] pub fn des_ctrl_output_ready(&mut self) -> _DES_CTRL_OUTPUT_READYW { _DES_CTRL_OUTPUT_READYW { w: self } } #[doc = "Bit 1 - When 1, ready to encrypt/decrypt data"] #[inline(always)] pub fn des_ctrl_input_ready(&mut self) -> _DES_CTRL_INPUT_READYW { _DES_CTRL_INPUT_READYW { w: self } } #[doc = "Bit 2 - Select encryption/decryption 0x0: decryption is selected0x1: Encryption is selected"] #[inline(always)] pub fn des_ctrl_direction(&mut self) -> _DES_CTRL_DIRECTIONW { _DES_CTRL_DIRECTIONW { w: self } } #[doc = "Bit 3 - Select DES or triple DES encryption/decryption"] #[inline(always)] pub fn des_ctrl_tdes(&mut self) -> _DES_CTRL_TDESW { _DES_CTRL_TDESW { w: self } } #[doc = "Bits 4:5 - Select CBC, ECB or CFB mode0x0: ECB mode0x1: CBC mode0x2: CFB mode0x3: reserved"] #[inline(always)] pub fn des_ctrl_mode(&mut self) -> _DES_CTRL_MODEW { _DES_CTRL_MODEW { w: self } } #[doc = "Bit 31 - If 1, this read-only status bit indicates that the context data registers can be overwritten and the host is permitted to write the next context"] #[inline(always)] pub fn des_ctrl_context(&mut self) -> _DES_CTRL_CONTEXTW { _DES_CTRL_CONTEXTW { w: self } } }
mod aes; mod utils; extern crate openssl; extern crate base64; use openssl::symm::{encrypt, Cipher, Crypter, decrypt, Mode}; use std::io::prelude::*; use std::fs::File; use utils::*; fn main() { let input = base64::decode(lines_from_file("data.txt")[0].as_bytes()).unwrap(); let key = b"YELLOW SUBMARINE"; let iv = [0; 16]; let ciphertext = aes::aes_cbc_encrypt(&input, &iv, key); println!("guessed: {:?}", String::from_utf8_lossy(&padding_oracle(&ciphertext, &iv, key))); } fn padding_oracle(ciphertext: &[u8], iv: &[u8], key: &[u8]) -> Vec<u8> { let mut guessed = Vec::new(); let len = ciphertext.len(); let mut padding_result = Vec::new(); let mut first_block = iv.to_vec(); first_block.extend_from_slice(&ciphertext[0..16]); padding_result = block_padding_oracle(&first_block, iv, key); for i in 0..16 { guessed.push(padding_result[i]); } for z in 0..ciphertext.len() / 16 { if 16 * z + 32 <= ciphertext.len() { padding_result = block_padding_oracle(&ciphertext[16 * z..16 * z + 32], iv, key); for i in 0..16 { guessed.push(padding_result[i]); } } } guessed } fn block_padding_oracle(ciphertext: &[u8], iv: &[u8], key: &[u8]) -> Vec<u8> { let mut found = false; let mut crafted = ciphertext.to_vec().clone(); let mut guessed: Vec<u8> = Vec::new(); let mut lol = Vec::new(); let len = ciphertext.len(); let mut pre_xor = 0; let mut i = 0; for z in 0..16 { found = false; while found == false { if crafted[len - 17 - z] < 255 { crafted[len - 17 - z] += 1; } else { crafted[len - 17 - z] = 0; } i += 1; found = aes::validate_padding(&aes::aes_cbc(&crafted, iv, key)); } pre_xor = aes::byte_xor(&[crafted[len - 17 - z]], &[z as u8 + 1])[0]; lol.push(pre_xor); for h in 0..(z + 1) { crafted[len - 17 - h] = aes::byte_xor(&[lol[h]], &[z as u8 + 2])[0]; } guessed.insert(0, aes::byte_xor(&[pre_xor], &[ciphertext[len - 17 - z]])[0]); } guessed }
use druid::{keyboard_types::Key, widget::Controller, Env, Event, EventCtx, Widget}; use std::any::Any; pub struct EnterController<D> { callback: Box<dyn Fn(&mut EventCtx, &mut D)>, } impl<D> EnterController<D> { pub fn new(callback: impl Fn(&mut EventCtx, &mut D) + Any) -> Self { Self { callback: Box::new(callback), } } } impl<D, W: Widget<D>> Controller<D, W> for EnterController<D> { fn event(&mut self, child: &mut W, ctx: &mut EventCtx, event: &Event, data: &mut D, env: &Env) { child.event(ctx, event, data, env); if let Event::KeyUp(event) = event { if event.key == Key::Enter { (self.callback)(ctx, data); } } } }
use fraction::ToPrimitive; use crate::{io::*, gp::*}; //MIDI channels pub const CHANNEL_DEFAULT_NAMES: [&str; 128] = ["Piano", "Bright Piano", "Electric Grand", "Honky Tonk Piano", "Electric Piano 1", "Electric Piano 2", "Harpsichord", "Clavinet", "Celesta", "Glockenspiel", "Music Box", "Vibraphone", "Marimba", "Xylophone", "Tubular Bell", "Dulcimer", "Hammond Organ", "Perc Organ", "Rock Organ", "Church Organ", "Reed Organ", "Accordion", "Harmonica", "Tango Accordion", "Nylon Str Guitar", "Steel String Guitar", "Jazz Electric Gtr", "Clean Guitar", "Muted Guitar", "Overdrive Guitar", "Distortion Guitar", "Guitar Harmonics", "Acoustic Bass", "Fingered Bass", "Picked Bass", "Fretless Bass", "Slap Bass 1", "Slap Bass 2", "Syn Bass 1", "Syn Bass 2", "Violin", "Viola", "Cello", "Contrabass", "Tremolo Strings", "Pizzicato Strings", "Orchestral Harp", "Timpani", "Ensemble Strings", "Slow Strings", "Synth Strings 1", "Synth Strings 2", "Choir Aahs", "Voice Oohs", "Syn Choir", "Orchestra Hit", "Trumpet", "Trombone", "Tuba", "Muted Trumpet", "French Horn", "Brass Ensemble", "Syn Brass 1", "Syn Brass 2", "Soprano Sax", "Alto Sax", "Tenor Sax", "Baritone Sax", "Oboe", "English Horn", "Bassoon", "Clarinet", "Piccolo", "Flute", "Recorder", "Pan Flute", "Bottle Blow", "Shakuhachi", "Whistle", "Ocarina", "Syn Square Wave", "Syn Saw Wave", "Syn Calliope", "Syn Chiff", "Syn Charang", "Syn Voice", "Syn Fifths Saw", "Syn Brass and Lead", "Fantasia", "Warm Pad", "Polysynth", "Space Vox", "Bowed Glass", "Metal Pad", "Halo Pad", "Sweep Pad", "Ice Rain", "Soundtrack", "Crystal", "Atmosphere", "Brightness", "Goblins", "Echo Drops", "Sci Fi", "Sitar", "Banjo", "Shamisen", "Koto", "Kalimba", "Bag Pipe", "Fiddle", "Shanai", "Tinkle Bell", "Agogo", "Steel Drums", "Woodblock", "Taiko Drum", "Melodic Tom", "Syn Drum", "Reverse Cymbal", "Guitar Fret Noise", "Breath Noise", "Seashore", "Bird", "Telephone", "Helicopter", "Applause", "Gunshot"]; pub const DEFAULT_PERCUSSION_CHANNEL: u8 = 9; /// A MIDI channel describes playing data for a track. #[derive(Debug,Copy,Clone)] pub struct MidiChannel { pub channel: u8, pub effect_channel: u8, instrument: i32, pub volume: i8, pub balance: i8, pub chorus: i8, pub reverb: i8, pub phaser: i8, pub tremolo: i8, pub bank: u8, } impl Default for MidiChannel { fn default() -> Self { MidiChannel { channel: 0, effect_channel: 1, instrument: 25, volume: 104, balance: 64, chorus: 0, reverb: 0, phaser: 0, tremolo: 0, bank: 0, }} } impl MidiChannel { pub(crate) fn is_percussion_channel(self) -> bool { (self.channel % 16) == DEFAULT_PERCUSSION_CHANNEL } pub(crate) fn set_instrument(mut self, instrument: i32) { if instrument == -1 && self.is_percussion_channel() { self.instrument = 0; } else {self.instrument = instrument;} } pub(crate) fn _get_instrument(self) -> i32 {self.instrument} pub(crate) fn get_instrument_name(&self) -> String {String::from(CHANNEL_DEFAULT_NAMES[self.instrument.to_usize().unwrap()])} //TODO: FIXME: does not seems OK } impl Song{ /// Read all the MIDI channels pub(crate) fn read_midi_channels(&mut self, data: &[u8], seek: &mut usize) { for i in 0u8..64u8 { self.channels.push(self.read_midi_channel(data, seek, i)); } } /// Read MIDI channels. Guitar Pro format provides 64 channels (4 MIDI ports by 16 hannels), the channels are stored in this order: ///`port1/channel1`, `port1/channel2`, ..., `port1/channel16`, `port2/channel1`, ..., `port4/channel16`. /// /// Each channel has the following form: /// /// * **Instrument**: `int` /// * **Volume**: `byte` /// * **Balance**: `byte` /// * **Chorus**: `byte` /// * **Reverb**: `byte` /// * **Phaser**: `byte` /// * **Tremolo**: `byte` /// * **blank1**: `byte` => Backward compatibility with version 3.0 /// * **blank2**: `byte` => Backward compatibility with version 3.0 pub(crate) fn read_midi_channel(&self, data: &[u8], seek: &mut usize, channel: u8) -> MidiChannel { let instrument = read_int(data, seek); let mut c = MidiChannel{channel, effect_channel: channel, ..Default::default()}; c.volume = read_signed_byte(data, seek); c.balance = read_signed_byte(data, seek); c.chorus = read_signed_byte(data, seek); c.reverb = read_signed_byte(data, seek); c.phaser = read_signed_byte(data, seek); c.tremolo = read_signed_byte(data, seek); c.set_instrument(instrument); //println!("Channel: {}\t Volume: {}\tBalance: {}\tInstrument={}, {}, {}", c.channel, c.volume, c.balance, instrument, c.get_instrument(), c.get_instrument_name()); *seek += 2; //Backward compatibility with version 3.0 c } /// Read MIDI channel. MIDI channel in Guitar Pro is represented by two integers. First is zero-based number of channel, second is zero-based number of channel used for effects. pub(crate) fn read_channel(&mut self, data: &[u8], seek: &mut usize) -> usize { //TODO: fixme for writing let index = read_int(data, seek) - 1; let effect_channel = read_int(data, seek) - 1; if 0 <= index && index < self.channels.len().to_i32().unwrap() { if self.channels[index.to_usize().unwrap()].instrument < 0 {self.channels[index.to_usize().unwrap()].instrument = 0;} if !self.channels[index.to_usize().unwrap()].is_percussion_channel() {self.channels[index.to_usize().unwrap()].effect_channel = effect_channel.to_u8().unwrap();} } index.to_usize().unwrap() } pub(crate) fn write_midi_channels(&self, data: &mut Vec<u8>) { for i in 0..self.channels.len() { println!("writing channel: {:?}", self.channels[i]); if self.channels[i].is_percussion_channel() && self.channels[i].instrument == 0 {write_i32(data, -1);} else {write_i32(data, self.channels[i].instrument);} write_signed_byte(data, Self::from_channel_short(self.channels[i].volume)); write_signed_byte(data, Self::from_channel_short(self.channels[i].balance)); write_signed_byte(data, Self::from_channel_short(self.channels[i].chorus)); write_signed_byte(data, Self::from_channel_short(self.channels[i].reverb)); write_signed_byte(data, Self::from_channel_short(self.channels[i].phaser)); write_signed_byte(data, Self::from_channel_short(self.channels[i].tremolo)); write_placeholder_default(data, 2); //Backward compatibility with version 3.0 } } fn from_channel_short(data: i8) -> i8 { ((data >> 3) - 1).clamp(-128, 127) + 1 } }
//! Implements a command for uploading dSYM files. use clap::{App, AppSettings, Arg, ArgMatches}; use failure::Error; use crate::commands::upload_dif; use crate::utils::args::{validate_uuid, ArgExt}; pub fn make_app<'a, 'b: 'a>(app: App<'a, 'b>) -> App<'a, 'b> { app.about("DEPRECATED: Upload Mac debug symbols to a project.") .setting(AppSettings::Hidden) .org_project_args() .arg( Arg::with_name("paths") .value_name("PATH") .help("A path to search recursively for symbol files.") .multiple(true) .number_of_values(1) .index(1), ).arg( Arg::with_name("ids") .value_name("UUID") .long("uuid") .help("Search for specific UUIDs.") .validator(validate_uuid) .multiple(true) .number_of_values(1), ).arg( Arg::with_name("require_all") .long("require-all") .help("Errors if not all UUIDs specified with --uuid could be found."), ).arg( Arg::with_name("symbol_maps") .long("symbol-maps") .value_name("PATH") .help( "Optional path to BCSymbolMap files which are used to \ resolve hidden symbols in the actual dSYM files. This \ requires the dsymutil tool to be available.", ), ).arg( Arg::with_name("derived_data") .long("derived-data") .help("Search for debug symbols in derived data."), ).arg( Arg::with_name("no_zips") .long("no-zips") .help("Do not search in ZIP files."), ).arg( Arg::with_name("info_plist") .long("info-plist") .value_name("PATH") .help( "Optional path to the Info.plist.{n}We will try to find this \ automatically if run from Xcode. Providing this information \ will associate the debug symbols with a specific ITC application \ and build in Sentry. Note that if you provide the plist \ explicitly it must already be processed.", ), ).arg( Arg::with_name("no_reprocessing") .long("no-reprocessing") .help("Do not trigger reprocessing after uploading."), ).arg( Arg::with_name("force_foreground") .long("force-foreground") .help( "Wait for the process to finish.{n}\ By default, the upload process will detach and continue in the \ background when triggered from Xcode. When an error happens, \ a dialog is shown. If this parameter is passed Xcode will wait \ for the process to finish before the build finishes and output \ will be shown in the Xcode build output.", ), ) } pub fn execute(matches: &ArgMatches) -> Result<(), Error> { upload_dif::execute_legacy(matches) }
// Copyright 2022 Datafuse Labs. // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. #![allow(clippy::uninlined_format_args)] #![feature(box_patterns)] #![feature(cursor_remaining)] mod clickhouse; mod common_settings; mod delimiter; mod field_decoder; pub mod field_encoder; mod file_format_type; mod format_option_checker; pub mod output_format; pub use clickhouse::ClickhouseFormatType; pub use delimiter::RecordDelimiter; pub use field_decoder::*; pub use file_format_type::parse_timezone; pub use file_format_type::FileFormatOptionsExt; pub use file_format_type::FileFormatTypeExt; pub use format_option_checker::check_record_delimiter; pub use format_option_checker::get_format_option_checker; use crate::common_settings::CommonSettings;
use super::*; /// Asserts that all elements are compatible with themselves and /// not equal to the other elements fn assert_distinct_elements(array: &[Tag]) { let array = array .iter() .cloned() .map(Tag::to_checkable) .collect::<Vec<CheckableTag>>(); for (index, value) in array.iter().enumerate() { assert_eq!(value.check_compatible(value), Ok(())); for (_, incomp) in array.iter().enumerate().filter(|(i, _)| *i != index) { assert_ne!(value.check_compatible(incomp), Ok(()),); } } } const TAG_SET_EMPTY: Tag = Tag::set(rslice![]); const TAG_ARR_EMPTY: Tag = Tag::arr(rslice![]); const TAG_SET_0: Tag = Tag::set(rslice![Tag::bool_(false)]); const TAG_ARR_0: Tag = Tag::arr(rslice![Tag::bool_(false)]); const TAG_1_ORDER_0_VALUE: RSlice<'static, Tag> = rslice![ Tag::bool_(false), Tag::bool_(true), Tag::arr(rslice![Tag::uint(0), Tag::int(-100)]), Tag::int(-100), Tag::int(100), Tag::set(rslice![Tag::str("Cap'n Rogers"), Tag::str("ironman")]), Tag::uint(!0), Tag::uint(100), ]; const TAG_SET_1_ORDER_0: Tag = Tag::set(TAG_1_ORDER_0_VALUE); const TAG_ARR_1_ORDER_0: Tag = Tag::arr(TAG_1_ORDER_0_VALUE); const TAG_1_ORDER_1_VALUE: RSlice<'static, Tag> = rslice![ Tag::uint(!0), Tag::int(100), Tag::bool_(true), Tag::set(rslice![Tag::str("ironman"), Tag::str("Cap'n Rogers")]), Tag::uint(100), Tag::int(-100), Tag::bool_(false), Tag::arr(rslice![Tag::uint(0), Tag::int(-100)]), ]; const TAG_SET_1_ORDER_1: Tag = Tag::set(TAG_1_ORDER_1_VALUE); const TAG_ARR_1_ORDER_1: Tag = Tag::arr(TAG_1_ORDER_1_VALUE); const TAG_2_VALUE: RSlice<'static, Tag> = rslice![ Tag::uint(!0), Tag::int(100), Tag::arr(rslice![Tag::uint(0), Tag::int(-100)]), Tag::bool_(true), Tag::set(rslice![ Tag::str("Cap'n Rogers"), Tag::str("ironman"), Tag::str("Fe-male") ]), Tag::uint(100), Tag::int(-100), Tag::bool_(false), Tag::str("what the [redacted_for_g]"), ]; const TAG_SET_2: Tag = Tag::set(TAG_2_VALUE); const TAG_ARR_2: Tag = Tag::arr(TAG_2_VALUE); const TAG_MAP_EMPTY: Tag = Tag::map(rslice![]); const TAG_MAP_0A: Tag = tag!({ Tag::null()=>"baz", "world"=>"hello", "hello"=>"huh?", "hello"=>"world", }); const TAG_MAP_0B: Tag = tag!({ "hello"=>"world", "world"=>"hello", }); const TAG_MAP_0E: Tag = tag!({ 0=>"what", 1=>"foo" }); const TAG_MAP_0F: Tag = tag!({ 0=>"foo", 1=>"what" }); const TAG_MAP_0G: Tag = tag!({ 1=>"foo", 2=>"what" }); const TAG_MAP_1A: Tag = tag!({ "world"=>"hello", "foo"=>"bar", "foo"=>"baz", "hello"=>"huh?", "hello"=>"world", }); const TAG_MAP_1B: Tag = tag!({ "hello"=>"world", "world"=>"hello", "foo"=>"baz", }); const TAG_MAP_2A: Tag = tag!({ Tag::null()=>"baz", "world"=>"hello", Tag::null()=>"baz", 0=>"fun", 0=>"house", Tag::uint(100)=>"what", Tag::uint(100)=>"the", "foo"=>"bar", "foo"=>"baz", "hello"=>"huh?", "hello"=>"world", }); const TAG_MAP_2B: Tag = tag!({ "hello"=>"world", "world"=>"hello", "foo"=>"baz", 0=>"house", Tag::uint(100)=>"the", }); fn assert_subsets(array: &[(u32, Tag)]) { let array = array .iter() .cloned() .map(|(i, v)| (i, Tag::to_checkable(v))) .collect::<Vec<_>>(); for (l_index, (l_ident, l_value)) in array.iter().enumerate() { for (r_index, (r_ident, r_value)) in array.iter().enumerate() { let res = l_value.check_compatible(r_value); if l_index <= r_index || l_ident == r_ident { assert_eq!(res, Ok(()), "left:{}\n\nright:{}", l_value, r_value); } else { assert_ne!(res, Ok(()), "left:{}\n\nright:{}", l_value, r_value); } } } } #[test] fn check_set_compatibility() { assert_subsets(&[ (0, TAG_SET_EMPTY), (1, TAG_SET_0), (2, TAG_SET_1_ORDER_0), (2, TAG_SET_1_ORDER_1), (3, TAG_SET_2), ]); } #[test] fn check_map_compatibility() { assert_subsets(&[ (0, TAG_MAP_EMPTY), (1, TAG_MAP_0A), (1, TAG_MAP_0B), (2, TAG_MAP_1A), (2, TAG_MAP_1B), (3, TAG_MAP_2A), (3, TAG_MAP_2B), ]); assert_distinct_elements(&[TAG_MAP_0E, TAG_MAP_0F, TAG_MAP_0G]); } #[test] fn check_arr_compatibility() { assert_distinct_elements(&[ TAG_ARR_EMPTY, TAG_ARR_0, TAG_ARR_1_ORDER_0, TAG_ARR_1_ORDER_1, TAG_ARR_2, ]); } const TAG_BOOLS: &[Tag] = &[Tag::bool_(false), Tag::bool_(true)]; #[test] fn check_bool() { assert_distinct_elements(TAG_BOOLS); } const TAG_UINTS: &[Tag] = &[Tag::uint(0), Tag::uint(1), Tag::uint(2)]; #[test] fn check_uint() { assert_distinct_elements(TAG_UINTS); } const TAG_INTS: &[Tag] = &[ Tag::int(-2), Tag::int(-1), Tag::int(0), Tag::int(1), Tag::int(2), ]; #[test] fn check_int() { assert_distinct_elements(TAG_INTS); } const TAG_STRS: &[Tag] = &[ Tag::str("what"), Tag::str("the"), Tag::str("is"), Tag::str("this"), Tag::str("Hello, world!"), ]; #[test] fn check_str() { assert_distinct_elements(TAG_STRS); } #[test] fn check_different_same_variant() { assert_distinct_elements(&[ Tag::bool_(false), Tag::int(0), Tag::uint(0), Tag::str(""), Tag::arr(rslice![]), Tag::set(rslice![]), Tag::map(rslice![]), ]); } #[test] fn check_null() { let mut list = vec![ TAG_SET_EMPTY, TAG_SET_0, TAG_SET_1_ORDER_0, TAG_SET_1_ORDER_1, TAG_SET_2, TAG_ARR_EMPTY, TAG_ARR_0, TAG_ARR_1_ORDER_0, TAG_ARR_1_ORDER_1, TAG_ARR_2, ]; list.extend_from_slice(TAG_BOOLS); list.extend_from_slice(TAG_UINTS); list.extend_from_slice(TAG_INTS); list.extend_from_slice(TAG_STRS); let null_checkable = Tag::null().to_checkable(); let list = list .into_iter() .map(Tag::to_checkable) .collect::<Vec<CheckableTag>>(); for elems in &list { assert_eq!(null_checkable.check_compatible(elems), Ok(())); assert_ne!(elems.check_compatible(&null_checkable), Ok(())); } }
import front.ast; import std.option; import std.option.some; import std.option.none; type ast_visitor = rec(fn () -> bool keep_going, fn () -> bool want_crate_directives, fn (&ast.crate c) visit_crate_pre, fn (&ast.crate c) visit_crate_post, fn (@ast.crate_directive cd) visit_crate_directive_pre, fn (@ast.crate_directive cd) visit_crate_directive_post, fn (@ast.view_item i) visit_view_item_pre, fn (@ast.view_item i) visit_view_item_post, fn (@ast.native_item i) visit_native_item_pre, fn (@ast.native_item i) visit_native_item_post, fn (@ast.item i) visit_item_pre, fn (@ast.item i) visit_item_post, fn (&ast.block b) visit_block_pre, fn (&ast.block b) visit_block_post, fn (@ast.stmt s) visit_stmt_pre, fn (@ast.stmt s) visit_stmt_post, fn (@ast.decl d) visit_decl_pre, fn (@ast.decl d) visit_decl_post, fn (@ast.expr e) visit_expr_pre, fn (@ast.expr e) visit_expr_post, fn (@ast.ty t) visit_ty_pre, fn (@ast.ty t) visit_ty_post); fn walk_crate(&ast_visitor v, &ast.crate c) { if (!v.keep_going()) { ret; } v.visit_crate_pre(c); walk_mod(v, c.node.module); v.visit_crate_post(c); } fn walk_crate_directive(&ast_visitor v, @ast.crate_directive cd) { if (!v.keep_going()) { ret; } if (!v.want_crate_directives()) { ret; } v.visit_crate_directive_pre(cd); alt (cd.node) { case (ast.cdir_let(_, ?e, ?cdirs)) { walk_expr(v, e); for (@ast.crate_directive cdir in cdirs) { walk_crate_directive(v, cdir); } } case (ast.cdir_src_mod(_, _)) {} case (ast.cdir_dir_mod(_, _, ?cdirs)) { for (@ast.crate_directive cdir in cdirs) { walk_crate_directive(v, cdir); } } case (ast.cdir_view_item(?vi)) { walk_view_item(v, vi); } case (ast.cdir_meta(_)) {} case (ast.cdir_syntax(_)) {} case (ast.cdir_auth(_, _)) {} } v.visit_crate_directive_post(cd); } fn walk_mod(&ast_visitor v, &ast._mod m) { if (!v.keep_going()) { ret; } for (@ast.view_item vi in m.view_items) { walk_view_item(v, vi); } for (@ast.item i in m.items) { walk_item(v, i); } } fn walk_view_item(&ast_visitor v, @ast.view_item vi) { if (!v.keep_going()) { ret; } v.visit_view_item_pre(vi); v.visit_view_item_post(vi); } fn walk_item(&ast_visitor v, @ast.item i) { if (!v.keep_going()) { ret; } v.visit_item_pre(i); alt (i.node) { case (ast.item_const(_, ?t, ?e, _, _)) { walk_ty(v, t); walk_expr(v, e); } case (ast.item_fn(_, ?f, _, _, _)) { walk_fn(v, f); } case (ast.item_mod(_, ?m, _)) { walk_mod(v, m); } case (ast.item_native_mod(_, ?nm, _)) { walk_native_mod(v, nm); } case (ast.item_ty(_, ?t, _, _, _)) { walk_ty(v, t); } case (ast.item_tag(_, ?variants, _, _, _)) { for (ast.variant vr in variants) { for (ast.variant_arg va in vr.node.args) { walk_ty(v, va.ty); } } } case (ast.item_obj(_, ?ob, _, _, _)) { for (ast.obj_field f in ob.fields) { walk_ty(v, f.ty); } for (@ast.method m in ob.methods) { walk_fn(v, m.node.meth); } alt (ob.dtor) { case (none[@ast.method]) {} case (some[@ast.method](?m)) { walk_fn(v, m.node.meth); } } } } v.visit_item_post(i); } fn walk_ty(&ast_visitor v, @ast.ty t) { if (!v.keep_going()) { ret; } v.visit_ty_pre(t); alt (t.node) { case (ast.ty_nil) {} case (ast.ty_bool) {} case (ast.ty_int) {} case (ast.ty_uint) {} case (ast.ty_float) {} case (ast.ty_machine(_)) {} case (ast.ty_char) {} case (ast.ty_str) {} case (ast.ty_box(?mt)) { walk_ty(v, mt.ty); } case (ast.ty_vec(?mt)) { walk_ty(v, mt.ty); } case (ast.ty_port(?t)) { walk_ty(v, t); } case (ast.ty_chan(?t)) { walk_ty(v, t); } case (ast.ty_tup(?mts)) { for (ast.mt mt in mts) { walk_ty(v, mt.ty); } } case (ast.ty_rec(?flds)) { for (ast.ty_field f in flds) { walk_ty(v, f.mt.ty); } } case (ast.ty_fn(_, ?args, ?out)) { for (ast.ty_arg a in args) { walk_ty(v, a.ty); } walk_ty(v, out); } case (ast.ty_obj(?tmeths)) { for (ast.ty_method m in tmeths) { for (ast.ty_arg a in m.inputs) { walk_ty(v, a.ty); } walk_ty(v, m.output); } } case (ast.ty_path(_, _)) {} case (ast.ty_type) {} case (ast.ty_constr(?t, _)) { walk_ty(v, t); } } v.visit_ty_post(t); } fn walk_native_mod(&ast_visitor v, &ast.native_mod nm) { if (!v.keep_going()) { ret; } for (@ast.view_item vi in nm.view_items) { walk_view_item(v, vi); } for (@ast.native_item ni in nm.items) { walk_native_item(v, ni); } } fn walk_native_item(&ast_visitor v, @ast.native_item ni) { if (!v.keep_going()) { ret; } v.visit_native_item_pre(ni); alt (ni.node) { case (ast.native_item_fn(_, _, ?fd, _, _, _)) { walk_fn_decl(v, fd); } case (ast.native_item_ty(_, _)) { } } v.visit_native_item_post(ni); } fn walk_fn_decl(&ast_visitor v, &ast.fn_decl fd) { for (ast.arg a in fd.inputs) { walk_ty(v, a.ty); } walk_ty(v, fd.output); } fn walk_fn(&ast_visitor v, &ast._fn f) { if (!v.keep_going()) { ret; } walk_fn_decl(v, f.decl); walk_block(v, f.body); } fn walk_block(&ast_visitor v, &ast.block b) { if (!v.keep_going()) { ret; } v.visit_block_pre(b); for (@ast.stmt s in b.node.stmts) { walk_stmt(v, s); } walk_expr_opt(v, b.node.expr); v.visit_block_post(b); } fn walk_stmt(&ast_visitor v, @ast.stmt s) { if (!v.keep_going()) { ret; } v.visit_stmt_pre(s); alt (s.node) { case (ast.stmt_decl(?d, _)) { walk_decl(v, d); } case (ast.stmt_expr(?e, _)) { walk_expr(v, e); } case (ast.stmt_crate_directive(?cdir)) { walk_crate_directive(v, cdir); } } v.visit_stmt_post(s); } fn walk_decl(&ast_visitor v, @ast.decl d) { if (!v.keep_going()) { ret; } v.visit_decl_pre(d); alt (d.node) { case (ast.decl_local(?loc)) { alt (loc.ty) { case (none[@ast.ty]) {} case (some[@ast.ty](?t)) { walk_ty(v, t); } } alt (loc.init) { case (none[ast.initializer]) {} case (some[ast.initializer](?i)) { walk_expr(v, i.expr); } } } case (ast.decl_item(?it)) { walk_item(v, it); } } v.visit_decl_post(d); } fn walk_expr_opt(&ast_visitor v, option.t[@ast.expr] eo) { alt (eo) { case (none[@ast.expr]) {} case (some[@ast.expr](?e)) { walk_expr(v, e); } } } fn walk_exprs(&ast_visitor v, vec[@ast.expr] exprs) { for (@ast.expr e in exprs) { walk_expr(v, e); } } fn walk_expr(&ast_visitor v, @ast.expr e) { if (!v.keep_going()) { ret; } v.visit_expr_pre(e); alt (e.node) { case (ast.expr_vec(?es, _, _)) { walk_exprs(v, es); } case (ast.expr_tup(?elts, _)) { for (ast.elt e in elts) { walk_expr(v, e.expr); } } case (ast.expr_rec(?flds, ?base, _)) { for (ast.field f in flds) { walk_expr(v, f.expr); } walk_expr_opt(v, base); } case (ast.expr_call(?callee, ?args, _)) { walk_expr(v, callee); walk_exprs(v, args); } case (ast.expr_self_method(_, _)) { } case (ast.expr_bind(?callee, ?args, _)) { walk_expr(v, callee); for (option.t[@ast.expr] eo in args) { walk_expr_opt(v, eo); } } case (ast.expr_spawn(_, _, ?callee, ?args, _)) { walk_expr(v, callee); walk_exprs(v, args); } case (ast.expr_binary(_, ?a, ?b, _)) { walk_expr(v, a); walk_expr(v, b); } case (ast.expr_unary(_, ?a, _)) { walk_expr(v, a); } case (ast.expr_lit(_, _)) { } case (ast.expr_cast(?x, ?t, _)) { walk_expr(v, x); walk_ty(v, t); } case (ast.expr_if(?x, ?b, ?eo, _)) { walk_expr(v, x); walk_block(v, b); walk_expr_opt(v, eo); } case (ast.expr_while(?x, ?b, _)) { walk_expr(v, x); walk_block(v, b); } case (ast.expr_for(?dcl, ?x, ?b, _)) { walk_decl(v, dcl); walk_expr(v, x); walk_block(v, b); } case (ast.expr_for_each(?dcl, ?x, ?b, _)) { walk_decl(v, dcl); walk_expr(v, x); walk_block(v, b); } case (ast.expr_do_while(?b, ?x, _)) { walk_block(v, b); walk_expr(v, x); } case (ast.expr_alt(?x, ?arms, _)) { walk_expr(v, x); for (ast.arm a in arms) { walk_block(v, a.block); } } case (ast.expr_block(?b, _)) { walk_block(v, b); } case (ast.expr_assign(?a, ?b, _)) { walk_expr(v, a); walk_expr(v, b); } case (ast.expr_assign_op(_, ?a, ?b, _)) { walk_expr(v, a); walk_expr(v, b); } case (ast.expr_send(?a, ?b, _)) { walk_expr(v, a); walk_expr(v, b); } case (ast.expr_recv(?a, ?b, _)) { walk_expr(v, a); walk_expr(v, b); } case (ast.expr_field(?x, _, _)) { walk_expr(v, x); } case (ast.expr_index(?a, ?b, _)) { walk_expr(v, a); walk_expr(v, b); } case (ast.expr_path(_, _, _)) { } case (ast.expr_ext(_, ?args, ?body, ?expansion, _)) { // Only walk expansion, not args/body. walk_expr(v, expansion); } case (ast.expr_fail(_)) { } case (ast.expr_break(_)) { } case (ast.expr_cont(_)) { } case (ast.expr_ret(?eo, _)) { walk_expr_opt(v, eo); } case (ast.expr_put(?eo, _)) { walk_expr_opt(v, eo); } case (ast.expr_be(?x, _)) { walk_expr(v, x); } case (ast.expr_log(_,?x, _)) { walk_expr(v, x); } case (ast.expr_check_expr(?x, _)) { walk_expr(v, x); } case (ast.expr_port(_)) { } case (ast.expr_chan(?x, _)) { walk_expr(v, x); } } v.visit_expr_post(e); } fn def_keep_going() -> bool { ret true; } fn def_want_crate_directives() -> bool { ret false; } fn def_visit_crate(&ast.crate c) { } fn def_visit_crate_directive(@ast.crate_directive c) { } fn def_visit_view_item(@ast.view_item vi) { } fn def_visit_native_item(@ast.native_item ni) { } fn def_visit_item(@ast.item i) { } fn def_visit_block(&ast.block b) { } fn def_visit_stmt(@ast.stmt s) { } fn def_visit_decl(@ast.decl d) { } fn def_visit_expr(@ast.expr e) { } fn def_visit_ty(@ast.ty t) { } fn default_visitor() -> ast_visitor { auto d_keep_going = def_keep_going; auto d_want_crate_directives = def_want_crate_directives; auto d_visit_crate = def_visit_crate; auto d_visit_crate_directive = def_visit_crate_directive; auto d_visit_view_item = def_visit_view_item; auto d_visit_native_item = def_visit_native_item; auto d_visit_item = def_visit_item; auto d_visit_block = def_visit_block; auto d_visit_stmt = def_visit_stmt; auto d_visit_decl = def_visit_decl; auto d_visit_expr = def_visit_expr; auto d_visit_ty = def_visit_ty; ret rec(keep_going = d_keep_going, want_crate_directives = d_want_crate_directives, visit_crate_pre = d_visit_crate, visit_crate_post = d_visit_crate, visit_crate_directive_pre = d_visit_crate_directive, visit_crate_directive_post = d_visit_crate_directive, visit_view_item_pre = d_visit_view_item, visit_view_item_post = d_visit_view_item, visit_native_item_pre = d_visit_native_item, visit_native_item_post = d_visit_native_item, visit_item_pre = d_visit_item, visit_item_post = d_visit_item, visit_block_pre = d_visit_block, visit_block_post = d_visit_block, visit_stmt_pre = d_visit_stmt, visit_stmt_post = d_visit_stmt, visit_decl_pre = d_visit_decl, visit_decl_post = d_visit_decl, visit_expr_pre = d_visit_expr, visit_expr_post = d_visit_expr, visit_ty_pre = d_visit_ty, visit_ty_post = d_visit_ty); } // // Local Variables: // mode: rust // fill-column: 78; // indent-tabs-mode: nil // c-basic-offset: 4 // buffer-file-coding-system: utf-8-unix // compile-command: "make -k -C $RBUILD 2>&1 | sed -e 's/\\/x\\//x:\\//g'"; // End: //
use super::{DropdownID, ExampleBox, Model, Msg}; use seed::{prelude::*, *}; use seed_bootstrap::button::Button; use seed_bootstrap::button_group::ButtonGroup; use seed_bootstrap::dropdown::{Dropdown, Item}; pub fn view(model: &Model) -> Node<Msg> { div![ C!["pt-5"], h1!["Button groups"], hr![], ExampleBox::new("Basic example") .content(div![ ButtonGroup::new("Basic example") .content(vec![ Button::new("Left").view(), Button::new("Middle").view(), Button::new("Right").view(), ]) ]) .code( r#"ButtonGroup::new("Basic example") .content(vec![ Button::new("Left").view(), Button::new("Middle").view(), Button::new("Right").view(), ])"# ), ExampleBox::new("Button toolbar") .content(div![ ButtonGroup::new("Toolbar with button groups") .toolbar() .content(vec![ ButtonGroup::new("First group") .add_attrs(C!["mr-2"]) .content(vec![ Button::new("1").secondary().view(), Button::new("2").secondary().view(), Button::new("3").secondary().view(), Button::new("4").secondary().view(), ]).view(), ButtonGroup::new("Second group") .add_attrs(C!["mr-2"]) .content(vec![ Button::new("5").secondary().view(), Button::new("6").secondary().view(), Button::new("7").secondary().view(), ]).view(), ButtonGroup::new("Third group") .content( Button::new("8").secondary().view() ).view(), ]) ]) .code( r#"ButtonGroup::new("Toolbar with button groups") .toolbar() .content(vec![ ButtonGroup::new("First group") .add_attrs(C!["mr-2"]) .content(vec![ Button::new("1").secondary().view(), Button::new("2").secondary().view(), Button::new("3").secondary().view(), Button::new("4").secondary().view(), ]).view(), ButtonGroup::new("Second group") .add_attrs(C!["mr-2"]) .content(vec![ Button::new("5").secondary().view(), Button::new("6").secondary().view(), Button::new("7").secondary().view(), ]).view(), ButtonGroup::new("Third group") .content( Button::new("8").secondary().view() ).view(), ])"# ), ExampleBox::new("Nesting") .content(div![ ButtonGroup::new("Button group with nested dropdown") .content(vec![ Button::new("1").view(), Button::new("2").view(), ButtonGroup::default() .content( Dropdown::new("Dropdown ") .items(vec![Item::a("Dropdown link", (), "#"), Item::a("Dropdown link", (), "#")]) .add_on_item_click(|event, _| { event.prevent_default(); Msg::NoOp }) .view(&model.dropdowns[&DropdownID::Nested], |msg| Msg::DropdownMsg(msg, DropdownID::Nested)) ).view(), ]) ]) .code( r##"ButtonGroup::new("Button group with nested dropdown") .content(vec![ Button::new("1").view(), Button::new("2").view(), ButtonGroup::default() .content( Dropdown::new("Dropdown ") .items(vec![Item::a("Dropdown link", (), "#"), Item::a("Dropdown link", (), "#")]) .add_on_item_click(|event, _| { event.prevent_default(); Msg::NoOp }) .view(&model.dropdowns[&DropdownID::Nested], |msg| Msg::DropdownMsg(msg, DropdownID::Nested)) ).view(), ])"## ), ExampleBox::new("Vertical variation") .content(div![ ButtonGroup::new("Button group with nested dropdown - vertical") .vertical() .content(vec![ Button::new("Button").secondary().view(), Button::new("Button").secondary().view(), ButtonGroup::default() .content( Dropdown::new("Dropdown ") .items(vec![Item::a("Dropdown link", (), "#"), Item::a("Dropdown link", (), "#")]) .update_toggle(|toggle| toggle.secondary()) .add_on_item_click(|event, _| { event.prevent_default(); Msg::NoOp }) .view(&model.dropdowns[&DropdownID::NestedVertical], |msg| Msg::DropdownMsg(msg, DropdownID::NestedVertical)) ).view(), ]) ]) .code( r##"ButtonGroup::new("Button group with nested dropdown - vertical") .vertical() .content(vec![ Button::new("Button").secondary().view(), Button::new("Button").secondary().view(), ButtonGroup::default() .content( Dropdown::new("Dropdown ") .items(vec![Item::a("Dropdown link", (), "#"), Item::a("Dropdown link", (), "#")]) .update_toggle(|toggle| toggle.secondary()) .add_on_item_click(|event, _| { event.prevent_default(); Msg::NoOp }) .view(&model.dropdowns[&DropdownID::NestedVertical], |msg| Msg::DropdownMsg(msg, DropdownID::NestedVertical)) ).view(), ])"## ), ] }
#[doc = r"Value read from the register"] pub struct R { bits: u8, } #[doc = r"Value to write to the register"] pub struct W { bits: u8, } impl super::TXCSRH7 { #[doc = r"Modifies the contents of the register"] #[inline(always)] pub fn modify<F>(&self, f: F) where for<'w> F: FnOnce(&R, &'w mut W) -> &'w mut W, { let bits = self.register.get(); self.register.set(f(&R { bits }, &mut W { bits }).bits); } #[doc = r"Reads the contents of the register"] #[inline(always)] pub fn read(&self) -> R { R { bits: self.register.get(), } } #[doc = r"Writes to the register"] #[inline(always)] pub fn write<F>(&self, f: F) where F: FnOnce(&mut W) -> &mut W, { self.register.set( f(&mut W { bits: Self::reset_value(), }) .bits, ); } #[doc = r"Reset value of the register"] #[inline(always)] pub const fn reset_value() -> u8 { 0 } #[doc = r"Writes the reset value to the register"] #[inline(always)] pub fn reset(&self) { self.register.set(Self::reset_value()) } } #[doc = r"Value of the field"] pub struct USB_TXCSRH7_DTR { bits: bool, } impl USB_TXCSRH7_DTR { #[doc = r"Value of the field as raw bits"] #[inline(always)] pub fn bit(&self) -> bool { self.bits } #[doc = r"Returns `true` if the bit is clear (0)"] #[inline(always)] pub fn bit_is_clear(&self) -> bool { !self.bit() } #[doc = r"Returns `true` if the bit is set (1)"] #[inline(always)] pub fn bit_is_set(&self) -> bool { self.bit() } } #[doc = r"Proxy"] pub struct _USB_TXCSRH7_DTW<'a> { w: &'a mut W, } impl<'a> _USB_TXCSRH7_DTW<'a> { #[doc = r"Sets the field bit"] #[inline(always)] pub fn set_bit(self) -> &'a mut W { self.bit(true) } #[doc = r"Clears the field bit"] #[inline(always)] pub fn clear_bit(self) -> &'a mut W { self.bit(false) } #[doc = r"Writes raw bits to the field"] #[inline(always)] pub fn bit(self, value: bool) -> &'a mut W { self.w.bits &= !(1 << 0); self.w.bits |= ((value as u8) & 1) << 0; self.w } } #[doc = r"Value of the field"] pub struct USB_TXCSRH7_DTWER { bits: bool, } impl USB_TXCSRH7_DTWER { #[doc = r"Value of the field as raw bits"] #[inline(always)] pub fn bit(&self) -> bool { self.bits } #[doc = r"Returns `true` if the bit is clear (0)"] #[inline(always)] pub fn bit_is_clear(&self) -> bool { !self.bit() } #[doc = r"Returns `true` if the bit is set (1)"] #[inline(always)] pub fn bit_is_set(&self) -> bool { self.bit() } } #[doc = r"Proxy"] pub struct _USB_TXCSRH7_DTWEW<'a> { w: &'a mut W, } impl<'a> _USB_TXCSRH7_DTWEW<'a> { #[doc = r"Sets the field bit"] #[inline(always)] pub fn set_bit(self) -> &'a mut W { self.bit(true) } #[doc = r"Clears the field bit"] #[inline(always)] pub fn clear_bit(self) -> &'a mut W { self.bit(false) } #[doc = r"Writes raw bits to the field"] #[inline(always)] pub fn bit(self, value: bool) -> &'a mut W { self.w.bits &= !(1 << 1); self.w.bits |= ((value as u8) & 1) << 1; self.w } } #[doc = r"Value of the field"] pub struct USB_TXCSRH7_DMAMODR { bits: bool, } impl USB_TXCSRH7_DMAMODR { #[doc = r"Value of the field as raw bits"] #[inline(always)] pub fn bit(&self) -> bool { self.bits } #[doc = r"Returns `true` if the bit is clear (0)"] #[inline(always)] pub fn bit_is_clear(&self) -> bool { !self.bit() } #[doc = r"Returns `true` if the bit is set (1)"] #[inline(always)] pub fn bit_is_set(&self) -> bool { self.bit() } } #[doc = r"Proxy"] pub struct _USB_TXCSRH7_DMAMODW<'a> { w: &'a mut W, } impl<'a> _USB_TXCSRH7_DMAMODW<'a> { #[doc = r"Sets the field bit"] #[inline(always)] pub fn set_bit(self) -> &'a mut W { self.bit(true) } #[doc = r"Clears the field bit"] #[inline(always)] pub fn clear_bit(self) -> &'a mut W { self.bit(false) } #[doc = r"Writes raw bits to the field"] #[inline(always)] pub fn bit(self, value: bool) -> &'a mut W { self.w.bits &= !(1 << 2); self.w.bits |= ((value as u8) & 1) << 2; self.w } } #[doc = r"Value of the field"] pub struct USB_TXCSRH7_FDTR { bits: bool, } impl USB_TXCSRH7_FDTR { #[doc = r"Value of the field as raw bits"] #[inline(always)] pub fn bit(&self) -> bool { self.bits } #[doc = r"Returns `true` if the bit is clear (0)"] #[inline(always)] pub fn bit_is_clear(&self) -> bool { !self.bit() } #[doc = r"Returns `true` if the bit is set (1)"] #[inline(always)] pub fn bit_is_set(&self) -> bool { self.bit() } } #[doc = r"Proxy"] pub struct _USB_TXCSRH7_FDTW<'a> { w: &'a mut W, } impl<'a> _USB_TXCSRH7_FDTW<'a> { #[doc = r"Sets the field bit"] #[inline(always)] pub fn set_bit(self) -> &'a mut W { self.bit(true) } #[doc = r"Clears the field bit"] #[inline(always)] pub fn clear_bit(self) -> &'a mut W { self.bit(false) } #[doc = r"Writes raw bits to the field"] #[inline(always)] pub fn bit(self, value: bool) -> &'a mut W { self.w.bits &= !(1 << 3); self.w.bits |= ((value as u8) & 1) << 3; self.w } } #[doc = r"Value of the field"] pub struct USB_TXCSRH7_DMAENR { bits: bool, } impl USB_TXCSRH7_DMAENR { #[doc = r"Value of the field as raw bits"] #[inline(always)] pub fn bit(&self) -> bool { self.bits } #[doc = r"Returns `true` if the bit is clear (0)"] #[inline(always)] pub fn bit_is_clear(&self) -> bool { !self.bit() } #[doc = r"Returns `true` if the bit is set (1)"] #[inline(always)] pub fn bit_is_set(&self) -> bool { self.bit() } } #[doc = r"Proxy"] pub struct _USB_TXCSRH7_DMAENW<'a> { w: &'a mut W, } impl<'a> _USB_TXCSRH7_DMAENW<'a> { #[doc = r"Sets the field bit"] #[inline(always)] pub fn set_bit(self) -> &'a mut W { self.bit(true) } #[doc = r"Clears the field bit"] #[inline(always)] pub fn clear_bit(self) -> &'a mut W { self.bit(false) } #[doc = r"Writes raw bits to the field"] #[inline(always)] pub fn bit(self, value: bool) -> &'a mut W { self.w.bits &= !(1 << 4); self.w.bits |= ((value as u8) & 1) << 4; self.w } } #[doc = r"Value of the field"] pub struct USB_TXCSRH7_MODER { bits: bool, } impl USB_TXCSRH7_MODER { #[doc = r"Value of the field as raw bits"] #[inline(always)] pub fn bit(&self) -> bool { self.bits } #[doc = r"Returns `true` if the bit is clear (0)"] #[inline(always)] pub fn bit_is_clear(&self) -> bool { !self.bit() } #[doc = r"Returns `true` if the bit is set (1)"] #[inline(always)] pub fn bit_is_set(&self) -> bool { self.bit() } } #[doc = r"Proxy"] pub struct _USB_TXCSRH7_MODEW<'a> { w: &'a mut W, } impl<'a> _USB_TXCSRH7_MODEW<'a> { #[doc = r"Sets the field bit"] #[inline(always)] pub fn set_bit(self) -> &'a mut W { self.bit(true) } #[doc = r"Clears the field bit"] #[inline(always)] pub fn clear_bit(self) -> &'a mut W { self.bit(false) } #[doc = r"Writes raw bits to the field"] #[inline(always)] pub fn bit(self, value: bool) -> &'a mut W { self.w.bits &= !(1 << 5); self.w.bits |= ((value as u8) & 1) << 5; self.w } } #[doc = r"Value of the field"] pub struct USB_TXCSRH7_ISOR { bits: bool, } impl USB_TXCSRH7_ISOR { #[doc = r"Value of the field as raw bits"] #[inline(always)] pub fn bit(&self) -> bool { self.bits } #[doc = r"Returns `true` if the bit is clear (0)"] #[inline(always)] pub fn bit_is_clear(&self) -> bool { !self.bit() } #[doc = r"Returns `true` if the bit is set (1)"] #[inline(always)] pub fn bit_is_set(&self) -> bool { self.bit() } } #[doc = r"Proxy"] pub struct _USB_TXCSRH7_ISOW<'a> { w: &'a mut W, } impl<'a> _USB_TXCSRH7_ISOW<'a> { #[doc = r"Sets the field bit"] #[inline(always)] pub fn set_bit(self) -> &'a mut W { self.bit(true) } #[doc = r"Clears the field bit"] #[inline(always)] pub fn clear_bit(self) -> &'a mut W { self.bit(false) } #[doc = r"Writes raw bits to the field"] #[inline(always)] pub fn bit(self, value: bool) -> &'a mut W { self.w.bits &= !(1 << 6); self.w.bits |= ((value as u8) & 1) << 6; self.w } } #[doc = r"Value of the field"] pub struct USB_TXCSRH7_AUTOSETR { bits: bool, } impl USB_TXCSRH7_AUTOSETR { #[doc = r"Value of the field as raw bits"] #[inline(always)] pub fn bit(&self) -> bool { self.bits } #[doc = r"Returns `true` if the bit is clear (0)"] #[inline(always)] pub fn bit_is_clear(&self) -> bool { !self.bit() } #[doc = r"Returns `true` if the bit is set (1)"] #[inline(always)] pub fn bit_is_set(&self) -> bool { self.bit() } } #[doc = r"Proxy"] pub struct _USB_TXCSRH7_AUTOSETW<'a> { w: &'a mut W, } impl<'a> _USB_TXCSRH7_AUTOSETW<'a> { #[doc = r"Sets the field bit"] #[inline(always)] pub fn set_bit(self) -> &'a mut W { self.bit(true) } #[doc = r"Clears the field bit"] #[inline(always)] pub fn clear_bit(self) -> &'a mut W { self.bit(false) } #[doc = r"Writes raw bits to the field"] #[inline(always)] pub fn bit(self, value: bool) -> &'a mut W { self.w.bits &= !(1 << 7); self.w.bits |= ((value as u8) & 1) << 7; self.w } } impl R { #[doc = r"Value of the register as raw bits"] #[inline(always)] pub fn bits(&self) -> u8 { self.bits } #[doc = "Bit 0 - Data Toggle"] #[inline(always)] pub fn usb_txcsrh7_dt(&self) -> USB_TXCSRH7_DTR { let bits = ((self.bits >> 0) & 1) != 0; USB_TXCSRH7_DTR { bits } } #[doc = "Bit 1 - Data Toggle Write Enable"] #[inline(always)] pub fn usb_txcsrh7_dtwe(&self) -> USB_TXCSRH7_DTWER { let bits = ((self.bits >> 1) & 1) != 0; USB_TXCSRH7_DTWER { bits } } #[doc = "Bit 2 - DMA Request Mode"] #[inline(always)] pub fn usb_txcsrh7_dmamod(&self) -> USB_TXCSRH7_DMAMODR { let bits = ((self.bits >> 2) & 1) != 0; USB_TXCSRH7_DMAMODR { bits } } #[doc = "Bit 3 - Force Data Toggle"] #[inline(always)] pub fn usb_txcsrh7_fdt(&self) -> USB_TXCSRH7_FDTR { let bits = ((self.bits >> 3) & 1) != 0; USB_TXCSRH7_FDTR { bits } } #[doc = "Bit 4 - DMA Request Enable"] #[inline(always)] pub fn usb_txcsrh7_dmaen(&self) -> USB_TXCSRH7_DMAENR { let bits = ((self.bits >> 4) & 1) != 0; USB_TXCSRH7_DMAENR { bits } } #[doc = "Bit 5 - Mode"] #[inline(always)] pub fn usb_txcsrh7_mode(&self) -> USB_TXCSRH7_MODER { let bits = ((self.bits >> 5) & 1) != 0; USB_TXCSRH7_MODER { bits } } #[doc = "Bit 6 - Isochronous Transfers"] #[inline(always)] pub fn usb_txcsrh7_iso(&self) -> USB_TXCSRH7_ISOR { let bits = ((self.bits >> 6) & 1) != 0; USB_TXCSRH7_ISOR { bits } } #[doc = "Bit 7 - Auto Set"] #[inline(always)] pub fn usb_txcsrh7_autoset(&self) -> USB_TXCSRH7_AUTOSETR { let bits = ((self.bits >> 7) & 1) != 0; USB_TXCSRH7_AUTOSETR { bits } } } impl W { #[doc = r"Writes raw bits to the register"] #[inline(always)] pub unsafe fn bits(&mut self, bits: u8) -> &mut Self { self.bits = bits; self } #[doc = "Bit 0 - Data Toggle"] #[inline(always)] pub fn usb_txcsrh7_dt(&mut self) -> _USB_TXCSRH7_DTW { _USB_TXCSRH7_DTW { w: self } } #[doc = "Bit 1 - Data Toggle Write Enable"] #[inline(always)] pub fn usb_txcsrh7_dtwe(&mut self) -> _USB_TXCSRH7_DTWEW { _USB_TXCSRH7_DTWEW { w: self } } #[doc = "Bit 2 - DMA Request Mode"] #[inline(always)] pub fn usb_txcsrh7_dmamod(&mut self) -> _USB_TXCSRH7_DMAMODW { _USB_TXCSRH7_DMAMODW { w: self } } #[doc = "Bit 3 - Force Data Toggle"] #[inline(always)] pub fn usb_txcsrh7_fdt(&mut self) -> _USB_TXCSRH7_FDTW { _USB_TXCSRH7_FDTW { w: self } } #[doc = "Bit 4 - DMA Request Enable"] #[inline(always)] pub fn usb_txcsrh7_dmaen(&mut self) -> _USB_TXCSRH7_DMAENW { _USB_TXCSRH7_DMAENW { w: self } } #[doc = "Bit 5 - Mode"] #[inline(always)] pub fn usb_txcsrh7_mode(&mut self) -> _USB_TXCSRH7_MODEW { _USB_TXCSRH7_MODEW { w: self } } #[doc = "Bit 6 - Isochronous Transfers"] #[inline(always)] pub fn usb_txcsrh7_iso(&mut self) -> _USB_TXCSRH7_ISOW { _USB_TXCSRH7_ISOW { w: self } } #[doc = "Bit 7 - Auto Set"] #[inline(always)] pub fn usb_txcsrh7_autoset(&mut self) -> _USB_TXCSRH7_AUTOSETW { _USB_TXCSRH7_AUTOSETW { w: self } } }
// Copyright 2019 The Fuchsia Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. //! A portable representation of handle-like objects for fidl. //! Since this code needs implementation of the fidlhdl_* groups of functions, tests for this //! module exist in th src/connectivity/overnet/lib/hoist/src/fidlhdl.rs module (which provides //! them). /// Fuchsia implementation of handles just aliases the zircon library #[cfg(target_os = "fuchsia")] pub mod fuchsia_handles { use fuchsia_async as fasync; use fuchsia_zircon as zx; pub use zx::AsHandleRef; pub use zx::Handle; pub use zx::HandleBased; pub use zx::HandleRef; pub use zx::MessageBuf; pub use zx::Channel; pub use zx::DebugLog; pub use zx::Event; pub use zx::EventPair; pub use zx::Fifo; pub use zx::Interrupt; pub use zx::Job; pub use zx::Port; pub use zx::Process; pub use zx::Resource; pub use zx::Socket; pub use zx::Thread; pub use zx::Timer; pub use zx::Vmar; pub use zx::Vmo; pub use fasync::Channel as AsyncChannel; pub use fasync::Socket as AsyncSocket; pub use zx::SocketOpts; } /// Non-Fuchsia implementation of handles #[cfg(not(target_os = "fuchsia"))] pub mod non_fuchsia_handles { use fuchsia_zircon_status as zx_status; use futures::{ task::{AtomicWaker, Context}, Poll, }; use parking_lot::Mutex; use std::{borrow::BorrowMut, pin::Pin, sync::Arc}; /// Invalid handle value pub const INVALID_HANDLE: u32 = 0xffff_ffff; /// Read result for IO operations #[repr(C)] pub enum FidlHdlReadResult { /// Success! Ok, /// Nothing read Pending, /// Peer handle is closed PeerClosed, /// Not enough buffer space BufferTooSmall, } /// Write result for IO operations #[repr(C)] pub enum FidlHdlWriteResult { /// Success! Ok, /// Peer handle is closed PeerClosed, } /// Return type for fidlhdl_channel_create // Upon success, left=first handle, right=second handle // Upon failure, left=INVALID_HANDLE, right=reason #[repr(C)] pub struct FidlHdlPairCreateResult { left: u32, right: u32, } impl FidlHdlPairCreateResult { unsafe fn into_handles<T: HandleBased>(&self) -> Result<(T, T), zx_status::Status> { match self.left { INVALID_HANDLE => Err(zx_status::Status::from_raw(self.right as i32)), _ => Ok(( T::from_handle(Handle::from_raw(self.left)), T::from_handle(Handle::from_raw(self.right)), )), } } /// Create a new (successful) result pub fn new(left: u32, right: u32) -> Self { assert_ne!(left, INVALID_HANDLE); assert_ne!(right, INVALID_HANDLE); Self { left, right } } /// Create a new (failed) result pub fn new_err(status: zx_status::Status) -> Self { Self { left: INVALID_HANDLE, right: status.into_raw() as u32 } } } /// The type of a handle #[repr(C)] pub enum FidlHdlType { /// An invalid handle Invalid, /// A channel Channel, /// A socket Socket, } /// Non-Fuchsia implementation of handles extern "C" { /// Close the handle: no action if hdl==INVALID_HANDLE fn fidlhdl_close(hdl: u32); /// Return the type of a handle fn fidlhdl_type(hdl: u32) -> FidlHdlType; /// Create a channel pair fn fidlhdl_channel_create() -> FidlHdlPairCreateResult; /// Read from a channel - takes ownership of all handles fn fidlhdl_channel_read( hdl: u32, bytes: *mut u8, handles: *mut u32, num_bytes: usize, num_handles: usize, actual_bytes: *mut usize, actual_handles: *mut usize, ) -> FidlHdlReadResult; /// Write to a channel fn fidlhdl_channel_write( hdl: u32, bytes: *const u8, handles: *mut Handle, num_bytes: usize, num_handles: usize, ) -> FidlHdlWriteResult; /// Write to a socket fn fidlhdl_socket_write(hdl: u32, bytes: *const u8, num_bytes: usize) -> FidlHdlWriteResult; /// Read from a socket fn fidlhdl_socket_read( hdl: u32, bytes: *const u8, num_bytes: usize, actual_bytes: *mut usize, ) -> FidlHdlReadResult; /// Signal that a read is required fn fidlhdl_need_read(hdl: u32); /// Create a socket pair fn fidlhdl_socket_create(sock_opts: SocketOpts) -> FidlHdlPairCreateResult; } #[derive(Debug)] struct HdlWaker { hdl: u32, waker: AtomicWaker, } impl HdlWaker { fn sched(&self, cx: &mut Context<'_>) { self.waker.register(cx.waker()); unsafe { fidlhdl_need_read(self.hdl); } } } lazy_static::lazy_static! { static ref HANDLE_WAKEUPS: Mutex<Vec<Arc<HdlWaker>>> = Mutex::new(Vec::new()); } /// Awaken a handle by index. /// /// Wakeup flow: /// There are no wakeups issued unless fidlhdl_need_read is called. /// fidlhdl_need_read arms the wakeup, and no wakeups will occur until that call is made. pub fn awaken_hdl(hdl: u32) { HANDLE_WAKEUPS.lock()[hdl as usize].waker.wake(); } fn get_or_create_arc_waker(hdl: u32) -> Arc<HdlWaker> { assert_ne!(hdl, INVALID_HANDLE); let mut wakers = HANDLE_WAKEUPS.lock(); while wakers.len() <= (hdl as usize) { let index = wakers.len(); wakers.push(Arc::new(HdlWaker { hdl: index as u32, waker: AtomicWaker::new() })); } wakers[hdl as usize].clone() } /// A borrowed reference to an underlying handle pub struct HandleRef(u32); /// A trait to get a reference to the underlying handle of an object. pub trait AsHandleRef { /// Get a reference to the handle. fn as_handle_ref(&self) -> HandleRef; } /// A trait implemented by all handle-based types. pub trait HandleBased: AsHandleRef + From<Handle> + Into<Handle> { /// Creates an instance of this type from a handle. /// /// This is a convenience function which simply forwards to the `From` trait. fn from_handle(handle: Handle) -> Self { Self::from(handle) } /// Converts the value into its inner handle. /// /// This is a convenience function which simply forwards to the `Into` trait. fn into_handle(self) -> Handle { self.into() } } /// Representation of a handle-like object #[repr(C)] #[derive(PartialEq, Eq, Debug)] pub struct Handle(u32); impl Drop for Handle { fn drop(&mut self) { unsafe { fidlhdl_close(self.0); } } } impl AsHandleRef for Handle { fn as_handle_ref(&self) -> HandleRef { HandleRef(self.0) } } impl HandleBased for Handle {} impl Handle { /// Non-fuchsia only: return the type of a handle pub fn handle_type(&self) -> FidlHdlType { if self.is_invalid() { FidlHdlType::Invalid } else { unsafe { fidlhdl_type(self.0) } } } /// Return an invalid handle pub fn invalid() -> Handle { Handle(INVALID_HANDLE) } /// Return true if this handle is invalid pub fn is_invalid(&self) -> bool { self.0 == INVALID_HANDLE } /// If a raw handle is obtained from some other source, this method converts /// it into a type-safe owned handle. pub unsafe fn from_raw(hdl: u32) -> Handle { Handle(hdl) } /// Take this handle and return a new handle (leaves this handle invalid) pub fn take(&mut self) -> Handle { let h = Handle(self.0); self.0 = INVALID_HANDLE; h } /// Take this handle and return a new raw handle (leaves this handle invalid) pub unsafe fn raw_take(&mut self) -> u32 { let h = self.0; self.0 = INVALID_HANDLE; h } } macro_rules! declare_unsupported_fidl_handle { ($name:ident) => { /// A Zircon-like $name #[derive(PartialEq, Eq, Debug, PartialOrd, Ord, Hash)] pub struct $name; impl From<$crate::handle::Handle> for $name { fn from(_: $crate::handle::Handle) -> $name { $name } } impl From<$name> for Handle { fn from(_: $name) -> $crate::handle::Handle { $crate::handle::Handle::invalid() } } impl HandleBased for $name {} impl AsHandleRef for $name { fn as_handle_ref(&self) -> HandleRef { HandleRef(INVALID_HANDLE) } } }; } declare_unsupported_fidl_handle!(Event); declare_unsupported_fidl_handle!(EventPair); declare_unsupported_fidl_handle!(Vmo); macro_rules! declare_fidl_handle { ($name:ident) => { /// A Zircon-like $name #[derive(PartialEq, Eq, Debug, PartialOrd, Ord, Hash)] pub struct $name(u32); impl From<$crate::handle::Handle> for $name { fn from(mut hdl: $crate::handle::Handle) -> $name { let out = $name(hdl.0); hdl.0 = INVALID_HANDLE; out } } impl From<$name> for Handle { fn from(mut hdl: $name) -> $crate::handle::Handle { let out = unsafe { $crate::handle::Handle::from_raw(hdl.0) }; hdl.0 = INVALID_HANDLE; out } } impl HandleBased for $name {} impl AsHandleRef for $name { fn as_handle_ref(&self) -> HandleRef { HandleRef(self.0) } } impl Drop for $name { fn drop(&mut self) { unsafe { fidlhdl_close(self.0) }; } } }; } declare_fidl_handle!(Channel); impl Channel { /// Create a channel, resulting in a pair of `Channel` objects representing both /// sides of the channel. Messages written into one maybe read from the opposite. pub fn create() -> Result<(Channel, Channel), zx_status::Status> { unsafe { fidlhdl_channel_create().into_handles() } } /// Read a message from a channel. pub fn read(&self, buf: &mut MessageBuf) -> Result<(), zx_status::Status> { let (bytes, handles) = buf.split_mut(); self.read_split(bytes, handles) } /// Read a message from a channel into a separate byte vector and handle vector. /// /// Note that this method can cause internal reallocations in the `MessageBuf` /// if it is lacks capacity to hold the full message. If such reallocations /// are not desirable, use `read_raw` instead. pub fn read_split( &self, bytes: &mut Vec<u8>, handles: &mut Vec<Handle>, ) -> Result<(), zx_status::Status> { loop { match self.read_raw(bytes, handles) { Ok(result) => return result, Err((num_bytes, num_handles)) => { ensure_capacity(bytes, num_bytes); ensure_capacity(handles, num_handles); } } } } /// Read a message from a channel. Wraps the /// [zx_channel_read](https://fuchsia.googlesource.com/fuchsia/+/master/zircon/docs/syscalls/channel_read.md) /// syscall. /// /// If the vectors lack the capacity to hold the pending message, /// returns an `Err` with the number of bytes and number of handles needed. /// Otherwise returns an `Ok` with the result as usual. pub fn read_raw( &self, bytes: &mut Vec<u8>, handles: &mut Vec<Handle>, ) -> Result<Result<(), zx_status::Status>, (usize, usize)> { unsafe { bytes.clear(); handles.clear(); let mut num_bytes = bytes.capacity(); let mut num_handles = handles.capacity(); match fidlhdl_channel_read( self.0, bytes.as_mut_ptr(), handles.as_mut_ptr() as *mut u32, num_bytes, num_handles, &mut num_bytes, &mut num_handles, ) { FidlHdlReadResult::Ok => { bytes.set_len(num_bytes as usize); handles.set_len(num_handles as usize); Ok(Ok(())) } FidlHdlReadResult::Pending => Ok(Err(zx_status::Status::SHOULD_WAIT)), FidlHdlReadResult::PeerClosed => Ok(Err(zx_status::Status::PEER_CLOSED)), FidlHdlReadResult::BufferTooSmall => { Err((num_bytes as usize, num_handles as usize)) } } } } /// Write a message to a channel. pub fn write( &self, bytes: &[u8], handles: &mut Vec<Handle>, ) -> Result<(), zx_status::Status> { match unsafe { fidlhdl_channel_write( self.0, bytes.as_ptr(), handles.as_mut_ptr(), bytes.len(), handles.len(), ) } { FidlHdlWriteResult::Ok => Ok(()), FidlHdlWriteResult::PeerClosed => Err(zx_status::Status::PEER_CLOSED), } } } /// An I/O object representing a `Channel`. #[derive(Debug)] pub struct AsyncChannel { channel: Channel, waker: Arc<HdlWaker>, } impl AsyncChannel { /// Writes a message into the channel. pub fn write( &self, bytes: &[u8], handles: &mut Vec<Handle>, ) -> Result<(), zx_status::Status> { self.channel.write(bytes, handles) } /// Receives a message on the channel and registers this `Channel` as /// needing a read on receiving a `io::std::ErrorKind::WouldBlock`. /// /// Identical to `recv_from` except takes separate bytes and handles buffers /// rather than a single `MessageBuf`. pub fn read( &self, cx: &mut Context<'_>, bytes: &mut Vec<u8>, handles: &mut Vec<Handle>, ) -> Poll<Result<(), zx_status::Status>> { match self.channel.read_split(bytes, handles) { Err(zx_status::Status::SHOULD_WAIT) => { self.waker.sched(cx); Poll::Pending } x => Poll::Ready(x), } } /// Receives a message on the channel and registers this `Channel` as /// needing a read on receiving a `io::std::ErrorKind::WouldBlock`. pub fn recv_from( &self, ctx: &mut Context<'_>, buf: &mut MessageBuf, ) -> Poll<Result<(), zx_status::Status>> { let (bytes, handles) = buf.split_mut(); self.read(ctx, bytes, handles) } /// Creates a future that receive a message to be written to the buffer /// provided. /// /// The returned future will return after a message has been received on /// this socket and been placed into the buffer. pub fn recv_msg<'a>(&'a self, buf: &'a mut MessageBuf) -> RecvMsg<'a> { RecvMsg { channel: self, buf } } /// Creates a new `AsyncChannel` from a previously-created `Channel`. pub fn from_channel(channel: Channel) -> std::io::Result<AsyncChannel> { Ok(AsyncChannel { waker: get_or_create_arc_waker(channel.0), channel }) } } /// A future used to receive a message from a channel. /// /// This is created by the `Channel::recv_msg` method. #[must_use = "futures do nothing unless polled"] pub struct RecvMsg<'a> { channel: &'a AsyncChannel, buf: &'a mut MessageBuf, } impl<'a> futures::Future for RecvMsg<'a> { type Output = Result<(), zx_status::Status>; fn poll(mut self: Pin<&mut Self>, cx: &mut Context<'_>) -> Poll<Self::Output> { let this = &mut *self; this.channel.recv_from(cx, this.buf) } } /// Socket options available portable #[repr(C)] pub enum SocketOpts { /// A bytestream style socket STREAM, } declare_fidl_handle!(Socket); impl Socket { /// Create a pair of sockets pub fn create(sock_opts: SocketOpts) -> Result<(Socket, Socket), zx_status::Status> { unsafe { fidlhdl_socket_create(sock_opts).into_handles() } } /// Write the given bytes into the socket. /// Return value (on success) is number of bytes actually written. pub fn write(&self, bytes: &[u8]) -> Result<usize, zx_status::Status> { match unsafe { fidlhdl_socket_write(self.0, bytes.as_ptr(), bytes.len()) } { FidlHdlWriteResult::Ok => Ok(bytes.len()), FidlHdlWriteResult::PeerClosed => Err(zx_status::Status::PEER_CLOSED), } } /// Read bytes from the socket. /// Return value (on success) is number of bytes actually read. pub fn read(&self, bytes: &mut [u8]) -> Result<usize, zx_status::Status> { let mut actual_len: usize = 0; match unsafe { fidlhdl_socket_read(self.0, bytes.as_ptr(), bytes.len(), &mut actual_len) } { FidlHdlReadResult::Ok => Ok(actual_len), FidlHdlReadResult::Pending => Err(zx_status::Status::SHOULD_WAIT), FidlHdlReadResult::PeerClosed => Err(zx_status::Status::PEER_CLOSED), FidlHdlReadResult::BufferTooSmall => unimplemented!(), } } } /// An I/O object representing a `Socket`. #[derive(Debug)] pub struct AsyncSocket { socket: Socket, waker: Arc<HdlWaker>, } impl AsyncSocket { /// Construct an `AsyncSocket` from an existing `Socket` pub fn from_socket(socket: Socket) -> std::io::Result<AsyncSocket> { Ok(AsyncSocket { waker: get_or_create_arc_waker(socket.0), socket }) } } impl futures::io::AsyncWrite for AsyncSocket { fn poll_write( self: Pin<&mut Self>, _cx: &mut std::task::Context<'_>, bytes: &[u8], ) -> Poll<Result<usize, std::io::Error>> { Poll::Ready(self.socket.write(bytes).map_err(|e| e.into())) } fn poll_flush( self: Pin<&mut Self>, _cx: &mut std::task::Context<'_>, ) -> Poll<Result<(), std::io::Error>> { Poll::Ready(Ok(())) } fn poll_close( mut self: Pin<&mut Self>, _cx: &mut std::task::Context<'_>, ) -> Poll<Result<(), std::io::Error>> { self.borrow_mut().socket = Socket::from_handle(Handle::invalid()); Poll::Ready(Ok(())) } } impl futures::io::AsyncRead for AsyncSocket { fn poll_read( self: Pin<&mut Self>, cx: &mut std::task::Context<'_>, bytes: &mut [u8], ) -> Poll<Result<usize, std::io::Error>> { match self.socket.read(bytes) { Err(zx_status::Status::SHOULD_WAIT) => { self.waker.sched(cx); Poll::Pending } Ok(x) => Poll::Ready(Ok(x)), Err(x) => Poll::Ready(Err(x.into())), } } } /// A buffer for _receiving_ messages from a channel. /// /// A `MessageBuf` is essentially a byte buffer and a vector of /// handles, but move semantics for "taking" handles requires special handling. /// /// Note that for sending messages to a channel, the caller manages the buffers, /// using a plain byte slice and `Vec<Handle>`. #[derive(Debug, Default)] pub struct MessageBuf { bytes: Vec<u8>, handles: Vec<Handle>, } impl MessageBuf { /// Create a new, empty, message buffer. pub fn new() -> Self { Default::default() } /// Create a new non-empty message buffer. pub fn new_with(v: Vec<u8>, h: Vec<Handle>) -> Self { Self { bytes: v, handles: h } } /// Splits apart the message buf into a vector of bytes and a vector of handles. pub fn split_mut(&mut self) -> (&mut Vec<u8>, &mut Vec<Handle>) { (&mut self.bytes, &mut self.handles) } /// Splits apart the message buf into a vector of bytes and a vector of handles. pub fn split(self) -> (Vec<u8>, Vec<Handle>) { (self.bytes, self.handles) } /// Ensure that the buffer has the capacity to hold at least `n_bytes` bytes. pub fn ensure_capacity_bytes(&mut self, n_bytes: usize) { ensure_capacity(&mut self.bytes, n_bytes); } /// Ensure that the buffer has the capacity to hold at least `n_handles` handles. pub fn ensure_capacity_handles(&mut self, n_handles: usize) { ensure_capacity(&mut self.handles, n_handles); } /// Ensure that at least n_bytes bytes are initialized (0 fill). pub fn ensure_initialized_bytes(&mut self, n_bytes: usize) { if n_bytes <= self.bytes.len() { return; } self.bytes.resize(n_bytes, 0); } /// Get a reference to the bytes of the message buffer, as a `&[u8]` slice. pub fn bytes(&self) -> &[u8] { self.bytes.as_slice() } /// The number of handles in the message buffer. Note this counts the number /// available when the message was received; `take_handle` does not affect /// the count. pub fn n_handles(&self) -> usize { self.handles.len() } /// Take the handle at the specified index from the message buffer. If the /// method is called again with the same index, it will return `None`, as /// will happen if the index exceeds the number of handles available. pub fn take_handle(&mut self, index: usize) -> Option<Handle> { self.handles.get_mut(index).and_then(|handle| { if handle.is_invalid() { None } else { Some(std::mem::replace(handle, Handle::invalid())) } }) } /// Clear the bytes and handles contained in the buf. This will drop any /// contained handles, resulting in their resources being freed. pub fn clear(&mut self) { self.bytes.clear(); self.handles.clear(); } } fn ensure_capacity<T>(vec: &mut Vec<T>, size: usize) { let len = vec.len(); if size > len { vec.reserve(size - len); } } } #[cfg(target_os = "fuchsia")] pub use fuchsia_handles::*; #[cfg(not(target_os = "fuchsia"))] pub use non_fuchsia_handles::*; #[cfg(all(test, not(target_os = "fuchsia")))] #[no_mangle] pub extern "C" fn fidlhdl_close(_hdl: u32) {}
/*! Example on how to use custom types directly with native windows derive `cargo run --example subclassing_d --features "flexbox"` */ extern crate native_windows_gui as nwg; extern crate native_windows_derive as nwd; use nwd::NwgUi; use nwg::NativeUi; use nwg::stretch::style::FlexDirection; type UserButton = nwg::Button; #[allow(dead_code)] #[derive(Default)] pub struct CustomButton { base: nwg::Button, data: usize } // Implements default trait so that the control can be used by native windows derive // The parameters are: subclass_control!(user type, base type, base field name) nwg::subclass_control!(CustomButton, Button, base); // // Implement a builder API compatible with native window derive // impl CustomButton { fn builder<'a>() -> CustomButtonBuilder<'a> { CustomButtonBuilder { button_builder: nwg::Button::builder().text("Custom button with builder"), data: 0 } } } pub struct CustomButtonBuilder<'a> { button_builder: nwg::ButtonBuilder<'a>, data: usize } impl<'a> CustomButtonBuilder<'a> { pub fn data(mut self, v: usize) -> CustomButtonBuilder<'a> { self.data = v; self } pub fn parent<C: Into<nwg::ControlHandle>>(mut self, p: C) -> CustomButtonBuilder<'a> { self.button_builder = self.button_builder.parent(p); self } pub fn build(self, btn: &mut CustomButton) -> Result<(), nwg::NwgError> { self.button_builder.build(&mut btn.base)?; btn.data = self.data; Ok(()) } } // // Actual interface code // #[derive(Default, NwgUi)] pub struct SubclassApp { #[nwg_control(size: (300, 300), position: (700, 300), title: "Subclass example")] #[nwg_events( OnWindowClose: [SubclassApp::exit] )] window: nwg::Window, #[nwg_layout(parent: window, flex_direction: FlexDirection::Column)] layout: nwg::FlexboxLayout, #[nwg_control(text: "Simple button", focus: true)] #[nwg_layout_item(layout: layout)] #[nwg_events( OnButtonClick: [SubclassApp::button_click1] )] button1: nwg::Button, #[nwg_control(text: "User type button")] #[nwg_layout_item(layout: layout)] #[nwg_events( OnButtonClick: [SubclassApp::button_click2] )] button2: UserButton, #[nwg_control(ty: Button, text: "Subclassed button")] #[nwg_layout_item(layout: layout)] #[nwg_events( OnButtonClick: [SubclassApp::button_click3(SELF, CTRL)] )] button3: CustomButton, #[nwg_control(data: 100)] #[nwg_layout_item(layout: layout)] #[nwg_events( OnButtonClick: [SubclassApp::button_click3(SELF, CTRL)] )] button4: CustomButton, } impl SubclassApp { fn button_click1(&self) { nwg::modal_info_message(&self.window, "Simple button", "Hey, I'm a simple button!"); } fn button_click2(&self) { nwg::modal_info_message(&self.window, "User type button", "Hey, I'm a button with a user type def!"); } fn button_click3(&self, button: &CustomButton) { nwg::modal_info_message(&self.window, "Custom button", &format!("Hey, I'm a button with custom data! The data is {}!", button.data) ); } fn exit(&self) { nwg::stop_thread_dispatch(); } } fn main() { nwg::init().expect("Failed to init Native Windows GUI"); nwg::Font::set_global_family("Segoe UI").expect("Failed to set default font"); let _app = SubclassApp::build_ui(Default::default()).expect("Failed to build UI"); nwg::dispatch_thread_events(); }
use std::ops::Add; use std::ops::Sub; use std::ops::Mul; use std::ops::Div; #[derive(Debug, Copy, Clone)] pub struct Vector2 { pub x: f32, pub y: f32, } impl Vector2 { #![allow(unused)] pub fn new(x: f32, y: f32) -> Self { Self {x: x, y: y } } pub fn one() -> Self { Self::new(1.0, 1.0) } pub fn magnitude(&self) -> f32 { (self.x * self.x + self.y * self.y).sqrt() } pub fn distance(&self, other: Self) -> f32 { (*self - other).magnitude() } pub fn angle(&self, other: Self) -> f32 { ((self.dot(other)) / (self.magnitude() * other.magnitude())) } pub fn dot(&self, other: Self) -> f32 { self.x * other.x + self.y * other.y } pub fn normalized(&self) -> Self { let magnitude = self.magnitude(); *self / self.magnitude() } } impl PartialEq for Vector2 { fn eq(&self, other: &Self) -> bool { self.x == other.x && self.y == other.y } } impl Add for Vector2 { type Output = Self; fn add(self, other: Self) -> Self { Self { x: self.x + other.x, y: self.y + other.y } } } impl Sub for Vector2 { type Output = Self; fn sub(self, other: Self) -> Self { Self { x: self.x - other.x, y: self.y - other.y } } } impl Mul for Vector2 { type Output = Self; fn mul(self, other: Self) -> Self { Self { x: self.x * other.x, y: self.y * other.y } } } impl Div<f32> for Vector2 { type Output = Self; fn div(self, num: f32) -> Self { Self { x: self.x / num, y: self.y / num } } } // TESTS #[cfg(test)] mod tests { use super::*; #[test] fn new_vector2() { let vec = Vector2::new(20.0, 20.0); assert_eq!(vec.x, 20.0); assert_eq!(vec.y, 20.0); } #[test] fn equals() { let vec_a = Vector2::new(5.0, 3.0); let vec_b = Vector2::new(5.0, 3.0); assert_eq!(vec_a == vec_b, true); } #[test] fn magnitude() { let vec = Vector2::new(20.0, 20.0); assert_eq!(vec.magnitude(), 28.284271); } #[test] fn add_vectors() { let vec_a = Vector2::new(5.0, 3.0); let vec_b = Vector2::new(3.0, 5.0); let sum = vec_a + vec_b; assert_eq!(sum.x, 8.0); assert_eq!(sum.y, 8.0); } #[test] fn sub_vectors() { let vec_a = Vector2::new(5.0, 3.0); let vec_b = Vector2::new(3.0, 5.0); let sum = vec_a - vec_b; assert_eq!(sum.x, 2.0); assert_eq!(sum.y, -2.0); } #[test] fn dot_product() { let vec_a = Vector2::new(5.0, 3.0); let vec_b = Vector2::new(3.0, 5.0); let dot = vec_a * vec_b; assert_eq!(dot.x, 15.0); assert_eq!(dot.y, 15.0); } #[test] fn distance() { let vec_a = Vector2::new(5.0, 3.0); let vec_b = Vector2::new(3.0, 5.0); assert_eq!(vec_a.distance(vec_b), 2.828427); } #[test] fn one() { let vec = Vector2::one(); assert_eq!(vec.x, 1.0); assert_eq!(vec.y, 1.0); } #[test] fn dot() { let vec_a = Vector2::new(5.0, 3.0); let vec_b = Vector2::new(3.0, 5.0); let dot = vec_a.dot(vec_b); assert_eq!(dot, 30.0); } #[test] fn angle() { let vec_a = Vector2::new(5.0, 3.0); let vec_b = Vector2::new(3.0, 5.0); let angle = vec_a.angle(vec_b); assert_eq!(angle, 0.88235307); } #[test] fn normalized() { let vec = Vector2::new(3.0, 4.0); let norm_vec = vec.normalized(); assert_eq!(norm_vec.magnitude(), 1.0); } }
// Copyright 2021 Datafuse Labs. // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. //! Everything you need to get started with this crate. pub use crate::data_value::*; pub use crate::types::*; // common structs pub use crate::DataField; pub use crate::DataSchema; pub use crate::DataSchemaRef; pub use crate::DataSchemaRefExt; pub use crate::DataValue;
use amethyst::{ assets::{AssetStorage, Handle, Loader, Processor}, core::{Named, Parent, Transform, TransformBundle}, ecs::{ Component, Entity, Join, NullStorage, Read, ReadExpect, ReadStorage, Resources, System, SystemData, WriteStorage, }, input::{is_close_requested, is_key_down, InputBundle, InputHandler, StringBindings}, prelude::*, renderer::{ pass::DrawFlat2DTransparentDesc, sprite_visibility::SpriteVisibilitySortingSystem, types::DefaultBackend, Camera, Factory, Format, GraphBuilder, GraphCreator, ImageFormat, Kind, RenderGroupDesc, RenderingSystem, SpriteRender, SpriteSheet, SpriteSheetFormat, SubpassBuilder, Texture, Transparent, }, utils::application_root_dir, window::{ScreenDimensions, Window, WindowBundle}, winit, }; #[derive(Default)] struct Player; impl Component for Player { type Storage = NullStorage<Self>; } struct MovementSystem; impl<'s> System<'s> for MovementSystem { type SystemData = ( ReadStorage<'s, Player>, WriteStorage<'s, Transform>, Read<'s, InputHandler<StringBindings>>, ); fn run(&mut self, (players, mut transforms, input): Self::SystemData) { let x_move = input.axis_value("entity_x").unwrap(); let y_move = input.axis_value("entity_y").unwrap(); for (_, transform) in (&players, &mut transforms).join() { transform.prepend_translation_x(x_move as f32 * 5.0); transform.prepend_translation_y(y_move as f32 * 5.0); // println!("Player = {:?}", transform); } } } fn load_sprite_sheet(world: &mut World, png_path: &str, ron_path: &str) -> Handle<SpriteSheet> { let texture_handle = { let loader = world.read_resource::<Loader>(); let texture_storage = world.read_resource::<AssetStorage<Texture>>(); loader.load(png_path, ImageFormat::default(), (), &texture_storage) }; let loader = world.read_resource::<Loader>(); let sprite_sheet_store = world.read_resource::<AssetStorage<SpriteSheet>>(); loader.load( ron_path, SpriteSheetFormat(texture_handle), (), &sprite_sheet_store, ) } // Initialize a background fn init_background_sprite(world: &mut World, sprite_sheet: &Handle<SpriteSheet>) -> Entity { let mut transform = Transform::default(); transform.set_translation_z(-10.0); let sprite = SpriteRender { sprite_sheet: sprite_sheet.clone(), sprite_number: 0, }; world .create_entity() .with(transform) .with(sprite) .named("background") .with(Transparent) .build() } // Initialize a sprite as a reference point at a fixed location fn init_reference_sprite(world: &mut World, sprite_sheet: &Handle<SpriteSheet>) -> Entity { let mut transform = Transform::default(); transform.set_translation_xyz(0.0, 0.0, 0.0); let sprite = SpriteRender { sprite_sheet: sprite_sheet.clone(), sprite_number: 0, }; world .create_entity() .with(transform) .with(sprite) .with(Transparent) .named("reference") .build() } // Initialize a sprite as a reference point fn init_screen_reference_sprite(world: &mut World, sprite_sheet: &Handle<SpriteSheet>) -> Entity { let mut transform = Transform::default(); transform.set_translation_xyz(-250.0, -245.0, -11.0); let sprite = SpriteRender { sprite_sheet: sprite_sheet.clone(), sprite_number: 0, }; world .create_entity() .with(transform) .with(sprite) .with(Transparent) .named("screen_reference") .build() } fn init_player(world: &mut World, sprite_sheet: &Handle<SpriteSheet>) -> Entity { let mut transform = Transform::default(); transform.set_translation_xyz(0.0, 0.0, -3.0); let sprite = SpriteRender { sprite_sheet: sprite_sheet.clone(), sprite_number: 1, }; world .create_entity() .with(transform) .with(Player) .with(sprite) .with(Transparent) .named("player") .build() } fn initialise_camera(world: &mut World, parent: Entity) -> Entity { let (width, height) = { let dim = world.read_resource::<ScreenDimensions>(); (dim.width(), dim.height()) }; //println!("Init camera with dimensions: {}x{}", width, height); let mut camera_transform = Transform::default(); camera_transform.set_translation_z(5.0); world .create_entity() .with(camera_transform) .with(Parent { entity: parent }) .with(Camera::standard_2d(width, height)) .named("camera") .build() } struct Example; impl SimpleState for Example { fn on_start(&mut self, data: StateData<'_, GameData<'_, '_>>) { let world = data.world; world.register::<Named>(); let circle_sprite_sheet_handle = load_sprite_sheet(world, "Circle_Spritesheet.png", "Circle_Spritesheet.ron"); let background_sprite_sheet_handle = load_sprite_sheet(world, "Background.png", "Background.ron"); let _background = init_background_sprite(world, &background_sprite_sheet_handle); let _reference = init_reference_sprite(world, &circle_sprite_sheet_handle); let player = init_player(world, &circle_sprite_sheet_handle); let _camera = initialise_camera(world, player); let _reference_screen = init_screen_reference_sprite(world, &circle_sprite_sheet_handle); } fn handle_event( &mut self, data: StateData<'_, GameData<'_, '_>>, event: StateEvent, ) -> SimpleTrans { let StateData { world, .. } = data; if let StateEvent::Window(event) = &event { if is_close_requested(&event) || is_key_down(&event, winit::VirtualKeyCode::Escape) { Trans::Quit } else if is_key_down(&event, winit::VirtualKeyCode::Space) { world.exec( |(named, transforms): (ReadStorage<Named>, ReadStorage<Transform>)| { for (name, transform) in (&named, &transforms).join() { println!("{} => {:?}", name.name, transform.translation()); } }, ); Trans::None } else { Trans::None } } else { Trans::None } } } fn main() -> amethyst::Result<()> { amethyst::Logger::from_config(Default::default()) .level_for("amethyst_assets", log::LevelFilter::Debug) .start(); let app_root = application_root_dir()?; let assets_directory = app_root.join("examples/sprite_camera_follow/assets"); let display_config_path = app_root.join("examples/sprite_camera_follow/config/display.ron"); let game_data = GameDataBuilder::default() .with_bundle(WindowBundle::from_config_path(display_config_path))? .with_bundle(TransformBundle::new())? .with_bundle( InputBundle::<StringBindings>::new().with_bindings_from_file( app_root.join("examples/sprite_camera_follow/config/input.ron"), )?, )? .with(MovementSystem, "movement", &[]) .with( Processor::<SpriteSheet>::new(), "sprite_sheet_processor", &[], ) .with( SpriteVisibilitySortingSystem::new(), "sprite_visibility_system", &["transform_system"], ) .with_thread_local(RenderingSystem::<DefaultBackend, _>::new( ExampleGraph::default(), )); let mut game = Application::build(assets_directory, Example)?.build(game_data)?; game.run(); Ok(()) } #[derive(Default)] struct ExampleGraph { dimensions: Option<ScreenDimensions>, surface_format: Option<Format>, dirty: bool, } #[allow(clippy::map_clone)] impl GraphCreator<DefaultBackend> for ExampleGraph { fn rebuild(&mut self, res: &Resources) -> bool { // Rebuild when dimensions change, but wait until at least two frames have the same. let new_dimensions = res.try_fetch::<ScreenDimensions>(); use std::ops::Deref; if self.dimensions.as_ref() != new_dimensions.as_ref().map(|d| d.deref()) { self.dirty = true; self.dimensions = new_dimensions.map(|d| d.clone()); return false; } self.dirty } fn builder( &mut self, factory: &mut Factory<DefaultBackend>, res: &Resources, ) -> GraphBuilder<DefaultBackend, Resources> { use amethyst::renderer::rendy::{ graph::present::PresentNode, hal::command::{ClearDepthStencil, ClearValue}, }; self.dirty = false; let window = <ReadExpect<'_, Window>>::fetch(res); let surface = factory.create_surface(&window); // cache surface format to speed things up let surface_format = *self .surface_format .get_or_insert_with(|| factory.get_surface_format(&surface)); let dimensions = self.dimensions.as_ref().unwrap(); let window_kind = Kind::D2(dimensions.width() as u32, dimensions.height() as u32, 1, 1); let mut graph_builder = GraphBuilder::new(); let color = graph_builder.create_image( window_kind, 1, surface_format, Some(ClearValue::Color([0.34, 0.36, 0.52, 1.0].into())), ); let depth = graph_builder.create_image( window_kind, 1, Format::D32Sfloat, Some(ClearValue::DepthStencil(ClearDepthStencil(1.0, 0))), ); let sprite = graph_builder.add_node( SubpassBuilder::new() .with_group(DrawFlat2DTransparentDesc::new().builder()) .with_color(color) .with_depth_stencil(depth) .into_pass(), ); let _present = graph_builder .add_node(PresentNode::builder(factory, surface, color).with_dependency(sprite)); graph_builder } }
use crate::text_write::{TextWrite, TextWriteError}; use image::imageops::FilterType; use ordered_float::OrderedFloat; use crate::intensity::{CharIntensities, Intensity}; fn avg_intensity(image: &image::GrayImage, x1: u32, y1: u32, x2: u32, y2: u32) -> f32 { let mut s: u32 = 0; for i in x1..x2 + 1 { for j in y1..y2 + 1 { s += image.get_pixel(i, j).0[0] as u32; } } s as f32 / ((x2 + 1 - x1) * (y2 + 1 - y1)) as f32 / 256. } pub fn asciify( writer: &mut dyn TextWrite<TextWriteError>, new_width: u32, new_height: u32, image: image::DynamicImage, char_intensities: CharIntensities, contrast: f32, gamma: f32, ) -> anyhow::Result<()> { let new_image = image::imageops::resize(&image, new_width * 3, new_height * 3, FilterType::Triangle); let grayscale = image::imageops::grayscale(&new_image); let mut intensities: Vec<Intensity> = vec![Intensity::default(); (new_height * new_width) as usize]; for j in 0..new_height { for i in 0..new_width { let int = &mut intensities[(i + j * new_width) as usize]; // send help int.left = avg_intensity(&grayscale, 3 * i, 3 * j, 3 * i, 3 * j + 2); int.right = avg_intensity(&grayscale, 3 * i + 2, 3 * j, 3 * i + 2, 3 * j + 2); int.top = avg_intensity(&grayscale, 3 * i, 3 * j, 3 * i + 2, 3 * j); int.bottom = avg_intensity(&grayscale, 3 * i, 3 * j + 2, 3 * i + 2, 3 * j + 2); int.middle = avg_intensity(&grayscale, 3 * i + 1, 3 * j + 1, 3 * i + 1, 3 * j + 1); } } for j in 0..new_height { for i in 0..new_width { let a = &mut intensities[(i + j * new_width) as usize]; a.apply(|x: f32| { let f: f32 = contrast * (x.powf(gamma) - 0.5) + 0.5; f.max(0.0).min(1.0) }); let next_char = char_intensities .iter() .min_by_key(|(_, x)| OrderedFloat(a.distance(&x))) .unwrap_or(&(' ', Intensity::default())) .0; // todo writer.write_char(next_char)?; } writer.write_newline()?; } Ok(()) } #[cfg(test)] mod test { use super::*; #[test] fn image_intensity() { let image = image::GrayImage::from_raw(3, 3, vec![1, 2, 3, 4, 5, 6, 7, 8, 9]).unwrap(); assert_eq!(avg_intensity(&image, 1, 1, 2, 2), 7. / 256.); assert_eq!(avg_intensity(&image, 1, 1, 1, 1), 5. / 256.); assert_eq!(avg_intensity(&image, 0, 0, 0, 2), 4. / 256.); } }
fn main() { let width1 = 30; let height1 = 50; println!("Area of rectangle is {}", area1(width1, height1)); let r = (30, 50); println!("Area of rectangle is {}", area2(r)); let rect = Rectangle { width: 30, height: 50 }; println!("Rectangle is {:#?}", rect); println!("Area of rectangle is {}", area(&rect)); // method on Rectangle struct println!("Area of rectangle is {}", rect.area()); let rect2 = Rectangle { width: 40, height: 20 }; println!("Can rect hold rect2? - {}", rect.can_hold(&rect2)); let rect3 = Rectangle { width: 10, height: 20 }; println!("Can rect hold rect3? - {}", rect.can_hold(&rect3)); // syntax to call associated functions is :: println!("Square is {:?}", Rectangle::square(5)); } fn area1(width: u32, height: u32) -> u32 { width * height } fn area2(dimensions: (u32, u32)) -> u32 { dimensions.0 * dimensions.1 } #[derive(Debug)] // allows printing Rectangle instance using {:?} or {:#?} struct Rectangle { width: u32, height: u32 } fn area(rectangle: &Rectangle) -> u32 { rectangle.width * rectangle.height } // area as method on Rectangle struct impl Rectangle { // no need to give type of &self // self can also be borrowed mutably - (&mut self) fn area(&self) -> u32 { self.width * self.height } fn can_hold(&self, other: &Rectangle) -> bool { self.width > other.width && self.height > other.height } // square is associated function not method // because it does not accept self as argument // these are usually constructor-style functions fn square(size: u32) -> Rectangle { Rectangle { width: size, height: size, } } } // these methods/associated-functions can be split into multiple `impl` blocks
//! A driver concretely executes a Falcon IL programs. use error::*; use executor::State; use executor::successor::*; use il; use RC; use types::Architecture; /// A driver for a concrete executor over Falcon IL. #[derive(Debug, Clone)] pub struct Driver<'d> { program: RC<il::Program>, location: il::ProgramLocation, state: State<'d>, architecture: Architecture, } impl<'d> Driver<'d> { /// Create a new driver for concrete execution over Falcon IL. pub fn new( program: RC<il::Program>, location: il::ProgramLocation, state: State<'d>, architecture: Architecture, ) -> Driver { Driver { program: program, location: location, state: state, architecture: architecture } } /// Step forward over Falcon IL. pub fn step(self) -> Result<Driver<'d>> { let location = self.location.apply(&self.program).unwrap(); match *location.function_location() { il::RefFunctionLocation::Instruction(_, instruction) => { let successor = self.state.execute(instruction.operation())?; match successor.type_().clone() { SuccessorType::FallThrough => { let locations = location.forward()?; if locations.len() == 1 { return Ok(Driver::new( self.program.clone(), locations[0].clone().into(), successor.into(), self.architecture )); } else { // every location should be an edge, and only one // edge should be satisfiable for location in locations { if let il::RefFunctionLocation::Edge(edge) = *location.function_location() { if successor.state() .symbolize_and_eval(&edge.condition().clone().unwrap())? .value() == 1 { return Ok(Driver::new( self.program.clone(), location.clone().into(), successor.into(), self.architecture )); } } } bail!("No valid successor location found on fall through"); } }, SuccessorType::Branch(address) => { match il::RefProgramLocation::from_address(&self.program, address) { Some(location) => return Ok(Driver::new( self.program.clone(), location.into(), successor.into(), self.architecture )), None => { let state: State = successor.into(); let function = self.architecture .translator() .translate_function(state.memory(), address) .expect(&format!("Failed to lift function at 0x{:x}", address)); let mut program = self.program.clone(); RC::make_mut(&mut program).add_function(function); let location = il::RefProgramLocation::from_address( &program, address ); return Ok(Driver::new( program.clone(), location.unwrap().into(), state, self.architecture )); } } }, SuccessorType::Raise(ref expression) => { bail!(format!("Raise is unimplemented, {}", expression)); } } }, il::RefFunctionLocation::Edge(_) => { let locations = location.forward()?; return Ok(Driver::new( self.program.clone(), locations[0].clone().into(), self.state, self.architecture )); }, il::RefFunctionLocation::EmptyBlock(_) => { let locations = location.forward()?; if locations.len() == 1 { return Ok(Driver::new( self.program.clone(), locations[0].clone().into(), self.state, self.architecture )); } else { for location in locations { if let il::RefFunctionLocation::Edge(edge) = *location.function_location() { if self.state .symbolize_and_eval(&edge.condition().clone().unwrap())? .value() == 1 { return Ok(Driver::new( self.program.clone(), location.clone().into(), self.state, self.architecture )); } } } } bail!("No valid location out of empty block"); } } } /// Retrieve the Falcon IL program associated with this driver. pub fn program(&self) -> &il::Program { &self.program } /// Retrieve the `il::ProgramLocation` associated with this driver. pub fn location(&self) -> &il::ProgramLocation { &self.location } /// Retrieve the concrete `State` associated with this driver. pub fn state(&self) -> &State { &self.state } }
use crate::prelude::*; use utilities::prelude::*; use super::{block::Block, chunk::Chunk, chunk_allocator::ChunkAllocator}; use std::sync::Arc; pub struct DeviceAllocator { chunk_allocator: ChunkAllocator, chunks: Vec<Chunk>, } impl DeviceAllocator { pub fn new(size: VkDeviceSize) -> Self { DeviceAllocator { chunk_allocator: ChunkAllocator::new(size), chunks: Vec::new(), } } pub fn allocate( &mut self, device: Arc<Device>, size: VkDeviceSize, memory_type_index: u32, alignment: VkDeviceSize, ) -> VerboseResult<Block> { for chunk in &mut self.chunks { if chunk.memory_type_index() == memory_type_index { if let Some(block) = chunk.allocate(size, alignment)? { return Ok(block); } } } let mut new_chunk = self .chunk_allocator .allocate(device, size, memory_type_index)?; let block = new_chunk .allocate(size, alignment)? .ok_or("couldn't allocate memory")?; self.chunks.push(new_chunk); Ok(block) } pub fn deallocate(&mut self, block: &Block) { for chunk in &mut self.chunks { if chunk.contains(block) { chunk.deallocate(block); return; } } } }
use image::{DynamicImage, GenericImageView, Rgba}; use rayon::iter::ParallelBridge; use rayon::prelude::ParallelIterator; use std::sync::mpsc::channel; use serde::*; use serde_derive::*; use serde_json::*; use std::fs::File; use std::io::Write; fn main() { let img = image::open("src/images/trees.jpg").unwrap(); let threshold: f32 = 100.0; let mut circles: Vec<(u32, u32, f32, (usize, usize, usize, usize))> = Vec::new(); for index in 0..10000 { let current_circle = img .pixels() .par_bridge() .filter(|pixel| { circles .iter() .map(|circle| { is_point_inside_circle(pixel.0, pixel.1, circle.0, circle.1, circle.2) }) .any(|circle| circle == true) == false }) .map(|pixel_a| { ( pixel_a.0, pixel_a.1, img.pixels() .map(move |pixel_b| { ( compute_color_distance(pixel_a, pixel_b), compute_location_distance(pixel_a, pixel_b), ) }) .filter(|pixel| pixel.0 > threshold && pixel.1 > 1.0) .map(|pixel| pixel.1) .fold(1000.0, |lowest: f32, pixel: f32| { if lowest >= pixel { return pixel; } else { return lowest; } }), ) }) .filter(|pixel| { circles .iter() .map(|circle| do_circles_intersect(*pixel, *circle)) .any(|circle| circle == true) == false }) .reduce( || (0, 0, 0.0), |highest, pixel| { if highest.0 <= pixel.0 { return pixel; } else { return highest; } }, ); let color_added = img .pixels() .filter(|pixel| { is_point_inside_circle( pixel.0, pixel.1, current_circle.0, current_circle.1, current_circle.2, ) == true }) .fold((0, 0, image::Rgba([0, 0, 0, 0])), |color, pixel| { ( pixel.0, pixel.1, image::Rgba([ color.2 .0[0] as usize + pixel.2 .0[0] as usize, color.2 .0[1] as usize + pixel.2 .0[1] as usize, color.2 .0[2] as usize + pixel.2 .0[2] as usize, color.2 .0[3] as usize + pixel.2 .0[3] as usize, ]), ) }); let mut count = img .pixels() .filter(|pixel| { is_point_inside_circle( pixel.0, pixel.1, current_circle.0, current_circle.1, current_circle.2, ) }) .count(); if count == 0 { count = 1 } let color = ( color_added.2 .0[0] as usize / count, color_added.2 .0[1] as usize / count, color_added.2 .0[2] as usize / count, color_added.2 .0[3] as usize / count, ); circles.push(( current_circle.0, current_circle.1, round_to_golden(current_circle.2), color, )); println!("{}{:?}{:?}", index, current_circle, color); File::create("./result.json") .expect("Unable to create file") .write_all( serde_json::to_string(&circles) .expect("Unable to write file") .as_bytes(), ) .expect("Unable to write data"); } } fn compute_location_distance( pixel_a: (u32, u32, image::Rgba<u8>), pixel_b: (u32, u32, image::Rgba<u8>), ) -> f32 { (((pixel_a.0 as i32 - pixel_b.0 as i32).pow(2) + (pixel_a.1 as i32 - pixel_b.1 as i32).pow(2)) as f32) .sqrt() } fn compute_color_distance( pixel_a: (u32, u32, image::Rgba<u8>), pixel_b: (u32, u32, image::Rgba<u8>), ) -> f32 { (((pixel_a.2 .0[0] as i32 - pixel_b.2 .0[0] as i32).pow(2) + (pixel_a.2 .0[1] as i32 - pixel_b.2 .0[1] as i32).pow(2) + (pixel_a.2 .0[2] as i32 - pixel_b.2 .0[2] as i32).pow(2)) as f32) .sqrt() } fn do_circles_intersect( pixel_a: (u32, u32, f32), pixel_b: (u32, u32, f32, (usize, usize, usize, usize)), ) -> bool { (((pixel_a.0 - pixel_b.0).pow(2) + (pixel_a.1 - pixel_b.1).pow(2)) as f32).sqrt() <= (pixel_a.2) + (pixel_b.2) } fn is_point_inside_circle(a: u32, b: u32, x: u32, y: u32, r: f32) -> bool { let dist_points = (a - x).pow(2) + (b - y).pow(2); if dist_points < (r * r) as u32 { return true; } return false; } fn round_to_golden(radius: f32) -> f32 { if radius <= 2.0 { return 1.0; } else if radius <= 3.0 { return 2.0; } else if radius <= 5.0 { return 3.0; } else if radius <= 8.0 { return 5.0; } else if radius <= 13.0 { return 8.0; } else if radius <= 13.0 { return 13.0; } else if radius <= 21.0 { return 13.0; } else if radius <= 34.0 { return 21.0; } else if radius <= 55.0 { return 34.0; } else if radius <= 89.0 { return 55.0; } return 89.0; }
//! 文件相关的内核功能 use super::*; use core::slice::from_raw_parts_mut; use core::str; use core::slice; use crate::fs::ROOT_INODE; // 使用条件变量之后, // 对于线程而言, 读取字符的系统调用是阻塞的, 因为在等待有效输入之前线程都会暂停。 // 对于操作系统而言,等待输入的时间完全分配给了其他线程,所以对于操作系统来说是非阻塞的。 /// 从指定的文件中读取字符 /// /// 如果缓冲区暂无数据,返回 0;出现错误返回 -1 pub(super) fn sys_read(fd: usize, buffer: *mut u8, size: usize) -> SyscallResult { // 从进程中获取 inode let process = PROCESSOR.lock().current_thread().process.clone(); if let Some(inode) = process.inner().descriptors.get(fd) { // 从系统调用传入的参数生成缓冲区 let buffer = unsafe { from_raw_parts_mut(buffer, size) }; // 尝试读取 if let Ok(ret) = inode.read_at(0, buffer) { let ret = ret as isize; if ret > 0 { return SyscallResult::Proceed(ret); } if ret == 0 { return SyscallResult::Park(ret); } } } SyscallResult::Proceed(-1) } /// 将字符写入指定的文件 pub(super) fn sys_write(fd: usize, buffer: *mut u8, size: usize) -> SyscallResult { // 从进程中获取 inode let process = PROCESSOR.lock().current_thread().process.clone(); if let Some(inode) = process.inner().descriptors.get(fd) { // 从系统调用传入的参数生成缓冲区 let buffer = unsafe { from_raw_parts_mut(buffer, size) }; // 尝试写入 if let Ok(ret) = inode.write_at(0, buffer) { let ret = ret as isize; if ret >= 0 { return SyscallResult::Proceed(ret); } } } SyscallResult::Proceed(-1) } // 将一个文件打包进用户镜像,并让一个用户进程读取它并打印其内容。 // sys_open: 将文件描述符加入进程的 descriptors 中,然后通过 sys_read 来读取。 pub(super) fn sys_open(buffer: *mut u8, size: usize) -> SyscallResult { let name = unsafe { let slice = slice::from_raw_parts(buffer, size); str::from_utf8(slice).unwrap() }; // 从文件系统中找到程序 let file = ROOT_INODE.find(name).unwrap(); let process = PROCESSOR.lock().current_thread().process.clone(); // 将文件描述符加入进程的 descriptors 中 process.inner().descriptors.push(file); SyscallResult::Proceed( (PROCESSOR .lock() .current_thread() .process .clone() .inner() .descriptors .len() - 1 ) as isize, ) }
use super::moves::Move; #[derive(Debug)] pub struct Game { /** The game turns, with `o` move then `x` move. */ pub turns: Vec<(Option<Move>, Option<Move>)>, } impl Game { pub fn make(turns: Vec<(Option<Move>, Option<Move>)>) -> Game { Game { turns } } } #[derive(Debug)] pub struct Match { pub games: Vec<Game>, } impl Match { pub fn make(games: Vec<Game>) -> Match { Match { games } } }
use crate::scene::error::SceneError; use std::io; #[derive(Debug)] pub enum ConfigError { YamlError(serde_yaml::Error), IoError(io::Error), TobjLoadError(tobj::LoadError), SceneError(SceneError), } impl From<serde_yaml::Error> for ConfigError { fn from(e: serde_yaml::Error) -> Self { ConfigError::YamlError(e) } } impl From<io::Error> for ConfigError { fn from(e: io::Error) -> Self { ConfigError::IoError(e) } } impl From<tobj::LoadError> for ConfigError { fn from(e: tobj::LoadError) -> Self { ConfigError::TobjLoadError(e) } } impl From<SceneError> for ConfigError { fn from(e: SceneError) -> Self { ConfigError::SceneError(e) } }
fn main() { test00(); } fn test00() { let r: int = 0; let sum: int = 0; let p: port[int] = port(); let c0: chan[int] = chan(p); let c1: chan[int] = chan(p); let c2: chan[int] = chan(p); let c3: chan[int] = chan(p); let number_of_messages: int = 1000; let i: int = 0; while i < number_of_messages { c0 <| i; c1 <| i; c2 <| i; c3 <| i; i += 1; } i = 0; while i < number_of_messages { p |> r; sum += r; p |> r; sum += r; p |> r; sum += r; p |> r; sum += r; i += 1; } assert (sum == 1998000); // assert (sum == 4 * ((number_of_messages * // (number_of_messages - 1)) / 2)); }
fn main(){ println!("Hello Aurelia !"); }
// Copyright 2019-2020 PolkaX. Licensed under MIT or Apache-2.0. #![allow(clippy::or_fun_call, clippy::mut_from_ref)] mod datastore; mod error; #[cfg(test)] mod tests; pub mod basic_ds; pub mod key; pub mod keytransform; pub mod namespace; pub mod query; pub mod singleton; // TODO impl mount // pub mod mount; pub use self::datastore::*; pub use self::error::DSError;
use std::collections::HashMap; /// Returns a HashMap with the the number of times each word appears in text pub fn word_count(text: &str) -> HashMap<String, u32> { let mut map_counts: HashMap<String, u32> = HashMap::new(); let not_alphanumeric = |c: char| !c.is_alphanumeric(); for x in text.split(not_alphanumeric).filter(|s| !s.is_empty()) { let entry = map_counts.entry(x.to_lowercase().to_string()).or_insert(0); *entry += 1; } map_counts }
#![allow(unused_variables, non_upper_case_globals, non_snake_case, unused_unsafe, non_camel_case_types, dead_code, clippy::all)] #[repr(transparent)] #[doc(hidden)] pub struct ISystemUpdateItem(pub ::windows::core::IInspectable); unsafe impl ::windows::core::Interface for ISystemUpdateItem { type Vtable = ISystemUpdateItem_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x779740eb_5624_519e_a8e2_09e9173b3fb7); } #[repr(C)] #[doc(hidden)] pub struct ISystemUpdateItem_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, count: *mut u32, values: *mut *mut ::windows::core::GUID) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, value: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, value: *mut i32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, result__: *mut SystemUpdateItemState) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, result__: *mut ::core::mem::ManuallyDrop<::windows::core::HSTRING>) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, result__: *mut ::core::mem::ManuallyDrop<::windows::core::HSTRING>) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, result__: *mut ::core::mem::ManuallyDrop<::windows::core::HSTRING>) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, result__: *mut u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, result__: *mut f64) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, result__: *mut f64) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, result__: *mut ::windows::core::HRESULT) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[doc(hidden)] pub struct ISystemUpdateLastErrorInfo(pub ::windows::core::IInspectable); unsafe impl ::windows::core::Interface for ISystemUpdateLastErrorInfo { type Vtable = ISystemUpdateLastErrorInfo_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x7ee887f7_8a44_5b6e_bd07_7aece4116ea9); } #[repr(C)] #[doc(hidden)] pub struct ISystemUpdateLastErrorInfo_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, count: *mut u32, values: *mut *mut ::windows::core::GUID) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, value: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, value: *mut i32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, result__: *mut SystemUpdateManagerState) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, result__: *mut ::windows::core::HRESULT) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, result__: *mut bool) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[doc(hidden)] pub struct ISystemUpdateManagerStatics(pub ::windows::core::IInspectable); unsafe impl ::windows::core::Interface for ISystemUpdateManagerStatics { type Vtable = ISystemUpdateManagerStatics_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xb2d3fcef_2971_51be_b41a_8bd703bb701a); } #[repr(C)] #[doc(hidden)] pub struct ISystemUpdateManagerStatics_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, count: *mut u32, values: *mut *mut ::windows::core::GUID) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, value: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, value: *mut i32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, result__: *mut bool) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, result__: *mut SystemUpdateManagerState) -> ::windows::core::HRESULT, #[cfg(feature = "Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, handler: ::windows::core::RawPtr, result__: *mut super::super::Foundation::EventRegistrationToken) -> ::windows::core::HRESULT, #[cfg(not(feature = "Foundation"))] usize, #[cfg(feature = "Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, token: super::super::Foundation::EventRegistrationToken) -> ::windows::core::HRESULT, #[cfg(not(feature = "Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, result__: *mut f64) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, result__: *mut f64) -> ::windows::core::HRESULT, #[cfg(feature = "Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, result__: *mut super::super::Foundation::TimeSpan) -> ::windows::core::HRESULT, #[cfg(not(feature = "Foundation"))] usize, #[cfg(feature = "Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, result__: *mut super::super::Foundation::TimeSpan) -> ::windows::core::HRESULT, #[cfg(not(feature = "Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, result__: *mut i32) -> ::windows::core::HRESULT, #[cfg(feature = "Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, start: super::super::Foundation::TimeSpan, end: super::super::Foundation::TimeSpan, result__: *mut bool) -> ::windows::core::HRESULT, #[cfg(not(feature = "Foundation"))] usize, #[cfg(feature = "Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, result__: *mut super::super::Foundation::DateTime) -> ::windows::core::HRESULT, #[cfg(not(feature = "Foundation"))] usize, #[cfg(feature = "Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, result__: *mut super::super::Foundation::DateTime) -> ::windows::core::HRESULT, #[cfg(not(feature = "Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, result__: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(feature = "Foundation_Collections")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, result__: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Foundation_Collections"))] usize, #[cfg(feature = "Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, lockid: ::core::mem::ManuallyDrop<::windows::core::HSTRING>, result__: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Foundation"))] usize, #[cfg(feature = "Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, lockid: ::core::mem::ManuallyDrop<::windows::core::HSTRING>, result__: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, result__: *mut ::windows::core::HRESULT) -> ::windows::core::HRESULT, #[cfg(feature = "Foundation_Collections")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, result__: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Foundation_Collections"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, result__: *mut SystemUpdateAttentionRequiredReason) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, flightring: ::core::mem::ManuallyDrop<::windows::core::HSTRING>, result__: *mut bool) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, result__: *mut ::core::mem::ManuallyDrop<::windows::core::HSTRING>) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, action: SystemUpdateStartInstallAction) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, ); #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct SystemUpdateAttentionRequiredReason(pub i32); impl SystemUpdateAttentionRequiredReason { pub const None: SystemUpdateAttentionRequiredReason = SystemUpdateAttentionRequiredReason(0i32); pub const NetworkRequired: SystemUpdateAttentionRequiredReason = SystemUpdateAttentionRequiredReason(1i32); pub const InsufficientDiskSpace: SystemUpdateAttentionRequiredReason = SystemUpdateAttentionRequiredReason(2i32); pub const InsufficientBattery: SystemUpdateAttentionRequiredReason = SystemUpdateAttentionRequiredReason(3i32); pub const UpdateBlocked: SystemUpdateAttentionRequiredReason = SystemUpdateAttentionRequiredReason(4i32); } impl ::core::convert::From<i32> for SystemUpdateAttentionRequiredReason { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for SystemUpdateAttentionRequiredReason { type Abi = Self; } unsafe impl ::windows::core::RuntimeType for SystemUpdateAttentionRequiredReason { const SIGNATURE: ::windows::core::ConstBuffer = ::windows::core::ConstBuffer::from_slice(b"enum(Windows.System.Update.SystemUpdateAttentionRequiredReason;i4)"); } impl ::windows::core::DefaultType for SystemUpdateAttentionRequiredReason { type DefaultType = Self; } #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct SystemUpdateItem(pub ::windows::core::IInspectable); impl SystemUpdateItem { pub fn State(&self) -> ::windows::core::Result<SystemUpdateItemState> { let this = self; unsafe { let mut result__: SystemUpdateItemState = ::core::mem::zeroed(); (::windows::core::Interface::vtable(this).6)(::core::mem::transmute_copy(this), &mut result__).from_abi::<SystemUpdateItemState>(result__) } } pub fn Title(&self) -> ::windows::core::Result<::windows::core::HSTRING> { let this = self; unsafe { let mut result__: ::core::mem::ManuallyDrop<::windows::core::HSTRING> = ::core::mem::zeroed(); (::windows::core::Interface::vtable(this).7)(::core::mem::transmute_copy(this), &mut result__).from_abi::<::windows::core::HSTRING>(result__) } } pub fn Description(&self) -> ::windows::core::Result<::windows::core::HSTRING> { let this = self; unsafe { let mut result__: ::core::mem::ManuallyDrop<::windows::core::HSTRING> = ::core::mem::zeroed(); (::windows::core::Interface::vtable(this).8)(::core::mem::transmute_copy(this), &mut result__).from_abi::<::windows::core::HSTRING>(result__) } } pub fn Id(&self) -> ::windows::core::Result<::windows::core::HSTRING> { let this = self; unsafe { let mut result__: ::core::mem::ManuallyDrop<::windows::core::HSTRING> = ::core::mem::zeroed(); (::windows::core::Interface::vtable(this).9)(::core::mem::transmute_copy(this), &mut result__).from_abi::<::windows::core::HSTRING>(result__) } } pub fn Revision(&self) -> ::windows::core::Result<u32> { let this = self; unsafe { let mut result__: u32 = ::core::mem::zeroed(); (::windows::core::Interface::vtable(this).10)(::core::mem::transmute_copy(this), &mut result__).from_abi::<u32>(result__) } } pub fn DownloadProgress(&self) -> ::windows::core::Result<f64> { let this = self; unsafe { let mut result__: f64 = ::core::mem::zeroed(); (::windows::core::Interface::vtable(this).11)(::core::mem::transmute_copy(this), &mut result__).from_abi::<f64>(result__) } } pub fn InstallProgress(&self) -> ::windows::core::Result<f64> { let this = self; unsafe { let mut result__: f64 = ::core::mem::zeroed(); (::windows::core::Interface::vtable(this).12)(::core::mem::transmute_copy(this), &mut result__).from_abi::<f64>(result__) } } pub fn ExtendedError(&self) -> ::windows::core::Result<::windows::core::HRESULT> { let this = self; unsafe { let mut result__: ::windows::core::HRESULT = ::core::mem::zeroed(); (::windows::core::Interface::vtable(this).13)(::core::mem::transmute_copy(this), &mut result__).from_abi::<::windows::core::HRESULT>(result__) } } } unsafe impl ::windows::core::RuntimeType for SystemUpdateItem { const SIGNATURE: ::windows::core::ConstBuffer = ::windows::core::ConstBuffer::from_slice(b"rc(Windows.System.Update.SystemUpdateItem;{779740eb-5624-519e-a8e2-09e9173b3fb7})"); } unsafe impl ::windows::core::Interface for SystemUpdateItem { type Vtable = ISystemUpdateItem_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x779740eb_5624_519e_a8e2_09e9173b3fb7); } impl ::windows::core::RuntimeName for SystemUpdateItem { const NAME: &'static str = "Windows.System.Update.SystemUpdateItem"; } impl ::core::convert::From<SystemUpdateItem> for ::windows::core::IUnknown { fn from(value: SystemUpdateItem) -> Self { value.0 .0 } } impl ::core::convert::From<&SystemUpdateItem> for ::windows::core::IUnknown { fn from(value: &SystemUpdateItem) -> Self { value.0 .0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for SystemUpdateItem { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0 .0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a SystemUpdateItem { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0 .0) } } impl ::core::convert::From<SystemUpdateItem> for ::windows::core::IInspectable { fn from(value: SystemUpdateItem) -> Self { value.0 } } impl ::core::convert::From<&SystemUpdateItem> for ::windows::core::IInspectable { fn from(value: &SystemUpdateItem) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IInspectable> for SystemUpdateItem { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IInspectable> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IInspectable> for &'a SystemUpdateItem { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IInspectable> { ::windows::core::Param::Borrowed(&self.0) } } unsafe impl ::core::marker::Send for SystemUpdateItem {} unsafe impl ::core::marker::Sync for SystemUpdateItem {} #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct SystemUpdateItemState(pub i32); impl SystemUpdateItemState { pub const NotStarted: SystemUpdateItemState = SystemUpdateItemState(0i32); pub const Initializing: SystemUpdateItemState = SystemUpdateItemState(1i32); pub const Preparing: SystemUpdateItemState = SystemUpdateItemState(2i32); pub const Calculating: SystemUpdateItemState = SystemUpdateItemState(3i32); pub const Downloading: SystemUpdateItemState = SystemUpdateItemState(4i32); pub const Installing: SystemUpdateItemState = SystemUpdateItemState(5i32); pub const Completed: SystemUpdateItemState = SystemUpdateItemState(6i32); pub const RebootRequired: SystemUpdateItemState = SystemUpdateItemState(7i32); pub const Error: SystemUpdateItemState = SystemUpdateItemState(8i32); } impl ::core::convert::From<i32> for SystemUpdateItemState { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for SystemUpdateItemState { type Abi = Self; } unsafe impl ::windows::core::RuntimeType for SystemUpdateItemState { const SIGNATURE: ::windows::core::ConstBuffer = ::windows::core::ConstBuffer::from_slice(b"enum(Windows.System.Update.SystemUpdateItemState;i4)"); } impl ::windows::core::DefaultType for SystemUpdateItemState { type DefaultType = Self; } #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct SystemUpdateLastErrorInfo(pub ::windows::core::IInspectable); impl SystemUpdateLastErrorInfo { pub fn State(&self) -> ::windows::core::Result<SystemUpdateManagerState> { let this = self; unsafe { let mut result__: SystemUpdateManagerState = ::core::mem::zeroed(); (::windows::core::Interface::vtable(this).6)(::core::mem::transmute_copy(this), &mut result__).from_abi::<SystemUpdateManagerState>(result__) } } pub fn ExtendedError(&self) -> ::windows::core::Result<::windows::core::HRESULT> { let this = self; unsafe { let mut result__: ::windows::core::HRESULT = ::core::mem::zeroed(); (::windows::core::Interface::vtable(this).7)(::core::mem::transmute_copy(this), &mut result__).from_abi::<::windows::core::HRESULT>(result__) } } pub fn IsInteractive(&self) -> ::windows::core::Result<bool> { let this = self; unsafe { let mut result__: bool = ::core::mem::zeroed(); (::windows::core::Interface::vtable(this).8)(::core::mem::transmute_copy(this), &mut result__).from_abi::<bool>(result__) } } } unsafe impl ::windows::core::RuntimeType for SystemUpdateLastErrorInfo { const SIGNATURE: ::windows::core::ConstBuffer = ::windows::core::ConstBuffer::from_slice(b"rc(Windows.System.Update.SystemUpdateLastErrorInfo;{7ee887f7-8a44-5b6e-bd07-7aece4116ea9})"); } unsafe impl ::windows::core::Interface for SystemUpdateLastErrorInfo { type Vtable = ISystemUpdateLastErrorInfo_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x7ee887f7_8a44_5b6e_bd07_7aece4116ea9); } impl ::windows::core::RuntimeName for SystemUpdateLastErrorInfo { const NAME: &'static str = "Windows.System.Update.SystemUpdateLastErrorInfo"; } impl ::core::convert::From<SystemUpdateLastErrorInfo> for ::windows::core::IUnknown { fn from(value: SystemUpdateLastErrorInfo) -> Self { value.0 .0 } } impl ::core::convert::From<&SystemUpdateLastErrorInfo> for ::windows::core::IUnknown { fn from(value: &SystemUpdateLastErrorInfo) -> Self { value.0 .0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for SystemUpdateLastErrorInfo { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0 .0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a SystemUpdateLastErrorInfo { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0 .0) } } impl ::core::convert::From<SystemUpdateLastErrorInfo> for ::windows::core::IInspectable { fn from(value: SystemUpdateLastErrorInfo) -> Self { value.0 } } impl ::core::convert::From<&SystemUpdateLastErrorInfo> for ::windows::core::IInspectable { fn from(value: &SystemUpdateLastErrorInfo) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IInspectable> for SystemUpdateLastErrorInfo { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IInspectable> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IInspectable> for &'a SystemUpdateLastErrorInfo { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IInspectable> { ::windows::core::Param::Borrowed(&self.0) } } unsafe impl ::core::marker::Send for SystemUpdateLastErrorInfo {} unsafe impl ::core::marker::Sync for SystemUpdateLastErrorInfo {} pub struct SystemUpdateManager {} impl SystemUpdateManager { pub fn IsSupported() -> ::windows::core::Result<bool> { Self::ISystemUpdateManagerStatics(|this| unsafe { let mut result__: bool = ::core::mem::zeroed(); (::windows::core::Interface::vtable(this).6)(::core::mem::transmute_copy(this), &mut result__).from_abi::<bool>(result__) }) } pub fn State() -> ::windows::core::Result<SystemUpdateManagerState> { Self::ISystemUpdateManagerStatics(|this| unsafe { let mut result__: SystemUpdateManagerState = ::core::mem::zeroed(); (::windows::core::Interface::vtable(this).7)(::core::mem::transmute_copy(this), &mut result__).from_abi::<SystemUpdateManagerState>(result__) }) } #[cfg(feature = "Foundation")] pub fn StateChanged<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::EventHandler<::windows::core::IInspectable>>>(handler: Param0) -> ::windows::core::Result<super::super::Foundation::EventRegistrationToken> { Self::ISystemUpdateManagerStatics(|this| unsafe { let mut result__: super::super::Foundation::EventRegistrationToken = ::core::mem::zeroed(); (::windows::core::Interface::vtable(this).8)(::core::mem::transmute_copy(this), handler.into_param().abi(), &mut result__).from_abi::<super::super::Foundation::EventRegistrationToken>(result__) }) } #[cfg(feature = "Foundation")] pub fn RemoveStateChanged<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::EventRegistrationToken>>(token: Param0) -> ::windows::core::Result<()> { Self::ISystemUpdateManagerStatics(|this| unsafe { (::windows::core::Interface::vtable(this).9)(::core::mem::transmute_copy(this), token.into_param().abi()).ok() }) } pub fn DownloadProgress() -> ::windows::core::Result<f64> { Self::ISystemUpdateManagerStatics(|this| unsafe { let mut result__: f64 = ::core::mem::zeroed(); (::windows::core::Interface::vtable(this).10)(::core::mem::transmute_copy(this), &mut result__).from_abi::<f64>(result__) }) } pub fn InstallProgress() -> ::windows::core::Result<f64> { Self::ISystemUpdateManagerStatics(|this| unsafe { let mut result__: f64 = ::core::mem::zeroed(); (::windows::core::Interface::vtable(this).11)(::core::mem::transmute_copy(this), &mut result__).from_abi::<f64>(result__) }) } #[cfg(feature = "Foundation")] pub fn UserActiveHoursStart() -> ::windows::core::Result<super::super::Foundation::TimeSpan> { Self::ISystemUpdateManagerStatics(|this| unsafe { let mut result__: super::super::Foundation::TimeSpan = ::core::mem::zeroed(); (::windows::core::Interface::vtable(this).12)(::core::mem::transmute_copy(this), &mut result__).from_abi::<super::super::Foundation::TimeSpan>(result__) }) } #[cfg(feature = "Foundation")] pub fn UserActiveHoursEnd() -> ::windows::core::Result<super::super::Foundation::TimeSpan> { Self::ISystemUpdateManagerStatics(|this| unsafe { let mut result__: super::super::Foundation::TimeSpan = ::core::mem::zeroed(); (::windows::core::Interface::vtable(this).13)(::core::mem::transmute_copy(this), &mut result__).from_abi::<super::super::Foundation::TimeSpan>(result__) }) } pub fn UserActiveHoursMax() -> ::windows::core::Result<i32> { Self::ISystemUpdateManagerStatics(|this| unsafe { let mut result__: i32 = ::core::mem::zeroed(); (::windows::core::Interface::vtable(this).14)(::core::mem::transmute_copy(this), &mut result__).from_abi::<i32>(result__) }) } #[cfg(feature = "Foundation")] pub fn TrySetUserActiveHours<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::TimeSpan>, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::TimeSpan>>(start: Param0, end: Param1) -> ::windows::core::Result<bool> { Self::ISystemUpdateManagerStatics(|this| unsafe { let mut result__: bool = ::core::mem::zeroed(); (::windows::core::Interface::vtable(this).15)(::core::mem::transmute_copy(this), start.into_param().abi(), end.into_param().abi(), &mut result__).from_abi::<bool>(result__) }) } #[cfg(feature = "Foundation")] pub fn LastUpdateCheckTime() -> ::windows::core::Result<super::super::Foundation::DateTime> { Self::ISystemUpdateManagerStatics(|this| unsafe { let mut result__: super::super::Foundation::DateTime = ::core::mem::zeroed(); (::windows::core::Interface::vtable(this).16)(::core::mem::transmute_copy(this), &mut result__).from_abi::<super::super::Foundation::DateTime>(result__) }) } #[cfg(feature = "Foundation")] pub fn LastUpdateInstallTime() -> ::windows::core::Result<super::super::Foundation::DateTime> { Self::ISystemUpdateManagerStatics(|this| unsafe { let mut result__: super::super::Foundation::DateTime = ::core::mem::zeroed(); (::windows::core::Interface::vtable(this).17)(::core::mem::transmute_copy(this), &mut result__).from_abi::<super::super::Foundation::DateTime>(result__) }) } pub fn LastErrorInfo() -> ::windows::core::Result<SystemUpdateLastErrorInfo> { Self::ISystemUpdateManagerStatics(|this| unsafe { let mut result__: ::windows::core::RawPtr = ::core::mem::zeroed(); (::windows::core::Interface::vtable(this).18)(::core::mem::transmute_copy(this), &mut result__).from_abi::<SystemUpdateLastErrorInfo>(result__) }) } #[cfg(feature = "Foundation_Collections")] pub fn GetAutomaticRebootBlockIds() -> ::windows::core::Result<super::super::Foundation::Collections::IVectorView<::windows::core::HSTRING>> { Self::ISystemUpdateManagerStatics(|this| unsafe { let mut result__: ::windows::core::RawPtr = ::core::mem::zeroed(); (::windows::core::Interface::vtable(this).19)(::core::mem::transmute_copy(this), &mut result__).from_abi::<super::super::Foundation::Collections::IVectorView<::windows::core::HSTRING>>(result__) }) } #[cfg(feature = "Foundation")] pub fn BlockAutomaticRebootAsync<'a, Param0: ::windows::core::IntoParam<'a, ::windows::core::HSTRING>>(lockid: Param0) -> ::windows::core::Result<super::super::Foundation::IAsyncOperation<bool>> { Self::ISystemUpdateManagerStatics(|this| unsafe { let mut result__: ::windows::core::RawPtr = ::core::mem::zeroed(); (::windows::core::Interface::vtable(this).20)(::core::mem::transmute_copy(this), lockid.into_param().abi(), &mut result__).from_abi::<super::super::Foundation::IAsyncOperation<bool>>(result__) }) } #[cfg(feature = "Foundation")] pub fn UnblockAutomaticRebootAsync<'a, Param0: ::windows::core::IntoParam<'a, ::windows::core::HSTRING>>(lockid: Param0) -> ::windows::core::Result<super::super::Foundation::IAsyncOperation<bool>> { Self::ISystemUpdateManagerStatics(|this| unsafe { let mut result__: ::windows::core::RawPtr = ::core::mem::zeroed(); (::windows::core::Interface::vtable(this).21)(::core::mem::transmute_copy(this), lockid.into_param().abi(), &mut result__).from_abi::<super::super::Foundation::IAsyncOperation<bool>>(result__) }) } pub fn ExtendedError() -> ::windows::core::Result<::windows::core::HRESULT> { Self::ISystemUpdateManagerStatics(|this| unsafe { let mut result__: ::windows::core::HRESULT = ::core::mem::zeroed(); (::windows::core::Interface::vtable(this).22)(::core::mem::transmute_copy(this), &mut result__).from_abi::<::windows::core::HRESULT>(result__) }) } #[cfg(feature = "Foundation_Collections")] pub fn GetUpdateItems() -> ::windows::core::Result<super::super::Foundation::Collections::IVectorView<SystemUpdateItem>> { Self::ISystemUpdateManagerStatics(|this| unsafe { let mut result__: ::windows::core::RawPtr = ::core::mem::zeroed(); (::windows::core::Interface::vtable(this).23)(::core::mem::transmute_copy(this), &mut result__).from_abi::<super::super::Foundation::Collections::IVectorView<SystemUpdateItem>>(result__) }) } pub fn AttentionRequiredReason() -> ::windows::core::Result<SystemUpdateAttentionRequiredReason> { Self::ISystemUpdateManagerStatics(|this| unsafe { let mut result__: SystemUpdateAttentionRequiredReason = ::core::mem::zeroed(); (::windows::core::Interface::vtable(this).24)(::core::mem::transmute_copy(this), &mut result__).from_abi::<SystemUpdateAttentionRequiredReason>(result__) }) } pub fn SetFlightRing<'a, Param0: ::windows::core::IntoParam<'a, ::windows::core::HSTRING>>(flightring: Param0) -> ::windows::core::Result<bool> { Self::ISystemUpdateManagerStatics(|this| unsafe { let mut result__: bool = ::core::mem::zeroed(); (::windows::core::Interface::vtable(this).25)(::core::mem::transmute_copy(this), flightring.into_param().abi(), &mut result__).from_abi::<bool>(result__) }) } pub fn GetFlightRing() -> ::windows::core::Result<::windows::core::HSTRING> { Self::ISystemUpdateManagerStatics(|this| unsafe { let mut result__: ::core::mem::ManuallyDrop<::windows::core::HSTRING> = ::core::mem::zeroed(); (::windows::core::Interface::vtable(this).26)(::core::mem::transmute_copy(this), &mut result__).from_abi::<::windows::core::HSTRING>(result__) }) } pub fn StartInstall(action: SystemUpdateStartInstallAction) -> ::windows::core::Result<()> { Self::ISystemUpdateManagerStatics(|this| unsafe { (::windows::core::Interface::vtable(this).27)(::core::mem::transmute_copy(this), action).ok() }) } pub fn RebootToCompleteInstall() -> ::windows::core::Result<()> { Self::ISystemUpdateManagerStatics(|this| unsafe { (::windows::core::Interface::vtable(this).28)(::core::mem::transmute_copy(this)).ok() }) } pub fn StartCancelUpdates() -> ::windows::core::Result<()> { Self::ISystemUpdateManagerStatics(|this| unsafe { (::windows::core::Interface::vtable(this).29)(::core::mem::transmute_copy(this)).ok() }) } pub fn ISystemUpdateManagerStatics<R, F: FnOnce(&ISystemUpdateManagerStatics) -> ::windows::core::Result<R>>(callback: F) -> ::windows::core::Result<R> { static mut SHARED: ::windows::core::FactoryCache<SystemUpdateManager, ISystemUpdateManagerStatics> = ::windows::core::FactoryCache::new(); unsafe { SHARED.call(callback) } } } impl ::windows::core::RuntimeName for SystemUpdateManager { const NAME: &'static str = "Windows.System.Update.SystemUpdateManager"; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct SystemUpdateManagerState(pub i32); impl SystemUpdateManagerState { pub const Idle: SystemUpdateManagerState = SystemUpdateManagerState(0i32); pub const Detecting: SystemUpdateManagerState = SystemUpdateManagerState(1i32); pub const ReadyToDownload: SystemUpdateManagerState = SystemUpdateManagerState(2i32); pub const Downloading: SystemUpdateManagerState = SystemUpdateManagerState(3i32); pub const ReadyToInstall: SystemUpdateManagerState = SystemUpdateManagerState(4i32); pub const Installing: SystemUpdateManagerState = SystemUpdateManagerState(5i32); pub const RebootRequired: SystemUpdateManagerState = SystemUpdateManagerState(6i32); pub const ReadyToFinalize: SystemUpdateManagerState = SystemUpdateManagerState(7i32); pub const Finalizing: SystemUpdateManagerState = SystemUpdateManagerState(8i32); pub const Completed: SystemUpdateManagerState = SystemUpdateManagerState(9i32); pub const AttentionRequired: SystemUpdateManagerState = SystemUpdateManagerState(10i32); pub const Error: SystemUpdateManagerState = SystemUpdateManagerState(11i32); } impl ::core::convert::From<i32> for SystemUpdateManagerState { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for SystemUpdateManagerState { type Abi = Self; } unsafe impl ::windows::core::RuntimeType for SystemUpdateManagerState { const SIGNATURE: ::windows::core::ConstBuffer = ::windows::core::ConstBuffer::from_slice(b"enum(Windows.System.Update.SystemUpdateManagerState;i4)"); } impl ::windows::core::DefaultType for SystemUpdateManagerState { type DefaultType = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct SystemUpdateStartInstallAction(pub i32); impl SystemUpdateStartInstallAction { pub const UpToReboot: SystemUpdateStartInstallAction = SystemUpdateStartInstallAction(0i32); pub const AllowReboot: SystemUpdateStartInstallAction = SystemUpdateStartInstallAction(1i32); } impl ::core::convert::From<i32> for SystemUpdateStartInstallAction { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for SystemUpdateStartInstallAction { type Abi = Self; } unsafe impl ::windows::core::RuntimeType for SystemUpdateStartInstallAction { const SIGNATURE: ::windows::core::ConstBuffer = ::windows::core::ConstBuffer::from_slice(b"enum(Windows.System.Update.SystemUpdateStartInstallAction;i4)"); } impl ::windows::core::DefaultType for SystemUpdateStartInstallAction { type DefaultType = Self; }
#![allow(non_snake_case, non_camel_case_types, dead_code)] use libc::*; use std::mem::{size_of, transmute}; use std::ptr::null_mut; pub const UNITY_AUDIO_PLUGIN_API_VERSION: usize = 0x010401; // from macro pub type UnityAudioDSPResult = c_int; pub const UNITY_AUDIODSP_OK: UnityAudioDSPResult = 0; pub const UNITY_AUDIODSP_ERR_UNSUPPORTED: UnityAudioDSPResult = 1; pub type UnityAudioEffect_CreateCallback = extern "C" fn(state: *mut UnityAudioEffectState) -> UnityAudioDSPResult; pub type UnityAudioEffect_ReleaseCallback = extern "C" fn(state: *mut UnityAudioEffectState) -> UnityAudioDSPResult; pub type UnityAudioEffect_ResetCallback = extern "C" fn(state: *mut UnityAudioEffectState) -> UnityAudioDSPResult; pub type UnityAudioEffect_ProcessCallback = extern "C" fn(state: *mut UnityAudioEffectState, inbuffer: *mut c_float, outbuffer: *mut c_float, length: c_uint, inchannels: c_int, outchannels: c_int) -> UnityAudioDSPResult; pub type UnityAudioEffect_SetPositionCallback = extern "C" fn(state: *mut UnityAudioEffectState, pos: c_uint) -> UnityAudioDSPResult; pub type UnityAudioEffect_SetFloatParameterCallback = extern "C" fn(state: *mut UnityAudioEffectState, index: c_int, value: c_float) -> UnityAudioDSPResult; pub type UnityAudioEffect_GetFloatParameterCallback = extern "C" fn(state: *mut UnityAudioEffectState, index: c_int, value: *mut c_float, valuestr: *mut c_char) -> UnityAudioDSPResult; pub type UnityAudioEffect_GetFloatBufferCallback = extern "C" fn(state: *mut UnityAudioEffectState, name: *const c_char, buffer: *mut c_float, numsamples: c_int) -> UnityAudioDSPResult; #[repr(C)] pub enum UnityAudioEffectDefinitionFlags { /// Does this effect need a side chain buffer and can it be targeted by a Send? IsSideChainTarget = 1 << 0, /// Should this plugin be inserted at sources and take over panning? IsSpatializer = 1 << 1, /// Should this plugin be used for ambisonic decoding? Added in Unity 2017.1, with UNITY_AUDIO_PLUGIN_API_VERSION 0x010400 IsAmbisonicDecoder = 1 << 2, /// Spatializers Only: Does this spatializer apply distance-based attenuation? Added in Unity 2017.1, with UNITY_AUDIO_PLUGIN_API_VERSION 0x010400 AppliesDistanceAttenuation = 1 << 3 } #[repr(C)] pub enum UnityAudioEffectStateFlags { /// Set when engine is in play mode. Also true while paused IsPlaying = 1 << 0, /// Set when engine is paused mode IsPaused = 1 << 1, /// Set when effect is being muted (only available in the editor) IsMuted = 1 << 2, /// Does this effect need a side chain buffer and can it be targeted by a Send? IsSideChainTargeted = 1 << 3 } /// This callback can be used to override the way distance attenuation is performed on AudioSources. /// distanceIn is the distance between the source and the listener and attenuationOut is the output volume. /// attenuationIn is the volume-curve based attenuation that would have been applied by Unity if this callback were not set. /// A typical attenuation curve may look like this: *attenuationOut = 1.0f / max(1.0f, distanceIn); /// The callback may also be used to apply a secondary gain on top of the one through attenuationIn by Unity's AudioSource curve. pub type UnityAudioEffect_DistanceAttenuationCallback = extern "C" fn(state: *mut UnityAudioEffectState, distanceIn: c_float, attenuationIn: c_float, attenuationOut: c_float) -> UnityAudioDSPResult; #[repr(C)] pub struct UnityAudioSpatializerData { /// Matrix that transforms sourcepos into local space of the listener pub listenermatrix: [c_float; 16], /// Transform matrix of audio source pub sourcematrix: [c_float; 16], /// Distance-controlled spatial blend pub spatialblend: c_float, /// Reverb zone mix leve parameter (and curve) on audio source pub reverbzonemix: c_float, /// Spread parameter of the audio source (0 .. 360 degrees) pub spread: c_float, /// Stereo panning parameter of the audio source (-1 = fully left, 1 = fully right) pub stereopan: c_float, /// The spatializer plugin may override the distance attenuation in order to influence the voice prioritization /// (leave this callback as `None` to use the built-in audio source attenuation curve) pub distanceattenuationcallback: Option<UnityAudioEffect_DistanceAttenuationCallback>, /// Min distance of the audio source. This value may be helpful to determine when to apply near-field effects. /// Added in Unity 2018.1, with UNITY_AUDIO_PLUGIN_API_VERSION 0x010401 pub minDistance: c_float, /// Max distance of the audio source. Added in Unity 2018.1, with UNITY_AUDIO_PLUGIN_API_VERSION 0x010401 pub maxDistance: c_float } #[repr(C)] pub struct UnityAudioAmbisonicData { /// Matrix that transforms sourcepos into local space of the listener pub listenermatrix: [c_float; 16], /// Transform matrix of audio source pub sourcematrix: [c_float; 16], /// Distance-controlled spatial blend pub spatialblend: c_float, /// Reverb zone mix leve parameter (and curve) on audio source pub reverbzonemix: c_float, /// Spread parameter of the audio source (0 .. 360 degrees) pub spread: c_float, /// Stereo panning parameter of the audio source (-1 = fully left, 1 = fully right) pub stereopan: c_float, /// The spatializer plugin may override the distance attenuation in order to influence the voice prioritization /// (leave this callback as `None` to use the built-in audio source attenuation curve) pub distanceattenuationcallback: Option<UnityAudioEffect_DistanceAttenuationCallback>, /// This tells ambisonic decoders how many output channels will actually be used pub ambisonicOutChannels: c_int, /// Volume/mute of the audio source. If the the source ismuted, volume is set to 0.0; otherwise, it is set to the audio source's volume. /// Volume is applied after the ambisonic decoder, so this is just informational. Added in Unity 2018.1, with UNITY_AUDIO_PLUGIN_API_VERSION 0x010401 pub volume: c_float } // This padding was historically due to PS3 SPU DMA requirement. We aren't removing it now because plugins may rely on this struct being at least this size. #[repr(C)] pub struct UnityAudioEffectState([c_uchar; 80]); /// Union accessor impls impl UnityAudioEffectState { /// Size of this struct pub fn structsize(&self) -> u32 { unsafe { transmute::<_, &[u32]>(&self.0[..])[0] } } /// System sample rate pub fn samplerate(&self) -> u32 { unsafe { transmute::<_, &[u32]>(&self.0[..])[1] } } /// Pointer to a sample counter marking the start of the current block being processed pub fn currdsptick(&self) -> u64 { unsafe { transmute::<_, &[u64]>(&self.0[..])[1] } } /// Used for determining when DSPs are bypassed and so sidechain info becomes invalid pub fn prevdsptick(&self) -> u64 { unsafe { transmute::<_, &[u64]>(&self.0[..])[2] } } /// Side-chain buffers to read from pub fn sidechainbuffer(&self) -> *const c_float { unsafe { transmute::<_, &[*const c_float]>(&self.0[size_of::<u64>() * 3..])[0] } } /// Internal data for the effect pub fn effectdata(&self) -> *const c_void { unsafe { transmute::<_, &[*const c_void]>(&self.0[size_of::<u64>() * 3 + size_of::<*const c_float>()..])[0] } } /// Internal data for the effect pub fn effectdata_mut(&mut self) -> *mut c_void { unsafe { transmute::<_, &[*mut c_void]>(&self.0[size_of::<u64>() * 3 +size_of::<*const c_float>()..])[0] } } /// Various flags through which information can be queried from the host pub fn flags(&self) -> u32 { unsafe { transmute::<_, &[u32]>(&self.0[size_of::<u64>() * 3 + size_of::<*const c_void>() * 2..])[0] } } /// Data for spatializers pub fn spatializerdata(&self) -> *const UnityAudioSpatializerData { unsafe { transmute::<_, &[*const _]>(&self.0[size_of::<u64>() * 3 + size_of::<*const c_void>() * 3 + size_of::<u32>()..])[0] } } /// Number of frames bein processed per process callback. Use this to allocate temporary buffers before processing starts. pub fn dspbuffersize(&self) -> u32 { unsafe { transmute::<_, &[u32]>(&self.0[size_of::<u64>() * 3 + size_of::<*const c_void>() * 4 + size_of::<u32>()..])[0] } } /// Version of plugin API used by host pub fn hostapiversion(&self) -> u32 { unsafe { transmute::<_, &[u32]>(&self.0[size_of::<u64>() * 3 + size_of::<*const c_void>() * 4 + size_of::<u32>() * 2..])[0] } } /// Data for ambisonic plugins. Added in Unity 2017.1, with UNITY_AUDIO_PLUGIN_API_VERSION 0x010400 pub fn ambisonicdata(&self) -> *const UnityAudioAmbisonicData { unsafe { transmute::<_, &[*const _]>(&self.0[size_of::<u64>() * 3 + size_of::<*const c_void>() * 4 + size_of::<u32>() * 3..])[0] } } pub fn effect_data<T>(&self) -> &T { assert!(!self.effectdata().is_null()); unsafe { &*(self.effectdata() as *const T) } } pub fn effect_data_mut<T>(&mut self) -> &mut T { assert!(!self.effectdata().is_null()); unsafe { &mut *(self.effectdata_mut() as *mut T) } } pub fn write_effect_data<T>(&mut self, ptr: *mut T) { unsafe { transmute::<_, &mut [*mut c_void]>(&mut self.0[size_of::<u64>() * 3 + size_of::<*const c_float>()..])[0] = ptr as _; } } } #[repr(C)] pub struct UnityAudioParameterDefinition { /// Display name on the GUI pub name: [c_char; 16], /// Scientific unit of parameter to eb appended after the value in textboxes pub unit: [c_char; 16], /// Description of parameter (displayed in tool tips, automatically generated documentation, etc.) pub description: *const c_char, /// Minimum value of the parameter pub min: c_float, /// Maximum value of the parameter pub max: c_float, /// Default and initial value of the parameter pub defaultval: c_float, /// Scale factor used only for the display of parameters (i.e. 100 for a percentage value ranging from 0 to 1) pub displayscale: c_float, /// Exponent for mapping parameters to sliders pub displayexponent: c_float } #[repr(C)] pub struct UnityAudioEffectDefinition { /// Size of this struct pub structsize: u32, /// Size of paramdesc fields pub paramstructsize: u32, /// Plugin API version pub apiversion: u32, /// Version of this plugin pub pluginversion: u32, /// Number of channels. Effects should set this to 0 and process any number of input/output channels they get in the process callback. /// Generator elements should specify a >0 value here. pub channels: u32, /// The number of parameters exposed by this plugin pub numparameters: u32, /// Various capabilities an requirements of the plugin pub flags: u64, /// Name used for registration of the effect. This name will also be displayed in the GUI pub name: [c_char; 32], /// The create callback is called when DSP unit is created and can be null. pub create: Option<UnityAudioEffect_CreateCallback>, /// The release callback is called just before the plugin is freed and should free any data associated with this specific instance of the plugin. /// No further callbacks related to the instance will happen after this function has been called. pub release: Option<UnityAudioEffect_ReleaseCallback>, /// The reset callback is called by the user to bring back the plugin instance into its initial state. Use to avoid clicks or artifacts. pub reset: Option<UnityAudioEffect_ResetCallback>, /// The processing callback is repeatedly called with a block of input audio to read from and an output block to write to. pub process: Option<UnityAudioEffect_ProcessCallback>, /// The position callback can be used for implementing seek operations. pub setposition: Option<UnityAudioEffect_SetPositionCallback>, /// A pointer to the definitions of the parameters exposed by this plugin. This data pointed to must remain valid for the whole lifetime of the dynamic library /// (ideally it's static) pub paramdefs: *const UnityAudioParameterDefinition, /// This is called whenever one of the exposed parameters is changed pub setfloatparameter: Option<UnityAudioEffect_SetFloatParameterCallback>, /// This is called to query parameter values pub getfloatparameter: Option<UnityAudioEffect_GetFloatParameterCallback>, /// Get N samples of named buffer. Used for displaying analysis data from the runtime. pub getfloatbuffer: Option<UnityAudioEffect_GetFloatBufferCallback> } unsafe impl Sync for UnityAudioParameterDefinition {} unsafe impl Sync for UnityAudioEffectDefinition {} impl Default for UnityAudioEffectDefinition { fn default() -> Self { UnityAudioEffectDefinition { structsize: size_of::<UnityAudioEffectDefinition>() as _, paramstructsize: size_of::<UnityAudioParameterDefinition>() as _, apiversion: UNITY_AUDIO_PLUGIN_API_VERSION as _, pluginversion: 0x010000, channels: 2, numparameters: 0, flags: 0, name: [0; 32], create: None, release: None, reset: None, process: None, setposition: None, paramdefs: null_mut(), setfloatparameter: None, getfloatparameter: None, getfloatbuffer: None } } }
#![allow(unused_variables, non_upper_case_globals, non_snake_case, unused_unsafe, non_camel_case_types, dead_code, clippy::all)] #[cfg(feature = "Win32_System_Search_Common")] pub mod Common; #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct ACCESS_MASKENUM(pub i32); pub const PERM_EXCLUSIVE: ACCESS_MASKENUM = ACCESS_MASKENUM(512i32); pub const PERM_READDESIGN: ACCESS_MASKENUM = ACCESS_MASKENUM(1024i32); pub const PERM_WRITEDESIGN: ACCESS_MASKENUM = ACCESS_MASKENUM(2048i32); pub const PERM_WITHGRANT: ACCESS_MASKENUM = ACCESS_MASKENUM(4096i32); pub const PERM_REFERENCE: ACCESS_MASKENUM = ACCESS_MASKENUM(8192i32); pub const PERM_CREATE: ACCESS_MASKENUM = ACCESS_MASKENUM(16384i32); pub const PERM_INSERT: ACCESS_MASKENUM = ACCESS_MASKENUM(32768i32); pub const PERM_DELETE: ACCESS_MASKENUM = ACCESS_MASKENUM(65536i32); pub const PERM_READCONTROL: ACCESS_MASKENUM = ACCESS_MASKENUM(131072i32); pub const PERM_WRITEPERMISSIONS: ACCESS_MASKENUM = ACCESS_MASKENUM(262144i32); pub const PERM_WRITEOWNER: ACCESS_MASKENUM = ACCESS_MASKENUM(524288i32); pub const PERM_MAXIMUM_ALLOWED: ACCESS_MASKENUM = ACCESS_MASKENUM(33554432i32); pub const PERM_ALL: ACCESS_MASKENUM = ACCESS_MASKENUM(268435456i32); pub const PERM_EXECUTE: ACCESS_MASKENUM = ACCESS_MASKENUM(536870912i32); pub const PERM_READ: ACCESS_MASKENUM = ACCESS_MASKENUM(-2147483648i32); pub const PERM_UPDATE: ACCESS_MASKENUM = ACCESS_MASKENUM(1073741824i32); pub const PERM_DROP: ACCESS_MASKENUM = ACCESS_MASKENUM(256i32); impl ::core::convert::From<i32> for ACCESS_MASKENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for ACCESS_MASKENUM { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(feature = "Win32_Foundation")] pub struct AUTHENTICATION_INFO { pub dwSize: u32, pub atAuthenticationType: AUTH_TYPE, pub pcwszUser: super::super::Foundation::PWSTR, pub pcwszPassword: super::super::Foundation::PWSTR, } #[cfg(feature = "Win32_Foundation")] impl AUTHENTICATION_INFO {} #[cfg(feature = "Win32_Foundation")] impl ::core::default::Default for AUTHENTICATION_INFO { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(feature = "Win32_Foundation")] impl ::core::fmt::Debug for AUTHENTICATION_INFO { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("AUTHENTICATION_INFO").field("dwSize", &self.dwSize).field("atAuthenticationType", &self.atAuthenticationType).field("pcwszUser", &self.pcwszUser).field("pcwszPassword", &self.pcwszPassword).finish() } } #[cfg(feature = "Win32_Foundation")] impl ::core::cmp::PartialEq for AUTHENTICATION_INFO { fn eq(&self, other: &Self) -> bool { self.dwSize == other.dwSize && self.atAuthenticationType == other.atAuthenticationType && self.pcwszUser == other.pcwszUser && self.pcwszPassword == other.pcwszPassword } } #[cfg(feature = "Win32_Foundation")] impl ::core::cmp::Eq for AUTHENTICATION_INFO {} #[cfg(feature = "Win32_Foundation")] unsafe impl ::windows::core::Abi for AUTHENTICATION_INFO { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct AUTH_TYPE(pub i32); pub const eAUTH_TYPE_ANONYMOUS: AUTH_TYPE = AUTH_TYPE(0i32); pub const eAUTH_TYPE_NTLM: AUTH_TYPE = AUTH_TYPE(1i32); pub const eAUTH_TYPE_BASIC: AUTH_TYPE = AUTH_TYPE(2i32); impl ::core::convert::From<i32> for AUTH_TYPE { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for AUTH_TYPE { type Abi = Self; } pub const BCP6xFILEFMT: u32 = 9u32; pub const BCPABORT: u32 = 6u32; pub const BCPBATCH: u32 = 4u32; pub const BCPFILECP: u32 = 12u32; pub const BCPFILECP_ACP: u32 = 0u32; pub const BCPFILECP_OEMCP: u32 = 1u32; pub const BCPFILECP_RAW: i32 = -1i32; pub const BCPFILEFMT: u32 = 15u32; pub const BCPFIRST: u32 = 2u32; pub const BCPHINTS: u32 = 11u32; pub const BCPHINTSA: u32 = 10u32; pub const BCPHINTSW: u32 = 11u32; pub const BCPKEEPIDENTITY: u32 = 8u32; pub const BCPKEEPNULLS: u32 = 5u32; pub const BCPLAST: u32 = 3u32; pub const BCPMAXERRS: u32 = 1u32; pub const BCPODBC: u32 = 7u32; pub const BCPTEXTFILE: u32 = 14u32; pub const BCPUNICODEFILE: u32 = 13u32; pub const BCP_FMT_COLLATION: u32 = 6u32; pub const BCP_FMT_COLLATION_ID: u32 = 7u32; pub const BCP_FMT_DATA_LEN: u32 = 3u32; pub const BCP_FMT_INDICATOR_LEN: u32 = 2u32; pub const BCP_FMT_SERVER_COL: u32 = 5u32; pub const BCP_FMT_TERMINATOR: u32 = 4u32; pub const BCP_FMT_TYPE: u32 = 1u32; pub const BMK_DURABILITY_INTRANSACTION: i32 = 1i32; pub const BMK_DURABILITY_REORGANIZATION: i32 = 3i32; pub const BMK_DURABILITY_ROWSET: i32 = 0i32; pub const BMK_DURABILITY_XTRANSACTION: i32 = 2i32; #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] pub struct BUCKETCATEGORIZE { pub cBuckets: u32, pub Distribution: u32, } impl BUCKETCATEGORIZE {} impl ::core::default::Default for BUCKETCATEGORIZE { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } impl ::core::fmt::Debug for BUCKETCATEGORIZE { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("BUCKETCATEGORIZE").field("cBuckets", &self.cBuckets).field("Distribution", &self.Distribution).finish() } } impl ::core::cmp::PartialEq for BUCKETCATEGORIZE { fn eq(&self, other: &Self) -> bool { self.cBuckets == other.cBuckets && self.Distribution == other.Distribution } } impl ::core::cmp::Eq for BUCKETCATEGORIZE {} unsafe impl ::windows::core::Abi for BUCKETCATEGORIZE { type Abi = Self; } pub const BUCKET_EXPONENTIAL: u32 = 1u32; pub const BUCKET_LINEAR: u32 = 0u32; #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct CASE_REQUIREMENT(pub i32); pub const CASE_REQUIREMENT_ANY: CASE_REQUIREMENT = CASE_REQUIREMENT(0i32); pub const CASE_REQUIREMENT_UPPER_IF_AQS: CASE_REQUIREMENT = CASE_REQUIREMENT(1i32); impl ::core::convert::From<i32> for CASE_REQUIREMENT { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for CASE_REQUIREMENT { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub struct CATEGORIZATION { pub ulCatType: u32, pub Anonymous: CATEGORIZATION_0, pub csColumns: COLUMNSET, } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl CATEGORIZATION {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::default::Default for CATEGORIZATION { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::cmp::PartialEq for CATEGORIZATION { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::cmp::Eq for CATEGORIZATION {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] unsafe impl ::windows::core::Abi for CATEGORIZATION { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub union CATEGORIZATION_0 { pub cClusters: u32, pub bucket: BUCKETCATEGORIZE, pub range: RANGECATEGORIZE, } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl CATEGORIZATION_0 {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::default::Default for CATEGORIZATION_0 { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::cmp::PartialEq for CATEGORIZATION_0 { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::cmp::Eq for CATEGORIZATION_0 {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] unsafe impl ::windows::core::Abi for CATEGORIZATION_0 { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub struct CATEGORIZATIONSET { pub cCat: u32, pub aCat: *mut CATEGORIZATION, } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl CATEGORIZATIONSET {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::default::Default for CATEGORIZATIONSET { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::fmt::Debug for CATEGORIZATIONSET { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("CATEGORIZATIONSET").field("cCat", &self.cCat).field("aCat", &self.aCat).finish() } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::cmp::PartialEq for CATEGORIZATIONSET { fn eq(&self, other: &Self) -> bool { self.cCat == other.cCat && self.aCat == other.aCat } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::cmp::Eq for CATEGORIZATIONSET {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] unsafe impl ::windows::core::Abi for CATEGORIZATIONSET { type Abi = Self; } pub const CATEGORIZE_BUCKETS: u32 = 2u32; pub const CATEGORIZE_CLUSTER: u32 = 1u32; pub const CATEGORIZE_RANGE: u32 = 3u32; pub const CATEGORIZE_UNIQUE: u32 = 0u32; pub const CATEGORY_COLLATOR: i32 = 2i32; pub const CATEGORY_GATHERER: i32 = 3i32; pub const CATEGORY_INDEXER: i32 = 4i32; pub const CATEGORY_SEARCH: i32 = 1i32; pub const CDBBMKDISPIDS: u32 = 8u32; pub const CDBCOLDISPIDS: u32 = 28u32; pub const CDBSELFDISPIDS: u32 = 8u32; pub const CERT_E_NOT_FOUND_OR_NO_PERMISSSION: i32 = -2147211263i32; #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct CHANNEL_AGENT_FLAGS(pub i32); pub const CHANNEL_AGENT_DYNAMIC_SCHEDULE: CHANNEL_AGENT_FLAGS = CHANNEL_AGENT_FLAGS(1i32); pub const CHANNEL_AGENT_PRECACHE_SOME: CHANNEL_AGENT_FLAGS = CHANNEL_AGENT_FLAGS(2i32); pub const CHANNEL_AGENT_PRECACHE_ALL: CHANNEL_AGENT_FLAGS = CHANNEL_AGENT_FLAGS(4i32); pub const CHANNEL_AGENT_PRECACHE_SCRNSAVER: CHANNEL_AGENT_FLAGS = CHANNEL_AGENT_FLAGS(8i32); impl ::core::convert::From<i32> for CHANNEL_AGENT_FLAGS { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for CHANNEL_AGENT_FLAGS { type Abi = Self; } pub const CI_E_CORRUPT_FWIDX: ::windows::core::HRESULT = ::windows::core::HRESULT(-1073473491i32 as _); pub const CI_E_DIACRITIC_SETTINGS_DIFFER: ::windows::core::HRESULT = ::windows::core::HRESULT(-1073473490i32 as _); pub const CI_E_INCONSISTENT_TRANSACTION: ::windows::core::HRESULT = ::windows::core::HRESULT(-1073473486i32 as _); pub const CI_E_INVALID_CATALOG_LIST_VERSION: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147215313i32 as _); pub const CI_E_MULTIPLE_PROTECTED_USERS_UNSUPPORTED: ::windows::core::HRESULT = ::windows::core::HRESULT(-1073473483i32 as _); pub const CI_E_NO_AUXMETADATA: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147215318i32 as _); pub const CI_E_NO_CATALOG_MANAGER: ::windows::core::HRESULT = ::windows::core::HRESULT(-1073473487i32 as _); pub const CI_E_NO_PROTECTED_USER: ::windows::core::HRESULT = ::windows::core::HRESULT(-1073473484i32 as _); pub const CI_E_PROTECTED_CATALOG_NON_INTERACTIVE_USER: ::windows::core::HRESULT = ::windows::core::HRESULT(-1073473481i32 as _); pub const CI_E_PROTECTED_CATALOG_NOT_AVAILABLE: ::windows::core::HRESULT = ::windows::core::HRESULT(-1073473485i32 as _); pub const CI_E_PROTECTED_CATALOG_SID_MISMATCH: ::windows::core::HRESULT = ::windows::core::HRESULT(-1073473482i32 as _); pub const CI_S_CATALOG_RESET: ::windows::core::HRESULT = ::windows::core::HRESULT(268336i32 as _); pub const CI_S_CLIENT_REQUESTED_ABORT: ::windows::core::HRESULT = ::windows::core::HRESULT(268331i32 as _); pub const CI_S_NEW_AUXMETADATA: ::windows::core::HRESULT = ::windows::core::HRESULT(268329i32 as _); pub const CI_S_RETRY_DOCUMENT: ::windows::core::HRESULT = ::windows::core::HRESULT(268332i32 as _); pub const CLSID_DataShapeProvider: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x3449a1c8_c56c_11d0_ad72_00c04fc29863); pub const CLSID_MSDASQL: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xc8b522cb_5cf3_11ce_ade5_00aa0044773d); pub const CLSID_MSDASQL_ENUMERATOR: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xc8b522cd_5cf3_11ce_ade5_00aa0044773d); pub const CLSID_MSPersist: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x7c07e0d0_4418_11d2_9212_00c04fbbbfb3); pub const CLSID_SQLOLEDB: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c7ff16c_38e3_11d0_97ab_00c04fc2ad98); pub const CLSID_SQLOLEDB_ENUMERATOR: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xdfa22b8e_e68d_11d0_97e4_00c04fc2ad98); pub const CLSID_SQLOLEDB_ERROR: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xc0932c62_38e5_11d0_97ab_00c04fc2ad98); #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct CLUSION_REASON(pub i32); pub const CLUSIONREASON_UNKNOWNSCOPE: CLUSION_REASON = CLUSION_REASON(0i32); pub const CLUSIONREASON_DEFAULT: CLUSION_REASON = CLUSION_REASON(1i32); pub const CLUSIONREASON_USER: CLUSION_REASON = CLUSION_REASON(2i32); pub const CLUSIONREASON_GROUPPOLICY: CLUSION_REASON = CLUSION_REASON(3i32); impl ::core::convert::From<i32> for CLUSION_REASON { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for CLUSION_REASON { type Abi = Self; } pub const CMDLINE_E_ALREADY_INIT: i32 = -2147216123i32; pub const CMDLINE_E_NOT_INIT: i32 = -2147216124i32; pub const CMDLINE_E_NUM_PARAMS: i32 = -2147216122i32; pub const CMDLINE_E_PARAM_SIZE: i32 = -2147216125i32; pub const CMDLINE_E_PAREN: i32 = -2147216126i32; pub const CMDLINE_E_UNEXPECTED: i32 = -2147216127i32; pub const CM_E_CONNECTIONTIMEOUT: i32 = -2147219963i32; pub const CM_E_DATASOURCENOTAVAILABLE: i32 = -2147219964i32; pub const CM_E_INSUFFICIENTBUFFER: i32 = -2147219957i32; pub const CM_E_INVALIDDATASOURCE: i32 = -2147219959i32; pub const CM_E_NOQUERYCONNECTIONS: i32 = -2147219965i32; pub const CM_E_REGISTRY: i32 = -2147219960i32; pub const CM_E_SERVERNOTFOUND: i32 = -2147219962i32; pub const CM_E_TIMEOUT: i32 = -2147219958i32; pub const CM_E_TOOMANYDATASERVERS: i32 = -2147219967i32; pub const CM_E_TOOMANYDATASOURCES: i32 = -2147219966i32; pub const CM_S_NODATASERVERS: i32 = 263687i32; pub const COLL_E_BADRESULT: i32 = -2147220218i32; pub const COLL_E_BADSEQUENCE: i32 = -2147220223i32; pub const COLL_E_BUFFERTOOSMALL: i32 = -2147220220i32; pub const COLL_E_DUPLICATEDBID: i32 = -2147220216i32; pub const COLL_E_INCOMPATIBLECOLUMNS: i32 = -2147220221i32; pub const COLL_E_MAXCONNEXCEEDED: i32 = -2147220213i32; pub const COLL_E_NODEFAULTCATALOG: i32 = -2147220214i32; pub const COLL_E_NOMOREDATA: i32 = -2147220222i32; pub const COLL_E_NOSORTCOLUMN: i32 = -2147220217i32; pub const COLL_E_TOOMANYMERGECOLUMNS: i32 = -2147220215i32; #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage"))] pub struct COLUMNSET { pub cCol: u32, pub aCol: *mut super::super::Storage::IndexServer::FULLPROPSPEC, } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage"))] impl COLUMNSET {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::default::Default for COLUMNSET { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::fmt::Debug for COLUMNSET { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("COLUMNSET").field("cCol", &self.cCol).field("aCol", &self.aCol).finish() } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::cmp::PartialEq for COLUMNSET { fn eq(&self, other: &Self) -> bool { self.cCol == other.cCol && self.aCol == other.aCol } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::cmp::Eq for COLUMNSET {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage"))] unsafe impl ::windows::core::Abi for COLUMNSET { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct CONDITION_CREATION_OPTIONS(pub u32); pub const CONDITION_CREATION_DEFAULT: CONDITION_CREATION_OPTIONS = CONDITION_CREATION_OPTIONS(0u32); pub const CONDITION_CREATION_NONE: CONDITION_CREATION_OPTIONS = CONDITION_CREATION_OPTIONS(0u32); pub const CONDITION_CREATION_SIMPLIFY: CONDITION_CREATION_OPTIONS = CONDITION_CREATION_OPTIONS(1u32); pub const CONDITION_CREATION_VECTOR_AND: CONDITION_CREATION_OPTIONS = CONDITION_CREATION_OPTIONS(2u32); pub const CONDITION_CREATION_VECTOR_OR: CONDITION_CREATION_OPTIONS = CONDITION_CREATION_OPTIONS(4u32); pub const CONDITION_CREATION_VECTOR_LEAF: CONDITION_CREATION_OPTIONS = CONDITION_CREATION_OPTIONS(8u32); pub const CONDITION_CREATION_USE_CONTENT_LOCALE: CONDITION_CREATION_OPTIONS = CONDITION_CREATION_OPTIONS(16u32); impl ::core::convert::From<u32> for CONDITION_CREATION_OPTIONS { fn from(value: u32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for CONDITION_CREATION_OPTIONS { type Abi = Self; } impl ::core::ops::BitOr for CONDITION_CREATION_OPTIONS { type Output = Self; fn bitor(self, rhs: Self) -> Self { Self(self.0 | rhs.0) } } impl ::core::ops::BitAnd for CONDITION_CREATION_OPTIONS { type Output = Self; fn bitand(self, rhs: Self) -> Self { Self(self.0 & rhs.0) } } impl ::core::ops::BitOrAssign for CONDITION_CREATION_OPTIONS { fn bitor_assign(&mut self, rhs: Self) { self.0.bitor_assign(rhs.0) } } impl ::core::ops::BitAndAssign for CONDITION_CREATION_OPTIONS { fn bitand_assign(&mut self, rhs: Self) { self.0.bitand_assign(rhs.0) } } impl ::core::ops::Not for CONDITION_CREATION_OPTIONS { type Output = Self; fn not(self) -> Self { Self(self.0.not()) } } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage"))] pub struct CONTENTRESTRICTION { pub prop: super::super::Storage::IndexServer::FULLPROPSPEC, pub pwcsPhrase: super::super::Foundation::PWSTR, pub lcid: u32, pub ulGenerateMethod: u32, } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage"))] impl CONTENTRESTRICTION {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::default::Default for CONTENTRESTRICTION { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::cmp::PartialEq for CONTENTRESTRICTION { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::cmp::Eq for CONTENTRESTRICTION {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage"))] unsafe impl ::windows::core::Abi for CONTENTRESTRICTION { type Abi = Self; } pub const CONTENT_SOURCE_E_CONTENT_CLASS_READ: i32 = -2147208188i32; pub const CONTENT_SOURCE_E_CONTENT_SOURCE_COLUMN_TYPE: i32 = -2147208185i32; pub const CONTENT_SOURCE_E_NULL_CONTENT_CLASS_BSTR: i32 = -2147208186i32; pub const CONTENT_SOURCE_E_NULL_URI: i32 = -2147208183i32; pub const CONTENT_SOURCE_E_OUT_OF_RANGE: i32 = -2147208184i32; pub const CONTENT_SOURCE_E_PROPERTY_MAPPING_BAD_VECTOR_SIZE: i32 = -2147208189i32; pub const CONTENT_SOURCE_E_PROPERTY_MAPPING_READ: i32 = -2147208191i32; pub const CONTENT_SOURCE_E_UNEXPECTED_EXCEPTION: i32 = -2147208187i32; pub const CONTENT_SOURCE_E_UNEXPECTED_NULL_POINTER: i32 = -2147208190i32; pub const CQUERYDISPIDS: u32 = 11u32; pub const CQUERYMETADISPIDS: u32 = 10u32; pub const CQUERYPROPERTY: u32 = 64u32; #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct CREATESUBSCRIPTIONFLAGS(pub i32); pub const CREATESUBS_ADDTOFAVORITES: CREATESUBSCRIPTIONFLAGS = CREATESUBSCRIPTIONFLAGS(1i32); pub const CREATESUBS_FROMFAVORITES: CREATESUBSCRIPTIONFLAGS = CREATESUBSCRIPTIONFLAGS(2i32); pub const CREATESUBS_NOUI: CREATESUBSCRIPTIONFLAGS = CREATESUBSCRIPTIONFLAGS(4i32); pub const CREATESUBS_NOSAVE: CREATESUBSCRIPTIONFLAGS = CREATESUBSCRIPTIONFLAGS(8i32); pub const CREATESUBS_SOFTWAREUPDATE: CREATESUBSCRIPTIONFLAGS = CREATESUBSCRIPTIONFLAGS(16i32); impl ::core::convert::From<i32> for CREATESUBSCRIPTIONFLAGS { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for CREATESUBSCRIPTIONFLAGS { type Abi = Self; } pub const CRESTRICTIONS_DBSCHEMA_ASSERTIONS: u32 = 3u32; pub const CRESTRICTIONS_DBSCHEMA_CATALOGS: u32 = 1u32; pub const CRESTRICTIONS_DBSCHEMA_CHARACTER_SETS: u32 = 3u32; pub const CRESTRICTIONS_DBSCHEMA_CHECK_CONSTRAINTS: u32 = 3u32; pub const CRESTRICTIONS_DBSCHEMA_CHECK_CONSTRAINTS_BY_TABLE: u32 = 6u32; pub const CRESTRICTIONS_DBSCHEMA_COLLATIONS: u32 = 3u32; pub const CRESTRICTIONS_DBSCHEMA_COLUMNS: u32 = 4u32; pub const CRESTRICTIONS_DBSCHEMA_COLUMN_DOMAIN_USAGE: u32 = 4u32; pub const CRESTRICTIONS_DBSCHEMA_COLUMN_PRIVILEGES: u32 = 6u32; pub const CRESTRICTIONS_DBSCHEMA_CONSTRAINT_COLUMN_USAGE: u32 = 4u32; pub const CRESTRICTIONS_DBSCHEMA_CONSTRAINT_TABLE_USAGE: u32 = 3u32; pub const CRESTRICTIONS_DBSCHEMA_FOREIGN_KEYS: u32 = 6u32; pub const CRESTRICTIONS_DBSCHEMA_INDEXES: u32 = 5u32; pub const CRESTRICTIONS_DBSCHEMA_KEY_COLUMN_USAGE: u32 = 7u32; pub const CRESTRICTIONS_DBSCHEMA_LINKEDSERVERS: u32 = 1u32; pub const CRESTRICTIONS_DBSCHEMA_OBJECTS: u32 = 1u32; pub const CRESTRICTIONS_DBSCHEMA_OBJECT_ACTIONS: u32 = 1u32; pub const CRESTRICTIONS_DBSCHEMA_PRIMARY_KEYS: u32 = 3u32; pub const CRESTRICTIONS_DBSCHEMA_PROCEDURES: u32 = 4u32; pub const CRESTRICTIONS_DBSCHEMA_PROCEDURE_COLUMNS: u32 = 4u32; pub const CRESTRICTIONS_DBSCHEMA_PROCEDURE_PARAMETERS: u32 = 4u32; pub const CRESTRICTIONS_DBSCHEMA_PROVIDER_TYPES: u32 = 2u32; pub const CRESTRICTIONS_DBSCHEMA_REFERENTIAL_CONSTRAINTS: u32 = 3u32; pub const CRESTRICTIONS_DBSCHEMA_SCHEMATA: u32 = 3u32; pub const CRESTRICTIONS_DBSCHEMA_SQL_LANGUAGES: u32 = 0u32; pub const CRESTRICTIONS_DBSCHEMA_STATISTICS: u32 = 3u32; pub const CRESTRICTIONS_DBSCHEMA_TABLES: u32 = 4u32; pub const CRESTRICTIONS_DBSCHEMA_TABLES_INFO: u32 = 4u32; pub const CRESTRICTIONS_DBSCHEMA_TABLE_CONSTRAINTS: u32 = 7u32; pub const CRESTRICTIONS_DBSCHEMA_TABLE_PRIVILEGES: u32 = 5u32; pub const CRESTRICTIONS_DBSCHEMA_TABLE_STATISTICS: u32 = 7u32; pub const CRESTRICTIONS_DBSCHEMA_TRANSLATIONS: u32 = 3u32; pub const CRESTRICTIONS_DBSCHEMA_TRUSTEE: u32 = 4u32; pub const CRESTRICTIONS_DBSCHEMA_USAGE_PRIVILEGES: u32 = 6u32; pub const CRESTRICTIONS_DBSCHEMA_VIEWS: u32 = 3u32; pub const CRESTRICTIONS_DBSCHEMA_VIEW_COLUMN_USAGE: u32 = 3u32; pub const CRESTRICTIONS_DBSCHEMA_VIEW_TABLE_USAGE: u32 = 3u32; pub const CRESTRICTIONS_MDSCHEMA_ACTIONS: u32 = 8u32; pub const CRESTRICTIONS_MDSCHEMA_COMMANDS: u32 = 5u32; pub const CRESTRICTIONS_MDSCHEMA_CUBES: u32 = 3u32; pub const CRESTRICTIONS_MDSCHEMA_DIMENSIONS: u32 = 5u32; pub const CRESTRICTIONS_MDSCHEMA_FUNCTIONS: u32 = 4u32; pub const CRESTRICTIONS_MDSCHEMA_HIERARCHIES: u32 = 6u32; pub const CRESTRICTIONS_MDSCHEMA_LEVELS: u32 = 7u32; pub const CRESTRICTIONS_MDSCHEMA_MEASURES: u32 = 5u32; pub const CRESTRICTIONS_MDSCHEMA_MEMBERS: u32 = 12u32; pub const CRESTRICTIONS_MDSCHEMA_PROPERTIES: u32 = 9u32; pub const CRESTRICTIONS_MDSCHEMA_SETS: u32 = 5u32; pub const CSTORAGEPROPERTY: u32 = 23u32; pub const CSearchLanguageSupport: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x6a68cc80_4337_4dbc_bd27_fbfb1053820b); pub const CSearchManager: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x7d096c5f_ac08_4f1f_beb7_5c22c517ce39); pub const CSearchRoot: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x30766bd2_ea1c_4f28_bf27_0b44e2f68db7); pub const CSearchScopeRule: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xe63de750_3bd7_4be5_9c84_6b4281988c44); #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct CatalogPausedReason(pub i32); pub const CATALOG_PAUSED_REASON_NONE: CatalogPausedReason = CatalogPausedReason(0i32); pub const CATALOG_PAUSED_REASON_HIGH_IO: CatalogPausedReason = CatalogPausedReason(1i32); pub const CATALOG_PAUSED_REASON_HIGH_CPU: CatalogPausedReason = CatalogPausedReason(2i32); pub const CATALOG_PAUSED_REASON_HIGH_NTF_RATE: CatalogPausedReason = CatalogPausedReason(3i32); pub const CATALOG_PAUSED_REASON_LOW_BATTERY: CatalogPausedReason = CatalogPausedReason(4i32); pub const CATALOG_PAUSED_REASON_LOW_MEMORY: CatalogPausedReason = CatalogPausedReason(5i32); pub const CATALOG_PAUSED_REASON_LOW_DISK: CatalogPausedReason = CatalogPausedReason(6i32); pub const CATALOG_PAUSED_REASON_DELAYED_RECOVERY: CatalogPausedReason = CatalogPausedReason(7i32); pub const CATALOG_PAUSED_REASON_USER_ACTIVE: CatalogPausedReason = CatalogPausedReason(8i32); pub const CATALOG_PAUSED_REASON_EXTERNAL: CatalogPausedReason = CatalogPausedReason(9i32); pub const CATALOG_PAUSED_REASON_UPGRADING: CatalogPausedReason = CatalogPausedReason(10i32); impl ::core::convert::From<i32> for CatalogPausedReason { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for CatalogPausedReason { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct CatalogStatus(pub i32); pub const CATALOG_STATUS_IDLE: CatalogStatus = CatalogStatus(0i32); pub const CATALOG_STATUS_PAUSED: CatalogStatus = CatalogStatus(1i32); pub const CATALOG_STATUS_RECOVERING: CatalogStatus = CatalogStatus(2i32); pub const CATALOG_STATUS_FULL_CRAWL: CatalogStatus = CatalogStatus(3i32); pub const CATALOG_STATUS_INCREMENTAL_CRAWL: CatalogStatus = CatalogStatus(4i32); pub const CATALOG_STATUS_PROCESSING_NOTIFICATIONS: CatalogStatus = CatalogStatus(5i32); pub const CATALOG_STATUS_SHUTTING_DOWN: CatalogStatus = CatalogStatus(6i32); impl ::core::convert::From<i32> for CatalogStatus { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for CatalogStatus { type Abi = Self; } pub const CompoundCondition: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x116f8d13_101e_4fa5_84d4_ff8279381935); pub const ConditionFactory: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xe03e85b0_7be3_4000_ba98_6c13de9fa486); #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] pub struct DATE_STRUCT { pub year: i16, pub month: u16, pub day: u16, } impl DATE_STRUCT {} impl ::core::default::Default for DATE_STRUCT { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } impl ::core::fmt::Debug for DATE_STRUCT { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("DATE_STRUCT").field("year", &self.year).field("month", &self.month).field("day", &self.day).finish() } } impl ::core::cmp::PartialEq for DATE_STRUCT { fn eq(&self, other: &Self) -> bool { self.year == other.year && self.month == other.month && self.day == other.day } } impl ::core::cmp::Eq for DATE_STRUCT {} unsafe impl ::windows::core::Abi for DATE_STRUCT { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBACCESSORFLAGSENUM(pub i32); pub const DBACCESSOR_INVALID: DBACCESSORFLAGSENUM = DBACCESSORFLAGSENUM(0i32); pub const DBACCESSOR_PASSBYREF: DBACCESSORFLAGSENUM = DBACCESSORFLAGSENUM(1i32); pub const DBACCESSOR_ROWDATA: DBACCESSORFLAGSENUM = DBACCESSORFLAGSENUM(2i32); pub const DBACCESSOR_PARAMETERDATA: DBACCESSORFLAGSENUM = DBACCESSORFLAGSENUM(4i32); pub const DBACCESSOR_OPTIMIZED: DBACCESSORFLAGSENUM = DBACCESSORFLAGSENUM(8i32); pub const DBACCESSOR_INHERITED: DBACCESSORFLAGSENUM = DBACCESSORFLAGSENUM(16i32); impl ::core::convert::From<i32> for DBACCESSORFLAGSENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBACCESSORFLAGSENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBASYNCHOPENUM(pub i32); pub const DBASYNCHOP_OPEN: DBASYNCHOPENUM = DBASYNCHOPENUM(0i32); impl ::core::convert::From<i32> for DBASYNCHOPENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBASYNCHOPENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBASYNCHPHASEENUM(pub i32); pub const DBASYNCHPHASE_INITIALIZATION: DBASYNCHPHASEENUM = DBASYNCHPHASEENUM(0i32); pub const DBASYNCHPHASE_POPULATION: DBASYNCHPHASEENUM = DBASYNCHPHASEENUM(1i32); pub const DBASYNCHPHASE_COMPLETE: DBASYNCHPHASEENUM = DBASYNCHPHASEENUM(2i32); pub const DBASYNCHPHASE_CANCELED: DBASYNCHPHASEENUM = DBASYNCHPHASEENUM(3i32); impl ::core::convert::From<i32> for DBASYNCHPHASEENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBASYNCHPHASEENUM { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] pub struct DBBINDEXT { pub pExtension: *mut u8, pub ulExtension: usize, } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl DBBINDEXT {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::default::Default for DBBINDEXT { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::fmt::Debug for DBBINDEXT { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("DBBINDEXT").field("pExtension", &self.pExtension).field("ulExtension", &self.ulExtension).finish() } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::cmp::PartialEq for DBBINDEXT { fn eq(&self, other: &Self) -> bool { self.pExtension == other.pExtension && self.ulExtension == other.ulExtension } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::cmp::Eq for DBBINDEXT {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] unsafe impl ::windows::core::Abi for DBBINDEXT { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C, packed(2))] #[cfg(any(target_arch = "x86",))] pub struct DBBINDEXT { pub pExtension: *mut u8, pub ulExtension: usize, } #[cfg(any(target_arch = "x86",))] impl DBBINDEXT {} #[cfg(any(target_arch = "x86",))] impl ::core::default::Default for DBBINDEXT { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86",))] impl ::core::cmp::PartialEq for DBBINDEXT { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(any(target_arch = "x86",))] impl ::core::cmp::Eq for DBBINDEXT {} #[cfg(any(target_arch = "x86",))] unsafe impl ::windows::core::Abi for DBBINDEXT { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBBINDFLAGENUM(pub i32); pub const DBBINDFLAG_HTML: DBBINDFLAGENUM = DBBINDFLAGENUM(1i32); impl ::core::convert::From<i32> for DBBINDFLAGENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBBINDFLAGENUM { type Abi = Self; } #[derive(:: core :: clone :: Clone)] #[repr(C)] #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(feature = "Win32_System_Com")] pub struct DBBINDING { pub iOrdinal: usize, pub obValue: usize, pub obLength: usize, pub obStatus: usize, pub pTypeInfo: ::core::option::Option<super::Com::ITypeInfo>, pub pObject: *mut DBOBJECT, pub pBindExt: *mut DBBINDEXT, pub dwPart: u32, pub dwMemOwner: u32, pub eParamIO: u32, pub cbMaxLen: usize, pub dwFlags: u32, pub wType: u16, pub bPrecision: u8, pub bScale: u8, } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(feature = "Win32_System_Com")] impl DBBINDING {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(feature = "Win32_System_Com")] impl ::core::default::Default for DBBINDING { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(feature = "Win32_System_Com")] impl ::core::fmt::Debug for DBBINDING { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("DBBINDING") .field("iOrdinal", &self.iOrdinal) .field("obValue", &self.obValue) .field("obLength", &self.obLength) .field("obStatus", &self.obStatus) .field("pTypeInfo", &self.pTypeInfo) .field("pObject", &self.pObject) .field("pBindExt", &self.pBindExt) .field("dwPart", &self.dwPart) .field("dwMemOwner", &self.dwMemOwner) .field("eParamIO", &self.eParamIO) .field("cbMaxLen", &self.cbMaxLen) .field("dwFlags", &self.dwFlags) .field("wType", &self.wType) .field("bPrecision", &self.bPrecision) .field("bScale", &self.bScale) .finish() } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(feature = "Win32_System_Com")] impl ::core::cmp::PartialEq for DBBINDING { fn eq(&self, other: &Self) -> bool { self.iOrdinal == other.iOrdinal && self.obValue == other.obValue && self.obLength == other.obLength && self.obStatus == other.obStatus && self.pTypeInfo == other.pTypeInfo && self.pObject == other.pObject && self.pBindExt == other.pBindExt && self.dwPart == other.dwPart && self.dwMemOwner == other.dwMemOwner && self.eParamIO == other.eParamIO && self.cbMaxLen == other.cbMaxLen && self.dwFlags == other.dwFlags && self.wType == other.wType && self.bPrecision == other.bPrecision && self.bScale == other.bScale } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(feature = "Win32_System_Com")] impl ::core::cmp::Eq for DBBINDING {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(feature = "Win32_System_Com")] unsafe impl ::windows::core::Abi for DBBINDING { type Abi = ::core::mem::ManuallyDrop<Self>; } #[cfg(any(target_arch = "x86",))] #[cfg(feature = "Win32_System_Com")] impl ::core::clone::Clone for DBBINDING { fn clone(&self) -> Self { unimplemented!() } } #[repr(C, packed(2))] #[cfg(any(target_arch = "x86",))] #[cfg(feature = "Win32_System_Com")] pub struct DBBINDING { pub iOrdinal: usize, pub obValue: usize, pub obLength: usize, pub obStatus: usize, pub pTypeInfo: ::core::option::Option<super::Com::ITypeInfo>, pub pObject: *mut DBOBJECT, pub pBindExt: *mut DBBINDEXT, pub dwPart: u32, pub dwMemOwner: u32, pub eParamIO: u32, pub cbMaxLen: usize, pub dwFlags: u32, pub wType: u16, pub bPrecision: u8, pub bScale: u8, } #[cfg(any(target_arch = "x86",))] #[cfg(feature = "Win32_System_Com")] impl DBBINDING {} #[cfg(any(target_arch = "x86",))] #[cfg(feature = "Win32_System_Com")] impl ::core::default::Default for DBBINDING { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86",))] #[cfg(feature = "Win32_System_Com")] impl ::core::cmp::PartialEq for DBBINDING { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(any(target_arch = "x86",))] #[cfg(feature = "Win32_System_Com")] impl ::core::cmp::Eq for DBBINDING {} #[cfg(any(target_arch = "x86",))] #[cfg(feature = "Win32_System_Com")] unsafe impl ::windows::core::Abi for DBBINDING { type Abi = ::core::mem::ManuallyDrop<Self>; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBBINDSTATUSENUM(pub i32); pub const DBBINDSTATUS_OK: DBBINDSTATUSENUM = DBBINDSTATUSENUM(0i32); pub const DBBINDSTATUS_BADORDINAL: DBBINDSTATUSENUM = DBBINDSTATUSENUM(1i32); pub const DBBINDSTATUS_UNSUPPORTEDCONVERSION: DBBINDSTATUSENUM = DBBINDSTATUSENUM(2i32); pub const DBBINDSTATUS_BADBINDINFO: DBBINDSTATUSENUM = DBBINDSTATUSENUM(3i32); pub const DBBINDSTATUS_BADSTORAGEFLAGS: DBBINDSTATUSENUM = DBBINDSTATUSENUM(4i32); pub const DBBINDSTATUS_NOINTERFACE: DBBINDSTATUSENUM = DBBINDSTATUSENUM(5i32); pub const DBBINDSTATUS_MULTIPLESTORAGE: DBBINDSTATUSENUM = DBBINDSTATUSENUM(6i32); impl ::core::convert::From<i32> for DBBINDSTATUSENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBBINDSTATUSENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBBINDURLFLAGENUM(pub i32); pub const DBBINDURLFLAG_READ: DBBINDURLFLAGENUM = DBBINDURLFLAGENUM(1i32); pub const DBBINDURLFLAG_WRITE: DBBINDURLFLAGENUM = DBBINDURLFLAGENUM(2i32); pub const DBBINDURLFLAG_READWRITE: DBBINDURLFLAGENUM = DBBINDURLFLAGENUM(3i32); pub const DBBINDURLFLAG_SHARE_DENY_READ: DBBINDURLFLAGENUM = DBBINDURLFLAGENUM(4i32); pub const DBBINDURLFLAG_SHARE_DENY_WRITE: DBBINDURLFLAGENUM = DBBINDURLFLAGENUM(8i32); pub const DBBINDURLFLAG_SHARE_EXCLUSIVE: DBBINDURLFLAGENUM = DBBINDURLFLAGENUM(12i32); pub const DBBINDURLFLAG_SHARE_DENY_NONE: DBBINDURLFLAGENUM = DBBINDURLFLAGENUM(16i32); pub const DBBINDURLFLAG_ASYNCHRONOUS: DBBINDURLFLAGENUM = DBBINDURLFLAGENUM(4096i32); pub const DBBINDURLFLAG_COLLECTION: DBBINDURLFLAGENUM = DBBINDURLFLAGENUM(8192i32); pub const DBBINDURLFLAG_DELAYFETCHSTREAM: DBBINDURLFLAGENUM = DBBINDURLFLAGENUM(16384i32); pub const DBBINDURLFLAG_DELAYFETCHCOLUMNS: DBBINDURLFLAGENUM = DBBINDURLFLAGENUM(32768i32); pub const DBBINDURLFLAG_RECURSIVE: DBBINDURLFLAGENUM = DBBINDURLFLAGENUM(4194304i32); pub const DBBINDURLFLAG_OUTPUT: DBBINDURLFLAGENUM = DBBINDURLFLAGENUM(8388608i32); pub const DBBINDURLFLAG_WAITFORINIT: DBBINDURLFLAGENUM = DBBINDURLFLAGENUM(16777216i32); pub const DBBINDURLFLAG_OPENIFEXISTS: DBBINDURLFLAGENUM = DBBINDURLFLAGENUM(33554432i32); pub const DBBINDURLFLAG_OVERWRITE: DBBINDURLFLAGENUM = DBBINDURLFLAGENUM(67108864i32); pub const DBBINDURLFLAG_ISSTRUCTUREDDOCUMENT: DBBINDURLFLAGENUM = DBBINDURLFLAGENUM(134217728i32); impl ::core::convert::From<i32> for DBBINDURLFLAGENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBBINDURLFLAGENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBBINDURLSTATUSENUM(pub i32); pub const DBBINDURLSTATUS_S_OK: DBBINDURLSTATUSENUM = DBBINDURLSTATUSENUM(0i32); pub const DBBINDURLSTATUS_S_DENYNOTSUPPORTED: DBBINDURLSTATUSENUM = DBBINDURLSTATUSENUM(1i32); pub const DBBINDURLSTATUS_S_DENYTYPENOTSUPPORTED: DBBINDURLSTATUSENUM = DBBINDURLSTATUSENUM(4i32); pub const DBBINDURLSTATUS_S_REDIRECTED: DBBINDURLSTATUSENUM = DBBINDURLSTATUSENUM(8i32); impl ::core::convert::From<i32> for DBBINDURLSTATUSENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBBINDURLSTATUSENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBBOOKMARK(pub i32); pub const DBBMK_INVALID: DBBOOKMARK = DBBOOKMARK(0i32); pub const DBBMK_FIRST: DBBOOKMARK = DBBOOKMARK(1i32); pub const DBBMK_LAST: DBBOOKMARK = DBBOOKMARK(2i32); impl ::core::convert::From<i32> for DBBOOKMARK { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBBOOKMARK { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub struct DBCOLUMNACCESS { pub pData: *mut ::core::ffi::c_void, pub columnid: super::super::Storage::IndexServer::DBID, pub cbDataLen: usize, pub dwStatus: u32, pub cbMaxLen: usize, pub dwReserved: usize, pub wType: u16, pub bPrecision: u8, pub bScale: u8, } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] impl DBCOLUMNACCESS {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] impl ::core::default::Default for DBCOLUMNACCESS { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] impl ::core::cmp::PartialEq for DBCOLUMNACCESS { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] impl ::core::cmp::Eq for DBCOLUMNACCESS {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] unsafe impl ::windows::core::Abi for DBCOLUMNACCESS { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C, packed(2))] #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub struct DBCOLUMNACCESS { pub pData: *mut ::core::ffi::c_void, pub columnid: super::super::Storage::IndexServer::DBID, pub cbDataLen: usize, pub dwStatus: u32, pub cbMaxLen: usize, pub dwReserved: usize, pub wType: u16, pub bPrecision: u8, pub bScale: u8, } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] impl DBCOLUMNACCESS {} #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] impl ::core::default::Default for DBCOLUMNACCESS { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] impl ::core::cmp::PartialEq for DBCOLUMNACCESS { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] impl ::core::cmp::Eq for DBCOLUMNACCESS {} #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] unsafe impl ::windows::core::Abi for DBCOLUMNACCESS { type Abi = Self; } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::clone::Clone for DBCOLUMNDESC { fn clone(&self) -> Self { unimplemented!() } } #[repr(C)] #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub struct DBCOLUMNDESC { pub pwszTypeName: super::super::Foundation::PWSTR, pub pTypeInfo: ::core::option::Option<super::Com::ITypeInfo>, pub rgPropertySets: *mut DBPROPSET, pub pclsid: *mut ::windows::core::GUID, pub cPropertySets: u32, pub ulColumnSize: usize, pub dbcid: super::super::Storage::IndexServer::DBID, pub wType: u16, pub bPrecision: u8, pub bScale: u8, } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl DBCOLUMNDESC {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::default::Default for DBCOLUMNDESC { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::cmp::PartialEq for DBCOLUMNDESC { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::cmp::Eq for DBCOLUMNDESC {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] unsafe impl ::windows::core::Abi for DBCOLUMNDESC { type Abi = ::core::mem::ManuallyDrop<Self>; } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::clone::Clone for DBCOLUMNDESC { fn clone(&self) -> Self { unimplemented!() } } #[repr(C, packed(2))] #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub struct DBCOLUMNDESC { pub pwszTypeName: super::super::Foundation::PWSTR, pub pTypeInfo: ::core::option::Option<super::Com::ITypeInfo>, pub rgPropertySets: *mut DBPROPSET, pub pclsid: *mut ::windows::core::GUID, pub cPropertySets: u32, pub ulColumnSize: usize, pub dbcid: super::super::Storage::IndexServer::DBID, pub wType: u16, pub bPrecision: u8, pub bScale: u8, } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl DBCOLUMNDESC {} #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::default::Default for DBCOLUMNDESC { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::cmp::PartialEq for DBCOLUMNDESC { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::cmp::Eq for DBCOLUMNDESC {} #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] unsafe impl ::windows::core::Abi for DBCOLUMNDESC { type Abi = ::core::mem::ManuallyDrop<Self>; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBCOLUMNDESCFLAGSENUM(pub i32); pub const DBCOLUMNDESCFLAGS_TYPENAME: DBCOLUMNDESCFLAGSENUM = DBCOLUMNDESCFLAGSENUM(1i32); pub const DBCOLUMNDESCFLAGS_ITYPEINFO: DBCOLUMNDESCFLAGSENUM = DBCOLUMNDESCFLAGSENUM(2i32); pub const DBCOLUMNDESCFLAGS_PROPERTIES: DBCOLUMNDESCFLAGSENUM = DBCOLUMNDESCFLAGSENUM(4i32); pub const DBCOLUMNDESCFLAGS_CLSID: DBCOLUMNDESCFLAGSENUM = DBCOLUMNDESCFLAGSENUM(8i32); pub const DBCOLUMNDESCFLAGS_COLSIZE: DBCOLUMNDESCFLAGSENUM = DBCOLUMNDESCFLAGSENUM(16i32); pub const DBCOLUMNDESCFLAGS_DBCID: DBCOLUMNDESCFLAGSENUM = DBCOLUMNDESCFLAGSENUM(32i32); pub const DBCOLUMNDESCFLAGS_WTYPE: DBCOLUMNDESCFLAGSENUM = DBCOLUMNDESCFLAGSENUM(64i32); pub const DBCOLUMNDESCFLAGS_PRECISION: DBCOLUMNDESCFLAGSENUM = DBCOLUMNDESCFLAGSENUM(128i32); pub const DBCOLUMNDESCFLAGS_SCALE: DBCOLUMNDESCFLAGSENUM = DBCOLUMNDESCFLAGSENUM(256i32); impl ::core::convert::From<i32> for DBCOLUMNDESCFLAGSENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBCOLUMNDESCFLAGSENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBCOLUMNFLAGS15ENUM(pub i32); pub const DBCOLUMNFLAGS_ISCHAPTER: DBCOLUMNFLAGS15ENUM = DBCOLUMNFLAGS15ENUM(8192i32); impl ::core::convert::From<i32> for DBCOLUMNFLAGS15ENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBCOLUMNFLAGS15ENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBCOLUMNFLAGSENUM(pub i32); pub const DBCOLUMNFLAGS_ISBOOKMARK: DBCOLUMNFLAGSENUM = DBCOLUMNFLAGSENUM(1i32); pub const DBCOLUMNFLAGS_MAYDEFER: DBCOLUMNFLAGSENUM = DBCOLUMNFLAGSENUM(2i32); pub const DBCOLUMNFLAGS_WRITE: DBCOLUMNFLAGSENUM = DBCOLUMNFLAGSENUM(4i32); pub const DBCOLUMNFLAGS_WRITEUNKNOWN: DBCOLUMNFLAGSENUM = DBCOLUMNFLAGSENUM(8i32); pub const DBCOLUMNFLAGS_ISFIXEDLENGTH: DBCOLUMNFLAGSENUM = DBCOLUMNFLAGSENUM(16i32); pub const DBCOLUMNFLAGS_ISNULLABLE: DBCOLUMNFLAGSENUM = DBCOLUMNFLAGSENUM(32i32); pub const DBCOLUMNFLAGS_MAYBENULL: DBCOLUMNFLAGSENUM = DBCOLUMNFLAGSENUM(64i32); pub const DBCOLUMNFLAGS_ISLONG: DBCOLUMNFLAGSENUM = DBCOLUMNFLAGSENUM(128i32); pub const DBCOLUMNFLAGS_ISROWID: DBCOLUMNFLAGSENUM = DBCOLUMNFLAGSENUM(256i32); pub const DBCOLUMNFLAGS_ISROWVER: DBCOLUMNFLAGSENUM = DBCOLUMNFLAGSENUM(512i32); pub const DBCOLUMNFLAGS_CACHEDEFERRED: DBCOLUMNFLAGSENUM = DBCOLUMNFLAGSENUM(4096i32); impl ::core::convert::From<i32> for DBCOLUMNFLAGSENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBCOLUMNFLAGSENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBCOLUMNFLAGSENUM20(pub i32); pub const DBCOLUMNFLAGS_SCALEISNEGATIVE: DBCOLUMNFLAGSENUM20 = DBCOLUMNFLAGSENUM20(16384i32); pub const DBCOLUMNFLAGS_RESERVED: DBCOLUMNFLAGSENUM20 = DBCOLUMNFLAGSENUM20(32768i32); impl ::core::convert::From<i32> for DBCOLUMNFLAGSENUM20 { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBCOLUMNFLAGSENUM20 { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBCOLUMNFLAGSENUM21(pub i32); pub const DBCOLUMNFLAGS_ISROWURL: DBCOLUMNFLAGSENUM21 = DBCOLUMNFLAGSENUM21(65536i32); pub const DBCOLUMNFLAGS_ISDEFAULTSTREAM: DBCOLUMNFLAGSENUM21 = DBCOLUMNFLAGSENUM21(131072i32); pub const DBCOLUMNFLAGS_ISCOLLECTION: DBCOLUMNFLAGSENUM21 = DBCOLUMNFLAGSENUM21(262144i32); impl ::core::convert::From<i32> for DBCOLUMNFLAGSENUM21 { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBCOLUMNFLAGSENUM21 { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBCOLUMNFLAGSENUM26(pub i32); pub const DBCOLUMNFLAGS_ISSTREAM: DBCOLUMNFLAGSENUM26 = DBCOLUMNFLAGSENUM26(524288i32); pub const DBCOLUMNFLAGS_ISROWSET: DBCOLUMNFLAGSENUM26 = DBCOLUMNFLAGSENUM26(1048576i32); pub const DBCOLUMNFLAGS_ISROW: DBCOLUMNFLAGSENUM26 = DBCOLUMNFLAGSENUM26(2097152i32); pub const DBCOLUMNFLAGS_ROWSPECIFICCOLUMN: DBCOLUMNFLAGSENUM26 = DBCOLUMNFLAGSENUM26(4194304i32); impl ::core::convert::From<i32> for DBCOLUMNFLAGSENUM26 { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBCOLUMNFLAGSENUM26 { type Abi = Self; } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com"))] impl ::core::clone::Clone for DBCOLUMNINFO { fn clone(&self) -> Self { unimplemented!() } } #[repr(C)] #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com"))] pub struct DBCOLUMNINFO { pub pwszName: super::super::Foundation::PWSTR, pub pTypeInfo: ::core::option::Option<super::Com::ITypeInfo>, pub iOrdinal: usize, pub dwFlags: u32, pub ulColumnSize: usize, pub wType: u16, pub bPrecision: u8, pub bScale: u8, pub columnid: super::super::Storage::IndexServer::DBID, } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com"))] impl DBCOLUMNINFO {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com"))] impl ::core::default::Default for DBCOLUMNINFO { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com"))] impl ::core::cmp::PartialEq for DBCOLUMNINFO { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com"))] impl ::core::cmp::Eq for DBCOLUMNINFO {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com"))] unsafe impl ::windows::core::Abi for DBCOLUMNINFO { type Abi = ::core::mem::ManuallyDrop<Self>; } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com"))] impl ::core::clone::Clone for DBCOLUMNINFO { fn clone(&self) -> Self { unimplemented!() } } #[repr(C, packed(2))] #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com"))] pub struct DBCOLUMNINFO { pub pwszName: super::super::Foundation::PWSTR, pub pTypeInfo: ::core::option::Option<super::Com::ITypeInfo>, pub iOrdinal: usize, pub dwFlags: u32, pub ulColumnSize: usize, pub wType: u16, pub bPrecision: u8, pub bScale: u8, pub columnid: super::super::Storage::IndexServer::DBID, } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com"))] impl DBCOLUMNINFO {} #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com"))] impl ::core::default::Default for DBCOLUMNINFO { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com"))] impl ::core::cmp::PartialEq for DBCOLUMNINFO { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com"))] impl ::core::cmp::Eq for DBCOLUMNINFO {} #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com"))] unsafe impl ::windows::core::Abi for DBCOLUMNINFO { type Abi = ::core::mem::ManuallyDrop<Self>; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBCOMMANDPERSISTFLAGENUM(pub i32); pub const DBCOMMANDPERSISTFLAG_NOSAVE: DBCOMMANDPERSISTFLAGENUM = DBCOMMANDPERSISTFLAGENUM(1i32); impl ::core::convert::From<i32> for DBCOMMANDPERSISTFLAGENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBCOMMANDPERSISTFLAGENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBCOMMANDPERSISTFLAGENUM21(pub i32); pub const DBCOMMANDPERSISTFLAG_DEFAULT: DBCOMMANDPERSISTFLAGENUM21 = DBCOMMANDPERSISTFLAGENUM21(0i32); pub const DBCOMMANDPERSISTFLAG_PERSISTVIEW: DBCOMMANDPERSISTFLAGENUM21 = DBCOMMANDPERSISTFLAGENUM21(2i32); pub const DBCOMMANDPERSISTFLAG_PERSISTPROCEDURE: DBCOMMANDPERSISTFLAGENUM21 = DBCOMMANDPERSISTFLAGENUM21(4i32); impl ::core::convert::From<i32> for DBCOMMANDPERSISTFLAGENUM21 { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBCOMMANDPERSISTFLAGENUM21 { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBCOMPAREENUM(pub i32); pub const DBCOMPARE_LT: DBCOMPAREENUM = DBCOMPAREENUM(0i32); pub const DBCOMPARE_EQ: DBCOMPAREENUM = DBCOMPAREENUM(1i32); pub const DBCOMPARE_GT: DBCOMPAREENUM = DBCOMPAREENUM(2i32); pub const DBCOMPARE_NE: DBCOMPAREENUM = DBCOMPAREENUM(3i32); pub const DBCOMPARE_NOTCOMPARABLE: DBCOMPAREENUM = DBCOMPAREENUM(4i32); impl ::core::convert::From<i32> for DBCOMPAREENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBCOMPAREENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBCOMPAREOPSENUM(pub i32); pub const DBCOMPAREOPS_LT: DBCOMPAREOPSENUM = DBCOMPAREOPSENUM(0i32); pub const DBCOMPAREOPS_LE: DBCOMPAREOPSENUM = DBCOMPAREOPSENUM(1i32); pub const DBCOMPAREOPS_EQ: DBCOMPAREOPSENUM = DBCOMPAREOPSENUM(2i32); pub const DBCOMPAREOPS_GE: DBCOMPAREOPSENUM = DBCOMPAREOPSENUM(3i32); pub const DBCOMPAREOPS_GT: DBCOMPAREOPSENUM = DBCOMPAREOPSENUM(4i32); pub const DBCOMPAREOPS_BEGINSWITH: DBCOMPAREOPSENUM = DBCOMPAREOPSENUM(5i32); pub const DBCOMPAREOPS_CONTAINS: DBCOMPAREOPSENUM = DBCOMPAREOPSENUM(6i32); pub const DBCOMPAREOPS_NE: DBCOMPAREOPSENUM = DBCOMPAREOPSENUM(7i32); pub const DBCOMPAREOPS_IGNORE: DBCOMPAREOPSENUM = DBCOMPAREOPSENUM(8i32); pub const DBCOMPAREOPS_CASESENSITIVE: DBCOMPAREOPSENUM = DBCOMPAREOPSENUM(4096i32); pub const DBCOMPAREOPS_CASEINSENSITIVE: DBCOMPAREOPSENUM = DBCOMPAREOPSENUM(8192i32); impl ::core::convert::From<i32> for DBCOMPAREOPSENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBCOMPAREOPSENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBCOMPAREOPSENUM20(pub i32); pub const DBCOMPAREOPS_NOTBEGINSWITH: DBCOMPAREOPSENUM20 = DBCOMPAREOPSENUM20(9i32); pub const DBCOMPAREOPS_NOTCONTAINS: DBCOMPAREOPSENUM20 = DBCOMPAREOPSENUM20(10i32); impl ::core::convert::From<i32> for DBCOMPAREOPSENUM20 { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBCOMPAREOPSENUM20 { type Abi = Self; } pub const DBCOMPUTEMODE_COMPUTED: u32 = 1u32; pub const DBCOMPUTEMODE_DYNAMIC: u32 = 2u32; pub const DBCOMPUTEMODE_NOTCOMPUTED: u32 = 3u32; #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub struct DBCONSTRAINTDESC { pub pConstraintID: *mut super::super::Storage::IndexServer::DBID, pub ConstraintType: u32, pub cColumns: usize, pub rgColumnList: *mut super::super::Storage::IndexServer::DBID, pub pReferencedTableID: *mut super::super::Storage::IndexServer::DBID, pub cForeignKeyColumns: usize, pub rgForeignKeyColumnList: *mut super::super::Storage::IndexServer::DBID, pub pwszConstraintText: super::super::Foundation::PWSTR, pub UpdateRule: u32, pub DeleteRule: u32, pub MatchType: u32, pub Deferrability: u32, pub cReserved: usize, pub rgReserved: *mut DBPROPSET, } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl DBCONSTRAINTDESC {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::default::Default for DBCONSTRAINTDESC { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::fmt::Debug for DBCONSTRAINTDESC { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("DBCONSTRAINTDESC") .field("pConstraintID", &self.pConstraintID) .field("ConstraintType", &self.ConstraintType) .field("cColumns", &self.cColumns) .field("rgColumnList", &self.rgColumnList) .field("pReferencedTableID", &self.pReferencedTableID) .field("cForeignKeyColumns", &self.cForeignKeyColumns) .field("rgForeignKeyColumnList", &self.rgForeignKeyColumnList) .field("pwszConstraintText", &self.pwszConstraintText) .field("UpdateRule", &self.UpdateRule) .field("DeleteRule", &self.DeleteRule) .field("MatchType", &self.MatchType) .field("Deferrability", &self.Deferrability) .field("cReserved", &self.cReserved) .field("rgReserved", &self.rgReserved) .finish() } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::cmp::PartialEq for DBCONSTRAINTDESC { fn eq(&self, other: &Self) -> bool { self.pConstraintID == other.pConstraintID && self.ConstraintType == other.ConstraintType && self.cColumns == other.cColumns && self.rgColumnList == other.rgColumnList && self.pReferencedTableID == other.pReferencedTableID && self.cForeignKeyColumns == other.cForeignKeyColumns && self.rgForeignKeyColumnList == other.rgForeignKeyColumnList && self.pwszConstraintText == other.pwszConstraintText && self.UpdateRule == other.UpdateRule && self.DeleteRule == other.DeleteRule && self.MatchType == other.MatchType && self.Deferrability == other.Deferrability && self.cReserved == other.cReserved && self.rgReserved == other.rgReserved } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::cmp::Eq for DBCONSTRAINTDESC {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] unsafe impl ::windows::core::Abi for DBCONSTRAINTDESC { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C, packed(2))] #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub struct DBCONSTRAINTDESC { pub pConstraintID: *mut super::super::Storage::IndexServer::DBID, pub ConstraintType: u32, pub cColumns: usize, pub rgColumnList: *mut super::super::Storage::IndexServer::DBID, pub pReferencedTableID: *mut super::super::Storage::IndexServer::DBID, pub cForeignKeyColumns: usize, pub rgForeignKeyColumnList: *mut super::super::Storage::IndexServer::DBID, pub pwszConstraintText: super::super::Foundation::PWSTR, pub UpdateRule: u32, pub DeleteRule: u32, pub MatchType: u32, pub Deferrability: u32, pub cReserved: usize, pub rgReserved: *mut DBPROPSET, } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl DBCONSTRAINTDESC {} #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::default::Default for DBCONSTRAINTDESC { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::cmp::PartialEq for DBCONSTRAINTDESC { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::cmp::Eq for DBCONSTRAINTDESC {} #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] unsafe impl ::windows::core::Abi for DBCONSTRAINTDESC { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBCONSTRAINTTYPEENUM(pub i32); pub const DBCONSTRAINTTYPE_UNIQUE: DBCONSTRAINTTYPEENUM = DBCONSTRAINTTYPEENUM(0i32); pub const DBCONSTRAINTTYPE_FOREIGNKEY: DBCONSTRAINTTYPEENUM = DBCONSTRAINTTYPEENUM(1i32); pub const DBCONSTRAINTTYPE_PRIMARYKEY: DBCONSTRAINTTYPEENUM = DBCONSTRAINTTYPEENUM(2i32); pub const DBCONSTRAINTTYPE_CHECK: DBCONSTRAINTTYPEENUM = DBCONSTRAINTTYPEENUM(3i32); impl ::core::convert::From<i32> for DBCONSTRAINTTYPEENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBCONSTRAINTTYPEENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBCONVERTFLAGSENUM(pub i32); pub const DBCONVERTFLAGS_COLUMN: DBCONVERTFLAGSENUM = DBCONVERTFLAGSENUM(0i32); pub const DBCONVERTFLAGS_PARAMETER: DBCONVERTFLAGSENUM = DBCONVERTFLAGSENUM(1i32); impl ::core::convert::From<i32> for DBCONVERTFLAGSENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBCONVERTFLAGSENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBCONVERTFLAGSENUM20(pub i32); pub const DBCONVERTFLAGS_ISLONG: DBCONVERTFLAGSENUM20 = DBCONVERTFLAGSENUM20(2i32); pub const DBCONVERTFLAGS_ISFIXEDLENGTH: DBCONVERTFLAGSENUM20 = DBCONVERTFLAGSENUM20(4i32); pub const DBCONVERTFLAGS_FROMVARIANT: DBCONVERTFLAGSENUM20 = DBCONVERTFLAGSENUM20(8i32); impl ::core::convert::From<i32> for DBCONVERTFLAGSENUM20 { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBCONVERTFLAGSENUM20 { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBCOPYFLAGSENUM(pub i32); pub const DBCOPY_ASYNC: DBCOPYFLAGSENUM = DBCOPYFLAGSENUM(256i32); pub const DBCOPY_REPLACE_EXISTING: DBCOPYFLAGSENUM = DBCOPYFLAGSENUM(512i32); pub const DBCOPY_ALLOW_EMULATION: DBCOPYFLAGSENUM = DBCOPYFLAGSENUM(1024i32); pub const DBCOPY_NON_RECURSIVE: DBCOPYFLAGSENUM = DBCOPYFLAGSENUM(2048i32); pub const DBCOPY_ATOMIC: DBCOPYFLAGSENUM = DBCOPYFLAGSENUM(4096i32); impl ::core::convert::From<i32> for DBCOPYFLAGSENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBCOPYFLAGSENUM { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] pub struct DBCOST { pub eKind: u32, pub dwUnits: u32, pub lValue: i32, } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl DBCOST {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::default::Default for DBCOST { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::fmt::Debug for DBCOST { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("DBCOST").field("eKind", &self.eKind).field("dwUnits", &self.dwUnits).field("lValue", &self.lValue).finish() } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::cmp::PartialEq for DBCOST { fn eq(&self, other: &Self) -> bool { self.eKind == other.eKind && self.dwUnits == other.dwUnits && self.lValue == other.lValue } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::cmp::Eq for DBCOST {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] unsafe impl ::windows::core::Abi for DBCOST { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C, packed(2))] #[cfg(any(target_arch = "x86",))] pub struct DBCOST { pub eKind: u32, pub dwUnits: u32, pub lValue: i32, } #[cfg(any(target_arch = "x86",))] impl DBCOST {} #[cfg(any(target_arch = "x86",))] impl ::core::default::Default for DBCOST { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86",))] impl ::core::cmp::PartialEq for DBCOST { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(any(target_arch = "x86",))] impl ::core::cmp::Eq for DBCOST {} #[cfg(any(target_arch = "x86",))] unsafe impl ::windows::core::Abi for DBCOST { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBCOSTUNITENUM(pub i32); pub const DBUNIT_INVALID: DBCOSTUNITENUM = DBCOSTUNITENUM(0i32); pub const DBUNIT_WEIGHT: DBCOSTUNITENUM = DBCOSTUNITENUM(1i32); pub const DBUNIT_PERCENT: DBCOSTUNITENUM = DBCOSTUNITENUM(2i32); pub const DBUNIT_MAXIMUM: DBCOSTUNITENUM = DBCOSTUNITENUM(4i32); pub const DBUNIT_MINIMUM: DBCOSTUNITENUM = DBCOSTUNITENUM(8i32); pub const DBUNIT_MICRO_SECOND: DBCOSTUNITENUM = DBCOSTUNITENUM(16i32); pub const DBUNIT_MILLI_SECOND: DBCOSTUNITENUM = DBCOSTUNITENUM(32i32); pub const DBUNIT_SECOND: DBCOSTUNITENUM = DBCOSTUNITENUM(64i32); pub const DBUNIT_MINUTE: DBCOSTUNITENUM = DBCOSTUNITENUM(128i32); pub const DBUNIT_HOUR: DBCOSTUNITENUM = DBCOSTUNITENUM(256i32); pub const DBUNIT_BYTE: DBCOSTUNITENUM = DBCOSTUNITENUM(512i32); pub const DBUNIT_KILO_BYTE: DBCOSTUNITENUM = DBCOSTUNITENUM(1024i32); pub const DBUNIT_MEGA_BYTE: DBCOSTUNITENUM = DBCOSTUNITENUM(2048i32); pub const DBUNIT_GIGA_BYTE: DBCOSTUNITENUM = DBCOSTUNITENUM(4096i32); pub const DBUNIT_NUM_MSGS: DBCOSTUNITENUM = DBCOSTUNITENUM(8192i32); pub const DBUNIT_NUM_LOCKS: DBCOSTUNITENUM = DBCOSTUNITENUM(16384i32); pub const DBUNIT_NUM_ROWS: DBCOSTUNITENUM = DBCOSTUNITENUM(32768i32); pub const DBUNIT_OTHER: DBCOSTUNITENUM = DBCOSTUNITENUM(65536i32); impl ::core::convert::From<i32> for DBCOSTUNITENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBCOSTUNITENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBDATACONVERTENUM(pub i32); pub const DBDATACONVERT_DEFAULT: DBDATACONVERTENUM = DBDATACONVERTENUM(0i32); pub const DBDATACONVERT_SETDATABEHAVIOR: DBDATACONVERTENUM = DBDATACONVERTENUM(1i32); pub const DBDATACONVERT_LENGTHFROMNTS: DBDATACONVERTENUM = DBDATACONVERTENUM(2i32); pub const DBDATACONVERT_DSTISFIXEDLENGTH: DBDATACONVERTENUM = DBDATACONVERTENUM(4i32); pub const DBDATACONVERT_DECIMALSCALE: DBDATACONVERTENUM = DBDATACONVERTENUM(8i32); impl ::core::convert::From<i32> for DBDATACONVERTENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBDATACONVERTENUM { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] pub struct DBDATE { pub year: i16, pub month: u16, pub day: u16, } impl DBDATE {} impl ::core::default::Default for DBDATE { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } impl ::core::fmt::Debug for DBDATE { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("DBDATE").field("year", &self.year).field("month", &self.month).field("day", &self.day).finish() } } impl ::core::cmp::PartialEq for DBDATE { fn eq(&self, other: &Self) -> bool { self.year == other.year && self.month == other.month && self.day == other.day } } impl ::core::cmp::Eq for DBDATE {} unsafe impl ::windows::core::Abi for DBDATE { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBDEFERRABILITYENUM(pub i32); pub const DBDEFERRABILITY_DEFERRED: DBDEFERRABILITYENUM = DBDEFERRABILITYENUM(1i32); pub const DBDEFERRABILITY_DEFERRABLE: DBDEFERRABILITYENUM = DBDEFERRABILITYENUM(2i32); impl ::core::convert::From<i32> for DBDEFERRABILITYENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBDEFERRABILITYENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBDELETEFLAGSENUM(pub i32); pub const DBDELETE_ASYNC: DBDELETEFLAGSENUM = DBDELETEFLAGSENUM(256i32); pub const DBDELETE_ATOMIC: DBDELETEFLAGSENUM = DBDELETEFLAGSENUM(4096i32); impl ::core::convert::From<i32> for DBDELETEFLAGSENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBDELETEFLAGSENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBEVENTPHASEENUM(pub i32); pub const DBEVENTPHASE_OKTODO: DBEVENTPHASEENUM = DBEVENTPHASEENUM(0i32); pub const DBEVENTPHASE_ABOUTTODO: DBEVENTPHASEENUM = DBEVENTPHASEENUM(1i32); pub const DBEVENTPHASE_SYNCHAFTER: DBEVENTPHASEENUM = DBEVENTPHASEENUM(2i32); pub const DBEVENTPHASE_FAILEDTODO: DBEVENTPHASEENUM = DBEVENTPHASEENUM(3i32); pub const DBEVENTPHASE_DIDEVENT: DBEVENTPHASEENUM = DBEVENTPHASEENUM(4i32); impl ::core::convert::From<i32> for DBEVENTPHASEENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBEVENTPHASEENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBEXECLIMITSENUM(pub i32); pub const DBEXECLIMITS_ABORT: DBEXECLIMITSENUM = DBEXECLIMITSENUM(1i32); pub const DBEXECLIMITS_STOP: DBEXECLIMITSENUM = DBEXECLIMITSENUM(2i32); pub const DBEXECLIMITS_SUSPEND: DBEXECLIMITSENUM = DBEXECLIMITSENUM(3i32); impl ::core::convert::From<i32> for DBEXECLIMITSENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBEXECLIMITSENUM { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] pub struct DBFAILUREINFO { pub hRow: usize, pub iColumn: usize, pub failure: ::windows::core::HRESULT, } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl DBFAILUREINFO {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::default::Default for DBFAILUREINFO { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::fmt::Debug for DBFAILUREINFO { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("DBFAILUREINFO").field("hRow", &self.hRow).field("iColumn", &self.iColumn).field("failure", &self.failure).finish() } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::cmp::PartialEq for DBFAILUREINFO { fn eq(&self, other: &Self) -> bool { self.hRow == other.hRow && self.iColumn == other.iColumn && self.failure == other.failure } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::cmp::Eq for DBFAILUREINFO {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] unsafe impl ::windows::core::Abi for DBFAILUREINFO { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C, packed(2))] #[cfg(any(target_arch = "x86",))] pub struct DBFAILUREINFO { pub hRow: usize, pub iColumn: usize, pub failure: ::windows::core::HRESULT, } #[cfg(any(target_arch = "x86",))] impl DBFAILUREINFO {} #[cfg(any(target_arch = "x86",))] impl ::core::default::Default for DBFAILUREINFO { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86",))] impl ::core::cmp::PartialEq for DBFAILUREINFO { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(any(target_arch = "x86",))] impl ::core::cmp::Eq for DBFAILUREINFO {} #[cfg(any(target_arch = "x86",))] unsafe impl ::windows::core::Abi for DBFAILUREINFO { type Abi = Self; } pub const DBGUID_MSSQLXML: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x5d531cb2_e6ed_11d2_b252_00c04f681b71); pub const DBGUID_XPATH: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xec2a4293_e898_11d2_b1b7_00c04f680c56); #[derive(:: core :: clone :: Clone)] #[repr(C)] #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] pub struct DBIMPLICITSESSION { pub pUnkOuter: ::core::option::Option<::windows::core::IUnknown>, pub piid: *mut ::windows::core::GUID, pub pSession: ::core::option::Option<::windows::core::IUnknown>, } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl DBIMPLICITSESSION {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::default::Default for DBIMPLICITSESSION { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::fmt::Debug for DBIMPLICITSESSION { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("DBIMPLICITSESSION").field("pUnkOuter", &self.pUnkOuter).field("piid", &self.piid).field("pSession", &self.pSession).finish() } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::cmp::PartialEq for DBIMPLICITSESSION { fn eq(&self, other: &Self) -> bool { self.pUnkOuter == other.pUnkOuter && self.piid == other.piid && self.pSession == other.pSession } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::cmp::Eq for DBIMPLICITSESSION {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] unsafe impl ::windows::core::Abi for DBIMPLICITSESSION { type Abi = ::core::mem::ManuallyDrop<Self>; } #[cfg(any(target_arch = "x86",))] impl ::core::clone::Clone for DBIMPLICITSESSION { fn clone(&self) -> Self { unimplemented!() } } #[repr(C, packed(2))] #[cfg(any(target_arch = "x86",))] pub struct DBIMPLICITSESSION { pub pUnkOuter: ::core::option::Option<::windows::core::IUnknown>, pub piid: *mut ::windows::core::GUID, pub pSession: ::core::option::Option<::windows::core::IUnknown>, } #[cfg(any(target_arch = "x86",))] impl DBIMPLICITSESSION {} #[cfg(any(target_arch = "x86",))] impl ::core::default::Default for DBIMPLICITSESSION { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86",))] impl ::core::cmp::PartialEq for DBIMPLICITSESSION { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(any(target_arch = "x86",))] impl ::core::cmp::Eq for DBIMPLICITSESSION {} #[cfg(any(target_arch = "x86",))] unsafe impl ::windows::core::Abi for DBIMPLICITSESSION { type Abi = ::core::mem::ManuallyDrop<Self>; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub struct DBINDEXCOLUMNDESC { pub pColumnID: *mut super::super::Storage::IndexServer::DBID, pub eIndexColOrder: u32, } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] impl DBINDEXCOLUMNDESC {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] impl ::core::default::Default for DBINDEXCOLUMNDESC { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] impl ::core::fmt::Debug for DBINDEXCOLUMNDESC { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("DBINDEXCOLUMNDESC").field("pColumnID", &self.pColumnID).field("eIndexColOrder", &self.eIndexColOrder).finish() } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] impl ::core::cmp::PartialEq for DBINDEXCOLUMNDESC { fn eq(&self, other: &Self) -> bool { self.pColumnID == other.pColumnID && self.eIndexColOrder == other.eIndexColOrder } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] impl ::core::cmp::Eq for DBINDEXCOLUMNDESC {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] unsafe impl ::windows::core::Abi for DBINDEXCOLUMNDESC { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C, packed(2))] #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub struct DBINDEXCOLUMNDESC { pub pColumnID: *mut super::super::Storage::IndexServer::DBID, pub eIndexColOrder: u32, } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] impl DBINDEXCOLUMNDESC {} #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] impl ::core::default::Default for DBINDEXCOLUMNDESC { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] impl ::core::cmp::PartialEq for DBINDEXCOLUMNDESC { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] impl ::core::cmp::Eq for DBINDEXCOLUMNDESC {} #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] unsafe impl ::windows::core::Abi for DBINDEXCOLUMNDESC { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBINDEX_COL_ORDERENUM(pub i32); pub const DBINDEX_COL_ORDER_ASC: DBINDEX_COL_ORDERENUM = DBINDEX_COL_ORDERENUM(0i32); pub const DBINDEX_COL_ORDER_DESC: DBINDEX_COL_ORDERENUM = DBINDEX_COL_ORDERENUM(1i32); impl ::core::convert::From<i32> for DBINDEX_COL_ORDERENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBINDEX_COL_ORDERENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBLITERALENUM(pub i32); pub const DBLITERAL_INVALID: DBLITERALENUM = DBLITERALENUM(0i32); pub const DBLITERAL_BINARY_LITERAL: DBLITERALENUM = DBLITERALENUM(1i32); pub const DBLITERAL_CATALOG_NAME: DBLITERALENUM = DBLITERALENUM(2i32); pub const DBLITERAL_CATALOG_SEPARATOR: DBLITERALENUM = DBLITERALENUM(3i32); pub const DBLITERAL_CHAR_LITERAL: DBLITERALENUM = DBLITERALENUM(4i32); pub const DBLITERAL_COLUMN_ALIAS: DBLITERALENUM = DBLITERALENUM(5i32); pub const DBLITERAL_COLUMN_NAME: DBLITERALENUM = DBLITERALENUM(6i32); pub const DBLITERAL_CORRELATION_NAME: DBLITERALENUM = DBLITERALENUM(7i32); pub const DBLITERAL_CURSOR_NAME: DBLITERALENUM = DBLITERALENUM(8i32); pub const DBLITERAL_ESCAPE_PERCENT: DBLITERALENUM = DBLITERALENUM(9i32); pub const DBLITERAL_ESCAPE_UNDERSCORE: DBLITERALENUM = DBLITERALENUM(10i32); pub const DBLITERAL_INDEX_NAME: DBLITERALENUM = DBLITERALENUM(11i32); pub const DBLITERAL_LIKE_PERCENT: DBLITERALENUM = DBLITERALENUM(12i32); pub const DBLITERAL_LIKE_UNDERSCORE: DBLITERALENUM = DBLITERALENUM(13i32); pub const DBLITERAL_PROCEDURE_NAME: DBLITERALENUM = DBLITERALENUM(14i32); pub const DBLITERAL_QUOTE: DBLITERALENUM = DBLITERALENUM(15i32); pub const DBLITERAL_SCHEMA_NAME: DBLITERALENUM = DBLITERALENUM(16i32); pub const DBLITERAL_TABLE_NAME: DBLITERALENUM = DBLITERALENUM(17i32); pub const DBLITERAL_TEXT_COMMAND: DBLITERALENUM = DBLITERALENUM(18i32); pub const DBLITERAL_USER_NAME: DBLITERALENUM = DBLITERALENUM(19i32); pub const DBLITERAL_VIEW_NAME: DBLITERALENUM = DBLITERALENUM(20i32); impl ::core::convert::From<i32> for DBLITERALENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBLITERALENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBLITERALENUM20(pub i32); pub const DBLITERAL_CUBE_NAME: DBLITERALENUM20 = DBLITERALENUM20(21i32); pub const DBLITERAL_DIMENSION_NAME: DBLITERALENUM20 = DBLITERALENUM20(22i32); pub const DBLITERAL_HIERARCHY_NAME: DBLITERALENUM20 = DBLITERALENUM20(23i32); pub const DBLITERAL_LEVEL_NAME: DBLITERALENUM20 = DBLITERALENUM20(24i32); pub const DBLITERAL_MEMBER_NAME: DBLITERALENUM20 = DBLITERALENUM20(25i32); pub const DBLITERAL_PROPERTY_NAME: DBLITERALENUM20 = DBLITERALENUM20(26i32); pub const DBLITERAL_SCHEMA_SEPARATOR: DBLITERALENUM20 = DBLITERALENUM20(27i32); pub const DBLITERAL_QUOTE_SUFFIX: DBLITERALENUM20 = DBLITERALENUM20(28i32); impl ::core::convert::From<i32> for DBLITERALENUM20 { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBLITERALENUM20 { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBLITERALENUM21(pub i32); pub const DBLITERAL_ESCAPE_PERCENT_SUFFIX: DBLITERALENUM21 = DBLITERALENUM21(29i32); pub const DBLITERAL_ESCAPE_UNDERSCORE_SUFFIX: DBLITERALENUM21 = DBLITERALENUM21(30i32); impl ::core::convert::From<i32> for DBLITERALENUM21 { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBLITERALENUM21 { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(feature = "Win32_Foundation")] pub struct DBLITERALINFO { pub pwszLiteralValue: super::super::Foundation::PWSTR, pub pwszInvalidChars: super::super::Foundation::PWSTR, pub pwszInvalidStartingChars: super::super::Foundation::PWSTR, pub lt: u32, pub fSupported: super::super::Foundation::BOOL, pub cchMaxLen: u32, } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(feature = "Win32_Foundation")] impl DBLITERALINFO {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(feature = "Win32_Foundation")] impl ::core::default::Default for DBLITERALINFO { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(feature = "Win32_Foundation")] impl ::core::fmt::Debug for DBLITERALINFO { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("DBLITERALINFO") .field("pwszLiteralValue", &self.pwszLiteralValue) .field("pwszInvalidChars", &self.pwszInvalidChars) .field("pwszInvalidStartingChars", &self.pwszInvalidStartingChars) .field("lt", &self.lt) .field("fSupported", &self.fSupported) .field("cchMaxLen", &self.cchMaxLen) .finish() } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(feature = "Win32_Foundation")] impl ::core::cmp::PartialEq for DBLITERALINFO { fn eq(&self, other: &Self) -> bool { self.pwszLiteralValue == other.pwszLiteralValue && self.pwszInvalidChars == other.pwszInvalidChars && self.pwszInvalidStartingChars == other.pwszInvalidStartingChars && self.lt == other.lt && self.fSupported == other.fSupported && self.cchMaxLen == other.cchMaxLen } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(feature = "Win32_Foundation")] impl ::core::cmp::Eq for DBLITERALINFO {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(feature = "Win32_Foundation")] unsafe impl ::windows::core::Abi for DBLITERALINFO { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C, packed(2))] #[cfg(any(target_arch = "x86",))] #[cfg(feature = "Win32_Foundation")] pub struct DBLITERALINFO { pub pwszLiteralValue: super::super::Foundation::PWSTR, pub pwszInvalidChars: super::super::Foundation::PWSTR, pub pwszInvalidStartingChars: super::super::Foundation::PWSTR, pub lt: u32, pub fSupported: super::super::Foundation::BOOL, pub cchMaxLen: u32, } #[cfg(any(target_arch = "x86",))] #[cfg(feature = "Win32_Foundation")] impl DBLITERALINFO {} #[cfg(any(target_arch = "x86",))] #[cfg(feature = "Win32_Foundation")] impl ::core::default::Default for DBLITERALINFO { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86",))] #[cfg(feature = "Win32_Foundation")] impl ::core::cmp::PartialEq for DBLITERALINFO { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(any(target_arch = "x86",))] #[cfg(feature = "Win32_Foundation")] impl ::core::cmp::Eq for DBLITERALINFO {} #[cfg(any(target_arch = "x86",))] #[cfg(feature = "Win32_Foundation")] unsafe impl ::windows::core::Abi for DBLITERALINFO { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBMATCHTYPEENUM(pub i32); pub const DBMATCHTYPE_FULL: DBMATCHTYPEENUM = DBMATCHTYPEENUM(0i32); pub const DBMATCHTYPE_NONE: DBMATCHTYPEENUM = DBMATCHTYPEENUM(1i32); pub const DBMATCHTYPE_PARTIAL: DBMATCHTYPEENUM = DBMATCHTYPEENUM(2i32); impl ::core::convert::From<i32> for DBMATCHTYPEENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBMATCHTYPEENUM { type Abi = Self; } pub const DBMAXCHAR: u32 = 8001u32; #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBMEMOWNERENUM(pub i32); pub const DBMEMOWNER_CLIENTOWNED: DBMEMOWNERENUM = DBMEMOWNERENUM(0i32); pub const DBMEMOWNER_PROVIDEROWNED: DBMEMOWNERENUM = DBMEMOWNERENUM(1i32); impl ::core::convert::From<i32> for DBMEMOWNERENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBMEMOWNERENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBMOVEFLAGSENUM(pub i32); pub const DBMOVE_REPLACE_EXISTING: DBMOVEFLAGSENUM = DBMOVEFLAGSENUM(1i32); pub const DBMOVE_ASYNC: DBMOVEFLAGSENUM = DBMOVEFLAGSENUM(256i32); pub const DBMOVE_DONT_UPDATE_LINKS: DBMOVEFLAGSENUM = DBMOVEFLAGSENUM(512i32); pub const DBMOVE_ALLOW_EMULATION: DBMOVEFLAGSENUM = DBMOVEFLAGSENUM(1024i32); pub const DBMOVE_ATOMIC: DBMOVEFLAGSENUM = DBMOVEFLAGSENUM(4096i32); impl ::core::convert::From<i32> for DBMOVEFLAGSENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBMOVEFLAGSENUM { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] pub struct DBOBJECT { pub dwFlags: u32, pub iid: ::windows::core::GUID, } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl DBOBJECT {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::default::Default for DBOBJECT { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::fmt::Debug for DBOBJECT { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("DBOBJECT").field("dwFlags", &self.dwFlags).field("iid", &self.iid).finish() } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::cmp::PartialEq for DBOBJECT { fn eq(&self, other: &Self) -> bool { self.dwFlags == other.dwFlags && self.iid == other.iid } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::cmp::Eq for DBOBJECT {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] unsafe impl ::windows::core::Abi for DBOBJECT { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C, packed(2))] #[cfg(any(target_arch = "x86",))] pub struct DBOBJECT { pub dwFlags: u32, pub iid: ::windows::core::GUID, } #[cfg(any(target_arch = "x86",))] impl DBOBJECT {} #[cfg(any(target_arch = "x86",))] impl ::core::default::Default for DBOBJECT { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86",))] impl ::core::cmp::PartialEq for DBOBJECT { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(any(target_arch = "x86",))] impl ::core::cmp::Eq for DBOBJECT {} #[cfg(any(target_arch = "x86",))] unsafe impl ::windows::core::Abi for DBOBJECT { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(feature = "Win32_Foundation")] pub struct DBPARAMBINDINFO { pub pwszDataSourceType: super::super::Foundation::PWSTR, pub pwszName: super::super::Foundation::PWSTR, pub ulParamSize: usize, pub dwFlags: u32, pub bPrecision: u8, pub bScale: u8, } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(feature = "Win32_Foundation")] impl DBPARAMBINDINFO {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(feature = "Win32_Foundation")] impl ::core::default::Default for DBPARAMBINDINFO { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(feature = "Win32_Foundation")] impl ::core::fmt::Debug for DBPARAMBINDINFO { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("DBPARAMBINDINFO").field("pwszDataSourceType", &self.pwszDataSourceType).field("pwszName", &self.pwszName).field("ulParamSize", &self.ulParamSize).field("dwFlags", &self.dwFlags).field("bPrecision", &self.bPrecision).field("bScale", &self.bScale).finish() } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(feature = "Win32_Foundation")] impl ::core::cmp::PartialEq for DBPARAMBINDINFO { fn eq(&self, other: &Self) -> bool { self.pwszDataSourceType == other.pwszDataSourceType && self.pwszName == other.pwszName && self.ulParamSize == other.ulParamSize && self.dwFlags == other.dwFlags && self.bPrecision == other.bPrecision && self.bScale == other.bScale } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(feature = "Win32_Foundation")] impl ::core::cmp::Eq for DBPARAMBINDINFO {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(feature = "Win32_Foundation")] unsafe impl ::windows::core::Abi for DBPARAMBINDINFO { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C, packed(2))] #[cfg(any(target_arch = "x86",))] #[cfg(feature = "Win32_Foundation")] pub struct DBPARAMBINDINFO { pub pwszDataSourceType: super::super::Foundation::PWSTR, pub pwszName: super::super::Foundation::PWSTR, pub ulParamSize: usize, pub dwFlags: u32, pub bPrecision: u8, pub bScale: u8, } #[cfg(any(target_arch = "x86",))] #[cfg(feature = "Win32_Foundation")] impl DBPARAMBINDINFO {} #[cfg(any(target_arch = "x86",))] #[cfg(feature = "Win32_Foundation")] impl ::core::default::Default for DBPARAMBINDINFO { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86",))] #[cfg(feature = "Win32_Foundation")] impl ::core::cmp::PartialEq for DBPARAMBINDINFO { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(any(target_arch = "x86",))] #[cfg(feature = "Win32_Foundation")] impl ::core::cmp::Eq for DBPARAMBINDINFO {} #[cfg(any(target_arch = "x86",))] #[cfg(feature = "Win32_Foundation")] unsafe impl ::windows::core::Abi for DBPARAMBINDINFO { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBPARAMFLAGSENUM(pub i32); pub const DBPARAMFLAGS_ISINPUT: DBPARAMFLAGSENUM = DBPARAMFLAGSENUM(1i32); pub const DBPARAMFLAGS_ISOUTPUT: DBPARAMFLAGSENUM = DBPARAMFLAGSENUM(2i32); pub const DBPARAMFLAGS_ISSIGNED: DBPARAMFLAGSENUM = DBPARAMFLAGSENUM(16i32); pub const DBPARAMFLAGS_ISNULLABLE: DBPARAMFLAGSENUM = DBPARAMFLAGSENUM(64i32); pub const DBPARAMFLAGS_ISLONG: DBPARAMFLAGSENUM = DBPARAMFLAGSENUM(128i32); impl ::core::convert::From<i32> for DBPARAMFLAGSENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBPARAMFLAGSENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBPARAMFLAGSENUM20(pub i32); pub const DBPARAMFLAGS_SCALEISNEGATIVE: DBPARAMFLAGSENUM20 = DBPARAMFLAGSENUM20(256i32); impl ::core::convert::From<i32> for DBPARAMFLAGSENUM20 { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBPARAMFLAGSENUM20 { type Abi = Self; } #[derive(:: core :: clone :: Clone)] #[repr(C)] #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub struct DBPARAMINFO { pub dwFlags: u32, pub iOrdinal: usize, pub pwszName: super::super::Foundation::PWSTR, pub pTypeInfo: ::core::option::Option<super::Com::ITypeInfo>, pub ulParamSize: usize, pub wType: u16, pub bPrecision: u8, pub bScale: u8, } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl DBPARAMINFO {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::default::Default for DBPARAMINFO { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::fmt::Debug for DBPARAMINFO { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("DBPARAMINFO") .field("dwFlags", &self.dwFlags) .field("iOrdinal", &self.iOrdinal) .field("pwszName", &self.pwszName) .field("pTypeInfo", &self.pTypeInfo) .field("ulParamSize", &self.ulParamSize) .field("wType", &self.wType) .field("bPrecision", &self.bPrecision) .field("bScale", &self.bScale) .finish() } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::cmp::PartialEq for DBPARAMINFO { fn eq(&self, other: &Self) -> bool { self.dwFlags == other.dwFlags && self.iOrdinal == other.iOrdinal && self.pwszName == other.pwszName && self.pTypeInfo == other.pTypeInfo && self.ulParamSize == other.ulParamSize && self.wType == other.wType && self.bPrecision == other.bPrecision && self.bScale == other.bScale } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::cmp::Eq for DBPARAMINFO {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] unsafe impl ::windows::core::Abi for DBPARAMINFO { type Abi = ::core::mem::ManuallyDrop<Self>; } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::clone::Clone for DBPARAMINFO { fn clone(&self) -> Self { unimplemented!() } } #[repr(C, packed(2))] #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub struct DBPARAMINFO { pub dwFlags: u32, pub iOrdinal: usize, pub pwszName: super::super::Foundation::PWSTR, pub pTypeInfo: ::core::option::Option<super::Com::ITypeInfo>, pub ulParamSize: usize, pub wType: u16, pub bPrecision: u8, pub bScale: u8, } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl DBPARAMINFO {} #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::default::Default for DBPARAMINFO { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::cmp::PartialEq for DBPARAMINFO { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::cmp::Eq for DBPARAMINFO {} #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] unsafe impl ::windows::core::Abi for DBPARAMINFO { type Abi = ::core::mem::ManuallyDrop<Self>; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBPARAMIOENUM(pub i32); pub const DBPARAMIO_NOTPARAM: DBPARAMIOENUM = DBPARAMIOENUM(0i32); pub const DBPARAMIO_INPUT: DBPARAMIOENUM = DBPARAMIOENUM(1i32); pub const DBPARAMIO_OUTPUT: DBPARAMIOENUM = DBPARAMIOENUM(2i32); impl ::core::convert::From<i32> for DBPARAMIOENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBPARAMIOENUM { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] pub struct DBPARAMS { pub pData: *mut ::core::ffi::c_void, pub cParamSets: usize, pub hAccessor: usize, } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl DBPARAMS {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::default::Default for DBPARAMS { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::fmt::Debug for DBPARAMS { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("DBPARAMS").field("pData", &self.pData).field("cParamSets", &self.cParamSets).field("hAccessor", &self.hAccessor).finish() } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::cmp::PartialEq for DBPARAMS { fn eq(&self, other: &Self) -> bool { self.pData == other.pData && self.cParamSets == other.cParamSets && self.hAccessor == other.hAccessor } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::cmp::Eq for DBPARAMS {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] unsafe impl ::windows::core::Abi for DBPARAMS { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C, packed(2))] #[cfg(any(target_arch = "x86",))] pub struct DBPARAMS { pub pData: *mut ::core::ffi::c_void, pub cParamSets: usize, pub hAccessor: usize, } #[cfg(any(target_arch = "x86",))] impl DBPARAMS {} #[cfg(any(target_arch = "x86",))] impl ::core::default::Default for DBPARAMS { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86",))] impl ::core::cmp::PartialEq for DBPARAMS { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(any(target_arch = "x86",))] impl ::core::cmp::Eq for DBPARAMS {} #[cfg(any(target_arch = "x86",))] unsafe impl ::windows::core::Abi for DBPARAMS { type Abi = Self; } pub const DBPARAMTYPE_INPUT: u32 = 1u32; pub const DBPARAMTYPE_INPUTOUTPUT: u32 = 2u32; pub const DBPARAMTYPE_OUTPUT: u32 = 3u32; pub const DBPARAMTYPE_RETURNVALUE: u32 = 4u32; #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBPARTENUM(pub i32); pub const DBPART_INVALID: DBPARTENUM = DBPARTENUM(0i32); pub const DBPART_VALUE: DBPARTENUM = DBPARTENUM(1i32); pub const DBPART_LENGTH: DBPARTENUM = DBPARTENUM(2i32); pub const DBPART_STATUS: DBPARTENUM = DBPARTENUM(4i32); impl ::core::convert::From<i32> for DBPARTENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBPARTENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBPENDINGSTATUSENUM(pub i32); pub const DBPENDINGSTATUS_NEW: DBPENDINGSTATUSENUM = DBPENDINGSTATUSENUM(1i32); pub const DBPENDINGSTATUS_CHANGED: DBPENDINGSTATUSENUM = DBPENDINGSTATUSENUM(2i32); pub const DBPENDINGSTATUS_DELETED: DBPENDINGSTATUSENUM = DBPENDINGSTATUSENUM(4i32); pub const DBPENDINGSTATUS_UNCHANGED: DBPENDINGSTATUSENUM = DBPENDINGSTATUSENUM(8i32); pub const DBPENDINGSTATUS_INVALIDROW: DBPENDINGSTATUSENUM = DBPENDINGSTATUSENUM(16i32); impl ::core::convert::From<i32> for DBPENDINGSTATUSENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBPENDINGSTATUSENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBPOSITIONFLAGSENUM(pub i32); pub const DBPOSITION_OK: DBPOSITIONFLAGSENUM = DBPOSITIONFLAGSENUM(0i32); pub const DBPOSITION_NOROW: DBPOSITIONFLAGSENUM = DBPOSITIONFLAGSENUM(1i32); pub const DBPOSITION_BOF: DBPOSITIONFLAGSENUM = DBPOSITIONFLAGSENUM(2i32); pub const DBPOSITION_EOF: DBPOSITIONFLAGSENUM = DBPOSITIONFLAGSENUM(3i32); impl ::core::convert::From<i32> for DBPOSITIONFLAGSENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBPOSITIONFLAGSENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBPROMPTOPTIONSENUM(pub i32); pub const DBPROMPTOPTIONS_NONE: DBPROMPTOPTIONSENUM = DBPROMPTOPTIONSENUM(0i32); pub const DBPROMPTOPTIONS_WIZARDSHEET: DBPROMPTOPTIONSENUM = DBPROMPTOPTIONSENUM(1i32); pub const DBPROMPTOPTIONS_PROPERTYSHEET: DBPROMPTOPTIONSENUM = DBPROMPTOPTIONSENUM(2i32); pub const DBPROMPTOPTIONS_BROWSEONLY: DBPROMPTOPTIONSENUM = DBPROMPTOPTIONSENUM(8i32); pub const DBPROMPTOPTIONS_DISABLE_PROVIDER_SELECTION: DBPROMPTOPTIONSENUM = DBPROMPTOPTIONSENUM(16i32); pub const DBPROMPTOPTIONS_DISABLESAVEPASSWORD: DBPROMPTOPTIONSENUM = DBPROMPTOPTIONSENUM(32i32); impl ::core::convert::From<i32> for DBPROMPTOPTIONSENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBPROMPTOPTIONSENUM { type Abi = Self; } pub const DBPROMPT_COMPLETE: u32 = 2u32; pub const DBPROMPT_COMPLETEREQUIRED: u32 = 3u32; pub const DBPROMPT_NOPROMPT: u32 = 4u32; pub const DBPROMPT_PROMPT: u32 = 1u32; #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::clone::Clone for DBPROP { fn clone(&self) -> Self { unimplemented!() } } #[repr(C)] #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub struct DBPROP { pub dwPropertyID: u32, pub dwOptions: u32, pub dwStatus: u32, pub colid: super::super::Storage::IndexServer::DBID, pub vValue: super::Com::VARIANT, } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl DBPROP {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::default::Default for DBPROP { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::cmp::PartialEq for DBPROP { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::cmp::Eq for DBPROP {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] unsafe impl ::windows::core::Abi for DBPROP { type Abi = ::core::mem::ManuallyDrop<Self>; } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::clone::Clone for DBPROP { fn clone(&self) -> Self { unimplemented!() } } #[repr(C, packed(2))] #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub struct DBPROP { pub dwPropertyID: u32, pub dwOptions: u32, pub dwStatus: u32, pub colid: super::super::Storage::IndexServer::DBID, pub vValue: super::Com::VARIANT, } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl DBPROP {} #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::default::Default for DBPROP { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::cmp::PartialEq for DBPROP { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::cmp::Eq for DBPROP {} #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] unsafe impl ::windows::core::Abi for DBPROP { type Abi = ::core::mem::ManuallyDrop<Self>; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBPROPENUM(pub i32); pub const DBPROP_ABORTPRESERVE: DBPROPENUM = DBPROPENUM(2i32); pub const DBPROP_ACTIVESESSIONS: DBPROPENUM = DBPROPENUM(3i32); pub const DBPROP_APPENDONLY: DBPROPENUM = DBPROPENUM(187i32); pub const DBPROP_ASYNCTXNABORT: DBPROPENUM = DBPROPENUM(168i32); pub const DBPROP_ASYNCTXNCOMMIT: DBPROPENUM = DBPROPENUM(4i32); pub const DBPROP_AUTH_CACHE_AUTHINFO: DBPROPENUM = DBPROPENUM(5i32); pub const DBPROP_AUTH_ENCRYPT_PASSWORD: DBPROPENUM = DBPROPENUM(6i32); pub const DBPROP_AUTH_INTEGRATED: DBPROPENUM = DBPROPENUM(7i32); pub const DBPROP_AUTH_MASK_PASSWORD: DBPROPENUM = DBPROPENUM(8i32); pub const DBPROP_AUTH_PASSWORD: DBPROPENUM = DBPROPENUM(9i32); pub const DBPROP_AUTH_PERSIST_ENCRYPTED: DBPROPENUM = DBPROPENUM(10i32); pub const DBPROP_AUTH_PERSIST_SENSITIVE_AUTHINFO: DBPROPENUM = DBPROPENUM(11i32); pub const DBPROP_AUTH_USERID: DBPROPENUM = DBPROPENUM(12i32); pub const DBPROP_BLOCKINGSTORAGEOBJECTS: DBPROPENUM = DBPROPENUM(13i32); pub const DBPROP_BOOKMARKS: DBPROPENUM = DBPROPENUM(14i32); pub const DBPROP_BOOKMARKSKIPPED: DBPROPENUM = DBPROPENUM(15i32); pub const DBPROP_BOOKMARKTYPE: DBPROPENUM = DBPROPENUM(16i32); pub const DBPROP_BYREFACCESSORS: DBPROPENUM = DBPROPENUM(120i32); pub const DBPROP_CACHEDEFERRED: DBPROPENUM = DBPROPENUM(17i32); pub const DBPROP_CANFETCHBACKWARDS: DBPROPENUM = DBPROPENUM(18i32); pub const DBPROP_CANHOLDROWS: DBPROPENUM = DBPROPENUM(19i32); pub const DBPROP_CANSCROLLBACKWARDS: DBPROPENUM = DBPROPENUM(21i32); pub const DBPROP_CATALOGLOCATION: DBPROPENUM = DBPROPENUM(22i32); pub const DBPROP_CATALOGTERM: DBPROPENUM = DBPROPENUM(23i32); pub const DBPROP_CATALOGUSAGE: DBPROPENUM = DBPROPENUM(24i32); pub const DBPROP_CHANGEINSERTEDROWS: DBPROPENUM = DBPROPENUM(188i32); pub const DBPROP_COL_AUTOINCREMENT: DBPROPENUM = DBPROPENUM(26i32); pub const DBPROP_COL_DEFAULT: DBPROPENUM = DBPROPENUM(27i32); pub const DBPROP_COL_DESCRIPTION: DBPROPENUM = DBPROPENUM(28i32); pub const DBPROP_COL_FIXEDLENGTH: DBPROPENUM = DBPROPENUM(167i32); pub const DBPROP_COL_NULLABLE: DBPROPENUM = DBPROPENUM(29i32); pub const DBPROP_COL_PRIMARYKEY: DBPROPENUM = DBPROPENUM(30i32); pub const DBPROP_COL_UNIQUE: DBPROPENUM = DBPROPENUM(31i32); pub const DBPROP_COLUMNDEFINITION: DBPROPENUM = DBPROPENUM(32i32); pub const DBPROP_COLUMNRESTRICT: DBPROPENUM = DBPROPENUM(33i32); pub const DBPROP_COMMANDTIMEOUT: DBPROPENUM = DBPROPENUM(34i32); pub const DBPROP_COMMITPRESERVE: DBPROPENUM = DBPROPENUM(35i32); pub const DBPROP_CONCATNULLBEHAVIOR: DBPROPENUM = DBPROPENUM(36i32); pub const DBPROP_CURRENTCATALOG: DBPROPENUM = DBPROPENUM(37i32); pub const DBPROP_DATASOURCENAME: DBPROPENUM = DBPROPENUM(38i32); pub const DBPROP_DATASOURCEREADONLY: DBPROPENUM = DBPROPENUM(39i32); pub const DBPROP_DBMSNAME: DBPROPENUM = DBPROPENUM(40i32); pub const DBPROP_DBMSVER: DBPROPENUM = DBPROPENUM(41i32); pub const DBPROP_DEFERRED: DBPROPENUM = DBPROPENUM(42i32); pub const DBPROP_DELAYSTORAGEOBJECTS: DBPROPENUM = DBPROPENUM(43i32); pub const DBPROP_DSOTHREADMODEL: DBPROPENUM = DBPROPENUM(169i32); pub const DBPROP_GROUPBY: DBPROPENUM = DBPROPENUM(44i32); pub const DBPROP_HETEROGENEOUSTABLES: DBPROPENUM = DBPROPENUM(45i32); pub const DBPROP_IAccessor: DBPROPENUM = DBPROPENUM(121i32); pub const DBPROP_IColumnsInfo: DBPROPENUM = DBPROPENUM(122i32); pub const DBPROP_IColumnsRowset: DBPROPENUM = DBPROPENUM(123i32); pub const DBPROP_IConnectionPointContainer: DBPROPENUM = DBPROPENUM(124i32); pub const DBPROP_IConvertType: DBPROPENUM = DBPROPENUM(194i32); pub const DBPROP_IRowset: DBPROPENUM = DBPROPENUM(126i32); pub const DBPROP_IRowsetChange: DBPROPENUM = DBPROPENUM(127i32); pub const DBPROP_IRowsetIdentity: DBPROPENUM = DBPROPENUM(128i32); pub const DBPROP_IRowsetIndex: DBPROPENUM = DBPROPENUM(159i32); pub const DBPROP_IRowsetInfo: DBPROPENUM = DBPROPENUM(129i32); pub const DBPROP_IRowsetLocate: DBPROPENUM = DBPROPENUM(130i32); pub const DBPROP_IRowsetResynch: DBPROPENUM = DBPROPENUM(132i32); pub const DBPROP_IRowsetScroll: DBPROPENUM = DBPROPENUM(133i32); pub const DBPROP_IRowsetUpdate: DBPROPENUM = DBPROPENUM(134i32); pub const DBPROP_ISupportErrorInfo: DBPROPENUM = DBPROPENUM(135i32); pub const DBPROP_ILockBytes: DBPROPENUM = DBPROPENUM(136i32); pub const DBPROP_ISequentialStream: DBPROPENUM = DBPROPENUM(137i32); pub const DBPROP_IStorage: DBPROPENUM = DBPROPENUM(138i32); pub const DBPROP_IStream: DBPROPENUM = DBPROPENUM(139i32); pub const DBPROP_IDENTIFIERCASE: DBPROPENUM = DBPROPENUM(46i32); pub const DBPROP_IMMOBILEROWS: DBPROPENUM = DBPROPENUM(47i32); pub const DBPROP_INDEX_AUTOUPDATE: DBPROPENUM = DBPROPENUM(48i32); pub const DBPROP_INDEX_CLUSTERED: DBPROPENUM = DBPROPENUM(49i32); pub const DBPROP_INDEX_FILLFACTOR: DBPROPENUM = DBPROPENUM(50i32); pub const DBPROP_INDEX_INITIALSIZE: DBPROPENUM = DBPROPENUM(51i32); pub const DBPROP_INDEX_NULLCOLLATION: DBPROPENUM = DBPROPENUM(52i32); pub const DBPROP_INDEX_NULLS: DBPROPENUM = DBPROPENUM(53i32); pub const DBPROP_INDEX_PRIMARYKEY: DBPROPENUM = DBPROPENUM(54i32); pub const DBPROP_INDEX_SORTBOOKMARKS: DBPROPENUM = DBPROPENUM(55i32); pub const DBPROP_INDEX_TEMPINDEX: DBPROPENUM = DBPROPENUM(163i32); pub const DBPROP_INDEX_TYPE: DBPROPENUM = DBPROPENUM(56i32); pub const DBPROP_INDEX_UNIQUE: DBPROPENUM = DBPROPENUM(57i32); pub const DBPROP_INIT_DATASOURCE: DBPROPENUM = DBPROPENUM(59i32); pub const DBPROP_INIT_HWND: DBPROPENUM = DBPROPENUM(60i32); pub const DBPROP_INIT_IMPERSONATION_LEVEL: DBPROPENUM = DBPROPENUM(61i32); pub const DBPROP_INIT_LCID: DBPROPENUM = DBPROPENUM(186i32); pub const DBPROP_INIT_LOCATION: DBPROPENUM = DBPROPENUM(62i32); pub const DBPROP_INIT_MODE: DBPROPENUM = DBPROPENUM(63i32); pub const DBPROP_INIT_PROMPT: DBPROPENUM = DBPROPENUM(64i32); pub const DBPROP_INIT_PROTECTION_LEVEL: DBPROPENUM = DBPROPENUM(65i32); pub const DBPROP_INIT_PROVIDERSTRING: DBPROPENUM = DBPROPENUM(160i32); pub const DBPROP_INIT_TIMEOUT: DBPROPENUM = DBPROPENUM(66i32); pub const DBPROP_LITERALBOOKMARKS: DBPROPENUM = DBPROPENUM(67i32); pub const DBPROP_LITERALIDENTITY: DBPROPENUM = DBPROPENUM(68i32); pub const DBPROP_MAXINDEXSIZE: DBPROPENUM = DBPROPENUM(70i32); pub const DBPROP_MAXOPENROWS: DBPROPENUM = DBPROPENUM(71i32); pub const DBPROP_MAXPENDINGROWS: DBPROPENUM = DBPROPENUM(72i32); pub const DBPROP_MAXROWS: DBPROPENUM = DBPROPENUM(73i32); pub const DBPROP_MAXROWSIZE: DBPROPENUM = DBPROPENUM(74i32); pub const DBPROP_MAXROWSIZEINCLUDESBLOB: DBPROPENUM = DBPROPENUM(75i32); pub const DBPROP_MAXTABLESINSELECT: DBPROPENUM = DBPROPENUM(76i32); pub const DBPROP_MAYWRITECOLUMN: DBPROPENUM = DBPROPENUM(77i32); pub const DBPROP_MEMORYUSAGE: DBPROPENUM = DBPROPENUM(78i32); pub const DBPROP_MULTIPLEPARAMSETS: DBPROPENUM = DBPROPENUM(191i32); pub const DBPROP_MULTIPLERESULTS: DBPROPENUM = DBPROPENUM(196i32); pub const DBPROP_MULTIPLESTORAGEOBJECTS: DBPROPENUM = DBPROPENUM(80i32); pub const DBPROP_MULTITABLEUPDATE: DBPROPENUM = DBPROPENUM(81i32); pub const DBPROP_NOTIFICATIONGRANULARITY: DBPROPENUM = DBPROPENUM(198i32); pub const DBPROP_NOTIFICATIONPHASES: DBPROPENUM = DBPROPENUM(82i32); pub const DBPROP_NOTIFYCOLUMNSET: DBPROPENUM = DBPROPENUM(171i32); pub const DBPROP_NOTIFYROWDELETE: DBPROPENUM = DBPROPENUM(173i32); pub const DBPROP_NOTIFYROWFIRSTCHANGE: DBPROPENUM = DBPROPENUM(174i32); pub const DBPROP_NOTIFYROWINSERT: DBPROPENUM = DBPROPENUM(175i32); pub const DBPROP_NOTIFYROWRESYNCH: DBPROPENUM = DBPROPENUM(177i32); pub const DBPROP_NOTIFYROWSETCHANGED: DBPROPENUM = DBPROPENUM(211i32); pub const DBPROP_NOTIFYROWSETRELEASE: DBPROPENUM = DBPROPENUM(178i32); pub const DBPROP_NOTIFYROWSETFETCHPOSITIONCHANGE: DBPROPENUM = DBPROPENUM(179i32); pub const DBPROP_NOTIFYROWUNDOCHANGE: DBPROPENUM = DBPROPENUM(180i32); pub const DBPROP_NOTIFYROWUNDODELETE: DBPROPENUM = DBPROPENUM(181i32); pub const DBPROP_NOTIFYROWUNDOINSERT: DBPROPENUM = DBPROPENUM(182i32); pub const DBPROP_NOTIFYROWUPDATE: DBPROPENUM = DBPROPENUM(183i32); pub const DBPROP_NULLCOLLATION: DBPROPENUM = DBPROPENUM(83i32); pub const DBPROP_OLEOBJECTS: DBPROPENUM = DBPROPENUM(84i32); pub const DBPROP_ORDERBYCOLUMNSINSELECT: DBPROPENUM = DBPROPENUM(85i32); pub const DBPROP_ORDEREDBOOKMARKS: DBPROPENUM = DBPROPENUM(86i32); pub const DBPROP_OTHERINSERT: DBPROPENUM = DBPROPENUM(87i32); pub const DBPROP_OTHERUPDATEDELETE: DBPROPENUM = DBPROPENUM(88i32); pub const DBPROP_OUTPUTPARAMETERAVAILABILITY: DBPROPENUM = DBPROPENUM(184i32); pub const DBPROP_OWNINSERT: DBPROPENUM = DBPROPENUM(89i32); pub const DBPROP_OWNUPDATEDELETE: DBPROPENUM = DBPROPENUM(90i32); pub const DBPROP_PERSISTENTIDTYPE: DBPROPENUM = DBPROPENUM(185i32); pub const DBPROP_PREPAREABORTBEHAVIOR: DBPROPENUM = DBPROPENUM(91i32); pub const DBPROP_PREPARECOMMITBEHAVIOR: DBPROPENUM = DBPROPENUM(92i32); pub const DBPROP_PROCEDURETERM: DBPROPENUM = DBPROPENUM(93i32); pub const DBPROP_PROVIDERNAME: DBPROPENUM = DBPROPENUM(96i32); pub const DBPROP_PROVIDEROLEDBVER: DBPROPENUM = DBPROPENUM(97i32); pub const DBPROP_PROVIDERVER: DBPROPENUM = DBPROPENUM(98i32); pub const DBPROP_QUICKRESTART: DBPROPENUM = DBPROPENUM(99i32); pub const DBPROP_QUOTEDIDENTIFIERCASE: DBPROPENUM = DBPROPENUM(100i32); pub const DBPROP_REENTRANTEVENTS: DBPROPENUM = DBPROPENUM(101i32); pub const DBPROP_REMOVEDELETED: DBPROPENUM = DBPROPENUM(102i32); pub const DBPROP_REPORTMULTIPLECHANGES: DBPROPENUM = DBPROPENUM(103i32); pub const DBPROP_RETURNPENDINGINSERTS: DBPROPENUM = DBPROPENUM(189i32); pub const DBPROP_ROWRESTRICT: DBPROPENUM = DBPROPENUM(104i32); pub const DBPROP_ROWSETCONVERSIONSONCOMMAND: DBPROPENUM = DBPROPENUM(192i32); pub const DBPROP_ROWTHREADMODEL: DBPROPENUM = DBPROPENUM(105i32); pub const DBPROP_SCHEMATERM: DBPROPENUM = DBPROPENUM(106i32); pub const DBPROP_SCHEMAUSAGE: DBPROPENUM = DBPROPENUM(107i32); pub const DBPROP_SERVERCURSOR: DBPROPENUM = DBPROPENUM(108i32); pub const DBPROP_SESS_AUTOCOMMITISOLEVELS: DBPROPENUM = DBPROPENUM(190i32); pub const DBPROP_SQLSUPPORT: DBPROPENUM = DBPROPENUM(109i32); pub const DBPROP_STRONGIDENTITY: DBPROPENUM = DBPROPENUM(119i32); pub const DBPROP_STRUCTUREDSTORAGE: DBPROPENUM = DBPROPENUM(111i32); pub const DBPROP_SUBQUERIES: DBPROPENUM = DBPROPENUM(112i32); pub const DBPROP_SUPPORTEDTXNDDL: DBPROPENUM = DBPROPENUM(161i32); pub const DBPROP_SUPPORTEDTXNISOLEVELS: DBPROPENUM = DBPROPENUM(113i32); pub const DBPROP_SUPPORTEDTXNISORETAIN: DBPROPENUM = DBPROPENUM(114i32); pub const DBPROP_TABLETERM: DBPROPENUM = DBPROPENUM(115i32); pub const DBPROP_TBL_TEMPTABLE: DBPROPENUM = DBPROPENUM(140i32); pub const DBPROP_TRANSACTEDOBJECT: DBPROPENUM = DBPROPENUM(116i32); pub const DBPROP_UPDATABILITY: DBPROPENUM = DBPROPENUM(117i32); pub const DBPROP_USERNAME: DBPROPENUM = DBPROPENUM(118i32); impl ::core::convert::From<i32> for DBPROPENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBPROPENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBPROPENUM15(pub i32); pub const DBPROP_FILTERCOMPAREOPS: DBPROPENUM15 = DBPROPENUM15(209i32); pub const DBPROP_FINDCOMPAREOPS: DBPROPENUM15 = DBPROPENUM15(210i32); pub const DBPROP_IChapteredRowset: DBPROPENUM15 = DBPROPENUM15(202i32); pub const DBPROP_IDBAsynchStatus: DBPROPENUM15 = DBPROPENUM15(203i32); pub const DBPROP_IRowsetFind: DBPROPENUM15 = DBPROPENUM15(204i32); pub const DBPROP_IRowsetView: DBPROPENUM15 = DBPROPENUM15(212i32); pub const DBPROP_IViewChapter: DBPROPENUM15 = DBPROPENUM15(213i32); pub const DBPROP_IViewFilter: DBPROPENUM15 = DBPROPENUM15(214i32); pub const DBPROP_IViewRowset: DBPROPENUM15 = DBPROPENUM15(215i32); pub const DBPROP_IViewSort: DBPROPENUM15 = DBPROPENUM15(216i32); pub const DBPROP_INIT_ASYNCH: DBPROPENUM15 = DBPROPENUM15(200i32); pub const DBPROP_MAXOPENCHAPTERS: DBPROPENUM15 = DBPROPENUM15(199i32); pub const DBPROP_MAXORSINFILTER: DBPROPENUM15 = DBPROPENUM15(205i32); pub const DBPROP_MAXSORTCOLUMNS: DBPROPENUM15 = DBPROPENUM15(206i32); pub const DBPROP_ROWSET_ASYNCH: DBPROPENUM15 = DBPROPENUM15(201i32); pub const DBPROP_SORTONINDEX: DBPROPENUM15 = DBPROPENUM15(207i32); impl ::core::convert::From<i32> for DBPROPENUM15 { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBPROPENUM15 { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBPROPENUM20(pub i32); pub const DBPROP_IMultipleResults: DBPROPENUM20 = DBPROPENUM20(217i32); pub const DBPROP_DATASOURCE_TYPE: DBPROPENUM20 = DBPROPENUM20(251i32); pub const MDPROP_AXES: DBPROPENUM20 = DBPROPENUM20(252i32); pub const MDPROP_FLATTENING_SUPPORT: DBPROPENUM20 = DBPROPENUM20(253i32); pub const MDPROP_MDX_JOINCUBES: DBPROPENUM20 = DBPROPENUM20(254i32); pub const MDPROP_NAMED_LEVELS: DBPROPENUM20 = DBPROPENUM20(255i32); pub const MDPROP_RANGEROWSET: DBPROPENUM20 = DBPROPENUM20(256i32); pub const MDPROP_MDX_SLICER: DBPROPENUM20 = DBPROPENUM20(218i32); pub const MDPROP_MDX_CUBEQUALIFICATION: DBPROPENUM20 = DBPROPENUM20(219i32); pub const MDPROP_MDX_OUTERREFERENCE: DBPROPENUM20 = DBPROPENUM20(220i32); pub const MDPROP_MDX_QUERYBYPROPERTY: DBPROPENUM20 = DBPROPENUM20(221i32); pub const MDPROP_MDX_CASESUPPORT: DBPROPENUM20 = DBPROPENUM20(222i32); pub const MDPROP_MDX_STRING_COMPOP: DBPROPENUM20 = DBPROPENUM20(224i32); pub const MDPROP_MDX_DESCFLAGS: DBPROPENUM20 = DBPROPENUM20(225i32); pub const MDPROP_MDX_SET_FUNCTIONS: DBPROPENUM20 = DBPROPENUM20(226i32); pub const MDPROP_MDX_MEMBER_FUNCTIONS: DBPROPENUM20 = DBPROPENUM20(227i32); pub const MDPROP_MDX_NUMERIC_FUNCTIONS: DBPROPENUM20 = DBPROPENUM20(228i32); pub const MDPROP_MDX_FORMULAS: DBPROPENUM20 = DBPROPENUM20(229i32); pub const MDPROP_AGGREGATECELL_UPDATE: DBPROPENUM20 = DBPROPENUM20(230i32); pub const MDPROP_MDX_AGGREGATECELL_UPDATE: DBPROPENUM20 = DBPROPENUM20(230i32); pub const MDPROP_MDX_OBJQUALIFICATION: DBPROPENUM20 = DBPROPENUM20(261i32); pub const MDPROP_MDX_NONMEASURE_EXPRESSIONS: DBPROPENUM20 = DBPROPENUM20(262i32); pub const DBPROP_ACCESSORDER: DBPROPENUM20 = DBPROPENUM20(231i32); pub const DBPROP_BOOKMARKINFO: DBPROPENUM20 = DBPROPENUM20(232i32); pub const DBPROP_INIT_CATALOG: DBPROPENUM20 = DBPROPENUM20(233i32); pub const DBPROP_ROW_BULKOPS: DBPROPENUM20 = DBPROPENUM20(234i32); pub const DBPROP_PROVIDERFRIENDLYNAME: DBPROPENUM20 = DBPROPENUM20(235i32); pub const DBPROP_LOCKMODE: DBPROPENUM20 = DBPROPENUM20(236i32); pub const DBPROP_MULTIPLECONNECTIONS: DBPROPENUM20 = DBPROPENUM20(237i32); pub const DBPROP_UNIQUEROWS: DBPROPENUM20 = DBPROPENUM20(238i32); pub const DBPROP_SERVERDATAONINSERT: DBPROPENUM20 = DBPROPENUM20(239i32); pub const DBPROP_STORAGEFLAGS: DBPROPENUM20 = DBPROPENUM20(240i32); pub const DBPROP_CONNECTIONSTATUS: DBPROPENUM20 = DBPROPENUM20(244i32); pub const DBPROP_ALTERCOLUMN: DBPROPENUM20 = DBPROPENUM20(245i32); pub const DBPROP_COLUMNLCID: DBPROPENUM20 = DBPROPENUM20(246i32); pub const DBPROP_RESETDATASOURCE: DBPROPENUM20 = DBPROPENUM20(247i32); pub const DBPROP_INIT_OLEDBSERVICES: DBPROPENUM20 = DBPROPENUM20(248i32); pub const DBPROP_IRowsetRefresh: DBPROPENUM20 = DBPROPENUM20(249i32); pub const DBPROP_SERVERNAME: DBPROPENUM20 = DBPROPENUM20(250i32); pub const DBPROP_IParentRowset: DBPROPENUM20 = DBPROPENUM20(257i32); pub const DBPROP_HIDDENCOLUMNS: DBPROPENUM20 = DBPROPENUM20(258i32); pub const DBPROP_PROVIDERMEMORY: DBPROPENUM20 = DBPROPENUM20(259i32); pub const DBPROP_CLIENTCURSOR: DBPROPENUM20 = DBPROPENUM20(260i32); impl ::core::convert::From<i32> for DBPROPENUM20 { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBPROPENUM20 { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBPROPENUM21(pub i32); pub const DBPROP_TRUSTEE_USERNAME: DBPROPENUM21 = DBPROPENUM21(241i32); pub const DBPROP_TRUSTEE_AUTHENTICATION: DBPROPENUM21 = DBPROPENUM21(242i32); pub const DBPROP_TRUSTEE_NEWAUTHENTICATION: DBPROPENUM21 = DBPROPENUM21(243i32); pub const DBPROP_IRow: DBPROPENUM21 = DBPROPENUM21(263i32); pub const DBPROP_IRowChange: DBPROPENUM21 = DBPROPENUM21(264i32); pub const DBPROP_IRowSchemaChange: DBPROPENUM21 = DBPROPENUM21(265i32); pub const DBPROP_IGetRow: DBPROPENUM21 = DBPROPENUM21(266i32); pub const DBPROP_IScopedOperations: DBPROPENUM21 = DBPROPENUM21(267i32); pub const DBPROP_IBindResource: DBPROPENUM21 = DBPROPENUM21(268i32); pub const DBPROP_ICreateRow: DBPROPENUM21 = DBPROPENUM21(269i32); pub const DBPROP_INIT_BINDFLAGS: DBPROPENUM21 = DBPROPENUM21(270i32); pub const DBPROP_INIT_LOCKOWNER: DBPROPENUM21 = DBPROPENUM21(271i32); pub const DBPROP_GENERATEURL: DBPROPENUM21 = DBPROPENUM21(273i32); pub const DBPROP_IDBBinderProperties: DBPROPENUM21 = DBPROPENUM21(274i32); pub const DBPROP_IColumnsInfo2: DBPROPENUM21 = DBPROPENUM21(275i32); pub const DBPROP_IRegisterProvider: DBPROPENUM21 = DBPROPENUM21(276i32); pub const DBPROP_IGetSession: DBPROPENUM21 = DBPROPENUM21(277i32); pub const DBPROP_IGetSourceRow: DBPROPENUM21 = DBPROPENUM21(278i32); pub const DBPROP_IRowsetCurrentIndex: DBPROPENUM21 = DBPROPENUM21(279i32); pub const DBPROP_OPENROWSETSUPPORT: DBPROPENUM21 = DBPROPENUM21(280i32); pub const DBPROP_COL_ISLONG: DBPROPENUM21 = DBPROPENUM21(281i32); impl ::core::convert::From<i32> for DBPROPENUM21 { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBPROPENUM21 { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBPROPENUM25(pub i32); pub const DBPROP_COL_SEED: DBPROPENUM25 = DBPROPENUM25(282i32); pub const DBPROP_COL_INCREMENT: DBPROPENUM25 = DBPROPENUM25(283i32); pub const DBPROP_INIT_GENERALTIMEOUT: DBPROPENUM25 = DBPROPENUM25(284i32); pub const DBPROP_COMSERVICES: DBPROPENUM25 = DBPROPENUM25(285i32); impl ::core::convert::From<i32> for DBPROPENUM25 { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBPROPENUM25 { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBPROPENUM25_DEPRECATED(pub i32); pub const DBPROP_ICommandCost: DBPROPENUM25_DEPRECATED = DBPROPENUM25_DEPRECATED(141i32); pub const DBPROP_ICommandTree: DBPROPENUM25_DEPRECATED = DBPROPENUM25_DEPRECATED(142i32); pub const DBPROP_ICommandValidate: DBPROPENUM25_DEPRECATED = DBPROPENUM25_DEPRECATED(143i32); pub const DBPROP_IDBSchemaCommand: DBPROPENUM25_DEPRECATED = DBPROPENUM25_DEPRECATED(144i32); pub const DBPROP_IProvideMoniker: DBPROPENUM25_DEPRECATED = DBPROPENUM25_DEPRECATED(125i32); pub const DBPROP_IQuery: DBPROPENUM25_DEPRECATED = DBPROPENUM25_DEPRECATED(146i32); pub const DBPROP_IReadData: DBPROPENUM25_DEPRECATED = DBPROPENUM25_DEPRECATED(147i32); pub const DBPROP_IRowsetAsynch: DBPROPENUM25_DEPRECATED = DBPROPENUM25_DEPRECATED(148i32); pub const DBPROP_IRowsetCopyRows: DBPROPENUM25_DEPRECATED = DBPROPENUM25_DEPRECATED(149i32); pub const DBPROP_IRowsetKeys: DBPROPENUM25_DEPRECATED = DBPROPENUM25_DEPRECATED(151i32); pub const DBPROP_IRowsetNewRowAfter: DBPROPENUM25_DEPRECATED = DBPROPENUM25_DEPRECATED(152i32); pub const DBPROP_IRowsetNextRowset: DBPROPENUM25_DEPRECATED = DBPROPENUM25_DEPRECATED(153i32); pub const DBPROP_IRowsetWatchAll: DBPROPENUM25_DEPRECATED = DBPROPENUM25_DEPRECATED(155i32); pub const DBPROP_IRowsetWatchNotify: DBPROPENUM25_DEPRECATED = DBPROPENUM25_DEPRECATED(156i32); pub const DBPROP_IRowsetWatchRegion: DBPROPENUM25_DEPRECATED = DBPROPENUM25_DEPRECATED(157i32); pub const DBPROP_IRowsetWithParameters: DBPROPENUM25_DEPRECATED = DBPROPENUM25_DEPRECATED(158i32); impl ::core::convert::From<i32> for DBPROPENUM25_DEPRECATED { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBPROPENUM25_DEPRECATED { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBPROPENUM26(pub i32); pub const DBPROP_OUTPUTSTREAM: DBPROPENUM26 = DBPROPENUM26(286i32); pub const DBPROP_OUTPUTENCODING: DBPROPENUM26 = DBPROPENUM26(287i32); pub const DBPROP_TABLESTATISTICS: DBPROPENUM26 = DBPROPENUM26(288i32); pub const DBPROP_SKIPROWCOUNTRESULTS: DBPROPENUM26 = DBPROPENUM26(291i32); pub const DBPROP_IRowsetBookmark: DBPROPENUM26 = DBPROPENUM26(292i32); pub const MDPROP_VISUALMODE: DBPROPENUM26 = DBPROPENUM26(293i32); impl ::core::convert::From<i32> for DBPROPENUM26 { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBPROPENUM26 { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBPROPFLAGSENUM(pub i32); pub const DBPROPFLAGS_NOTSUPPORTED: DBPROPFLAGSENUM = DBPROPFLAGSENUM(0i32); pub const DBPROPFLAGS_COLUMN: DBPROPFLAGSENUM = DBPROPFLAGSENUM(1i32); pub const DBPROPFLAGS_DATASOURCE: DBPROPFLAGSENUM = DBPROPFLAGSENUM(2i32); pub const DBPROPFLAGS_DATASOURCECREATE: DBPROPFLAGSENUM = DBPROPFLAGSENUM(4i32); pub const DBPROPFLAGS_DATASOURCEINFO: DBPROPFLAGSENUM = DBPROPFLAGSENUM(8i32); pub const DBPROPFLAGS_DBINIT: DBPROPFLAGSENUM = DBPROPFLAGSENUM(16i32); pub const DBPROPFLAGS_INDEX: DBPROPFLAGSENUM = DBPROPFLAGSENUM(32i32); pub const DBPROPFLAGS_ROWSET: DBPROPFLAGSENUM = DBPROPFLAGSENUM(64i32); pub const DBPROPFLAGS_TABLE: DBPROPFLAGSENUM = DBPROPFLAGSENUM(128i32); pub const DBPROPFLAGS_COLUMNOK: DBPROPFLAGSENUM = DBPROPFLAGSENUM(256i32); pub const DBPROPFLAGS_READ: DBPROPFLAGSENUM = DBPROPFLAGSENUM(512i32); pub const DBPROPFLAGS_WRITE: DBPROPFLAGSENUM = DBPROPFLAGSENUM(1024i32); pub const DBPROPFLAGS_REQUIRED: DBPROPFLAGSENUM = DBPROPFLAGSENUM(2048i32); pub const DBPROPFLAGS_SESSION: DBPROPFLAGSENUM = DBPROPFLAGSENUM(4096i32); impl ::core::convert::From<i32> for DBPROPFLAGSENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBPROPFLAGSENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBPROPFLAGSENUM21(pub i32); pub const DBPROPFLAGS_TRUSTEE: DBPROPFLAGSENUM21 = DBPROPFLAGSENUM21(8192i32); impl ::core::convert::From<i32> for DBPROPFLAGSENUM21 { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBPROPFLAGSENUM21 { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBPROPFLAGSENUM25(pub i32); pub const DBPROPFLAGS_VIEW: DBPROPFLAGSENUM25 = DBPROPFLAGSENUM25(16384i32); impl ::core::convert::From<i32> for DBPROPFLAGSENUM25 { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBPROPFLAGSENUM25 { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBPROPFLAGSENUM26(pub i32); pub const DBPROPFLAGS_STREAM: DBPROPFLAGSENUM26 = DBPROPFLAGSENUM26(32768i32); impl ::core::convert::From<i32> for DBPROPFLAGSENUM26 { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBPROPFLAGSENUM26 { type Abi = Self; } pub const DBPROPFLAGS_PERSIST: u32 = 8192u32; #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] pub struct DBPROPIDSET { pub rgPropertyIDs: *mut u32, pub cPropertyIDs: u32, pub guidPropertySet: ::windows::core::GUID, } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl DBPROPIDSET {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::default::Default for DBPROPIDSET { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::fmt::Debug for DBPROPIDSET { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("DBPROPIDSET").field("rgPropertyIDs", &self.rgPropertyIDs).field("cPropertyIDs", &self.cPropertyIDs).field("guidPropertySet", &self.guidPropertySet).finish() } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::cmp::PartialEq for DBPROPIDSET { fn eq(&self, other: &Self) -> bool { self.rgPropertyIDs == other.rgPropertyIDs && self.cPropertyIDs == other.cPropertyIDs && self.guidPropertySet == other.guidPropertySet } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::cmp::Eq for DBPROPIDSET {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] unsafe impl ::windows::core::Abi for DBPROPIDSET { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C, packed(2))] #[cfg(any(target_arch = "x86",))] pub struct DBPROPIDSET { pub rgPropertyIDs: *mut u32, pub cPropertyIDs: u32, pub guidPropertySet: ::windows::core::GUID, } #[cfg(any(target_arch = "x86",))] impl DBPROPIDSET {} #[cfg(any(target_arch = "x86",))] impl ::core::default::Default for DBPROPIDSET { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86",))] impl ::core::cmp::PartialEq for DBPROPIDSET { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(any(target_arch = "x86",))] impl ::core::cmp::Eq for DBPROPIDSET {} #[cfg(any(target_arch = "x86",))] unsafe impl ::windows::core::Abi for DBPROPIDSET { type Abi = Self; } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::clone::Clone for DBPROPINFO { fn clone(&self) -> Self { unimplemented!() } } #[repr(C)] #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub struct DBPROPINFO { pub pwszDescription: super::super::Foundation::PWSTR, pub dwPropertyID: u32, pub dwFlags: u32, pub vtType: u16, pub vValues: super::Com::VARIANT, } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl DBPROPINFO {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::default::Default for DBPROPINFO { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::cmp::PartialEq for DBPROPINFO { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::cmp::Eq for DBPROPINFO {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] unsafe impl ::windows::core::Abi for DBPROPINFO { type Abi = ::core::mem::ManuallyDrop<Self>; } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::clone::Clone for DBPROPINFO { fn clone(&self) -> Self { unimplemented!() } } #[repr(C, packed(2))] #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub struct DBPROPINFO { pub pwszDescription: super::super::Foundation::PWSTR, pub dwPropertyID: u32, pub dwFlags: u32, pub vtType: u16, pub vValues: super::Com::VARIANT, } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl DBPROPINFO {} #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::default::Default for DBPROPINFO { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::cmp::PartialEq for DBPROPINFO { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::cmp::Eq for DBPROPINFO {} #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] unsafe impl ::windows::core::Abi for DBPROPINFO { type Abi = ::core::mem::ManuallyDrop<Self>; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub struct DBPROPINFOSET { pub rgPropertyInfos: *mut DBPROPINFO, pub cPropertyInfos: u32, pub guidPropertySet: ::windows::core::GUID, } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl DBPROPINFOSET {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::default::Default for DBPROPINFOSET { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::fmt::Debug for DBPROPINFOSET { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("DBPROPINFOSET").field("rgPropertyInfos", &self.rgPropertyInfos).field("cPropertyInfos", &self.cPropertyInfos).field("guidPropertySet", &self.guidPropertySet).finish() } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::cmp::PartialEq for DBPROPINFOSET { fn eq(&self, other: &Self) -> bool { self.rgPropertyInfos == other.rgPropertyInfos && self.cPropertyInfos == other.cPropertyInfos && self.guidPropertySet == other.guidPropertySet } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::cmp::Eq for DBPROPINFOSET {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] unsafe impl ::windows::core::Abi for DBPROPINFOSET { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C, packed(2))] #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub struct DBPROPINFOSET { pub rgPropertyInfos: *mut DBPROPINFO, pub cPropertyInfos: u32, pub guidPropertySet: ::windows::core::GUID, } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl DBPROPINFOSET {} #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::default::Default for DBPROPINFOSET { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::cmp::PartialEq for DBPROPINFOSET { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::cmp::Eq for DBPROPINFOSET {} #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] unsafe impl ::windows::core::Abi for DBPROPINFOSET { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBPROPOPTIONSENUM(pub i32); pub const DBPROPOPTIONS_REQUIRED: DBPROPOPTIONSENUM = DBPROPOPTIONSENUM(0i32); pub const DBPROPOPTIONS_SETIFCHEAP: DBPROPOPTIONSENUM = DBPROPOPTIONSENUM(1i32); pub const DBPROPOPTIONS_OPTIONAL: DBPROPOPTIONSENUM = DBPROPOPTIONSENUM(1i32); impl ::core::convert::From<i32> for DBPROPOPTIONSENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBPROPOPTIONSENUM { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub struct DBPROPSET { pub rgProperties: *mut DBPROP, pub cProperties: u32, pub guidPropertySet: ::windows::core::GUID, } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl DBPROPSET {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::default::Default for DBPROPSET { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::fmt::Debug for DBPROPSET { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("DBPROPSET").field("rgProperties", &self.rgProperties).field("cProperties", &self.cProperties).field("guidPropertySet", &self.guidPropertySet).finish() } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::cmp::PartialEq for DBPROPSET { fn eq(&self, other: &Self) -> bool { self.rgProperties == other.rgProperties && self.cProperties == other.cProperties && self.guidPropertySet == other.guidPropertySet } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::cmp::Eq for DBPROPSET {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] unsafe impl ::windows::core::Abi for DBPROPSET { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C, packed(2))] #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub struct DBPROPSET { pub rgProperties: *mut DBPROP, pub cProperties: u32, pub guidPropertySet: ::windows::core::GUID, } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl DBPROPSET {} #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::default::Default for DBPROPSET { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::cmp::PartialEq for DBPROPSET { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::cmp::Eq for DBPROPSET {} #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] unsafe impl ::windows::core::Abi for DBPROPSET { type Abi = Self; } pub const DBPROPSET_MSDAORA8_ROWSET: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x7f06a375_dd6a_43db_b4e0_1fc121e5e62b); pub const DBPROPSET_MSDAORA_ROWSET: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xe8cc4cbd_fdff_11d0_b865_00a0c9081c1d); pub const DBPROPSET_MSDSDBINIT: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x55cb91a8_5c7a_11d1_adad_00c04fc29863); pub const DBPROPSET_MSDSSESSION: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xedf17536_afbf_11d1_8847_0000f879f98c); pub const DBPROPSET_PERSIST: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x4d7839a0_5b8e_11d1_a6b3_00a0c9138c66); pub const DBPROPSET_PROVIDERCONNATTR: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x497c60e4_7123_11cf_b171_00aa0057599e); pub const DBPROPSET_PROVIDERDATASOURCEINFO: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x497c60e0_7123_11cf_b171_00aa0057599e); pub const DBPROPSET_PROVIDERDBINIT: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x497c60e2_7123_11cf_b171_00aa0057599e); pub const DBPROPSET_PROVIDERROWSET: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x497c60e1_7123_11cf_b171_00aa0057599e); pub const DBPROPSET_PROVIDERSTMTATTR: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x497c60e3_7123_11cf_b171_00aa0057599e); pub const DBPROPSET_SQLSERVERCOLUMN: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x3b63fb5e_3fbb_11d3_9f29_00c04f8ee9dc); pub const DBPROPSET_SQLSERVERDATASOURCE: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x28efaee4_2d2c_11d1_9807_00c04fc2ad98); pub const DBPROPSET_SQLSERVERDATASOURCEINFO: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xdf10cb94_35f6_11d2_9c54_00c04f7971d3); pub const DBPROPSET_SQLSERVERDBINIT: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x5cf4ca10_ef21_11d0_97e7_00c04fc2ad98); pub const DBPROPSET_SQLSERVERROWSET: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x5cf4ca11_ef21_11d0_97e7_00c04fc2ad98); pub const DBPROPSET_SQLSERVERSESSION: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x28efaee5_2d2c_11d1_9807_00c04fc2ad98); pub const DBPROPSET_SQLSERVERSTREAM: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x9f79c073_8a6d_4bca_a8a8_c9b79a9b962d); #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBPROPSTATUSENUM(pub i32); pub const DBPROPSTATUS_OK: DBPROPSTATUSENUM = DBPROPSTATUSENUM(0i32); pub const DBPROPSTATUS_NOTSUPPORTED: DBPROPSTATUSENUM = DBPROPSTATUSENUM(1i32); pub const DBPROPSTATUS_BADVALUE: DBPROPSTATUSENUM = DBPROPSTATUSENUM(2i32); pub const DBPROPSTATUS_BADOPTION: DBPROPSTATUSENUM = DBPROPSTATUSENUM(3i32); pub const DBPROPSTATUS_BADCOLUMN: DBPROPSTATUSENUM = DBPROPSTATUSENUM(4i32); pub const DBPROPSTATUS_NOTALLSETTABLE: DBPROPSTATUSENUM = DBPROPSTATUSENUM(5i32); pub const DBPROPSTATUS_NOTSETTABLE: DBPROPSTATUSENUM = DBPROPSTATUSENUM(6i32); pub const DBPROPSTATUS_NOTSET: DBPROPSTATUSENUM = DBPROPSTATUSENUM(7i32); pub const DBPROPSTATUS_CONFLICTING: DBPROPSTATUSENUM = DBPROPSTATUSENUM(8i32); impl ::core::convert::From<i32> for DBPROPSTATUSENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBPROPSTATUSENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBPROPSTATUSENUM21(pub i32); pub const DBPROPSTATUS_NOTAVAILABLE: DBPROPSTATUSENUM21 = DBPROPSTATUSENUM21(9i32); impl ::core::convert::From<i32> for DBPROPSTATUSENUM21 { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBPROPSTATUSENUM21 { type Abi = Self; } pub const DBPROPVAL_AO_RANDOM: i32 = 2i32; pub const DBPROPVAL_AO_SEQUENTIAL: i32 = 0i32; pub const DBPROPVAL_AO_SEQUENTIALSTORAGEOBJECTS: i32 = 1i32; pub const DBPROPVAL_ASYNCH_BACKGROUNDPOPULATION: i32 = 8i32; pub const DBPROPVAL_ASYNCH_INITIALIZE: i32 = 1i32; pub const DBPROPVAL_ASYNCH_POPULATEONDEMAND: i32 = 32i32; pub const DBPROPVAL_ASYNCH_PREPOPULATE: i32 = 16i32; pub const DBPROPVAL_ASYNCH_RANDOMPOPULATION: i32 = 4i32; pub const DBPROPVAL_ASYNCH_SEQUENTIALPOPULATION: i32 = 2i32; pub const DBPROPVAL_BD_INTRANSACTION: i32 = 1i32; pub const DBPROPVAL_BD_REORGANIZATION: i32 = 3i32; pub const DBPROPVAL_BD_ROWSET: i32 = 0i32; pub const DBPROPVAL_BD_XTRANSACTION: i32 = 2i32; pub const DBPROPVAL_BI_CROSSROWSET: i32 = 1i32; pub const DBPROPVAL_BMK_KEY: i32 = 2i32; pub const DBPROPVAL_BMK_NUMERIC: i32 = 1i32; pub const DBPROPVAL_BO_NOINDEXUPDATE: i32 = 1i32; pub const DBPROPVAL_BO_NOLOG: i32 = 0i32; pub const DBPROPVAL_BO_REFINTEGRITY: i32 = 2i32; pub const DBPROPVAL_CB_DELETE: i32 = 1i32; pub const DBPROPVAL_CB_NON_NULL: i32 = 2i32; pub const DBPROPVAL_CB_NULL: i32 = 1i32; pub const DBPROPVAL_CB_PRESERVE: i32 = 2i32; pub const DBPROPVAL_CD_NOTNULL: i32 = 1i32; pub const DBPROPVAL_CL_END: i32 = 2i32; pub const DBPROPVAL_CL_START: i32 = 1i32; pub const DBPROPVAL_CM_TRANSACTIONS: i32 = 1i32; pub const DBPROPVAL_CO_BEGINSWITH: i32 = 32i32; pub const DBPROPVAL_CO_CASEINSENSITIVE: i32 = 8i32; pub const DBPROPVAL_CO_CASESENSITIVE: i32 = 4i32; pub const DBPROPVAL_CO_CONTAINS: i32 = 16i32; pub const DBPROPVAL_CO_EQUALITY: i32 = 1i32; pub const DBPROPVAL_CO_STRING: i32 = 2i32; pub const DBPROPVAL_CS_COMMUNICATIONFAILURE: i32 = 2i32; pub const DBPROPVAL_CS_INITIALIZED: i32 = 1i32; pub const DBPROPVAL_CS_UNINITIALIZED: i32 = 0i32; pub const DBPROPVAL_CU_DML_STATEMENTS: i32 = 1i32; pub const DBPROPVAL_CU_INDEX_DEFINITION: i32 = 4i32; pub const DBPROPVAL_CU_PRIVILEGE_DEFINITION: i32 = 8i32; pub const DBPROPVAL_CU_TABLE_DEFINITION: i32 = 2i32; pub const DBPROPVAL_DF_INITIALLY_DEFERRED: u32 = 1u32; pub const DBPROPVAL_DF_INITIALLY_IMMEDIATE: u32 = 2u32; pub const DBPROPVAL_DF_NOT_DEFERRABLE: u32 = 3u32; pub const DBPROPVAL_DST_DOCSOURCE: i32 = 4i32; pub const DBPROPVAL_DST_MDP: i32 = 2i32; pub const DBPROPVAL_DST_TDP: i32 = 1i32; pub const DBPROPVAL_DST_TDPANDMDP: i32 = 3i32; pub const DBPROPVAL_FU_CATALOG: i32 = 8i32; pub const DBPROPVAL_FU_COLUMN: i32 = 2i32; pub const DBPROPVAL_FU_NOT_SUPPORTED: i32 = 1i32; pub const DBPROPVAL_FU_TABLE: i32 = 4i32; pub const DBPROPVAL_GB_COLLATE: i32 = 16i32; pub const DBPROPVAL_GB_CONTAINS_SELECT: i32 = 4i32; pub const DBPROPVAL_GB_EQUALS_SELECT: i32 = 2i32; pub const DBPROPVAL_GB_NOT_SUPPORTED: i32 = 1i32; pub const DBPROPVAL_GB_NO_RELATION: i32 = 8i32; pub const DBPROPVAL_GU_NOTSUPPORTED: i32 = 1i32; pub const DBPROPVAL_GU_SUFFIX: i32 = 2i32; pub const DBPROPVAL_HT_DIFFERENT_CATALOGS: i32 = 1i32; pub const DBPROPVAL_HT_DIFFERENT_PROVIDERS: i32 = 2i32; pub const DBPROPVAL_IC_LOWER: i32 = 2i32; pub const DBPROPVAL_IC_MIXED: i32 = 8i32; pub const DBPROPVAL_IC_SENSITIVE: i32 = 4i32; pub const DBPROPVAL_IC_UPPER: i32 = 1i32; pub const DBPROPVAL_IN_ALLOWNULL: i32 = 0i32; pub const DBPROPVAL_IN_DISALLOWNULL: i32 = 1i32; pub const DBPROPVAL_IN_IGNOREANYNULL: i32 = 4i32; pub const DBPROPVAL_IN_IGNORENULL: i32 = 2i32; pub const DBPROPVAL_IT_BTREE: i32 = 1i32; pub const DBPROPVAL_IT_CONTENT: i32 = 3i32; pub const DBPROPVAL_IT_HASH: i32 = 2i32; pub const DBPROPVAL_IT_OTHER: i32 = 4i32; pub const DBPROPVAL_LM_INTENT: i32 = 4i32; pub const DBPROPVAL_LM_NONE: i32 = 1i32; pub const DBPROPVAL_LM_READ: i32 = 2i32; pub const DBPROPVAL_LM_RITE: i32 = 8i32; pub const DBPROPVAL_LM_SINGLEROW: i32 = 2i32; pub const DBPROPVAL_MR_CONCURRENT: i32 = 2i32; pub const DBPROPVAL_MR_NOTSUPPORTED: i32 = 0i32; pub const DBPROPVAL_MR_SUPPORTED: i32 = 1i32; pub const DBPROPVAL_NC_END: i32 = 1i32; pub const DBPROPVAL_NC_HIGH: i32 = 2i32; pub const DBPROPVAL_NC_LOW: i32 = 4i32; pub const DBPROPVAL_NC_START: i32 = 8i32; pub const DBPROPVAL_NP_ABOUTTODO: i32 = 2i32; pub const DBPROPVAL_NP_DIDEVENT: i32 = 16i32; pub const DBPROPVAL_NP_FAILEDTODO: i32 = 8i32; pub const DBPROPVAL_NP_OKTODO: i32 = 1i32; pub const DBPROPVAL_NP_SYNCHAFTER: i32 = 4i32; pub const DBPROPVAL_NT_MULTIPLEROWS: i32 = 2i32; pub const DBPROPVAL_NT_SINGLEROW: i32 = 1i32; pub const DBPROPVAL_OA_ATEXECUTE: i32 = 2i32; pub const DBPROPVAL_OA_ATROWRELEASE: i32 = 4i32; pub const DBPROPVAL_OA_NOTSUPPORTED: i32 = 1i32; pub const DBPROPVAL_OO_BLOB: i32 = 1i32; pub const DBPROPVAL_OO_DIRECTBIND: i32 = 16i32; pub const DBPROPVAL_OO_IPERSIST: i32 = 2i32; pub const DBPROPVAL_OO_ROWOBJECT: i32 = 4i32; pub const DBPROPVAL_OO_SCOPED: i32 = 8i32; pub const DBPROPVAL_OO_SINGLETON: i32 = 32i32; pub const DBPROPVAL_OP_EQUAL: i32 = 1i32; pub const DBPROPVAL_OP_RELATIVE: i32 = 2i32; pub const DBPROPVAL_OP_STRING: i32 = 4i32; pub const DBPROPVAL_ORS_HISTOGRAM: i32 = 8i32; pub const DBPROPVAL_ORS_INDEX: i32 = 1i32; pub const DBPROPVAL_ORS_INTEGRATEDINDEX: i32 = 2i32; pub const DBPROPVAL_ORS_STOREDPROC: i32 = 4i32; pub const DBPROPVAL_ORS_TABLE: i32 = 0i32; pub const DBPROPVAL_OS_AGR_AFTERSESSION: i32 = 8i32; pub const DBPROPVAL_OS_CLIENTCURSOR: i32 = 4i32; pub const DBPROPVAL_OS_DISABLEALL: i32 = 0i32; pub const DBPROPVAL_OS_ENABLEALL: i32 = -1i32; pub const DBPROPVAL_OS_RESOURCEPOOLING: i32 = 1i32; pub const DBPROPVAL_OS_TXNENLISTMENT: i32 = 2i32; pub const DBPROPVAL_PERSIST_ADTG: u32 = 0u32; pub const DBPROPVAL_PERSIST_XML: u32 = 1u32; pub const DBPROPVAL_PT_GUID: i32 = 8i32; pub const DBPROPVAL_PT_GUID_NAME: i32 = 1i32; pub const DBPROPVAL_PT_GUID_PROPID: i32 = 2i32; pub const DBPROPVAL_PT_NAME: i32 = 4i32; pub const DBPROPVAL_PT_PGUID_NAME: i32 = 32i32; pub const DBPROPVAL_PT_PGUID_PROPID: i32 = 64i32; pub const DBPROPVAL_PT_PROPID: i32 = 16i32; pub const DBPROPVAL_RD_RESETALL: i32 = -1i32; pub const DBPROPVAL_RT_APTMTTHREAD: i32 = 2i32; pub const DBPROPVAL_RT_FREETHREAD: i32 = 1i32; pub const DBPROPVAL_RT_SINGLETHREAD: i32 = 4i32; pub const DBPROPVAL_SQL_ANSI89_IEF: i32 = 8i32; pub const DBPROPVAL_SQL_ANSI92_ENTRY: i32 = 16i32; pub const DBPROPVAL_SQL_ANSI92_FULL: i32 = 128i32; pub const DBPROPVAL_SQL_ANSI92_INTERMEDIATE: i32 = 64i32; pub const DBPROPVAL_SQL_ESCAPECLAUSES: i32 = 256i32; pub const DBPROPVAL_SQL_FIPS_TRANSITIONAL: i32 = 32i32; pub const DBPROPVAL_SQL_NONE: i32 = 0i32; pub const DBPROPVAL_SQL_ODBC_CORE: i32 = 2i32; pub const DBPROPVAL_SQL_ODBC_EXTENDED: i32 = 4i32; pub const DBPROPVAL_SQL_ODBC_MINIMUM: i32 = 1i32; pub const DBPROPVAL_SQL_SUBMINIMUM: i32 = 512i32; pub const DBPROPVAL_SQ_COMPARISON: i32 = 2i32; pub const DBPROPVAL_SQ_CORRELATEDSUBQUERIES: i32 = 1i32; pub const DBPROPVAL_SQ_EXISTS: i32 = 4i32; pub const DBPROPVAL_SQ_IN: i32 = 8i32; pub const DBPROPVAL_SQ_QUANTIFIED: i32 = 16i32; pub const DBPROPVAL_SQ_TABLE: i32 = 32i32; pub const DBPROPVAL_SS_ILOCKBYTES: i32 = 8i32; pub const DBPROPVAL_SS_ISEQUENTIALSTREAM: i32 = 1i32; pub const DBPROPVAL_SS_ISTORAGE: i32 = 4i32; pub const DBPROPVAL_SS_ISTREAM: i32 = 2i32; pub const DBPROPVAL_STGM_CONVERT: u32 = 262144u32; pub const DBPROPVAL_STGM_DELETEONRELEASE: u32 = 2097152u32; pub const DBPROPVAL_STGM_DIRECT: u32 = 65536u32; pub const DBPROPVAL_STGM_FAILIFTHERE: u32 = 524288u32; pub const DBPROPVAL_STGM_PRIORITY: u32 = 1048576u32; pub const DBPROPVAL_STGM_TRANSACTED: u32 = 131072u32; pub const DBPROPVAL_SU_DML_STATEMENTS: i32 = 1i32; pub const DBPROPVAL_SU_INDEX_DEFINITION: i32 = 4i32; pub const DBPROPVAL_SU_PRIVILEGE_DEFINITION: i32 = 8i32; pub const DBPROPVAL_SU_TABLE_DEFINITION: i32 = 2i32; pub const DBPROPVAL_TC_ALL: i32 = 8i32; pub const DBPROPVAL_TC_DDL_COMMIT: i32 = 2i32; pub const DBPROPVAL_TC_DDL_IGNORE: i32 = 4i32; pub const DBPROPVAL_TC_DDL_LOCK: i32 = 16i32; pub const DBPROPVAL_TC_DML: i32 = 1i32; pub const DBPROPVAL_TC_NONE: i32 = 0i32; pub const DBPROPVAL_TI_BROWSE: i32 = 256i32; pub const DBPROPVAL_TI_CHAOS: i32 = 16i32; pub const DBPROPVAL_TI_CURSORSTABILITY: i32 = 4096i32; pub const DBPROPVAL_TI_ISOLATED: i32 = 1048576i32; pub const DBPROPVAL_TI_READCOMMITTED: i32 = 4096i32; pub const DBPROPVAL_TI_READUNCOMMITTED: i32 = 256i32; pub const DBPROPVAL_TI_REPEATABLEREAD: i32 = 65536i32; pub const DBPROPVAL_TI_SERIALIZABLE: i32 = 1048576i32; pub const DBPROPVAL_TR_ABORT: i32 = 16i32; pub const DBPROPVAL_TR_ABORT_DC: i32 = 8i32; pub const DBPROPVAL_TR_ABORT_NO: i32 = 32i32; pub const DBPROPVAL_TR_BOTH: i32 = 128i32; pub const DBPROPVAL_TR_COMMIT: i32 = 2i32; pub const DBPROPVAL_TR_COMMIT_DC: i32 = 1i32; pub const DBPROPVAL_TR_COMMIT_NO: i32 = 4i32; pub const DBPROPVAL_TR_DONTCARE: i32 = 64i32; pub const DBPROPVAL_TR_NONE: i32 = 256i32; pub const DBPROPVAL_TR_OPTIMISTIC: i32 = 512i32; pub const DBPROPVAL_TS_CARDINALITY: i32 = 1i32; pub const DBPROPVAL_TS_HISTOGRAM: i32 = 2i32; pub const DBPROPVAL_UP_CHANGE: i32 = 1i32; pub const DBPROPVAL_UP_DELETE: i32 = 2i32; pub const DBPROPVAL_UP_INSERT: i32 = 4i32; pub const DBPROP_HCHAPTER: u32 = 4u32; pub const DBPROP_INTERLEAVEDROWS: u32 = 8u32; pub const DBPROP_MAINTAINPROPS: u32 = 5u32; pub const DBPROP_MSDAORA8_DETERMINEKEYCOLUMNS: u32 = 2u32; pub const DBPROP_MSDAORA_DETERMINEKEYCOLUMNS: u32 = 1u32; pub const DBPROP_PersistFormat: u32 = 2u32; pub const DBPROP_PersistSchema: u32 = 3u32; pub const DBPROP_Unicode: u32 = 6u32; #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBRANGEENUM(pub i32); pub const DBRANGE_INCLUSIVESTART: DBRANGEENUM = DBRANGEENUM(0i32); pub const DBRANGE_INCLUSIVEEND: DBRANGEENUM = DBRANGEENUM(0i32); pub const DBRANGE_EXCLUSIVESTART: DBRANGEENUM = DBRANGEENUM(1i32); pub const DBRANGE_EXCLUSIVEEND: DBRANGEENUM = DBRANGEENUM(2i32); pub const DBRANGE_EXCLUDENULLS: DBRANGEENUM = DBRANGEENUM(4i32); pub const DBRANGE_PREFIX: DBRANGEENUM = DBRANGEENUM(8i32); pub const DBRANGE_MATCH: DBRANGEENUM = DBRANGEENUM(16i32); impl ::core::convert::From<i32> for DBRANGEENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBRANGEENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBRANGEENUM20(pub i32); pub const DBRANGE_MATCH_N_SHIFT: DBRANGEENUM20 = DBRANGEENUM20(24i32); pub const DBRANGE_MATCH_N_MASK: DBRANGEENUM20 = DBRANGEENUM20(255i32); impl ::core::convert::From<i32> for DBRANGEENUM20 { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBRANGEENUM20 { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBREASONENUM(pub i32); pub const DBREASON_ROWSET_FETCHPOSITIONCHANGE: DBREASONENUM = DBREASONENUM(0i32); pub const DBREASON_ROWSET_RELEASE: DBREASONENUM = DBREASONENUM(1i32); pub const DBREASON_COLUMN_SET: DBREASONENUM = DBREASONENUM(2i32); pub const DBREASON_COLUMN_RECALCULATED: DBREASONENUM = DBREASONENUM(3i32); pub const DBREASON_ROW_ACTIVATE: DBREASONENUM = DBREASONENUM(4i32); pub const DBREASON_ROW_RELEASE: DBREASONENUM = DBREASONENUM(5i32); pub const DBREASON_ROW_DELETE: DBREASONENUM = DBREASONENUM(6i32); pub const DBREASON_ROW_FIRSTCHANGE: DBREASONENUM = DBREASONENUM(7i32); pub const DBREASON_ROW_INSERT: DBREASONENUM = DBREASONENUM(8i32); pub const DBREASON_ROW_RESYNCH: DBREASONENUM = DBREASONENUM(9i32); pub const DBREASON_ROW_UNDOCHANGE: DBREASONENUM = DBREASONENUM(10i32); pub const DBREASON_ROW_UNDOINSERT: DBREASONENUM = DBREASONENUM(11i32); pub const DBREASON_ROW_UNDODELETE: DBREASONENUM = DBREASONENUM(12i32); pub const DBREASON_ROW_UPDATE: DBREASONENUM = DBREASONENUM(13i32); pub const DBREASON_ROWSET_CHANGED: DBREASONENUM = DBREASONENUM(14i32); impl ::core::convert::From<i32> for DBREASONENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBREASONENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBREASONENUM15(pub i32); pub const DBREASON_ROWPOSITION_CHANGED: DBREASONENUM15 = DBREASONENUM15(15i32); pub const DBREASON_ROWPOSITION_CHAPTERCHANGED: DBREASONENUM15 = DBREASONENUM15(16i32); pub const DBREASON_ROWPOSITION_CLEARED: DBREASONENUM15 = DBREASONENUM15(17i32); pub const DBREASON_ROW_ASYNCHINSERT: DBREASONENUM15 = DBREASONENUM15(18i32); impl ::core::convert::From<i32> for DBREASONENUM15 { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBREASONENUM15 { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBREASONENUM25(pub i32); pub const DBREASON_ROWSET_ROWSADDED: DBREASONENUM25 = DBREASONENUM25(19i32); pub const DBREASON_ROWSET_POPULATIONCOMPLETE: DBREASONENUM25 = DBREASONENUM25(20i32); pub const DBREASON_ROWSET_POPULATIONSTOPPED: DBREASONENUM25 = DBREASONENUM25(21i32); impl ::core::convert::From<i32> for DBREASONENUM25 { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBREASONENUM25 { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBRESOURCEKINDENUM(pub i32); pub const DBRESOURCE_INVALID: DBRESOURCEKINDENUM = DBRESOURCEKINDENUM(0i32); pub const DBRESOURCE_TOTAL: DBRESOURCEKINDENUM = DBRESOURCEKINDENUM(1i32); pub const DBRESOURCE_CPU: DBRESOURCEKINDENUM = DBRESOURCEKINDENUM(2i32); pub const DBRESOURCE_MEMORY: DBRESOURCEKINDENUM = DBRESOURCEKINDENUM(3i32); pub const DBRESOURCE_DISK: DBRESOURCEKINDENUM = DBRESOURCEKINDENUM(4i32); pub const DBRESOURCE_NETWORK: DBRESOURCEKINDENUM = DBRESOURCEKINDENUM(5i32); pub const DBRESOURCE_RESPONSE: DBRESOURCEKINDENUM = DBRESOURCEKINDENUM(6i32); pub const DBRESOURCE_ROWS: DBRESOURCEKINDENUM = DBRESOURCEKINDENUM(7i32); pub const DBRESOURCE_OTHER: DBRESOURCEKINDENUM = DBRESOURCEKINDENUM(8i32); impl ::core::convert::From<i32> for DBRESOURCEKINDENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBRESOURCEKINDENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBRESULTFLAGENUM(pub i32); pub const DBRESULTFLAG_DEFAULT: DBRESULTFLAGENUM = DBRESULTFLAGENUM(0i32); pub const DBRESULTFLAG_ROWSET: DBRESULTFLAGENUM = DBRESULTFLAGENUM(1i32); pub const DBRESULTFLAG_ROW: DBRESULTFLAGENUM = DBRESULTFLAGENUM(2i32); impl ::core::convert::From<i32> for DBRESULTFLAGENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBRESULTFLAGENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBROWCHANGEKINDENUM(pub i32); pub const DBROWCHANGEKIND_INSERT: DBROWCHANGEKINDENUM = DBROWCHANGEKINDENUM(0i32); pub const DBROWCHANGEKIND_DELETE: DBROWCHANGEKINDENUM = DBROWCHANGEKINDENUM(1i32); pub const DBROWCHANGEKIND_UPDATE: DBROWCHANGEKINDENUM = DBROWCHANGEKINDENUM(2i32); pub const DBROWCHANGEKIND_COUNT: DBROWCHANGEKINDENUM = DBROWCHANGEKINDENUM(3i32); impl ::core::convert::From<i32> for DBROWCHANGEKINDENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBROWCHANGEKINDENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBROWSTATUSENUM(pub i32); pub const DBROWSTATUS_S_OK: DBROWSTATUSENUM = DBROWSTATUSENUM(0i32); pub const DBROWSTATUS_S_MULTIPLECHANGES: DBROWSTATUSENUM = DBROWSTATUSENUM(2i32); pub const DBROWSTATUS_S_PENDINGCHANGES: DBROWSTATUSENUM = DBROWSTATUSENUM(3i32); pub const DBROWSTATUS_E_CANCELED: DBROWSTATUSENUM = DBROWSTATUSENUM(4i32); pub const DBROWSTATUS_E_CANTRELEASE: DBROWSTATUSENUM = DBROWSTATUSENUM(6i32); pub const DBROWSTATUS_E_CONCURRENCYVIOLATION: DBROWSTATUSENUM = DBROWSTATUSENUM(7i32); pub const DBROWSTATUS_E_DELETED: DBROWSTATUSENUM = DBROWSTATUSENUM(8i32); pub const DBROWSTATUS_E_PENDINGINSERT: DBROWSTATUSENUM = DBROWSTATUSENUM(9i32); pub const DBROWSTATUS_E_NEWLYINSERTED: DBROWSTATUSENUM = DBROWSTATUSENUM(10i32); pub const DBROWSTATUS_E_INTEGRITYVIOLATION: DBROWSTATUSENUM = DBROWSTATUSENUM(11i32); pub const DBROWSTATUS_E_INVALID: DBROWSTATUSENUM = DBROWSTATUSENUM(12i32); pub const DBROWSTATUS_E_MAXPENDCHANGESEXCEEDED: DBROWSTATUSENUM = DBROWSTATUSENUM(13i32); pub const DBROWSTATUS_E_OBJECTOPEN: DBROWSTATUSENUM = DBROWSTATUSENUM(14i32); pub const DBROWSTATUS_E_OUTOFMEMORY: DBROWSTATUSENUM = DBROWSTATUSENUM(15i32); pub const DBROWSTATUS_E_PERMISSIONDENIED: DBROWSTATUSENUM = DBROWSTATUSENUM(16i32); pub const DBROWSTATUS_E_LIMITREACHED: DBROWSTATUSENUM = DBROWSTATUSENUM(17i32); pub const DBROWSTATUS_E_SCHEMAVIOLATION: DBROWSTATUSENUM = DBROWSTATUSENUM(18i32); pub const DBROWSTATUS_E_FAIL: DBROWSTATUSENUM = DBROWSTATUSENUM(19i32); impl ::core::convert::From<i32> for DBROWSTATUSENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBROWSTATUSENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBROWSTATUSENUM20(pub i32); pub const DBROWSTATUS_S_NOCHANGE: DBROWSTATUSENUM20 = DBROWSTATUSENUM20(20i32); impl ::core::convert::From<i32> for DBROWSTATUSENUM20 { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBROWSTATUSENUM20 { type Abi = Self; } pub const DBSCHEMA_LINKEDSERVERS: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x9093caf4_2eac_11d1_9809_00c04fc2ad98); #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBSEEKENUM(pub i32); pub const DBSEEK_INVALID: DBSEEKENUM = DBSEEKENUM(0i32); pub const DBSEEK_FIRSTEQ: DBSEEKENUM = DBSEEKENUM(1i32); pub const DBSEEK_LASTEQ: DBSEEKENUM = DBSEEKENUM(2i32); pub const DBSEEK_AFTEREQ: DBSEEKENUM = DBSEEKENUM(4i32); pub const DBSEEK_AFTER: DBSEEKENUM = DBSEEKENUM(8i32); pub const DBSEEK_BEFOREEQ: DBSEEKENUM = DBSEEKENUM(16i32); pub const DBSEEK_BEFORE: DBSEEKENUM = DBSEEKENUM(32i32); impl ::core::convert::From<i32> for DBSEEKENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBSEEKENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBSORTENUM(pub i32); pub const DBSORT_ASCENDING: DBSORTENUM = DBSORTENUM(0i32); pub const DBSORT_DESCENDING: DBSORTENUM = DBSORTENUM(1i32); impl ::core::convert::From<i32> for DBSORTENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBSORTENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBSOURCETYPEENUM(pub i32); pub const DBSOURCETYPE_DATASOURCE: DBSOURCETYPEENUM = DBSOURCETYPEENUM(1i32); pub const DBSOURCETYPE_ENUMERATOR: DBSOURCETYPEENUM = DBSOURCETYPEENUM(2i32); impl ::core::convert::From<i32> for DBSOURCETYPEENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBSOURCETYPEENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBSOURCETYPEENUM20(pub i32); pub const DBSOURCETYPE_DATASOURCE_TDP: DBSOURCETYPEENUM20 = DBSOURCETYPEENUM20(1i32); pub const DBSOURCETYPE_DATASOURCE_MDP: DBSOURCETYPEENUM20 = DBSOURCETYPEENUM20(3i32); impl ::core::convert::From<i32> for DBSOURCETYPEENUM20 { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBSOURCETYPEENUM20 { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBSOURCETYPEENUM25(pub i32); pub const DBSOURCETYPE_BINDER: DBSOURCETYPEENUM25 = DBSOURCETYPEENUM25(4i32); impl ::core::convert::From<i32> for DBSOURCETYPEENUM25 { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBSOURCETYPEENUM25 { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBSTATUSENUM(pub i32); pub const DBSTATUS_S_OK: DBSTATUSENUM = DBSTATUSENUM(0i32); pub const DBSTATUS_E_BADACCESSOR: DBSTATUSENUM = DBSTATUSENUM(1i32); pub const DBSTATUS_E_CANTCONVERTVALUE: DBSTATUSENUM = DBSTATUSENUM(2i32); pub const DBSTATUS_S_ISNULL: DBSTATUSENUM = DBSTATUSENUM(3i32); pub const DBSTATUS_S_TRUNCATED: DBSTATUSENUM = DBSTATUSENUM(4i32); pub const DBSTATUS_E_SIGNMISMATCH: DBSTATUSENUM = DBSTATUSENUM(5i32); pub const DBSTATUS_E_DATAOVERFLOW: DBSTATUSENUM = DBSTATUSENUM(6i32); pub const DBSTATUS_E_CANTCREATE: DBSTATUSENUM = DBSTATUSENUM(7i32); pub const DBSTATUS_E_UNAVAILABLE: DBSTATUSENUM = DBSTATUSENUM(8i32); pub const DBSTATUS_E_PERMISSIONDENIED: DBSTATUSENUM = DBSTATUSENUM(9i32); pub const DBSTATUS_E_INTEGRITYVIOLATION: DBSTATUSENUM = DBSTATUSENUM(10i32); pub const DBSTATUS_E_SCHEMAVIOLATION: DBSTATUSENUM = DBSTATUSENUM(11i32); pub const DBSTATUS_E_BADSTATUS: DBSTATUSENUM = DBSTATUSENUM(12i32); pub const DBSTATUS_S_DEFAULT: DBSTATUSENUM = DBSTATUSENUM(13i32); impl ::core::convert::From<i32> for DBSTATUSENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBSTATUSENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBSTATUSENUM20(pub i32); pub const MDSTATUS_S_CELLEMPTY: DBSTATUSENUM20 = DBSTATUSENUM20(14i32); pub const DBSTATUS_S_IGNORE: DBSTATUSENUM20 = DBSTATUSENUM20(15i32); impl ::core::convert::From<i32> for DBSTATUSENUM20 { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBSTATUSENUM20 { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBSTATUSENUM21(pub i32); pub const DBSTATUS_E_DOESNOTEXIST: DBSTATUSENUM21 = DBSTATUSENUM21(16i32); pub const DBSTATUS_E_INVALIDURL: DBSTATUSENUM21 = DBSTATUSENUM21(17i32); pub const DBSTATUS_E_RESOURCELOCKED: DBSTATUSENUM21 = DBSTATUSENUM21(18i32); pub const DBSTATUS_E_RESOURCEEXISTS: DBSTATUSENUM21 = DBSTATUSENUM21(19i32); pub const DBSTATUS_E_CANNOTCOMPLETE: DBSTATUSENUM21 = DBSTATUSENUM21(20i32); pub const DBSTATUS_E_VOLUMENOTFOUND: DBSTATUSENUM21 = DBSTATUSENUM21(21i32); pub const DBSTATUS_E_OUTOFSPACE: DBSTATUSENUM21 = DBSTATUSENUM21(22i32); pub const DBSTATUS_S_CANNOTDELETESOURCE: DBSTATUSENUM21 = DBSTATUSENUM21(23i32); pub const DBSTATUS_E_READONLY: DBSTATUSENUM21 = DBSTATUSENUM21(24i32); pub const DBSTATUS_E_RESOURCEOUTOFSCOPE: DBSTATUSENUM21 = DBSTATUSENUM21(25i32); pub const DBSTATUS_S_ALREADYEXISTS: DBSTATUSENUM21 = DBSTATUSENUM21(26i32); impl ::core::convert::From<i32> for DBSTATUSENUM21 { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBSTATUSENUM21 { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBSTATUSENUM25(pub i32); pub const DBSTATUS_E_CANCELED: DBSTATUSENUM25 = DBSTATUSENUM25(27i32); pub const DBSTATUS_E_NOTCOLLECTION: DBSTATUSENUM25 = DBSTATUSENUM25(28i32); impl ::core::convert::From<i32> for DBSTATUSENUM25 { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBSTATUSENUM25 { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBSTATUSENUM26(pub i32); pub const DBSTATUS_S_ROWSETCOLUMN: DBSTATUSENUM26 = DBSTATUSENUM26(29i32); impl ::core::convert::From<i32> for DBSTATUSENUM26 { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBSTATUSENUM26 { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBTABLESTATISTICSTYPE26(pub i32); pub const DBSTAT_HISTOGRAM: DBTABLESTATISTICSTYPE26 = DBTABLESTATISTICSTYPE26(1i32); pub const DBSTAT_COLUMN_CARDINALITY: DBTABLESTATISTICSTYPE26 = DBTABLESTATISTICSTYPE26(2i32); pub const DBSTAT_TUPLE_CARDINALITY: DBTABLESTATISTICSTYPE26 = DBTABLESTATISTICSTYPE26(4i32); impl ::core::convert::From<i32> for DBTABLESTATISTICSTYPE26 { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBTABLESTATISTICSTYPE26 { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] pub struct DBTIME { pub hour: u16, pub minute: u16, pub second: u16, } impl DBTIME {} impl ::core::default::Default for DBTIME { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } impl ::core::fmt::Debug for DBTIME { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("DBTIME").field("hour", &self.hour).field("minute", &self.minute).field("second", &self.second).finish() } } impl ::core::cmp::PartialEq for DBTIME { fn eq(&self, other: &Self) -> bool { self.hour == other.hour && self.minute == other.minute && self.second == other.second } } impl ::core::cmp::Eq for DBTIME {} unsafe impl ::windows::core::Abi for DBTIME { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] pub struct DBTIMESTAMP { pub year: i16, pub month: u16, pub day: u16, pub hour: u16, pub minute: u16, pub second: u16, pub fraction: u32, } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl DBTIMESTAMP {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::default::Default for DBTIMESTAMP { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::fmt::Debug for DBTIMESTAMP { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("DBTIMESTAMP").field("year", &self.year).field("month", &self.month).field("day", &self.day).field("hour", &self.hour).field("minute", &self.minute).field("second", &self.second).field("fraction", &self.fraction).finish() } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::cmp::PartialEq for DBTIMESTAMP { fn eq(&self, other: &Self) -> bool { self.year == other.year && self.month == other.month && self.day == other.day && self.hour == other.hour && self.minute == other.minute && self.second == other.second && self.fraction == other.fraction } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::cmp::Eq for DBTIMESTAMP {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] unsafe impl ::windows::core::Abi for DBTIMESTAMP { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C, packed(2))] #[cfg(any(target_arch = "x86",))] pub struct DBTIMESTAMP { pub year: i16, pub month: u16, pub day: u16, pub hour: u16, pub minute: u16, pub second: u16, pub fraction: u32, } #[cfg(any(target_arch = "x86",))] impl DBTIMESTAMP {} #[cfg(any(target_arch = "x86",))] impl ::core::default::Default for DBTIMESTAMP { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86",))] impl ::core::cmp::PartialEq for DBTIMESTAMP { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(any(target_arch = "x86",))] impl ::core::cmp::Eq for DBTIMESTAMP {} #[cfg(any(target_arch = "x86",))] unsafe impl ::windows::core::Abi for DBTIMESTAMP { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBTYPEENUM(pub i32); pub const DBTYPE_EMPTY: DBTYPEENUM = DBTYPEENUM(0i32); pub const DBTYPE_NULL: DBTYPEENUM = DBTYPEENUM(1i32); pub const DBTYPE_I2: DBTYPEENUM = DBTYPEENUM(2i32); pub const DBTYPE_I4: DBTYPEENUM = DBTYPEENUM(3i32); pub const DBTYPE_R4: DBTYPEENUM = DBTYPEENUM(4i32); pub const DBTYPE_R8: DBTYPEENUM = DBTYPEENUM(5i32); pub const DBTYPE_CY: DBTYPEENUM = DBTYPEENUM(6i32); pub const DBTYPE_DATE: DBTYPEENUM = DBTYPEENUM(7i32); pub const DBTYPE_BSTR: DBTYPEENUM = DBTYPEENUM(8i32); pub const DBTYPE_IDISPATCH: DBTYPEENUM = DBTYPEENUM(9i32); pub const DBTYPE_ERROR: DBTYPEENUM = DBTYPEENUM(10i32); pub const DBTYPE_BOOL: DBTYPEENUM = DBTYPEENUM(11i32); pub const DBTYPE_VARIANT: DBTYPEENUM = DBTYPEENUM(12i32); pub const DBTYPE_IUNKNOWN: DBTYPEENUM = DBTYPEENUM(13i32); pub const DBTYPE_DECIMAL: DBTYPEENUM = DBTYPEENUM(14i32); pub const DBTYPE_UI1: DBTYPEENUM = DBTYPEENUM(17i32); pub const DBTYPE_ARRAY: DBTYPEENUM = DBTYPEENUM(8192i32); pub const DBTYPE_BYREF: DBTYPEENUM = DBTYPEENUM(16384i32); pub const DBTYPE_I1: DBTYPEENUM = DBTYPEENUM(16i32); pub const DBTYPE_UI2: DBTYPEENUM = DBTYPEENUM(18i32); pub const DBTYPE_UI4: DBTYPEENUM = DBTYPEENUM(19i32); pub const DBTYPE_I8: DBTYPEENUM = DBTYPEENUM(20i32); pub const DBTYPE_UI8: DBTYPEENUM = DBTYPEENUM(21i32); pub const DBTYPE_GUID: DBTYPEENUM = DBTYPEENUM(72i32); pub const DBTYPE_VECTOR: DBTYPEENUM = DBTYPEENUM(4096i32); pub const DBTYPE_RESERVED: DBTYPEENUM = DBTYPEENUM(32768i32); pub const DBTYPE_BYTES: DBTYPEENUM = DBTYPEENUM(128i32); pub const DBTYPE_STR: DBTYPEENUM = DBTYPEENUM(129i32); pub const DBTYPE_WSTR: DBTYPEENUM = DBTYPEENUM(130i32); pub const DBTYPE_NUMERIC: DBTYPEENUM = DBTYPEENUM(131i32); pub const DBTYPE_UDT: DBTYPEENUM = DBTYPEENUM(132i32); pub const DBTYPE_DBDATE: DBTYPEENUM = DBTYPEENUM(133i32); pub const DBTYPE_DBTIME: DBTYPEENUM = DBTYPEENUM(134i32); pub const DBTYPE_DBTIMESTAMP: DBTYPEENUM = DBTYPEENUM(135i32); impl ::core::convert::From<i32> for DBTYPEENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBTYPEENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBTYPEENUM15(pub i32); pub const DBTYPE_HCHAPTER: DBTYPEENUM15 = DBTYPEENUM15(136i32); impl ::core::convert::From<i32> for DBTYPEENUM15 { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBTYPEENUM15 { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBTYPEENUM20(pub i32); pub const DBTYPE_FILETIME: DBTYPEENUM20 = DBTYPEENUM20(64i32); pub const DBTYPE_PROPVARIANT: DBTYPEENUM20 = DBTYPEENUM20(138i32); pub const DBTYPE_VARNUMERIC: DBTYPEENUM20 = DBTYPEENUM20(139i32); impl ::core::convert::From<i32> for DBTYPEENUM20 { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBTYPEENUM20 { type Abi = Self; } pub const DBTYPE_SQLVARIANT: u32 = 144u32; #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBUPDELRULEENUM(pub i32); pub const DBUPDELRULE_NOACTION: DBUPDELRULEENUM = DBUPDELRULEENUM(0i32); pub const DBUPDELRULE_CASCADE: DBUPDELRULEENUM = DBUPDELRULEENUM(1i32); pub const DBUPDELRULE_SETNULL: DBUPDELRULEENUM = DBUPDELRULEENUM(2i32); pub const DBUPDELRULE_SETDEFAULT: DBUPDELRULEENUM = DBUPDELRULEENUM(3i32); impl ::core::convert::From<i32> for DBUPDELRULEENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBUPDELRULEENUM { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] pub struct DBVECTOR { pub size: usize, pub ptr: *mut ::core::ffi::c_void, } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl DBVECTOR {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::default::Default for DBVECTOR { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::fmt::Debug for DBVECTOR { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("DBVECTOR").field("size", &self.size).field("ptr", &self.ptr).finish() } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::cmp::PartialEq for DBVECTOR { fn eq(&self, other: &Self) -> bool { self.size == other.size && self.ptr == other.ptr } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::cmp::Eq for DBVECTOR {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] unsafe impl ::windows::core::Abi for DBVECTOR { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C, packed(2))] #[cfg(any(target_arch = "x86",))] pub struct DBVECTOR { pub size: usize, pub ptr: *mut ::core::ffi::c_void, } #[cfg(any(target_arch = "x86",))] impl DBVECTOR {} #[cfg(any(target_arch = "x86",))] impl ::core::default::Default for DBVECTOR { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86",))] impl ::core::cmp::PartialEq for DBVECTOR { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(any(target_arch = "x86",))] impl ::core::cmp::Eq for DBVECTOR {} #[cfg(any(target_arch = "x86",))] unsafe impl ::windows::core::Abi for DBVECTOR { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBWATCHMODEENUM(pub i32); pub const DBWATCHMODE_ALL: DBWATCHMODEENUM = DBWATCHMODEENUM(1i32); pub const DBWATCHMODE_EXTEND: DBWATCHMODEENUM = DBWATCHMODEENUM(2i32); pub const DBWATCHMODE_MOVE: DBWATCHMODEENUM = DBWATCHMODEENUM(4i32); pub const DBWATCHMODE_COUNT: DBWATCHMODEENUM = DBWATCHMODEENUM(8i32); impl ::core::convert::From<i32> for DBWATCHMODEENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBWATCHMODEENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DBWATCHNOTIFYENUM(pub i32); pub const DBWATCHNOTIFY_ROWSCHANGED: DBWATCHNOTIFYENUM = DBWATCHNOTIFYENUM(1i32); pub const DBWATCHNOTIFY_QUERYDONE: DBWATCHNOTIFYENUM = DBWATCHNOTIFYENUM(2i32); pub const DBWATCHNOTIFY_QUERYREEXECUTED: DBWATCHNOTIFYENUM = DBWATCHNOTIFYENUM(3i32); impl ::core::convert::From<i32> for DBWATCHNOTIFYENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DBWATCHNOTIFYENUM { type Abi = Self; } pub const DB_ALL_EXCEPT_LIKE: u32 = 3u32; pub const DB_BINDFLAGS_COLLECTION: i32 = 16i32; pub const DB_BINDFLAGS_DELAYFETCHCOLUMNS: i32 = 1i32; pub const DB_BINDFLAGS_DELAYFETCHSTREAM: i32 = 2i32; pub const DB_BINDFLAGS_ISSTRUCTUREDDOCUMENT: i32 = 128i32; pub const DB_BINDFLAGS_OPENIFEXISTS: i32 = 32i32; pub const DB_BINDFLAGS_OUTPUT: i32 = 8i32; pub const DB_BINDFLAGS_OVERWRITE: i32 = 64i32; pub const DB_BINDFLAGS_RECURSIVE: i32 = 4i32; pub const DB_COLLATION_ASC: u32 = 1u32; pub const DB_COLLATION_DESC: u32 = 2u32; pub const DB_COUNTUNAVAILABLE: i32 = -1i32; pub const DB_E_ABORTLIMITREACHED: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217871i32 as _); pub const DB_E_ALREADYINITIALIZED: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217838i32 as _); pub const DB_E_ALTERRESTRICTED: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217763i32 as _); pub const DB_E_ASYNCNOTSUPPORTED: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217771i32 as _); pub const DB_E_BADACCESSORFLAGS: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217850i32 as _); pub const DB_E_BADACCESSORHANDLE: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217920i32 as _); pub const DB_E_BADACCESSORTYPE: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217845i32 as _); pub const DB_E_BADBINDINFO: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217912i32 as _); pub const DB_E_BADBOOKMARK: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217906i32 as _); pub const DB_E_BADCHAPTER: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217914i32 as _); pub const DB_E_BADCOLUMNID: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217903i32 as _); pub const DB_E_BADCOMMANDFLAGS: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217780i32 as _); pub const DB_E_BADCOMMANDID: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217802i32 as _); pub const DB_E_BADCOMPAREOP: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217881i32 as _); pub const DB_E_BADCONSTRAINTFORM: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217800i32 as _); pub const DB_E_BADCONSTRAINTID: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217781i32 as _); pub const DB_E_BADCONSTRAINTTYPE: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217801i32 as _); pub const DB_E_BADCONVERTFLAG: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217828i32 as _); pub const DB_E_BADCOPY: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217863i32 as _); pub const DB_E_BADDEFERRABILITY: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217799i32 as _); pub const DB_E_BADDYNAMICERRORID: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217830i32 as _); pub const DB_E_BADHRESULT: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217832i32 as _); pub const DB_E_BADID: i32 = -2147217860i32; pub const DB_E_BADINDEXID: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217806i32 as _); pub const DB_E_BADINITSTRING: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217805i32 as _); pub const DB_E_BADLOCKMODE: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217905i32 as _); pub const DB_E_BADLOOKUPID: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217831i32 as _); pub const DB_E_BADMATCHTYPE: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217792i32 as _); pub const DB_E_BADORDINAL: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217835i32 as _); pub const DB_E_BADPARAMETERNAME: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217827i32 as _); pub const DB_E_BADPRECISION: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217862i32 as _); pub const DB_E_BADPROPERTYVALUE: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217852i32 as _); pub const DB_E_BADRATIO: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217902i32 as _); pub const DB_E_BADRECORDNUM: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217854i32 as _); pub const DB_E_BADREGIONHANDLE: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217878i32 as _); pub const DB_E_BADROWHANDLE: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217916i32 as _); pub const DB_E_BADSCALE: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217861i32 as _); pub const DB_E_BADSOURCEHANDLE: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217840i32 as _); pub const DB_E_BADSTARTPOSITION: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217890i32 as _); pub const DB_E_BADSTATUSVALUE: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217880i32 as _); pub const DB_E_BADSTORAGEFLAG: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217882i32 as _); pub const DB_E_BADSTORAGEFLAGS: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217849i32 as _); pub const DB_E_BADTABLEID: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217860i32 as _); pub const DB_E_BADTYPE: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217859i32 as _); pub const DB_E_BADTYPENAME: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217872i32 as _); pub const DB_E_BADUPDATEDELETERULE: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217782i32 as _); pub const DB_E_BADVALUES: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217901i32 as _); pub const DB_E_BOGUS: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217665i32 as _); pub const DB_E_BOOKMARKSKIPPED: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217853i32 as _); pub const DB_E_BYREFACCESSORNOTSUPPORTED: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217848i32 as _); pub const DB_E_CANCELED: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217842i32 as _); pub const DB_E_CANNOTCONNECT: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217770i32 as _); pub const DB_E_CANNOTFREE: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217894i32 as _); pub const DB_E_CANNOTRESTART: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217896i32 as _); pub const DB_E_CANTCANCEL: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217899i32 as _); pub const DB_E_CANTCONVERTVALUE: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217913i32 as _); pub const DB_E_CANTFETCHBACKWARDS: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217884i32 as _); pub const DB_E_CANTFILTER: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217825i32 as _); pub const DB_E_CANTORDER: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217824i32 as _); pub const DB_E_CANTSCROLLBACKWARDS: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217879i32 as _); pub const DB_E_CANTTRANSLATE: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217869i32 as _); pub const DB_E_CHAPTERNOTRELEASED: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217841i32 as _); pub const DB_E_COLUMNUNAVAILABLE: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217760i32 as _); pub const DB_E_COMMANDNOTPERSISTED: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217817i32 as _); pub const DB_E_CONCURRENCYVIOLATION: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217864i32 as _); pub const DB_E_COSTLIMIT: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217907i32 as _); pub const DB_E_DATAOVERFLOW: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217833i32 as _); pub const DB_E_DELETEDROW: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217885i32 as _); pub const DB_E_DIALECTNOTSUPPORTED: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217898i32 as _); pub const DB_E_DROPRESTRICTED: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217776i32 as _); pub const DB_E_DUPLICATECOLUMNID: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217858i32 as _); pub const DB_E_DUPLICATECONSTRAINTID: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217767i32 as _); pub const DB_E_DUPLICATEDATASOURCE: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217897i32 as _); pub const DB_E_DUPLICATEID: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217816i32 as _); pub const DB_E_DUPLICATEINDEXID: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217868i32 as _); pub const DB_E_DUPLICATETABLEID: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217857i32 as _); pub const DB_E_ERRORSINCOMMAND: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217900i32 as _); pub const DB_E_ERRORSOCCURRED: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217887i32 as _); pub const DB_E_GOALREJECTED: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217892i32 as _); pub const DB_E_INDEXINUSE: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217866i32 as _); pub const DB_E_INTEGRITYVIOLATION: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217873i32 as _); pub const DB_E_INVALID: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217851i32 as _); pub const DB_E_INVALIDTRANSITION: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217876i32 as _); pub const DB_E_LIMITREJECTED: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217909i32 as _); pub const DB_E_MAXPENDCHANGESEXCEEDED: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217836i32 as _); pub const DB_E_MISMATCHEDPROVIDER: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217803i32 as _); pub const DB_E_MULTIPLESTATEMENTS: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217874i32 as _); pub const DB_E_MULTIPLESTORAGE: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217826i32 as _); pub const DB_E_NEWLYINSERTED: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217893i32 as _); pub const DB_E_NOAGGREGATION: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217886i32 as _); pub const DB_E_NOCOLUMN: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217819i32 as _); pub const DB_E_NOCOMMAND: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217908i32 as _); pub const DB_E_NOCONSTRAINT: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217761i32 as _); pub const DB_E_NOINDEX: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217867i32 as _); pub const DB_E_NOLOCALE: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217855i32 as _); pub const DB_E_NONCONTIGUOUSRANGE: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217877i32 as _); pub const DB_E_NOPROVIDERSREGISTERED: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217804i32 as _); pub const DB_E_NOQUERY: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217889i32 as _); pub const DB_E_NOSOURCEOBJECT: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217775i32 as _); pub const DB_E_NOSTATISTIC: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217764i32 as _); pub const DB_E_NOTABLE: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217865i32 as _); pub const DB_E_NOTAREFERENCECOLUMN: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217910i32 as _); pub const DB_E_NOTASUBREGION: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217875i32 as _); pub const DB_E_NOTCOLLECTION: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217773i32 as _); pub const DB_E_NOTFOUND: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217895i32 as _); pub const DB_E_NOTPREPARED: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217846i32 as _); pub const DB_E_NOTREENTRANT: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217888i32 as _); pub const DB_E_NOTSUPPORTED: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217837i32 as _); pub const DB_E_NULLACCESSORNOTSUPPORTED: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217847i32 as _); pub const DB_E_OBJECTCREATIONLIMITREACHED: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217815i32 as _); pub const DB_E_OBJECTMISMATCH: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217779i32 as _); pub const DB_E_OBJECTOPEN: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217915i32 as _); pub const DB_E_OUTOFSPACE: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217766i32 as _); pub const DB_E_PARAMNOTOPTIONAL: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217904i32 as _); pub const DB_E_PARAMUNAVAILABLE: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217839i32 as _); pub const DB_E_PENDINGCHANGES: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217834i32 as _); pub const DB_E_PENDINGINSERT: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217829i32 as _); pub const DB_E_READONLY: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217772i32 as _); pub const DB_E_READONLYACCESSOR: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217918i32 as _); pub const DB_E_RESOURCEEXISTS: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217768i32 as _); pub const DB_E_RESOURCELOCKED: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217774i32 as _); pub const DB_E_RESOURCENOTSUPPORTED: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217762i32 as _); pub const DB_E_RESOURCEOUTOFSCOPE: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217778i32 as _); pub const DB_E_ROWLIMITEXCEEDED: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217919i32 as _); pub const DB_E_ROWSETINCOMMAND: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217870i32 as _); pub const DB_E_ROWSNOTRELEASED: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217883i32 as _); pub const DB_E_SCHEMAVIOLATION: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217917i32 as _); pub const DB_E_TABLEINUSE: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217856i32 as _); pub const DB_E_TIMEOUT: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217769i32 as _); pub const DB_E_UNSUPPORTEDCONVERSION: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217891i32 as _); pub const DB_E_WRITEONLYACCESSOR: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217844i32 as _); pub const DB_IMP_LEVEL_ANONYMOUS: u32 = 0u32; pub const DB_IMP_LEVEL_DELEGATE: u32 = 3u32; pub const DB_IMP_LEVEL_IDENTIFY: u32 = 1u32; pub const DB_IMP_LEVEL_IMPERSONATE: u32 = 2u32; pub const DB_IN: u32 = 1u32; pub const DB_INVALID_HACCESSOR: u32 = 0u32; pub const DB_INVALID_HCHAPTER: u32 = 0u32; pub const DB_LIKE_ONLY: u32 = 2u32; pub const DB_LOCAL_EXCLUSIVE: u32 = 3u32; pub const DB_LOCAL_SHARED: u32 = 2u32; pub const DB_MODE_READ: u32 = 1u32; pub const DB_MODE_READWRITE: u32 = 3u32; pub const DB_MODE_SHARE_DENY_NONE: u32 = 16u32; pub const DB_MODE_SHARE_DENY_READ: u32 = 4u32; pub const DB_MODE_SHARE_DENY_WRITE: u32 = 8u32; pub const DB_MODE_SHARE_EXCLUSIVE: u32 = 12u32; pub const DB_MODE_WRITE: u32 = 2u32; pub const DB_NULL_HACCESSOR: u32 = 0u32; pub const DB_NULL_HCHAPTER: u32 = 0u32; pub const DB_NULL_HROW: u32 = 0u32; #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] pub struct DB_NUMERIC { pub precision: u8, pub scale: u8, pub sign: u8, pub val: [u8; 16], } impl DB_NUMERIC {} impl ::core::default::Default for DB_NUMERIC { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } impl ::core::fmt::Debug for DB_NUMERIC { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("DB_NUMERIC").field("precision", &self.precision).field("scale", &self.scale).field("sign", &self.sign).field("val", &self.val).finish() } } impl ::core::cmp::PartialEq for DB_NUMERIC { fn eq(&self, other: &Self) -> bool { self.precision == other.precision && self.scale == other.scale && self.sign == other.sign && self.val == other.val } } impl ::core::cmp::Eq for DB_NUMERIC {} unsafe impl ::windows::core::Abi for DB_NUMERIC { type Abi = Self; } pub const DB_OUT: u32 = 2u32; pub const DB_PROT_LEVEL_CALL: u32 = 2u32; pub const DB_PROT_LEVEL_CONNECT: u32 = 1u32; pub const DB_PROT_LEVEL_NONE: u32 = 0u32; pub const DB_PROT_LEVEL_PKT: u32 = 3u32; pub const DB_PROT_LEVEL_PKT_INTEGRITY: u32 = 4u32; pub const DB_PROT_LEVEL_PKT_PRIVACY: u32 = 5u32; pub const DB_PT_FUNCTION: u32 = 3u32; pub const DB_PT_PROCEDURE: u32 = 2u32; pub const DB_PT_UNKNOWN: u32 = 1u32; pub const DB_REMOTE: u32 = 1u32; pub const DB_SEARCHABLE: u32 = 4u32; pub const DB_SEC_E_AUTH_FAILED: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217843i32 as _); pub const DB_SEC_E_PERMISSIONDENIED: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217911i32 as _); pub const DB_SEC_E_SAFEMODE_DENIED: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217765i32 as _); pub const DB_S_ASYNCHRONOUS: ::windows::core::HRESULT = ::windows::core::HRESULT(265936i32 as _); pub const DB_S_BADROWHANDLE: ::windows::core::HRESULT = ::windows::core::HRESULT(265939i32 as _); pub const DB_S_BOOKMARKSKIPPED: ::windows::core::HRESULT = ::windows::core::HRESULT(265923i32 as _); pub const DB_S_BUFFERFULL: ::windows::core::HRESULT = ::windows::core::HRESULT(265928i32 as _); pub const DB_S_CANTRELEASE: ::windows::core::HRESULT = ::windows::core::HRESULT(265930i32 as _); pub const DB_S_COLUMNSCHANGED: ::windows::core::HRESULT = ::windows::core::HRESULT(265937i32 as _); pub const DB_S_COLUMNTYPEMISMATCH: ::windows::core::HRESULT = ::windows::core::HRESULT(265921i32 as _); pub const DB_S_COMMANDREEXECUTED: ::windows::core::HRESULT = ::windows::core::HRESULT(265927i32 as _); pub const DB_S_DELETEDROW: ::windows::core::HRESULT = ::windows::core::HRESULT(265940i32 as _); pub const DB_S_DIALECTIGNORED: ::windows::core::HRESULT = ::windows::core::HRESULT(265933i32 as _); pub const DB_S_ENDOFROWSET: ::windows::core::HRESULT = ::windows::core::HRESULT(265926i32 as _); pub const DB_S_ERRORSOCCURRED: ::windows::core::HRESULT = ::windows::core::HRESULT(265946i32 as _); pub const DB_S_ERRORSRETURNED: ::windows::core::HRESULT = ::windows::core::HRESULT(265938i32 as _); pub const DB_S_GOALCHANGED: ::windows::core::HRESULT = ::windows::core::HRESULT(265931i32 as _); pub const DB_S_LOCKUPGRADED: ::windows::core::HRESULT = ::windows::core::HRESULT(265944i32 as _); pub const DB_S_MULTIPLECHANGES: ::windows::core::HRESULT = ::windows::core::HRESULT(265948i32 as _); pub const DB_S_NONEXTROWSET: ::windows::core::HRESULT = ::windows::core::HRESULT(265925i32 as _); pub const DB_S_NORESULT: ::windows::core::HRESULT = ::windows::core::HRESULT(265929i32 as _); pub const DB_S_NOROWSPECIFICCOLUMNS: ::windows::core::HRESULT = ::windows::core::HRESULT(265949i32 as _); pub const DB_S_NOTSINGLETON: ::windows::core::HRESULT = ::windows::core::HRESULT(265943i32 as _); pub const DB_S_PARAMUNAVAILABLE: ::windows::core::HRESULT = ::windows::core::HRESULT(265947i32 as _); pub const DB_S_PROPERTIESCHANGED: ::windows::core::HRESULT = ::windows::core::HRESULT(265945i32 as _); pub const DB_S_ROWLIMITEXCEEDED: ::windows::core::HRESULT = ::windows::core::HRESULT(265920i32 as _); pub const DB_S_STOPLIMITREACHED: ::windows::core::HRESULT = ::windows::core::HRESULT(265942i32 as _); pub const DB_S_TOOMANYCHANGES: ::windows::core::HRESULT = ::windows::core::HRESULT(265941i32 as _); pub const DB_S_TYPEINFOOVERRIDDEN: ::windows::core::HRESULT = ::windows::core::HRESULT(265922i32 as _); pub const DB_S_UNWANTEDOPERATION: ::windows::core::HRESULT = ::windows::core::HRESULT(265932i32 as _); pub const DB_S_UNWANTEDPHASE: ::windows::core::HRESULT = ::windows::core::HRESULT(265934i32 as _); pub const DB_S_UNWANTEDREASON: ::windows::core::HRESULT = ::windows::core::HRESULT(265935i32 as _); pub const DB_UNSEARCHABLE: u32 = 1u32; #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] pub struct DB_VARNUMERIC { pub precision: u8, pub scale: i8, pub sign: u8, pub val: [u8; 1], } impl DB_VARNUMERIC {} impl ::core::default::Default for DB_VARNUMERIC { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } impl ::core::fmt::Debug for DB_VARNUMERIC { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("DB_VARNUMERIC").field("precision", &self.precision).field("scale", &self.scale).field("sign", &self.sign).field("val", &self.val).finish() } } impl ::core::cmp::PartialEq for DB_VARNUMERIC { fn eq(&self, other: &Self) -> bool { self.precision == other.precision && self.scale == other.scale && self.sign == other.sign && self.val == other.val } } impl ::core::cmp::Eq for DB_VARNUMERIC {} unsafe impl ::windows::core::Abi for DB_VARNUMERIC { type Abi = Self; } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::clone::Clone for DCINFO { fn clone(&self) -> Self { unimplemented!() } } #[repr(C)] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub struct DCINFO { pub eInfoType: u32, pub vData: super::Com::VARIANT, } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl DCINFO {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::default::Default for DCINFO { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::cmp::PartialEq for DCINFO { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::cmp::Eq for DCINFO {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] unsafe impl ::windows::core::Abi for DCINFO { type Abi = ::core::mem::ManuallyDrop<Self>; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DCINFOTYPEENUM(pub i32); pub const DCINFOTYPE_VERSION: DCINFOTYPEENUM = DCINFOTYPEENUM(1i32); impl ::core::convert::From<i32> for DCINFOTYPEENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DCINFOTYPEENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct DELIVERY_AGENT_FLAGS(pub i32); pub const DELIVERY_AGENT_FLAG_NO_BROADCAST: DELIVERY_AGENT_FLAGS = DELIVERY_AGENT_FLAGS(4i32); pub const DELIVERY_AGENT_FLAG_NO_RESTRICTIONS: DELIVERY_AGENT_FLAGS = DELIVERY_AGENT_FLAGS(8i32); pub const DELIVERY_AGENT_FLAG_SILENT_DIAL: DELIVERY_AGENT_FLAGS = DELIVERY_AGENT_FLAGS(16i32); impl ::core::convert::From<i32> for DELIVERY_AGENT_FLAGS { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for DELIVERY_AGENT_FLAGS { type Abi = Self; } pub const DISPID_QUERY_ALL: u32 = 6u32; pub const DISPID_QUERY_HITCOUNT: u32 = 4u32; pub const DISPID_QUERY_LASTSEENTIME: u32 = 10u32; pub const DISPID_QUERY_METADATA_PROPDISPID: u32 = 6u32; pub const DISPID_QUERY_METADATA_PROPGUID: u32 = 5u32; pub const DISPID_QUERY_METADATA_PROPMODIFIABLE: u32 = 9u32; pub const DISPID_QUERY_METADATA_PROPNAME: u32 = 7u32; pub const DISPID_QUERY_METADATA_STORELEVEL: u32 = 8u32; pub const DISPID_QUERY_METADATA_VROOTAUTOMATIC: u32 = 3u32; pub const DISPID_QUERY_METADATA_VROOTMANUAL: u32 = 4u32; pub const DISPID_QUERY_METADATA_VROOTUSED: u32 = 2u32; pub const DISPID_QUERY_RANK: u32 = 3u32; pub const DISPID_QUERY_RANKVECTOR: u32 = 2u32; pub const DISPID_QUERY_REVNAME: u32 = 8u32; pub const DISPID_QUERY_UNFILTERED: u32 = 7u32; pub const DISPID_QUERY_VIRTUALPATH: u32 = 9u32; pub const DISPID_QUERY_WORKID: u32 = 5u32; pub const DS_E_ALREADYDISABLED: i32 = -2147220447i32; pub const DS_E_ALREADYENABLED: i32 = -2147220454i32; pub const DS_E_BADREQUEST: i32 = -2147220475i32; pub const DS_E_BADRESULT: i32 = -2147220445i32; pub const DS_E_BADSEQUENCE: i32 = -2147220473i32; pub const DS_E_BUFFERTOOSMALL: i32 = -2147220449i32; pub const DS_E_CANNOTREMOVECONCURRENT: i32 = -2147220443i32; pub const DS_E_CANNOTWRITEREGISTRY: i32 = -2147220444i32; pub const DS_E_CONFIGBAD: i32 = -2147220470i32; pub const DS_E_CONFIGNOTRIGHTTYPE: i32 = -2147220456i32; pub const DS_E_DATANOTPRESENT: i32 = -2147220464i32; pub const DS_E_DATASOURCENOTAVAILABLE: i32 = -2147220478i32; pub const DS_E_DATASOURCENOTDISABLED: i32 = -2147220459i32; pub const DS_E_DUPLICATEID: i32 = -2147220462i32; pub const DS_E_INDEXDIRECTORY: i32 = -2147220452i32; pub const DS_E_INVALIDCATALOGNAME: i32 = -2147220457i32; pub const DS_E_INVALIDDATASOURCE: i32 = -2147220479i32; pub const DS_E_INVALIDTAGDB: i32 = -2147220458i32; pub const DS_E_MESSAGETOOLONG: i32 = -2147220472i32; pub const DS_E_MISSINGCATALOG: i32 = -2147220440i32; pub const DS_E_NOMOREDATA: i32 = -2147220480i32; pub const DS_E_PARAMOUTOFRANGE: i32 = -2147220448i32; pub const DS_E_PROPVERSIONMISMATCH: i32 = -2147220441i32; pub const DS_E_PROTOCOLVERSION: i32 = -2147220455i32; pub const DS_E_QUERYCANCELED: i32 = -2147220477i32; pub const DS_E_QUERYHUNG: i32 = -2147220446i32; pub const DS_E_REGISTRY: i32 = -2147220460i32; pub const DS_E_SEARCHCATNAMECOLLISION: i32 = -2147220442i32; pub const DS_E_SERVERCAPACITY: i32 = -2147220474i32; pub const DS_E_SERVERERROR: i32 = -2147220471i32; pub const DS_E_SETSTATUSINPROGRESS: i32 = -2147220463i32; pub const DS_E_TOOMANYDATASOURCES: i32 = -2147220461i32; pub const DS_E_UNKNOWNPARAM: i32 = -2147220450i32; pub const DS_E_UNKNOWNREQUEST: i32 = -2147220476i32; pub const DS_E_VALUETOOLARGE: i32 = -2147220451i32; pub const DataLinks: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x2206cdb2_19c1_11d1_89e0_00c04fd7a829); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct DataSource(pub ::windows::core::IUnknown); impl DataSource { pub unsafe fn getDataMember(&self, bstrdm: *const u16, riid: *const ::windows::core::GUID) -> ::windows::core::Result<::windows::core::IUnknown> { let mut result__: <::windows::core::IUnknown as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(bstrdm), ::core::mem::transmute(riid), &mut result__).from_abi::<::windows::core::IUnknown>(result__) } pub unsafe fn getDataMemberName(&self, lindex: i32) -> ::windows::core::Result<*mut u16> { let mut result__: <*mut u16 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(lindex), &mut result__).from_abi::<*mut u16>(result__) } pub unsafe fn getDataMemberCount(&self) -> ::windows::core::Result<i32> { let mut result__: <i32 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), &mut result__).from_abi::<i32>(result__) } pub unsafe fn addDataSourceListener<'a, Param0: ::windows::core::IntoParam<'a, DataSourceListener>>(&self, pdsl: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), pdsl.into_param().abi()).ok() } pub unsafe fn removeDataSourceListener<'a, Param0: ::windows::core::IntoParam<'a, DataSourceListener>>(&self, pdsl: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), pdsl.into_param().abi()).ok() } } unsafe impl ::windows::core::Interface for DataSource { type Vtable = DataSource_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x7c0ffab3_cd84_11d0_949a_00a0c91110ed); } impl ::core::convert::From<DataSource> for ::windows::core::IUnknown { fn from(value: DataSource) -> Self { value.0 } } impl ::core::convert::From<&DataSource> for ::windows::core::IUnknown { fn from(value: &DataSource) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for DataSource { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a DataSource { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct DataSource_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, bstrdm: *const u16, riid: *const ::windows::core::GUID, ppunk: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, lindex: i32, pbstrdm: *mut *mut u16) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, plcount: *mut i32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pdsl: ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pdsl: ::windows::core::RawPtr) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct DataSourceListener(pub ::windows::core::IUnknown); impl DataSourceListener { pub unsafe fn dataMemberChanged(&self, bstrdm: *const u16) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(bstrdm)).ok() } pub unsafe fn dataMemberAdded(&self, bstrdm: *const u16) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(bstrdm)).ok() } pub unsafe fn dataMemberRemoved(&self, bstrdm: *const u16) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(bstrdm)).ok() } } unsafe impl ::windows::core::Interface for DataSourceListener { type Vtable = DataSourceListener_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x7c0ffab2_cd84_11d0_949a_00a0c91110ed); } impl ::core::convert::From<DataSourceListener> for ::windows::core::IUnknown { fn from(value: DataSourceListener) -> Self { value.0 } } impl ::core::convert::From<&DataSourceListener> for ::windows::core::IUnknown { fn from(value: &DataSourceListener) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for DataSourceListener { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a DataSourceListener { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct DataSourceListener_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, bstrdm: *const u16) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, bstrdm: *const u16) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, bstrdm: *const u16) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct DataSourceObject(pub ::windows::core::IUnknown); impl DataSourceObject {} unsafe impl ::windows::core::Interface for DataSourceObject { type Vtable = DataSourceObject_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0ae9a4e4_18d4_11d1_b3b3_00aa00c1a924); } impl ::core::convert::From<DataSourceObject> for ::windows::core::IUnknown { fn from(value: DataSourceObject) -> Self { value.0 } } impl ::core::convert::From<&DataSourceObject> for ::windows::core::IUnknown { fn from(value: &DataSourceObject) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for DataSourceObject { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a DataSourceObject { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[cfg(feature = "Win32_System_Com")] impl ::core::convert::From<DataSourceObject> for super::Com::IDispatch { fn from(value: DataSourceObject) -> Self { unsafe { ::core::mem::transmute(value) } } } #[cfg(feature = "Win32_System_Com")] impl ::core::convert::From<&DataSourceObject> for super::Com::IDispatch { fn from(value: &DataSourceObject) -> Self { ::core::convert::From::from(::core::clone::Clone::clone(value)) } } #[cfg(feature = "Win32_System_Com")] impl<'a> ::windows::core::IntoParam<'a, super::Com::IDispatch> for DataSourceObject { fn into_param(self) -> ::windows::core::Param<'a, super::Com::IDispatch> { ::windows::core::Param::Owned(unsafe { ::core::mem::transmute(self) }) } } #[cfg(feature = "Win32_System_Com")] impl<'a> ::windows::core::IntoParam<'a, super::Com::IDispatch> for &DataSourceObject { fn into_param(self) -> ::windows::core::Param<'a, super::Com::IDispatch> { ::windows::core::Param::Borrowed(unsafe { ::core::mem::transmute(self) }) } } #[repr(C)] #[doc(hidden)] pub struct DataSourceObject_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pctinfo: *mut u32) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_System_Com")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, itinfo: u32, lcid: u32, pptinfo: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_System_Com"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, riid: *const ::windows::core::GUID, rgsznames: *const super::super::Foundation::PWSTR, cnames: u32, lcid: u32, rgdispid: *mut i32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, dispidmember: i32, riid: *const ::windows::core::GUID, lcid: u32, wflags: u16, pdispparams: *const super::Com::DISPPARAMS, pvarresult: *mut ::core::mem::ManuallyDrop<super::Com::VARIANT>, pexcepinfo: *mut ::core::mem::ManuallyDrop<super::Com::EXCEPINFO>, puargerr: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, ); #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct EBindInfoOptions(pub i32); pub const BIO_BINDER: EBindInfoOptions = EBindInfoOptions(1i32); impl ::core::convert::From<i32> for EBindInfoOptions { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for EBindInfoOptions { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] pub struct ERRORINFO { pub hrError: ::windows::core::HRESULT, pub dwMinor: u32, pub clsid: ::windows::core::GUID, pub iid: ::windows::core::GUID, pub dispid: i32, } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ERRORINFO {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::default::Default for ERRORINFO { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::fmt::Debug for ERRORINFO { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("ERRORINFO").field("hrError", &self.hrError).field("dwMinor", &self.dwMinor).field("clsid", &self.clsid).field("iid", &self.iid).field("dispid", &self.dispid).finish() } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::cmp::PartialEq for ERRORINFO { fn eq(&self, other: &Self) -> bool { self.hrError == other.hrError && self.dwMinor == other.dwMinor && self.clsid == other.clsid && self.iid == other.iid && self.dispid == other.dispid } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::cmp::Eq for ERRORINFO {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] unsafe impl ::windows::core::Abi for ERRORINFO { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C, packed(2))] #[cfg(any(target_arch = "x86",))] pub struct ERRORINFO { pub hrError: ::windows::core::HRESULT, pub dwMinor: u32, pub clsid: ::windows::core::GUID, pub iid: ::windows::core::GUID, pub dispid: i32, } #[cfg(any(target_arch = "x86",))] impl ERRORINFO {} #[cfg(any(target_arch = "x86",))] impl ::core::default::Default for ERRORINFO { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86",))] impl ::core::cmp::PartialEq for ERRORINFO { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(any(target_arch = "x86",))] impl ::core::cmp::Eq for ERRORINFO {} #[cfg(any(target_arch = "x86",))] unsafe impl ::windows::core::Abi for ERRORINFO { type Abi = Self; } pub const ERROR_FTE: u32 = 13824u32; pub const ERROR_FTE_CB: u32 = 51968u32; pub const ERROR_FTE_FD: u32 = 64768u32; pub const ERROR_SOURCE_CMDLINE: u32 = 5376u32; pub const ERROR_SOURCE_COLLATOR: u32 = 1280u32; pub const ERROR_SOURCE_CONNMGR: u32 = 1536u32; pub const ERROR_SOURCE_CONTENT_SOURCE: u32 = 13312u32; pub const ERROR_SOURCE_DATASOURCE: u32 = 1024u32; pub const ERROR_SOURCE_DAV: u32 = 8960u32; pub const ERROR_SOURCE_EXSTOREPH: u32 = 9984u32; pub const ERROR_SOURCE_FLTRDMN: u32 = 9216u32; pub const ERROR_SOURCE_GATHERER: u32 = 3328u32; pub const ERROR_SOURCE_INDEXER: u32 = 4352u32; pub const ERROR_SOURCE_MSS: u32 = 8448u32; pub const ERROR_SOURCE_NETWORKING: u32 = 768u32; pub const ERROR_SOURCE_NLADMIN: u32 = 6400u32; pub const ERROR_SOURCE_NOTESPH: u32 = 9728u32; pub const ERROR_SOURCE_OLEDB_BINDER: u32 = 9472u32; pub const ERROR_SOURCE_PEOPLE_IMPORT: u32 = 16384u32; pub const ERROR_SOURCE_PROTHNDLR: u32 = 4608u32; pub const ERROR_SOURCE_QUERY: u32 = 1792u32; pub const ERROR_SOURCE_REMOTE_EXSTOREPH: u32 = 13568u32; pub const ERROR_SOURCE_SCHEMA: u32 = 3072u32; pub const ERROR_SOURCE_SCRIPTPI: u32 = 8192u32; pub const ERROR_SOURCE_SECURITY: u32 = 5120u32; pub const ERROR_SOURCE_SETUP: u32 = 4864u32; pub const ERROR_SOURCE_SRCH_SCHEMA_CACHE: u32 = 13056u32; pub const ERROR_SOURCE_XML: u32 = 8704u32; pub const EVENT_AUDIENCECOMPUTATION_CANNOTSTART: i32 = -1073738223i32; pub const EVENT_AUTOCAT_CANT_CREATE_FILE_SHARE: i32 = -1073738726i32; pub const EVENT_AUTOCAT_PERFMON: i32 = -1073738753i32; pub const EVENT_CONFIG_ERROR: i32 = -1073738821i32; pub const EVENT_CONFIG_SYNTAX: i32 = -2147482604i32; pub const EVENT_CRAWL_SCHEDULED: i32 = 1073744884i32; pub const EVENT_DETAILED_FILTERPOOL_ADD_FAILED: i32 = -1073738719i32; pub const EVENT_DSS_NOT_ENABLED: i32 = -2147476572i32; pub const EVENT_ENUMERATE_SESSIONS_FAILED: i32 = -1073738720i32; pub const EVENT_EXCEPTION: i32 = -1073740815i32; pub const EVENT_FAILED_CREATE_GATHERER_LOG: i32 = -2147480587i32; pub const EVENT_FAILED_INITIALIZE_CRAWL: i32 = -1073738765i32; pub const EVENT_FILTERPOOL_ADD_FAILED: i32 = -1073738722i32; pub const EVENT_FILTERPOOL_DELETE_FAILED: i32 = -1073738721i32; pub const EVENT_FILTER_HOST_FORCE_TERMINATE: i32 = -2147473624i32; pub const EVENT_FILTER_HOST_NOT_INITIALIZED: i32 = -1073738724i32; pub const EVENT_FILTER_HOST_NOT_TERMINATED: i32 = -1073738723i32; pub const EVENT_GATHERER_DATASOURCE: i32 = -1073738727i32; pub const EVENT_GATHERER_PERFMON: i32 = -1073738817i32; pub const EVENT_GATHERSVC_PERFMON: i32 = -1073738818i32; pub const EVENT_GATHER_ADVISE_FAILED: i32 = -1073738798i32; pub const EVENT_GATHER_APP_INIT_FAILED: i32 = -1073738766i32; pub const EVENT_GATHER_AUTODESCENCODE_INVALID: i32 = -2147480592i32; pub const EVENT_GATHER_AUTODESCLEN_ADJUSTED: i32 = -2147480603i32; pub const EVENT_GATHER_BACKUPAPP_COMPLETE: i32 = 3077i32; pub const EVENT_GATHER_BACKUPAPP_ERROR: i32 = -1073738748i32; pub const EVENT_GATHER_CANT_CREATE_DOCID: i32 = -1073738793i32; pub const EVENT_GATHER_CANT_DELETE_DOCID: i32 = -1073738792i32; pub const EVENT_GATHER_CHECKPOINT_CORRUPT: i32 = -1073738732i32; pub const EVENT_GATHER_CHECKPOINT_FAILED: i32 = -1073738736i32; pub const EVENT_GATHER_CHECKPOINT_FILE_MISSING: i32 = -1073738731i32; pub const EVENT_GATHER_CRAWL_IN_PROGRESS: i32 = -2147480609i32; pub const EVENT_GATHER_CRAWL_NOT_STARTED: i32 = -2147480625i32; pub const EVENT_GATHER_CRAWL_SEED_ERROR: i32 = -2147480624i32; pub const EVENT_GATHER_CRAWL_SEED_FAILED: i32 = -2147480612i32; pub const EVENT_GATHER_CRAWL_SEED_FAILED_INIT: i32 = -2147480611i32; pub const EVENT_GATHER_CRITICAL_ERROR: i32 = -1073738799i32; pub const EVENT_GATHER_DAEMON_TERMINATED: i32 = -2147480570i32; pub const EVENT_GATHER_DELETING_HISTORY_ITEMS: i32 = -1073738774i32; pub const EVENT_GATHER_DIRTY_STARTUP: i32 = -2147480576i32; pub const EVENT_GATHER_DISK_FULL: i32 = -2147480594i32; pub const EVENT_GATHER_END_ADAPTIVE: i32 = 1073744891i32; pub const EVENT_GATHER_END_CRAWL: i32 = 1073744842i32; pub const EVENT_GATHER_END_INCREMENTAL: i32 = 1073744871i32; pub const EVENT_GATHER_EXCEPTION: i32 = -1073738810i32; pub const EVENT_GATHER_FLUSH_FAILED: i32 = -1073738737i32; pub const EVENT_GATHER_FROM_NOT_SET: i32 = -1073738776i32; pub const EVENT_GATHER_HISTORY_CORRUPTION_DETECTED: i32 = -2147480575i32; pub const EVENT_GATHER_INTERNAL: i32 = -1073738804i32; pub const EVENT_GATHER_INVALID_NETWORK_ACCESS_ACCOUNT: i32 = -1073738739i32; pub const EVENT_GATHER_LOCK_FAILED: i32 = -1073738784i32; pub const EVENT_GATHER_NO_CRAWL_SEEDS: i32 = -2147480602i32; pub const EVENT_GATHER_NO_SCHEMA: i32 = -2147480593i32; pub const EVENT_GATHER_OBJ_INIT_FAILED: i32 = -1073738796i32; pub const EVENT_GATHER_PLUGINMGR_INIT_FAILED: i32 = -1073738767i32; pub const EVENT_GATHER_PLUGIN_INIT_FAILED: i32 = -1073738795i32; pub const EVENT_GATHER_PROTOCOLHANDLER_INIT_FAILED: i32 = -1073738740i32; pub const EVENT_GATHER_PROTOCOLHANDLER_LOAD_FAILED: i32 = -1073738741i32; pub const EVENT_GATHER_READ_CHECKPOINT_FAILED: i32 = -1073738733i32; pub const EVENT_GATHER_RECOVERY_FAILURE: i32 = -1073738222i32; pub const EVENT_GATHER_REG_MISSING: i32 = -2147480610i32; pub const EVENT_GATHER_RESET_START: i32 = 1073744865i32; pub const EVENT_GATHER_RESTOREAPP_COMPLETE: i32 = 3075i32; pub const EVENT_GATHER_RESTOREAPP_ERROR: i32 = -1073738750i32; pub const EVENT_GATHER_RESTORE_CHECKPOINT_FAILED: i32 = -1073738734i32; pub const EVENT_GATHER_RESTORE_COMPLETE: i32 = 3069i32; pub const EVENT_GATHER_RESTORE_ERROR: i32 = -1073738754i32; pub const EVENT_GATHER_RESUME: i32 = 1073744868i32; pub const EVENT_GATHER_SAVE_FAILED: i32 = -1073738735i32; pub const EVENT_GATHER_SERVICE_INIT: i32 = -1073738794i32; pub const EVENT_GATHER_START_CRAWL: i32 = 1073744843i32; pub const EVENT_GATHER_START_CRAWL_IF_RESET: i32 = -2147480595i32; pub const EVENT_GATHER_START_PAUSE: i32 = -2147480606i32; pub const EVENT_GATHER_STOP_START: i32 = 1073744876i32; pub const EVENT_GATHER_SYSTEM_LCID_CHANGED: i32 = -2147480562i32; pub const EVENT_GATHER_THROTTLE: i32 = 1073744867i32; pub const EVENT_GATHER_TRANSACTION_FAIL: i32 = -1073738797i32; pub const EVENT_HASHMAP_INSERT: i32 = -1073738816i32; pub const EVENT_HASHMAP_UPDATE: i32 = -1073738811i32; pub const EVENT_INDEXER_ADD_DSS_DISCONNECT: i32 = -2147476585i32; pub const EVENT_INDEXER_ADD_DSS_FAILED: i32 = -2147476627i32; pub const EVENT_INDEXER_ADD_DSS_SUCCEEDED: i32 = 7019i32; pub const EVENT_INDEXER_BUILD_ENDED: i32 = 1073748873i32; pub const EVENT_INDEXER_BUILD_FAILED: i32 = -1073734797i32; pub const EVENT_INDEXER_BUILD_START: i32 = 1073748872i32; pub const EVENT_INDEXER_CI_LOAD_ERROR: i32 = -1073734785i32; pub const EVENT_INDEXER_DSS_ALREADY_ADDED: i32 = 1073748870i32; pub const EVENT_INDEXER_DSS_CONTACT_FAILED: i32 = -1073734800i32; pub const EVENT_INDEXER_DSS_UNABLE_TO_REMOVE: i32 = -1073734755i32; pub const EVENT_INDEXER_FAIL_TO_CREATE_PER_USER_CATALOG: i32 = -1073731797i32; pub const EVENT_INDEXER_FAIL_TO_SET_MAX_JETINSTANCE: i32 = -1073731798i32; pub const EVENT_INDEXER_FAIL_TO_UNLOAD_PER_USER_CATALOG: i32 = -1073731796i32; pub const EVENT_INDEXER_INIT_ERROR: i32 = -1073734814i32; pub const EVENT_INDEXER_INVALID_DIRECTORY: i32 = -1073734813i32; pub const EVENT_INDEXER_LOAD_FAIL: i32 = -1073734781i32; pub const EVENT_INDEXER_MISSING_APP_DIRECTORY: i32 = -1073734758i32; pub const EVENT_INDEXER_NEW_PROJECT: i32 = -1073734754i32; pub const EVENT_INDEXER_NO_SEARCH_SERVERS: i32 = -2147476630i32; pub const EVENT_INDEXER_OUT_OF_DATABASE_INSTANCE: i32 = -1073731799i32; pub const EVENT_INDEXER_PAUSED_FOR_DISKFULL: i32 = -1073734811i32; pub const EVENT_INDEXER_PERFMON: i32 = -1073734760i32; pub const EVENT_INDEXER_PROPSTORE_INIT_FAILED: i32 = -1073734787i32; pub const EVENT_INDEXER_PROP_ABORTED: i32 = 1073748899i32; pub const EVENT_INDEXER_PROP_COMMITTED: i32 = 1073748898i32; pub const EVENT_INDEXER_PROP_COMMIT_FAILED: i32 = -1073734747i32; pub const EVENT_INDEXER_PROP_ERROR: i32 = -1073734812i32; pub const EVENT_INDEXER_PROP_STARTED: i32 = 1073748841i32; pub const EVENT_INDEXER_PROP_STATE_CORRUPT: i32 = -1073734780i32; pub const EVENT_INDEXER_PROP_STOPPED: i32 = -2147476633i32; pub const EVENT_INDEXER_PROP_SUCCEEDED: i32 = 7016i32; pub const EVENT_INDEXER_REG_ERROR: i32 = -1073734756i32; pub const EVENT_INDEXER_REG_MISSING: i32 = -1073734796i32; pub const EVENT_INDEXER_REMOVED_PROJECT: i32 = -1073734753i32; pub const EVENT_INDEXER_REMOVE_DSS_FAILED: i32 = -1073734801i32; pub const EVENT_INDEXER_REMOVE_DSS_SUCCEEDED: i32 = 7020i32; pub const EVENT_INDEXER_RESET_FOR_CORRUPTION: i32 = -1073734784i32; pub const EVENT_INDEXER_SCHEMA_COPY_ERROR: i32 = -1073734823i32; pub const EVENT_INDEXER_SHUTDOWN: i32 = 1073748866i32; pub const EVENT_INDEXER_STARTED: i32 = 1073748824i32; pub const EVENT_INDEXER_VERIFY_PROP_ACCOUNT: i32 = -1073734768i32; pub const EVENT_LEARN_COMPILE_FAILED: i32 = -2147480583i32; pub const EVENT_LEARN_CREATE_DB_FAILED: i32 = -2147480584i32; pub const EVENT_LEARN_PROPAGATION_COPY_FAILED: i32 = -2147480585i32; pub const EVENT_LEARN_PROPAGATION_FAILED: i32 = -2147480582i32; pub const EVENT_LOCAL_GROUPS_CACHE_FLUSHED: i32 = 1073744920i32; pub const EVENT_LOCAL_GROUP_NOT_EXPANDED: i32 = 1073744919i32; pub const EVENT_NOTIFICATION_FAILURE: i32 = -1073738745i32; pub const EVENT_NOTIFICATION_FAILURE_SCOPE_EXCEEDED_LOGGING: i32 = -2147480568i32; pub const EVENT_NOTIFICATION_RESTORED: i32 = 1073744905i32; pub const EVENT_NOTIFICATION_RESTORED_SCOPE_EXCEEDED_LOGGING: i32 = -2147480566i32; pub const EVENT_NOTIFICATION_THREAD_EXIT_FAILED: i32 = -1073738725i32; pub const EVENT_OUTOFMEMORY: i32 = -1073740817i32; pub const EVENT_PERF_COUNTERS_ALREADY_EXISTS: i32 = -2147473626i32; pub const EVENT_PERF_COUNTERS_NOT_LOADED: i32 = -2147473628i32; pub const EVENT_PERF_COUNTERS_REGISTRY_TROUBLE: i32 = -2147473627i32; pub const EVENT_PROTOCOL_HOST_FORCE_TERMINATE: i32 = -2147473625i32; pub const EVENT_REG_VERSION: i32 = -1073738790i32; pub const EVENT_SSSEARCH_CREATE_PATH_RULES_FAILED: i32 = -2147482634i32; pub const EVENT_SSSEARCH_CSM_SAVE_FAILED: i32 = -1073740805i32; pub const EVENT_SSSEARCH_DATAFILES_MOVE_FAILED: i32 = -1073740808i32; pub const EVENT_SSSEARCH_DATAFILES_MOVE_ROLLBACK_ERRORS: i32 = -2147482630i32; pub const EVENT_SSSEARCH_DATAFILES_MOVE_SUCCEEDED: i32 = 1073742841i32; pub const EVENT_SSSEARCH_DROPPED_EVENTS: i32 = -2147482633i32; pub const EVENT_SSSEARCH_SETUP_CLEANUP_FAILED: i32 = -1073740813i32; pub const EVENT_SSSEARCH_SETUP_CLEANUP_STARTED: i32 = -2147482640i32; pub const EVENT_SSSEARCH_SETUP_CLEANUP_SUCCEEDED: i32 = 1073742834i32; pub const EVENT_SSSEARCH_SETUP_FAILED: i32 = -1073740818i32; pub const EVENT_SSSEARCH_SETUP_SUCCEEDED: i32 = 1073742829i32; pub const EVENT_SSSEARCH_STARTED: i32 = 1073742827i32; pub const EVENT_SSSEARCH_STARTING_SETUP: i32 = 1073742828i32; pub const EVENT_SSSEARCH_STOPPED: i32 = 1073742837i32; pub const EVENT_STS_INIT_SECURITY_FAILED: i32 = -2147480554i32; pub const EVENT_SYSTEM_EXCEPTION: i32 = -2147482595i32; pub const EVENT_TRANSACTION_READ: i32 = -1073738809i32; pub const EVENT_TRANSLOG_APPEND: i32 = -1073738814i32; pub const EVENT_TRANSLOG_CREATE: i32 = -1073738791i32; pub const EVENT_TRANSLOG_CREATE_TRX: i32 = -1073738815i32; pub const EVENT_TRANSLOG_UPDATE: i32 = -1073738813i32; pub const EVENT_UNPRIVILEGED_SERVICE_ACCOUNT: i32 = -2147482596i32; pub const EVENT_USING_DIFFERENT_WORD_BREAKER: i32 = -2147480580i32; pub const EVENT_WARNING_CANNOT_UPGRADE_NOISE_FILE: i32 = -2147473634i32; pub const EVENT_WARNING_CANNOT_UPGRADE_NOISE_FILES: i32 = -2147473635i32; pub const EVENT_WBREAKER_NOT_LOADED: i32 = -2147480586i32; pub const EVENT_WIN32_ERROR: i32 = -2147473633i32; pub const EXCI_E_ACCESS_DENIED: i32 = -2147216990i32; pub const EXCI_E_BADCONFIG_OR_ACCESSDENIED: i32 = -2147216988i32; pub const EXCI_E_INVALID_ACCOUNT_INFO: i32 = -2147216984i32; pub const EXCI_E_INVALID_EXCHANGE_SERVER: i32 = -2147216989i32; pub const EXCI_E_INVALID_SERVER_CONFIG: i32 = -2147216991i32; pub const EXCI_E_NOT_ADMIN_OR_WRONG_SITE: i32 = -2147216986i32; pub const EXCI_E_NO_CONFIG: i32 = -2147216992i32; pub const EXCI_E_NO_MAPI: i32 = -2147216985i32; pub const EXCI_E_WRONG_SERVER_OR_ACCT: i32 = -2147216987i32; pub const EXSTOREPH_E_UNEXPECTED: i32 = -2147211519i32; pub const EX_ANY: u32 = 0u32; pub const EX_CMDFATAL: u32 = 20u32; pub const EX_CONTROL: u32 = 25u32; pub const EX_DBCORRUPT: u32 = 23u32; pub const EX_DBFATAL: u32 = 21u32; pub const EX_DEADLOCK: u32 = 13u32; pub const EX_HARDWARE: u32 = 24u32; pub const EX_INFO: u32 = 10u32; pub const EX_INTOK: u32 = 18u32; pub const EX_LIMIT: u32 = 19u32; pub const EX_MAXISEVERITY: u32 = 10u32; pub const EX_MISSING: u32 = 11u32; pub const EX_PERMIT: u32 = 14u32; pub const EX_RESOURCE: u32 = 17u32; pub const EX_SYNTAX: u32 = 15u32; pub const EX_TABCORRUPT: u32 = 22u32; pub const EX_TYPE: u32 = 12u32; pub const EX_USER: u32 = 16u32; pub const FAIL: u32 = 0u32; #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(feature = "Win32_Foundation")] pub struct FILTERED_DATA_SOURCES { pub pwcsExtension: super::super::Foundation::PWSTR, pub pwcsMime: super::super::Foundation::PWSTR, pub pClsid: *mut ::windows::core::GUID, pub pwcsOverride: super::super::Foundation::PWSTR, } #[cfg(feature = "Win32_Foundation")] impl FILTERED_DATA_SOURCES {} #[cfg(feature = "Win32_Foundation")] impl ::core::default::Default for FILTERED_DATA_SOURCES { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(feature = "Win32_Foundation")] impl ::core::fmt::Debug for FILTERED_DATA_SOURCES { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("FILTERED_DATA_SOURCES").field("pwcsExtension", &self.pwcsExtension).field("pwcsMime", &self.pwcsMime).field("pClsid", &self.pClsid).field("pwcsOverride", &self.pwcsOverride).finish() } } #[cfg(feature = "Win32_Foundation")] impl ::core::cmp::PartialEq for FILTERED_DATA_SOURCES { fn eq(&self, other: &Self) -> bool { self.pwcsExtension == other.pwcsExtension && self.pwcsMime == other.pwcsMime && self.pClsid == other.pClsid && self.pwcsOverride == other.pwcsOverride } } #[cfg(feature = "Win32_Foundation")] impl ::core::cmp::Eq for FILTERED_DATA_SOURCES {} #[cfg(feature = "Win32_Foundation")] unsafe impl ::windows::core::Abi for FILTERED_DATA_SOURCES { type Abi = Self; } pub const FLTRDMN_E_CANNOT_DECRYPT_PASSWORD: i32 = -2147212282i32; pub const FLTRDMN_E_ENCRYPTED_DOCUMENT: i32 = -2147212283i32; pub const FLTRDMN_E_FILTER_INIT_FAILED: i32 = -2147212284i32; pub const FLTRDMN_E_QI_FILTER_FAILED: i32 = -2147212286i32; pub const FLTRDMN_E_UNEXPECTED: i32 = -2147212287i32; #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct FOLLOW_FLAGS(pub i32); pub const FF_INDEXCOMPLEXURLS: FOLLOW_FLAGS = FOLLOW_FLAGS(1i32); pub const FF_SUPPRESSINDEXING: FOLLOW_FLAGS = FOLLOW_FLAGS(2i32); impl ::core::convert::From<i32> for FOLLOW_FLAGS { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for FOLLOW_FLAGS { type Abi = Self; } pub const FTE_E_ADMIN_BLOB_CORRUPT: i32 = -2147207676i32; pub const FTE_E_AFFINITY_MASK: i32 = -2147207651i32; pub const FTE_E_ALREADY_INITIALIZED: i32 = -2147207604i32; pub const FTE_E_ANOTHER_STATUS_CHANGE_IS_ALREADY_ACTIVE: i32 = -2147207635i32; pub const FTE_E_BATCH_ABORTED: i32 = -2147207636i32; pub const FTE_E_CATALOG_ALREADY_EXISTS: i32 = -2147207656i32; pub const FTE_E_CATALOG_DOES_NOT_EXIST: i32 = -2147207639i32; pub const FTE_E_CB_CBID_OUT_OF_BOUND: i32 = -2147169535i32; pub const FTE_E_CB_NOT_ENOUGH_AVAIL_PHY_MEM: i32 = -2147169534i32; pub const FTE_E_CB_NOT_ENOUGH_OCC_BUFFER: i32 = -2147169533i32; pub const FTE_E_CB_OUT_OF_MEMORY: i32 = -2147169536i32; pub const FTE_E_COM_SIGNATURE_VALIDATION: i32 = -2147207652i32; pub const FTE_E_CORRUPT_GATHERER_HASH_MAP: i32 = -2147207619i32; pub const FTE_E_CORRUPT_PROPERTY_STORE: i32 = -2147207622i32; pub const FTE_E_CORRUPT_WORDLIST: i32 = -2147169532i32; pub const FTE_E_DATATYPE_MISALIGNMENT: i32 = -2147207605i32; pub const FTE_E_DEPENDENT_TRAN_FAILED_TO_PERSIST: i32 = -2147207641i32; pub const FTE_E_DOC_TOO_HUGE: i32 = -2147207606i32; pub const FTE_E_DUPLICATE_OBJECT: i32 = -2147207644i32; pub const FTE_E_ERROR_WRITING_REGISTRY: i32 = -2147207674i32; pub const FTE_E_EXCEEDED_MAX_PLUGINS: i32 = -2147207647i32; pub const FTE_E_FAILED_TO_CREATE_ACCESSOR: i32 = -2147207625i32; pub const FTE_E_FAILURE_TO_POST_SETCOMPLETION_STATUS: i32 = -2147207597i32; pub const FTE_E_FD_DID_NOT_CONNECT: i32 = -2147207660i32; pub const FTE_E_FD_DOC_TIMEOUT: i32 = -2147156733i32; pub const FTE_E_FD_DOC_UNEXPECTED_EXIT: i32 = -2147156731i32; pub const FTE_E_FD_FAILED_TO_LOAD_IFILTER: i32 = -2147156734i32; pub const FTE_E_FD_FILTER_CAUSED_SHARING_VIOLATION: i32 = -2147156725i32; pub const FTE_E_FD_IDLE: i32 = -2147207595i32; pub const FTE_E_FD_IFILTER_INIT_FAILED: i32 = -2147156735i32; pub const FTE_E_FD_NOISE_NO_IPERSISTSTREAM_ON_TEXT_FILTER: i32 = -2147156729i32; pub const FTE_E_FD_NOISE_NO_TEXT_FILTER: i32 = -2147156730i32; pub const FTE_E_FD_NOISE_TEXT_FILTER_INIT_FAILED: i32 = -2147156727i32; pub const FTE_E_FD_NOISE_TEXT_FILTER_LOAD_FAILED: i32 = -2147156728i32; pub const FTE_E_FD_NO_IPERSIST_INTERFACE: i32 = -2147156736i32; pub const FTE_E_FD_OCCURRENCE_OVERFLOW: i32 = -2147156726i32; pub const FTE_E_FD_OWNERSHIP_OBSOLETE: i32 = -2147207650i32; pub const FTE_E_FD_SHUTDOWN: i32 = -2147207640i32; pub const FTE_E_FD_TIMEOUT: i32 = -2147207632i32; pub const FTE_E_FD_UNEXPECTED_EXIT: i32 = -2147156732i32; pub const FTE_E_FD_UNRESPONSIVE: i32 = -2147207594i32; pub const FTE_E_FD_USED_TOO_MUCH_MEMORY: i32 = -2147207603i32; pub const FTE_E_FILTER_SINGLE_THREADED: i32 = -2147207675i32; pub const FTE_E_HIGH_MEMORY_PRESSURE: i32 = -2147207601i32; pub const FTE_E_INVALID_CODEPAGE: i32 = -2147207596i32; pub const FTE_E_INVALID_DOCID: i32 = -2147207663i32; pub const FTE_E_INVALID_ISOLATE_ERROR_BATCH: i32 = -2147207600i32; pub const FTE_E_INVALID_PROG_ID: i32 = -2147207614i32; pub const FTE_E_INVALID_PROJECT_ID: i32 = -2147207598i32; pub const FTE_E_INVALID_PROPERTY: i32 = -2147207630i32; pub const FTE_E_INVALID_TYPE: i32 = -2147207624i32; pub const FTE_E_KEY_NOT_CACHED: i32 = -2147207618i32; pub const FTE_E_LIBRARY_NOT_LOADED: i32 = -2147207627i32; pub const FTE_E_NOT_PROCESSED_DUE_TO_PREVIOUS_ERRORS: i32 = -2147207633i32; pub const FTE_E_NO_MORE_PROPERTIES: i32 = -2147207629i32; pub const FTE_E_NO_PLUGINS: i32 = -2147207638i32; pub const FTE_E_NO_PROPERTY_STORE: i32 = -1073465766i32; pub const FTE_E_OUT_OF_RANGE: i32 = -2147207623i32; pub const FTE_E_PATH_TOO_LONG: i32 = -2147207654i32; pub const FTE_E_PAUSE_EXTERNAL: i32 = -2147207662i32; pub const FTE_E_PERFMON_FULL: i32 = -2147207626i32; pub const FTE_E_PERF_NOT_LOADED: i32 = -2147207611i32; pub const FTE_E_PIPE_DATA_CORRUPTED: i32 = -2147207671i32; pub const FTE_E_PIPE_NOT_CONNECTED: i32 = -2147207677i32; pub const FTE_E_PROGID_REQUIRED: i32 = -2147207658i32; pub const FTE_E_PROJECT_NOT_INITALIZED: i32 = -2147207672i32; pub const FTE_E_PROJECT_SHUTDOWN: i32 = -2147207673i32; pub const FTE_E_PROPERTY_STORE_WORKID_NOTVALID: i32 = -2147207621i32; pub const FTE_E_READONLY_CATALOG: i32 = -2147207612i32; pub const FTE_E_REDUNDANT_TRAN_FAILURE: i32 = -2147207642i32; pub const FTE_E_REJECTED_DUE_TO_PROJECT_STATUS: i32 = -2147207661i32; pub const FTE_E_RESOURCE_SHUTDOWN: i32 = -2147207631i32; pub const FTE_E_RETRY_HUGE_DOC: i32 = -2147207608i32; pub const FTE_E_RETRY_SINGLE_DOC_PER_BATCH: i32 = -2147207599i32; pub const FTE_E_SECRET_NOT_FOUND: i32 = -2147207678i32; pub const FTE_E_SERIAL_STREAM_CORRUPT: i32 = -2147207613i32; pub const FTE_E_STACK_CORRUPTED: i32 = -2147207615i32; pub const FTE_E_STATIC_THREAD_INVALID_ARGUMENTS: i32 = -2147207657i32; pub const FTE_E_UNEXPECTED_EXIT: i32 = -2147207602i32; pub const FTE_E_UNKNOWN_FD_TYPE: i32 = -2147207607i32; pub const FTE_E_UNKNOWN_PLUGIN: i32 = -2147207628i32; pub const FTE_E_UPGRADE_INTERFACE_ALREADY_INSTANTIATED: i32 = -2147207616i32; pub const FTE_E_UPGRADE_INTERFACE_ALREADY_SHUTDOWN: i32 = -2147207617i32; pub const FTE_E_URB_TOO_BIG: i32 = -2147207664i32; pub const FTE_INVALID_ADMIN_CLIENT: i32 = -2147207653i32; pub const FTE_S_BEYOND_QUOTA: i32 = 276002i32; pub const FTE_S_CATALOG_BLOB_MISMATCHED: i32 = 276056i32; pub const FTE_S_PROPERTY_RESET: i32 = 276057i32; pub const FTE_S_PROPERTY_STORE_END_OF_ENUMERATION: i32 = 276028i32; pub const FTE_S_READONLY_CATALOG: i32 = 276038i32; pub const FTE_S_REDUNDANT: i32 = 276005i32; pub const FTE_S_RESOURCES_STARTING_TO_GET_LOW: i32 = 275993i32; pub const FTE_S_RESUME: i32 = 276014i32; pub const FTE_S_STATUS_CHANGE_REQUEST: i32 = 276011i32; pub const FTE_S_TRY_TO_FLUSH: i32 = 276055i32; pub const FilterRegistration: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x9e175b8d_f52a_11d8_b9a5_505054503030); pub const GENERATE_METHOD_PREFIXMATCH: u32 = 1u32; pub const GENERATE_METHOD_STEMMED: u32 = 2u32; pub const GHTR_E_INSUFFICIENT_DISK_SPACE: i32 = -2147218037i32; pub const GHTR_E_LOCAL_SERVER_UNAVAILABLE: i32 = -2147218055i32; pub const GTHR_E_ADDLINKS_FAILED_WILL_RETRY_PARENT: i32 = -2147217989i32; pub const GTHR_E_APPLICATION_NOT_FOUND: i32 = -2147218079i32; pub const GTHR_E_AUTOCAT_UNEXPECTED: i32 = -2147218012i32; pub const GTHR_E_BACKUP_VALIDATION_FAIL: i32 = -2147217994i32; pub const GTHR_E_BAD_FILTER_DAEMON: i32 = -2147218119i32; pub const GTHR_E_BAD_FILTER_HOST: i32 = -2147217993i32; pub const GTHR_E_CANNOT_ENABLE_CHECKPOINT: i32 = -2147218002i32; pub const GTHR_E_CANNOT_REMOVE_PLUGINMGR: i32 = -2147218078i32; pub const GTHR_E_CONFIG_DUP_EXTENSION: i32 = -2147218165i32; pub const GTHR_E_CONFIG_DUP_PROJECT: i32 = -2147218166i32; pub const GTHR_E_CONTENT_ID_CONFLICT: i32 = -2147218062i32; pub const GTHR_E_DIRMON_NOT_INITIALZED: i32 = -2147218019i32; pub const GTHR_E_DUPLICATE_OBJECT: i32 = -2147218174i32; pub const GTHR_E_DUPLICATE_PROJECT: i32 = -2147218094i32; pub const GTHR_E_DUPLICATE_URL: i32 = -2147218163i32; pub const GTHR_E_DUP_PROPERTY_MAPPING: i32 = -2147218134i32; pub const GTHR_E_EMPTY_DACL: i32 = -2147218006i32; pub const GTHR_E_ERROR_INITIALIZING_PERFMON: i32 = -2147218171i32; pub const GTHR_E_ERROR_OBJECT_NOT_FOUND: i32 = -2147218170i32; pub const GTHR_E_ERROR_WRITING_REGISTRY: i32 = -2147218172i32; pub const GTHR_E_FILTERPOOL_NOTFOUND: i32 = -2147217990i32; pub const GTHR_E_FILTER_FAULT: i32 = -2147218075i32; pub const GTHR_E_FILTER_INIT: i32 = -2147218130i32; pub const GTHR_E_FILTER_INTERRUPTED: i32 = -2147218092i32; pub const GTHR_E_FILTER_INVALID_MESSAGE: i32 = -2147218158i32; pub const GTHR_E_FILTER_NOT_FOUND: i32 = -2147218154i32; pub const GTHR_E_FILTER_NO_CODEPAGE: i32 = -2147218123i32; pub const GTHR_E_FILTER_NO_MORE_THREADS: i32 = -2147218153i32; pub const GTHR_E_FILTER_PROCESS_TERMINATED: i32 = -2147218159i32; pub const GTHR_E_FILTER_PROCESS_TERMINATED_QUOTA: i32 = -2147218151i32; pub const GTHR_E_FILTER_SINGLE_THREADED: i32 = -2147218069i32; pub const GTHR_E_FOLDER_CRAWLED_BY_ANOTHER_WORKSPACE: i32 = -2147218007i32; pub const GTHR_E_FORCE_NOTIFICATION_RESET: i32 = -2147218065i32; pub const GTHR_E_FROM_NOT_SPECIFIED: i32 = -2147218109i32; pub const GTHR_E_IE_OFFLINE: i32 = -2147218120i32; pub const GTHR_E_INSUFFICIENT_EXAMPLE_CATEGORIES: i32 = -2147218014i32; pub const GTHR_E_INSUFFICIENT_EXAMPLE_DOCUMENTS: i32 = -2147218013i32; pub const GTHR_E_INSUFFICIENT_FEATURE_TERMS: i32 = -2147218015i32; pub const GTHR_E_INVALIDFUNCTION: i32 = -2147218161i32; pub const GTHR_E_INVALID_ACCOUNT: i32 = -2147218132i32; pub const GTHR_E_INVALID_ACCOUNT_SYNTAX: i32 = -2147218129i32; pub const GTHR_E_INVALID_APPLICATION_NAME: i32 = -2147218077i32; pub const GTHR_E_INVALID_CALL_FROM_WBREAKER: i32 = -2147218058i32; pub const GTHR_E_INVALID_DIRECTORY: i32 = -2147218093i32; pub const GTHR_E_INVALID_EXTENSION: i32 = -2147218107i32; pub const GTHR_E_INVALID_GROW_FACTOR: i32 = -2147218106i32; pub const GTHR_E_INVALID_HOST_NAME: i32 = -2147218096i32; pub const GTHR_E_INVALID_LOG_FILE_NAME: i32 = -2147218103i32; pub const GTHR_E_INVALID_MAPPING: i32 = -2147218112i32; pub const GTHR_E_INVALID_PATH: i32 = -2147218124i32; pub const GTHR_E_INVALID_PATH_EXPRESSION: i32 = -2147218088i32; pub const GTHR_E_INVALID_PATH_SPEC: i32 = -2147218016i32; pub const GTHR_E_INVALID_PROJECT_NAME: i32 = -2147218142i32; pub const GTHR_E_INVALID_PROXY_PORT: i32 = -2147218091i32; pub const GTHR_E_INVALID_RESOURCE_ID: i32 = -2147218035i32; pub const GTHR_E_INVALID_RETRIES: i32 = -2147218104i32; pub const GTHR_E_INVALID_START_ADDRESS: i32 = -2147217998i32; pub const GTHR_E_INVALID_START_PAGE: i32 = -2147218095i32; pub const GTHR_E_INVALID_START_PAGE_HOST: i32 = -2147218087i32; pub const GTHR_E_INVALID_START_PAGE_PATH: i32 = -2147218080i32; pub const GTHR_E_INVALID_STREAM_LOGS_COUNT: i32 = -2147218108i32; pub const GTHR_E_INVALID_TIME_OUT: i32 = -2147218105i32; pub const GTHR_E_JET_BACKUP_ERROR: i32 = -2147218026i32; pub const GTHR_E_JET_RESTORE_ERROR: i32 = -2147218025i32; pub const GTHR_E_LOCAL_GROUPS_EXPANSION_INTERNAL_ERROR: i32 = -2147216867i32; pub const GTHR_E_NAME_TOO_LONG: i32 = -2147218156i32; pub const GTHR_E_NESTED_HIERARCHICAL_START_ADDRESSES: i32 = -2147218034i32; pub const GTHR_E_NOFILTERSINK: i32 = -2147218160i32; pub const GTHR_E_NON_FIXED_DRIVE: i32 = -2147218074i32; pub const GTHR_E_NOTIFICATION_FILE_SHARE_INFO_NOT_AVAILABLE: i32 = -2147218040i32; pub const GTHR_E_NOTIFICATION_LOCAL_PATH_MUST_USE_FIXED_DRIVE: i32 = -2147218039i32; pub const GTHR_E_NOTIFICATION_START_ADDRESS_INVALID: i32 = -2147218042i32; pub const GTHR_E_NOTIFICATION_START_PAGE: i32 = -2147218137i32; pub const GTHR_E_NOTIFICATION_TYPE_NOT_SUPPORTED: i32 = -2147218041i32; pub const GTHR_E_NOTIF_ACCESS_TOKEN_UPDATED: i32 = -2147218020i32; pub const GTHR_E_NOTIF_BEING_REMOVED: i32 = -2147218018i32; pub const GTHR_E_NOTIF_EXCESSIVE_THROUGHPUT: i32 = -2147218017i32; pub const GTHR_E_NO_IDENTITY: i32 = -2147218155i32; pub const GTHR_E_NO_PRTCLHNLR: i32 = -2147218121i32; pub const GTHR_E_NTF_CLIENT_NOT_SUBSCRIBED: i32 = -1073476167i32; pub const GTHR_E_OBJECT_NOT_VALID: i32 = -2147218005i32; pub const GTHR_E_OUT_OF_DOC_ID: i32 = -2147218138i32; pub const GTHR_E_PIPE_NOT_CONNECTTED: i32 = -2147217996i32; pub const GTHR_E_PLUGIN_NOT_REGISTERED: i32 = -2147218021i32; pub const GTHR_E_PROJECT_NOT_INITIALIZED: i32 = -2147218149i32; pub const GTHR_E_PROPERTIES_EXCEEDED: i32 = -2147218000i32; pub const GTHR_E_PROPERTY_LIST_NOT_INITIALIZED: i32 = -2147218057i32; pub const GTHR_E_PROXY_NAME: i32 = -2147218127i32; pub const GTHR_E_PRT_HNDLR_PROGID_MISSING: i32 = -2147218152i32; pub const GTHR_E_RECOVERABLE_EXOLEDB_ERROR: i32 = -2147218060i32; pub const GTHR_E_RETRY: i32 = -2147218027i32; pub const GTHR_E_SCHEMA_ERRORS_OCCURRED: i32 = -2147218054i32; pub const GTHR_E_SCOPES_EXCEEDED: i32 = -2147218001i32; pub const GTHR_E_SECRET_NOT_FOUND: i32 = -2147218089i32; pub const GTHR_E_SERVER_UNAVAILABLE: i32 = -2147218126i32; pub const GTHR_E_SHUTTING_DOWN: i32 = -2147218141i32; pub const GTHR_E_SINGLE_THREADED_EMBEDDING: i32 = -2147218011i32; pub const GTHR_E_TIMEOUT: i32 = -2147218053i32; pub const GTHR_E_TOO_MANY_PLUGINS: i32 = -2147218162i32; pub const GTHR_E_UNABLE_TO_READ_EXCHANGE_STORE: i32 = -2147218061i32; pub const GTHR_E_UNABLE_TO_READ_REGISTRY: i32 = -2147218173i32; pub const GTHR_E_UNKNOWN_PROTOCOL: i32 = -2147218150i32; pub const GTHR_E_UNSUPPORTED_PROPERTY_TYPE: i32 = -2147218157i32; pub const GTHR_E_URL_EXCLUDED: i32 = -2147218169i32; pub const GTHR_E_URL_UNIDENTIFIED: i32 = -2147218067i32; pub const GTHR_E_USER_AGENT_NOT_SPECIFIED: i32 = -2147218111i32; pub const GTHR_E_VALUE_NOT_AVAILABLE: i32 = -2147218139i32; pub const GTHR_S_BAD_FILE_LINK: i32 = 265580i32; pub const GTHR_S_CANNOT_FILTER: i32 = 265520i32; pub const GTHR_S_CANNOT_WORDBREAK: i32 = 265638i32; pub const GTHR_S_CONFIG_HAS_ACCOUNTS: i32 = 265558i32; pub const GTHR_S_CRAWL_ADAPTIVE: i32 = 265605i32; pub const GTHR_S_CRAWL_FULL: i32 = 265603i32; pub const GTHR_S_CRAWL_INCREMENTAL: i32 = 265604i32; pub const GTHR_S_CRAWL_SCHEDULED: i32 = 265576i32; pub const GTHR_S_END_PROCESS_LOOP_NOTIFY_QUEUE: i32 = 265584i32; pub const GTHR_S_END_STD_CHUNKS: i32 = 265508i32; pub const GTHR_S_MODIFIED_PARTS: i32 = 265592i32; pub const GTHR_S_NOT_ALL_PARTS: i32 = 265582i32; pub const GTHR_S_NO_CRAWL_SEEDS: i32 = 265515i32; pub const GTHR_S_NO_INDEX: i32 = 265616i32; pub const GTHR_S_OFFICE_CHILD: i32 = 265626i32; pub const GTHR_S_PAUSE_REASON_BACKOFF: i32 = 265620i32; pub const GTHR_S_PAUSE_REASON_EXTERNAL: i32 = 265618i32; pub const GTHR_S_PAUSE_REASON_PROFILE_IMPORT: i32 = 265651i32; pub const GTHR_S_PAUSE_REASON_UPGRADING: i32 = 265619i32; pub const GTHR_S_PROB_NOT_MODIFIED: i32 = 265575i32; pub const GTHR_S_START_FILTER_FROM_BODY: i32 = 265585i32; pub const GTHR_S_START_FILTER_FROM_PROTOCOL: i32 = 265578i32; pub const GTHR_S_STATUS_CHANGE_IGNORED: i32 = 265500i32; pub const GTHR_S_STATUS_END_CRAWL: i32 = 265501i32; pub const GTHR_S_STATUS_PAUSE: i32 = 265505i32; pub const GTHR_S_STATUS_RESET: i32 = 265502i32; pub const GTHR_S_STATUS_RESUME: i32 = 265504i32; pub const GTHR_S_STATUS_START: i32 = 265526i32; pub const GTHR_S_STATUS_STOP: i32 = 265523i32; pub const GTHR_S_STATUS_THROTTLE: i32 = 265503i32; pub const GTHR_S_TRANSACTION_IGNORED: i32 = 265577i32; pub const GTHR_S_USE_MIME_FILTER: i32 = 265639i32; #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] pub struct HITRANGE { pub iPosition: u32, pub cLength: u32, } impl HITRANGE {} impl ::core::default::Default for HITRANGE { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } impl ::core::fmt::Debug for HITRANGE { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("HITRANGE").field("iPosition", &self.iPosition).field("cLength", &self.cLength).finish() } } impl ::core::cmp::PartialEq for HITRANGE { fn eq(&self, other: &Self) -> bool { self.iPosition == other.iPosition && self.cLength == other.cLength } } impl ::core::cmp::Eq for HITRANGE {} unsafe impl ::windows::core::Abi for HITRANGE { type Abi = Self; } #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IAccessor(pub ::windows::core::IUnknown); impl IAccessor { pub unsafe fn AddRefAccessor(&self, haccessor: usize) -> ::windows::core::Result<u32> { let mut result__: <u32 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(haccessor), &mut result__).from_abi::<u32>(result__) } #[cfg(feature = "Win32_System_Com")] pub unsafe fn CreateAccessor(&self, dwaccessorflags: u32, cbindings: usize, rgbindings: *const DBBINDING, cbrowsize: usize, phaccessor: *mut usize, rgstatus: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(dwaccessorflags), ::core::mem::transmute(cbindings), ::core::mem::transmute(rgbindings), ::core::mem::transmute(cbrowsize), ::core::mem::transmute(phaccessor), ::core::mem::transmute(rgstatus)).ok() } #[cfg(feature = "Win32_System_Com")] pub unsafe fn GetBindings(&self, haccessor: usize, pdwaccessorflags: *mut u32, pcbindings: *mut usize, prgbindings: *mut *mut DBBINDING) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(haccessor), ::core::mem::transmute(pdwaccessorflags), ::core::mem::transmute(pcbindings), ::core::mem::transmute(prgbindings)).ok() } pub unsafe fn ReleaseAccessor(&self, haccessor: usize) -> ::windows::core::Result<u32> { let mut result__: <u32 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), ::core::mem::transmute(haccessor), &mut result__).from_abi::<u32>(result__) } } unsafe impl ::windows::core::Interface for IAccessor { type Vtable = IAccessor_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a8c_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IAccessor> for ::windows::core::IUnknown { fn from(value: IAccessor) -> Self { value.0 } } impl ::core::convert::From<&IAccessor> for ::windows::core::IUnknown { fn from(value: &IAccessor) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IAccessor { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IAccessor { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IAccessor_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, haccessor: usize, pcrefcount: *mut u32) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_System_Com")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, dwaccessorflags: u32, cbindings: usize, rgbindings: *const ::core::mem::ManuallyDrop<DBBINDING>, cbrowsize: usize, phaccessor: *mut usize, rgstatus: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_System_Com"))] usize, #[cfg(feature = "Win32_System_Com")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, haccessor: usize, pdwaccessorflags: *mut u32, pcbindings: *mut usize, prgbindings: *mut *mut DBBINDING) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_System_Com"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, haccessor: usize, pcrefcount: *mut u32) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IAlterIndex(pub ::windows::core::IUnknown); impl IAlterIndex { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn AlterIndex(&self, ptableid: *mut super::super::Storage::IndexServer::DBID, pindexid: *mut super::super::Storage::IndexServer::DBID, pnewindexid: *mut super::super::Storage::IndexServer::DBID, cpropertysets: u32, rgpropertysets: *mut DBPROPSET) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(ptableid), ::core::mem::transmute(pindexid), ::core::mem::transmute(pnewindexid), ::core::mem::transmute(cpropertysets), ::core::mem::transmute(rgpropertysets)).ok() } } unsafe impl ::windows::core::Interface for IAlterIndex { type Vtable = IAlterIndex_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733aa6_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IAlterIndex> for ::windows::core::IUnknown { fn from(value: IAlterIndex) -> Self { value.0 } } impl ::core::convert::From<&IAlterIndex> for ::windows::core::IUnknown { fn from(value: &IAlterIndex) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IAlterIndex { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IAlterIndex { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IAlterIndex_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ptableid: *mut super::super::Storage::IndexServer::DBID, pindexid: *mut super::super::Storage::IndexServer::DBID, pnewindexid: *mut super::super::Storage::IndexServer::DBID, cpropertysets: u32, rgpropertysets: *mut DBPROPSET) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IAlterTable(pub ::windows::core::IUnknown); impl IAlterTable { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn AlterColumn(&self, ptableid: *mut super::super::Storage::IndexServer::DBID, pcolumnid: *mut super::super::Storage::IndexServer::DBID, dwcolumndescflags: u32, pcolumndesc: *mut DBCOLUMNDESC) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(ptableid), ::core::mem::transmute(pcolumnid), ::core::mem::transmute(dwcolumndescflags), ::core::mem::transmute(pcolumndesc)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn AlterTable(&self, ptableid: *mut super::super::Storage::IndexServer::DBID, pnewtableid: *mut super::super::Storage::IndexServer::DBID, cpropertysets: u32, rgpropertysets: *mut DBPROPSET) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(ptableid), ::core::mem::transmute(pnewtableid), ::core::mem::transmute(cpropertysets), ::core::mem::transmute(rgpropertysets)).ok() } } unsafe impl ::windows::core::Interface for IAlterTable { type Vtable = IAlterTable_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733aa5_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IAlterTable> for ::windows::core::IUnknown { fn from(value: IAlterTable) -> Self { value.0 } } impl ::core::convert::From<&IAlterTable> for ::windows::core::IUnknown { fn from(value: &IAlterTable) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IAlterTable { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IAlterTable { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IAlterTable_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ptableid: *mut super::super::Storage::IndexServer::DBID, pcolumnid: *mut super::super::Storage::IndexServer::DBID, dwcolumndescflags: u32, pcolumndesc: *mut ::core::mem::ManuallyDrop<DBCOLUMNDESC>) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ptableid: *mut super::super::Storage::IndexServer::DBID, pnewtableid: *mut super::super::Storage::IndexServer::DBID, cpropertysets: u32, rgpropertysets: *mut DBPROPSET) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IBindResource(pub ::windows::core::IUnknown); impl IBindResource { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub unsafe fn Bind<'a, Param0: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param5: ::windows::core::IntoParam<'a, super::Com::IAuthenticate>>( &self, punkouter: Param0, pwszurl: Param1, dwbindurlflags: u32, rguid: *const ::windows::core::GUID, riid: *const ::windows::core::GUID, pauthenticate: Param5, pimplsession: *mut DBIMPLICITSESSION, pdwbindstatus: *mut u32, ppunk: *mut ::core::option::Option<::windows::core::IUnknown>, ) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)( ::core::mem::transmute_copy(self), punkouter.into_param().abi(), pwszurl.into_param().abi(), ::core::mem::transmute(dwbindurlflags), ::core::mem::transmute(rguid), ::core::mem::transmute(riid), pauthenticate.into_param().abi(), ::core::mem::transmute(pimplsession), ::core::mem::transmute(pdwbindstatus), ::core::mem::transmute(ppunk), ) .ok() } } unsafe impl ::windows::core::Interface for IBindResource { type Vtable = IBindResource_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733ab1_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IBindResource> for ::windows::core::IUnknown { fn from(value: IBindResource) -> Self { value.0 } } impl ::core::convert::From<&IBindResource> for ::windows::core::IUnknown { fn from(value: &IBindResource) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IBindResource { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IBindResource { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IBindResource_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, punkouter: ::windows::core::RawPtr, pwszurl: super::super::Foundation::PWSTR, dwbindurlflags: u32, rguid: *const ::windows::core::GUID, riid: *const ::windows::core::GUID, pauthenticate: ::windows::core::RawPtr, pimplsession: *mut ::core::mem::ManuallyDrop<DBIMPLICITSESSION>, pdwbindstatus: *mut u32, ppunk: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IChapteredRowset(pub ::windows::core::IUnknown); impl IChapteredRowset { pub unsafe fn AddRefChapter(&self, hchapter: usize) -> ::windows::core::Result<u32> { let mut result__: <u32 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(hchapter), &mut result__).from_abi::<u32>(result__) } pub unsafe fn ReleaseChapter(&self, hchapter: usize) -> ::windows::core::Result<u32> { let mut result__: <u32 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(hchapter), &mut result__).from_abi::<u32>(result__) } } unsafe impl ::windows::core::Interface for IChapteredRowset { type Vtable = IChapteredRowset_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a93_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IChapteredRowset> for ::windows::core::IUnknown { fn from(value: IChapteredRowset) -> Self { value.0 } } impl ::core::convert::From<&IChapteredRowset> for ::windows::core::IUnknown { fn from(value: &IChapteredRowset) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IChapteredRowset { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IChapteredRowset { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IChapteredRowset_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hchapter: usize, pcrefcount: *mut u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hchapter: usize, pcrefcount: *mut u32) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IColumnMapper(pub ::windows::core::IUnknown); impl IColumnMapper { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe fn GetPropInfoFromName<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, wcspropname: Param0, pppropid: *mut *mut super::super::Storage::IndexServer::DBID, pproptype: *mut u16, puiwidth: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), wcspropname.into_param().abi(), ::core::mem::transmute(pppropid), ::core::mem::transmute(pproptype), ::core::mem::transmute(puiwidth)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe fn GetPropInfoFromId(&self, ppropid: *const super::super::Storage::IndexServer::DBID, pwcsname: *mut *mut u16, pproptype: *mut u16, puiwidth: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(ppropid), ::core::mem::transmute(pwcsname), ::core::mem::transmute(pproptype), ::core::mem::transmute(puiwidth)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe fn EnumPropInfo(&self, ientry: u32, pwcsname: *const *const u16, pppropid: *mut *mut super::super::Storage::IndexServer::DBID, pproptype: *mut u16, puiwidth: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(ientry), ::core::mem::transmute(pwcsname), ::core::mem::transmute(pppropid), ::core::mem::transmute(pproptype), ::core::mem::transmute(puiwidth)).ok() } pub unsafe fn IsMapUpToDate(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self)).ok() } } unsafe impl ::windows::core::Interface for IColumnMapper { type Vtable = IColumnMapper_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0b63e37a_9ccc_11d0_bcdb_00805fccce04); } impl ::core::convert::From<IColumnMapper> for ::windows::core::IUnknown { fn from(value: IColumnMapper) -> Self { value.0 } } impl ::core::convert::From<&IColumnMapper> for ::windows::core::IUnknown { fn from(value: &IColumnMapper) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IColumnMapper { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IColumnMapper { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IColumnMapper_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, wcspropname: super::super::Foundation::PWSTR, pppropid: *mut *mut super::super::Storage::IndexServer::DBID, pproptype: *mut u16, puiwidth: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppropid: *const super::super::Storage::IndexServer::DBID, pwcsname: *mut *mut u16, pproptype: *mut u16, puiwidth: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ientry: u32, pwcsname: *const *const u16, pppropid: *mut *mut super::super::Storage::IndexServer::DBID, pproptype: *mut u16, puiwidth: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer")))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IColumnMapperCreator(pub ::windows::core::IUnknown); impl IColumnMapperCreator { #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetColumnMapper<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, wcsmachinename: Param0, wcscatalogname: Param1) -> ::windows::core::Result<IColumnMapper> { let mut result__: <IColumnMapper as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), wcsmachinename.into_param().abi(), wcscatalogname.into_param().abi(), &mut result__).from_abi::<IColumnMapper>(result__) } } unsafe impl ::windows::core::Interface for IColumnMapperCreator { type Vtable = IColumnMapperCreator_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0b63e37b_9ccc_11d0_bcdb_00805fccce04); } impl ::core::convert::From<IColumnMapperCreator> for ::windows::core::IUnknown { fn from(value: IColumnMapperCreator) -> Self { value.0 } } impl ::core::convert::From<&IColumnMapperCreator> for ::windows::core::IUnknown { fn from(value: &IColumnMapperCreator) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IColumnMapperCreator { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IColumnMapperCreator { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IColumnMapperCreator_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, wcsmachinename: super::super::Foundation::PWSTR, wcscatalogname: super::super::Foundation::PWSTR, ppcolumnmapper: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IColumnsInfo(pub ::windows::core::IUnknown); impl IColumnsInfo { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com"))] pub unsafe fn GetColumnInfo(&self, pccolumns: *mut usize, prginfo: *mut *mut DBCOLUMNINFO, ppstringsbuffer: *mut *mut u16) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(pccolumns), ::core::mem::transmute(prginfo), ::core::mem::transmute(ppstringsbuffer)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe fn MapColumnIDs(&self, ccolumnids: usize, rgcolumnids: *const super::super::Storage::IndexServer::DBID, rgcolumns: *mut usize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(ccolumnids), ::core::mem::transmute(rgcolumnids), ::core::mem::transmute(rgcolumns)).ok() } } unsafe impl ::windows::core::Interface for IColumnsInfo { type Vtable = IColumnsInfo_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a11_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IColumnsInfo> for ::windows::core::IUnknown { fn from(value: IColumnsInfo) -> Self { value.0 } } impl ::core::convert::From<&IColumnsInfo> for ::windows::core::IUnknown { fn from(value: &IColumnsInfo) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IColumnsInfo { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IColumnsInfo { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IColumnsInfo_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pccolumns: *mut usize, prginfo: *mut *mut DBCOLUMNINFO, ppstringsbuffer: *mut *mut u16) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ccolumnids: usize, rgcolumnids: *const super::super::Storage::IndexServer::DBID, rgcolumns: *mut usize) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IColumnsInfo2(pub ::windows::core::IUnknown); impl IColumnsInfo2 { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com"))] pub unsafe fn GetColumnInfo(&self, pccolumns: *mut usize, prginfo: *mut *mut DBCOLUMNINFO, ppstringsbuffer: *mut *mut u16) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(pccolumns), ::core::mem::transmute(prginfo), ::core::mem::transmute(ppstringsbuffer)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe fn MapColumnIDs(&self, ccolumnids: usize, rgcolumnids: *const super::super::Storage::IndexServer::DBID, rgcolumns: *mut usize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(ccolumnids), ::core::mem::transmute(rgcolumnids), ::core::mem::transmute(rgcolumns)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com"))] pub unsafe fn GetRestrictedColumnInfo(&self, ccolumnidmasks: usize, rgcolumnidmasks: *const super::super::Storage::IndexServer::DBID, dwflags: u32, pccolumns: *mut usize, prgcolumnids: *mut *mut super::super::Storage::IndexServer::DBID, prgcolumninfo: *mut *mut DBCOLUMNINFO, ppstringsbuffer: *mut *mut u16) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(ccolumnidmasks), ::core::mem::transmute(rgcolumnidmasks), ::core::mem::transmute(dwflags), ::core::mem::transmute(pccolumns), ::core::mem::transmute(prgcolumnids), ::core::mem::transmute(prgcolumninfo), ::core::mem::transmute(ppstringsbuffer)).ok() } } unsafe impl ::windows::core::Interface for IColumnsInfo2 { type Vtable = IColumnsInfo2_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733ab8_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IColumnsInfo2> for ::windows::core::IUnknown { fn from(value: IColumnsInfo2) -> Self { value.0 } } impl ::core::convert::From<&IColumnsInfo2> for ::windows::core::IUnknown { fn from(value: &IColumnsInfo2) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IColumnsInfo2 { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IColumnsInfo2 { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } impl ::core::convert::From<IColumnsInfo2> for IColumnsInfo { fn from(value: IColumnsInfo2) -> Self { unsafe { ::core::mem::transmute(value) } } } impl ::core::convert::From<&IColumnsInfo2> for IColumnsInfo { fn from(value: &IColumnsInfo2) -> Self { ::core::convert::From::from(::core::clone::Clone::clone(value)) } } impl<'a> ::windows::core::IntoParam<'a, IColumnsInfo> for IColumnsInfo2 { fn into_param(self) -> ::windows::core::Param<'a, IColumnsInfo> { ::windows::core::Param::Owned(unsafe { ::core::mem::transmute(self) }) } } impl<'a> ::windows::core::IntoParam<'a, IColumnsInfo> for &IColumnsInfo2 { fn into_param(self) -> ::windows::core::Param<'a, IColumnsInfo> { ::windows::core::Param::Borrowed(unsafe { ::core::mem::transmute(self) }) } } #[repr(C)] #[doc(hidden)] pub struct IColumnsInfo2_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pccolumns: *mut usize, prginfo: *mut *mut DBCOLUMNINFO, ppstringsbuffer: *mut *mut u16) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ccolumnids: usize, rgcolumnids: *const super::super::Storage::IndexServer::DBID, rgcolumns: *mut usize) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ccolumnidmasks: usize, rgcolumnidmasks: *const super::super::Storage::IndexServer::DBID, dwflags: u32, pccolumns: *mut usize, prgcolumnids: *mut *mut super::super::Storage::IndexServer::DBID, prgcolumninfo: *mut *mut DBCOLUMNINFO, ppstringsbuffer: *mut *mut u16) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IColumnsRowset(pub ::windows::core::IUnknown); impl IColumnsRowset { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe fn GetAvailableColumns(&self, pcoptcolumns: *mut usize, prgoptcolumns: *mut *mut super::super::Storage::IndexServer::DBID) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(pcoptcolumns), ::core::mem::transmute(prgoptcolumns)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn GetColumnsRowset<'a, Param0: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>>(&self, punkouter: Param0, coptcolumns: usize, rgoptcolumns: *const super::super::Storage::IndexServer::DBID, riid: *const ::windows::core::GUID, cpropertysets: u32, rgpropertysets: *mut DBPROPSET, ppcolrowset: *mut ::core::option::Option<::windows::core::IUnknown>) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), punkouter.into_param().abi(), ::core::mem::transmute(coptcolumns), ::core::mem::transmute(rgoptcolumns), ::core::mem::transmute(riid), ::core::mem::transmute(cpropertysets), ::core::mem::transmute(rgpropertysets), ::core::mem::transmute(ppcolrowset)).ok() } } unsafe impl ::windows::core::Interface for IColumnsRowset { type Vtable = IColumnsRowset_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a10_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IColumnsRowset> for ::windows::core::IUnknown { fn from(value: IColumnsRowset) -> Self { value.0 } } impl ::core::convert::From<&IColumnsRowset> for ::windows::core::IUnknown { fn from(value: &IColumnsRowset) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IColumnsRowset { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IColumnsRowset { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IColumnsRowset_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pcoptcolumns: *mut usize, prgoptcolumns: *mut *mut super::super::Storage::IndexServer::DBID) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, punkouter: ::windows::core::RawPtr, coptcolumns: usize, rgoptcolumns: *const super::super::Storage::IndexServer::DBID, riid: *const ::windows::core::GUID, cpropertysets: u32, rgpropertysets: *mut DBPROPSET, ppcolrowset: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ICommand(pub ::windows::core::IUnknown); impl ICommand { pub unsafe fn Cancel(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self)).ok() } pub unsafe fn Execute<'a, Param0: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>>(&self, punkouter: Param0, riid: *const ::windows::core::GUID, pparams: *mut DBPARAMS, pcrowsaffected: *mut isize, pprowset: *mut ::core::option::Option<::windows::core::IUnknown>) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), punkouter.into_param().abi(), ::core::mem::transmute(riid), ::core::mem::transmute(pparams), ::core::mem::transmute(pcrowsaffected), ::core::mem::transmute(pprowset)).ok() } pub unsafe fn GetDBSession(&self, riid: *const ::windows::core::GUID) -> ::windows::core::Result<::windows::core::IUnknown> { let mut result__: <::windows::core::IUnknown as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(riid), &mut result__).from_abi::<::windows::core::IUnknown>(result__) } } unsafe impl ::windows::core::Interface for ICommand { type Vtable = ICommand_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a63_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<ICommand> for ::windows::core::IUnknown { fn from(value: ICommand) -> Self { value.0 } } impl ::core::convert::From<&ICommand> for ::windows::core::IUnknown { fn from(value: &ICommand) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ICommand { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ICommand { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ICommand_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, punkouter: ::windows::core::RawPtr, riid: *const ::windows::core::GUID, pparams: *mut DBPARAMS, pcrowsaffected: *mut isize, pprowset: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, riid: *const ::windows::core::GUID, ppsession: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ICommandCost(pub ::windows::core::IUnknown); impl ICommandCost { #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetAccumulatedCost<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pwszrowsetname: Param0, pccostlimits: *mut u32, prgcostlimits: *mut *mut DBCOST) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), pwszrowsetname.into_param().abi(), ::core::mem::transmute(pccostlimits), ::core::mem::transmute(prgcostlimits)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetCostEstimate<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pwszrowsetname: Param0, pccostestimates: *mut u32, prgcostestimates: *mut DBCOST) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), pwszrowsetname.into_param().abi(), ::core::mem::transmute(pccostestimates), ::core::mem::transmute(prgcostestimates)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetCostGoals<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pwszrowsetname: Param0, pccostgoals: *mut u32, prgcostgoals: *mut DBCOST) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), pwszrowsetname.into_param().abi(), ::core::mem::transmute(pccostgoals), ::core::mem::transmute(prgcostgoals)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetCostLimits<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pwszrowsetname: Param0, pccostlimits: *mut u32, prgcostlimits: *mut DBCOST) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), pwszrowsetname.into_param().abi(), ::core::mem::transmute(pccostlimits), ::core::mem::transmute(prgcostlimits)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn SetCostGoals<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pwszrowsetname: Param0, ccostgoals: u32, rgcostgoals: *const DBCOST) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), pwszrowsetname.into_param().abi(), ::core::mem::transmute(ccostgoals), ::core::mem::transmute(rgcostgoals)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn SetCostLimits<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pwszrowsetname: Param0, ccostlimits: u32, prgcostlimits: *mut DBCOST, dwexecutionflags: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).8)(::core::mem::transmute_copy(self), pwszrowsetname.into_param().abi(), ::core::mem::transmute(ccostlimits), ::core::mem::transmute(prgcostlimits), ::core::mem::transmute(dwexecutionflags)).ok() } } unsafe impl ::windows::core::Interface for ICommandCost { type Vtable = ICommandCost_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a4e_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<ICommandCost> for ::windows::core::IUnknown { fn from(value: ICommandCost) -> Self { value.0 } } impl ::core::convert::From<&ICommandCost> for ::windows::core::IUnknown { fn from(value: &ICommandCost) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ICommandCost { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ICommandCost { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ICommandCost_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pwszrowsetname: super::super::Foundation::PWSTR, pccostlimits: *mut u32, prgcostlimits: *mut *mut DBCOST) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pwszrowsetname: super::super::Foundation::PWSTR, pccostestimates: *mut u32, prgcostestimates: *mut DBCOST) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pwszrowsetname: super::super::Foundation::PWSTR, pccostgoals: *mut u32, prgcostgoals: *mut DBCOST) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pwszrowsetname: super::super::Foundation::PWSTR, pccostlimits: *mut u32, prgcostlimits: *mut DBCOST) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pwszrowsetname: super::super::Foundation::PWSTR, ccostgoals: u32, rgcostgoals: *const DBCOST) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pwszrowsetname: super::super::Foundation::PWSTR, ccostlimits: u32, prgcostlimits: *mut DBCOST, dwexecutionflags: u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ICommandPersist(pub ::windows::core::IUnknown); impl ICommandPersist { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe fn DeleteCommand(&self, pcommandid: *mut super::super::Storage::IndexServer::DBID) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(pcommandid)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe fn GetCurrentCommand(&self, ppcommandid: *mut *mut super::super::Storage::IndexServer::DBID) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(ppcommandid)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe fn LoadCommand(&self, pcommandid: *mut super::super::Storage::IndexServer::DBID, dwflags: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(pcommandid), ::core::mem::transmute(dwflags)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe fn SaveCommand(&self, pcommandid: *mut super::super::Storage::IndexServer::DBID, dwflags: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), ::core::mem::transmute(pcommandid), ::core::mem::transmute(dwflags)).ok() } } unsafe impl ::windows::core::Interface for ICommandPersist { type Vtable = ICommandPersist_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733aa7_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<ICommandPersist> for ::windows::core::IUnknown { fn from(value: ICommandPersist) -> Self { value.0 } } impl ::core::convert::From<&ICommandPersist> for ::windows::core::IUnknown { fn from(value: &ICommandPersist) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ICommandPersist { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ICommandPersist { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ICommandPersist_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pcommandid: *mut super::super::Storage::IndexServer::DBID) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppcommandid: *mut *mut super::super::Storage::IndexServer::DBID) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pcommandid: *mut super::super::Storage::IndexServer::DBID, dwflags: u32) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pcommandid: *mut super::super::Storage::IndexServer::DBID, dwflags: u32) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ICommandPrepare(pub ::windows::core::IUnknown); impl ICommandPrepare { pub unsafe fn Prepare(&self, cexpectedruns: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(cexpectedruns)).ok() } pub unsafe fn Unprepare(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self)).ok() } } unsafe impl ::windows::core::Interface for ICommandPrepare { type Vtable = ICommandPrepare_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a26_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<ICommandPrepare> for ::windows::core::IUnknown { fn from(value: ICommandPrepare) -> Self { value.0 } } impl ::core::convert::From<&ICommandPrepare> for ::windows::core::IUnknown { fn from(value: &ICommandPrepare) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ICommandPrepare { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ICommandPrepare { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ICommandPrepare_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, cexpectedruns: u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ICommandProperties(pub ::windows::core::IUnknown); impl ICommandProperties { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn GetProperties(&self, cpropertyidsets: u32, rgpropertyidsets: *const DBPROPIDSET, pcpropertysets: *mut u32, prgpropertysets: *mut *mut DBPROPSET) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(cpropertyidsets), ::core::mem::transmute(rgpropertyidsets), ::core::mem::transmute(pcpropertysets), ::core::mem::transmute(prgpropertysets)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn SetProperties(&self, cpropertysets: u32, rgpropertysets: *const DBPROPSET) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(cpropertysets), ::core::mem::transmute(rgpropertysets)).ok() } } unsafe impl ::windows::core::Interface for ICommandProperties { type Vtable = ICommandProperties_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a79_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<ICommandProperties> for ::windows::core::IUnknown { fn from(value: ICommandProperties) -> Self { value.0 } } impl ::core::convert::From<&ICommandProperties> for ::windows::core::IUnknown { fn from(value: &ICommandProperties) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ICommandProperties { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ICommandProperties { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ICommandProperties_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, cpropertyidsets: u32, rgpropertyidsets: *const DBPROPIDSET, pcpropertysets: *mut u32, prgpropertysets: *mut *mut DBPROPSET) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, cpropertysets: u32, rgpropertysets: *const DBPROPSET) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ICommandStream(pub ::windows::core::IUnknown); impl ICommandStream { pub unsafe fn GetCommandStream(&self, piid: *mut ::windows::core::GUID, pguiddialect: *mut ::windows::core::GUID, ppcommandstream: *mut ::core::option::Option<::windows::core::IUnknown>) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(piid), ::core::mem::transmute(pguiddialect), ::core::mem::transmute(ppcommandstream)).ok() } pub unsafe fn SetCommandStream<'a, Param2: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>>(&self, riid: *const ::windows::core::GUID, rguiddialect: *const ::windows::core::GUID, pcommandstream: Param2) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(riid), ::core::mem::transmute(rguiddialect), pcommandstream.into_param().abi()).ok() } } unsafe impl ::windows::core::Interface for ICommandStream { type Vtable = ICommandStream_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733abf_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<ICommandStream> for ::windows::core::IUnknown { fn from(value: ICommandStream) -> Self { value.0 } } impl ::core::convert::From<&ICommandStream> for ::windows::core::IUnknown { fn from(value: &ICommandStream) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ICommandStream { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ICommandStream { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ICommandStream_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, piid: *mut ::windows::core::GUID, pguiddialect: *mut ::windows::core::GUID, ppcommandstream: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, riid: *const ::windows::core::GUID, rguiddialect: *const ::windows::core::GUID, pcommandstream: ::windows::core::RawPtr) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ICommandText(pub ::windows::core::IUnknown); impl ICommandText { pub unsafe fn Cancel(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self)).ok() } pub unsafe fn Execute<'a, Param0: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>>(&self, punkouter: Param0, riid: *const ::windows::core::GUID, pparams: *mut DBPARAMS, pcrowsaffected: *mut isize, pprowset: *mut ::core::option::Option<::windows::core::IUnknown>) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), punkouter.into_param().abi(), ::core::mem::transmute(riid), ::core::mem::transmute(pparams), ::core::mem::transmute(pcrowsaffected), ::core::mem::transmute(pprowset)).ok() } pub unsafe fn GetDBSession(&self, riid: *const ::windows::core::GUID) -> ::windows::core::Result<::windows::core::IUnknown> { let mut result__: <::windows::core::IUnknown as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(riid), &mut result__).from_abi::<::windows::core::IUnknown>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetCommandText(&self, pguiddialect: *mut ::windows::core::GUID, ppwszcommand: *mut super::super::Foundation::PWSTR) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), ::core::mem::transmute(pguiddialect), ::core::mem::transmute(ppwszcommand)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn SetCommandText<'a, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, rguiddialect: *const ::windows::core::GUID, pwszcommand: Param1) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), ::core::mem::transmute(rguiddialect), pwszcommand.into_param().abi()).ok() } } unsafe impl ::windows::core::Interface for ICommandText { type Vtable = ICommandText_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a27_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<ICommandText> for ::windows::core::IUnknown { fn from(value: ICommandText) -> Self { value.0 } } impl ::core::convert::From<&ICommandText> for ::windows::core::IUnknown { fn from(value: &ICommandText) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ICommandText { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ICommandText { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } impl ::core::convert::From<ICommandText> for ICommand { fn from(value: ICommandText) -> Self { unsafe { ::core::mem::transmute(value) } } } impl ::core::convert::From<&ICommandText> for ICommand { fn from(value: &ICommandText) -> Self { ::core::convert::From::from(::core::clone::Clone::clone(value)) } } impl<'a> ::windows::core::IntoParam<'a, ICommand> for ICommandText { fn into_param(self) -> ::windows::core::Param<'a, ICommand> { ::windows::core::Param::Owned(unsafe { ::core::mem::transmute(self) }) } } impl<'a> ::windows::core::IntoParam<'a, ICommand> for &ICommandText { fn into_param(self) -> ::windows::core::Param<'a, ICommand> { ::windows::core::Param::Borrowed(unsafe { ::core::mem::transmute(self) }) } } #[repr(C)] #[doc(hidden)] pub struct ICommandText_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, punkouter: ::windows::core::RawPtr, riid: *const ::windows::core::GUID, pparams: *mut DBPARAMS, pcrowsaffected: *mut isize, pprowset: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, riid: *const ::windows::core::GUID, ppsession: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pguiddialect: *mut ::windows::core::GUID, ppwszcommand: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, rguiddialect: *const ::windows::core::GUID, pwszcommand: super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ICommandValidate(pub ::windows::core::IUnknown); impl ICommandValidate { pub unsafe fn ValidateCompletely(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self)).ok() } pub unsafe fn ValidateSyntax(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self)).ok() } } unsafe impl ::windows::core::Interface for ICommandValidate { type Vtable = ICommandValidate_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a18_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<ICommandValidate> for ::windows::core::IUnknown { fn from(value: ICommandValidate) -> Self { value.0 } } impl ::core::convert::From<&ICommandValidate> for ::windows::core::IUnknown { fn from(value: &ICommandValidate) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ICommandValidate { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ICommandValidate { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ICommandValidate_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ICommandWithParameters(pub ::windows::core::IUnknown); impl ICommandWithParameters { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub unsafe fn GetParameterInfo(&self, pcparams: *mut usize, prgparaminfo: *mut *mut DBPARAMINFO, ppnamesbuffer: *mut *mut u16) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(pcparams), ::core::mem::transmute(prgparaminfo), ::core::mem::transmute(ppnamesbuffer)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn MapParameterNames(&self, cparamnames: usize, rgparamnames: *const super::super::Foundation::PWSTR, rgparamordinals: *mut isize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(cparamnames), ::core::mem::transmute(rgparamnames), ::core::mem::transmute(rgparamordinals)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn SetParameterInfo(&self, cparams: usize, rgparamordinals: *const usize, rgparambindinfo: *const DBPARAMBINDINFO) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(cparams), ::core::mem::transmute(rgparamordinals), ::core::mem::transmute(rgparambindinfo)).ok() } } unsafe impl ::windows::core::Interface for ICommandWithParameters { type Vtable = ICommandWithParameters_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a64_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<ICommandWithParameters> for ::windows::core::IUnknown { fn from(value: ICommandWithParameters) -> Self { value.0 } } impl ::core::convert::From<&ICommandWithParameters> for ::windows::core::IUnknown { fn from(value: &ICommandWithParameters) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ICommandWithParameters { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ICommandWithParameters { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ICommandWithParameters_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pcparams: *mut usize, prgparaminfo: *mut *mut DBPARAMINFO, ppnamesbuffer: *mut *mut u16) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com")))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, cparamnames: usize, rgparamnames: *const super::super::Foundation::PWSTR, rgparamordinals: *mut isize) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, cparams: usize, rgparamordinals: *const usize, rgparambindinfo: *const DBPARAMBINDINFO) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ICondition(pub ::windows::core::IUnknown); impl ICondition { pub unsafe fn GetClassID(&self) -> ::windows::core::Result<::windows::core::GUID> { let mut result__: <::windows::core::GUID as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), &mut result__).from_abi::<::windows::core::GUID>(result__) } pub unsafe fn IsDirty(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self)).ok() } #[cfg(feature = "Win32_System_Com")] pub unsafe fn Load<'a, Param0: ::windows::core::IntoParam<'a, super::Com::IStream>>(&self, pstm: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), pstm.into_param().abi()).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub unsafe fn Save<'a, Param0: ::windows::core::IntoParam<'a, super::Com::IStream>, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>(&self, pstm: Param0, fcleardirty: Param1) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), pstm.into_param().abi(), fcleardirty.into_param().abi()).ok() } pub unsafe fn GetSizeMax(&self) -> ::windows::core::Result<u64> { let mut result__: <u64 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), &mut result__).from_abi::<u64>(result__) } #[cfg(feature = "Win32_System_Search_Common")] pub unsafe fn GetConditionType(&self) -> ::windows::core::Result<Common::CONDITION_TYPE> { let mut result__: <Common::CONDITION_TYPE as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).8)(::core::mem::transmute_copy(self), &mut result__).from_abi::<Common::CONDITION_TYPE>(result__) } pub unsafe fn GetSubConditions<T: ::windows::core::Interface>(&self) -> ::windows::core::Result<T> { let mut result__ = ::core::option::Option::None; (::windows::core::Interface::vtable(self).9)(::core::mem::transmute_copy(self), &<T as ::windows::core::Interface>::IID, &mut result__ as *mut _ as *mut _).and_some(result__) } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_System_Search_Common"))] pub unsafe fn GetComparisonInfo(&self, ppszpropertyname: *mut super::super::Foundation::PWSTR, pcop: *mut Common::CONDITION_OPERATION, ppropvar: *mut super::Com::StructuredStorage::PROPVARIANT) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).10)(::core::mem::transmute_copy(self), ::core::mem::transmute(ppszpropertyname), ::core::mem::transmute(pcop), ::core::mem::transmute(ppropvar)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetValueType(&self) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).11)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetValueNormalization(&self) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).12)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } pub unsafe fn GetInputTerms(&self, pppropertyterm: *mut ::core::option::Option<IRichChunk>, ppoperationterm: *mut ::core::option::Option<IRichChunk>, ppvalueterm: *mut ::core::option::Option<IRichChunk>) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).13)(::core::mem::transmute_copy(self), ::core::mem::transmute(pppropertyterm), ::core::mem::transmute(ppoperationterm), ::core::mem::transmute(ppvalueterm)).ok() } pub unsafe fn Clone(&self) -> ::windows::core::Result<ICondition> { let mut result__: <ICondition as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).14)(::core::mem::transmute_copy(self), &mut result__).from_abi::<ICondition>(result__) } } unsafe impl ::windows::core::Interface for ICondition { type Vtable = ICondition_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0fc988d4_c935_4b97_a973_46282ea175c8); } impl ::core::convert::From<ICondition> for ::windows::core::IUnknown { fn from(value: ICondition) -> Self { value.0 } } impl ::core::convert::From<&ICondition> for ::windows::core::IUnknown { fn from(value: &ICondition) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ICondition { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ICondition { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[cfg(feature = "Win32_System_Com")] impl ::core::convert::From<ICondition> for super::Com::IPersistStream { fn from(value: ICondition) -> Self { unsafe { ::core::mem::transmute(value) } } } #[cfg(feature = "Win32_System_Com")] impl ::core::convert::From<&ICondition> for super::Com::IPersistStream { fn from(value: &ICondition) -> Self { ::core::convert::From::from(::core::clone::Clone::clone(value)) } } #[cfg(feature = "Win32_System_Com")] impl<'a> ::windows::core::IntoParam<'a, super::Com::IPersistStream> for ICondition { fn into_param(self) -> ::windows::core::Param<'a, super::Com::IPersistStream> { ::windows::core::Param::Owned(unsafe { ::core::mem::transmute(self) }) } } #[cfg(feature = "Win32_System_Com")] impl<'a> ::windows::core::IntoParam<'a, super::Com::IPersistStream> for &ICondition { fn into_param(self) -> ::windows::core::Param<'a, super::Com::IPersistStream> { ::windows::core::Param::Borrowed(unsafe { ::core::mem::transmute(self) }) } } #[cfg(feature = "Win32_System_Com")] impl ::core::convert::From<ICondition> for super::Com::IPersist { fn from(value: ICondition) -> Self { unsafe { ::core::mem::transmute(value) } } } #[cfg(feature = "Win32_System_Com")] impl ::core::convert::From<&ICondition> for super::Com::IPersist { fn from(value: &ICondition) -> Self { ::core::convert::From::from(::core::clone::Clone::clone(value)) } } #[cfg(feature = "Win32_System_Com")] impl<'a> ::windows::core::IntoParam<'a, super::Com::IPersist> for ICondition { fn into_param(self) -> ::windows::core::Param<'a, super::Com::IPersist> { ::windows::core::Param::Owned(unsafe { ::core::mem::transmute(self) }) } } #[cfg(feature = "Win32_System_Com")] impl<'a> ::windows::core::IntoParam<'a, super::Com::IPersist> for &ICondition { fn into_param(self) -> ::windows::core::Param<'a, super::Com::IPersist> { ::windows::core::Param::Borrowed(unsafe { ::core::mem::transmute(self) }) } } #[repr(C)] #[doc(hidden)] pub struct ICondition_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pclassid: *mut ::windows::core::GUID) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_System_Com")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pstm: ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_System_Com"))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pstm: ::windows::core::RawPtr, fcleardirty: super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com")))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pcbsize: *mut u64) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_System_Search_Common")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pnodetype: *mut Common::CONDITION_TYPE) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_System_Search_Common"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, riid: *const ::windows::core::GUID, ppv: *mut *mut ::core::ffi::c_void) -> ::windows::core::HRESULT, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_System_Search_Common"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppszpropertyname: *mut super::super::Foundation::PWSTR, pcop: *mut Common::CONDITION_OPERATION, ppropvar: *mut ::core::mem::ManuallyDrop<super::Com::StructuredStorage::PROPVARIANT>) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_System_Search_Common")))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppszvaluetypename: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppsznormalization: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pppropertyterm: *mut ::windows::core::RawPtr, ppoperationterm: *mut ::windows::core::RawPtr, ppvalueterm: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppc: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ICondition2(pub ::windows::core::IUnknown); impl ICondition2 { pub unsafe fn GetClassID(&self) -> ::windows::core::Result<::windows::core::GUID> { let mut result__: <::windows::core::GUID as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), &mut result__).from_abi::<::windows::core::GUID>(result__) } pub unsafe fn IsDirty(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self)).ok() } #[cfg(feature = "Win32_System_Com")] pub unsafe fn Load<'a, Param0: ::windows::core::IntoParam<'a, super::Com::IStream>>(&self, pstm: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), pstm.into_param().abi()).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub unsafe fn Save<'a, Param0: ::windows::core::IntoParam<'a, super::Com::IStream>, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>(&self, pstm: Param0, fcleardirty: Param1) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), pstm.into_param().abi(), fcleardirty.into_param().abi()).ok() } pub unsafe fn GetSizeMax(&self) -> ::windows::core::Result<u64> { let mut result__: <u64 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), &mut result__).from_abi::<u64>(result__) } #[cfg(feature = "Win32_System_Search_Common")] pub unsafe fn GetConditionType(&self) -> ::windows::core::Result<Common::CONDITION_TYPE> { let mut result__: <Common::CONDITION_TYPE as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).8)(::core::mem::transmute_copy(self), &mut result__).from_abi::<Common::CONDITION_TYPE>(result__) } pub unsafe fn GetSubConditions<T: ::windows::core::Interface>(&self) -> ::windows::core::Result<T> { let mut result__ = ::core::option::Option::None; (::windows::core::Interface::vtable(self).9)(::core::mem::transmute_copy(self), &<T as ::windows::core::Interface>::IID, &mut result__ as *mut _ as *mut _).and_some(result__) } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_System_Search_Common"))] pub unsafe fn GetComparisonInfo(&self, ppszpropertyname: *mut super::super::Foundation::PWSTR, pcop: *mut Common::CONDITION_OPERATION, ppropvar: *mut super::Com::StructuredStorage::PROPVARIANT) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).10)(::core::mem::transmute_copy(self), ::core::mem::transmute(ppszpropertyname), ::core::mem::transmute(pcop), ::core::mem::transmute(ppropvar)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetValueType(&self) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).11)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetValueNormalization(&self) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).12)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } pub unsafe fn GetInputTerms(&self, pppropertyterm: *mut ::core::option::Option<IRichChunk>, ppoperationterm: *mut ::core::option::Option<IRichChunk>, ppvalueterm: *mut ::core::option::Option<IRichChunk>) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).13)(::core::mem::transmute_copy(self), ::core::mem::transmute(pppropertyterm), ::core::mem::transmute(ppoperationterm), ::core::mem::transmute(ppvalueterm)).ok() } pub unsafe fn Clone(&self) -> ::windows::core::Result<ICondition> { let mut result__: <ICondition as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).14)(::core::mem::transmute_copy(self), &mut result__).from_abi::<ICondition>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetLocale(&self) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).15)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_System_Search_Common", feature = "Win32_UI_Shell_PropertiesSystem"))] pub unsafe fn GetLeafConditionInfo(&self, ppropkey: *mut super::super::UI::Shell::PropertiesSystem::PROPERTYKEY, pcop: *mut Common::CONDITION_OPERATION, ppropvar: *mut super::Com::StructuredStorage::PROPVARIANT) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).16)(::core::mem::transmute_copy(self), ::core::mem::transmute(ppropkey), ::core::mem::transmute(pcop), ::core::mem::transmute(ppropvar)).ok() } } unsafe impl ::windows::core::Interface for ICondition2 { type Vtable = ICondition2_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0db8851d_2e5b_47eb_9208_d28c325a01d7); } impl ::core::convert::From<ICondition2> for ::windows::core::IUnknown { fn from(value: ICondition2) -> Self { value.0 } } impl ::core::convert::From<&ICondition2> for ::windows::core::IUnknown { fn from(value: &ICondition2) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ICondition2 { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ICondition2 { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } impl ::core::convert::From<ICondition2> for ICondition { fn from(value: ICondition2) -> Self { unsafe { ::core::mem::transmute(value) } } } impl ::core::convert::From<&ICondition2> for ICondition { fn from(value: &ICondition2) -> Self { ::core::convert::From::from(::core::clone::Clone::clone(value)) } } impl<'a> ::windows::core::IntoParam<'a, ICondition> for ICondition2 { fn into_param(self) -> ::windows::core::Param<'a, ICondition> { ::windows::core::Param::Owned(unsafe { ::core::mem::transmute(self) }) } } impl<'a> ::windows::core::IntoParam<'a, ICondition> for &ICondition2 { fn into_param(self) -> ::windows::core::Param<'a, ICondition> { ::windows::core::Param::Borrowed(unsafe { ::core::mem::transmute(self) }) } } #[cfg(feature = "Win32_System_Com")] impl ::core::convert::From<ICondition2> for super::Com::IPersistStream { fn from(value: ICondition2) -> Self { unsafe { ::core::mem::transmute(value) } } } #[cfg(feature = "Win32_System_Com")] impl ::core::convert::From<&ICondition2> for super::Com::IPersistStream { fn from(value: &ICondition2) -> Self { ::core::convert::From::from(::core::clone::Clone::clone(value)) } } #[cfg(feature = "Win32_System_Com")] impl<'a> ::windows::core::IntoParam<'a, super::Com::IPersistStream> for ICondition2 { fn into_param(self) -> ::windows::core::Param<'a, super::Com::IPersistStream> { ::windows::core::Param::Owned(unsafe { ::core::mem::transmute(self) }) } } #[cfg(feature = "Win32_System_Com")] impl<'a> ::windows::core::IntoParam<'a, super::Com::IPersistStream> for &ICondition2 { fn into_param(self) -> ::windows::core::Param<'a, super::Com::IPersistStream> { ::windows::core::Param::Borrowed(unsafe { ::core::mem::transmute(self) }) } } #[cfg(feature = "Win32_System_Com")] impl ::core::convert::From<ICondition2> for super::Com::IPersist { fn from(value: ICondition2) -> Self { unsafe { ::core::mem::transmute(value) } } } #[cfg(feature = "Win32_System_Com")] impl ::core::convert::From<&ICondition2> for super::Com::IPersist { fn from(value: &ICondition2) -> Self { ::core::convert::From::from(::core::clone::Clone::clone(value)) } } #[cfg(feature = "Win32_System_Com")] impl<'a> ::windows::core::IntoParam<'a, super::Com::IPersist> for ICondition2 { fn into_param(self) -> ::windows::core::Param<'a, super::Com::IPersist> { ::windows::core::Param::Owned(unsafe { ::core::mem::transmute(self) }) } } #[cfg(feature = "Win32_System_Com")] impl<'a> ::windows::core::IntoParam<'a, super::Com::IPersist> for &ICondition2 { fn into_param(self) -> ::windows::core::Param<'a, super::Com::IPersist> { ::windows::core::Param::Borrowed(unsafe { ::core::mem::transmute(self) }) } } #[repr(C)] #[doc(hidden)] pub struct ICondition2_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pclassid: *mut ::windows::core::GUID) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_System_Com")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pstm: ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_System_Com"))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pstm: ::windows::core::RawPtr, fcleardirty: super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com")))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pcbsize: *mut u64) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_System_Search_Common")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pnodetype: *mut Common::CONDITION_TYPE) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_System_Search_Common"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, riid: *const ::windows::core::GUID, ppv: *mut *mut ::core::ffi::c_void) -> ::windows::core::HRESULT, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_System_Search_Common"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppszpropertyname: *mut super::super::Foundation::PWSTR, pcop: *mut Common::CONDITION_OPERATION, ppropvar: *mut ::core::mem::ManuallyDrop<super::Com::StructuredStorage::PROPVARIANT>) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_System_Search_Common")))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppszvaluetypename: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppsznormalization: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pppropertyterm: *mut ::windows::core::RawPtr, ppoperationterm: *mut ::windows::core::RawPtr, ppvalueterm: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppc: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppszlocalename: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_System_Search_Common", feature = "Win32_UI_Shell_PropertiesSystem"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppropkey: *mut super::super::UI::Shell::PropertiesSystem::PROPERTYKEY, pcop: *mut Common::CONDITION_OPERATION, ppropvar: *mut ::core::mem::ManuallyDrop<super::Com::StructuredStorage::PROPVARIANT>) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_System_Search_Common", feature = "Win32_UI_Shell_PropertiesSystem")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IConditionFactory(pub ::windows::core::IUnknown); impl IConditionFactory { #[cfg(feature = "Win32_Foundation")] pub unsafe fn MakeNot<'a, Param0: ::windows::core::IntoParam<'a, ICondition>, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>(&self, pcsub: Param0, fsimplify: Param1) -> ::windows::core::Result<ICondition> { let mut result__: <ICondition as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), pcsub.into_param().abi(), fsimplify.into_param().abi(), &mut result__).from_abi::<ICondition>(result__) } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Search_Common"))] pub unsafe fn MakeAndOr<'a, Param1: ::windows::core::IntoParam<'a, super::Com::IEnumUnknown>, Param2: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>(&self, ct: Common::CONDITION_TYPE, peusubs: Param1, fsimplify: Param2) -> ::windows::core::Result<ICondition> { let mut result__: <ICondition as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(ct), peusubs.into_param().abi(), fsimplify.into_param().abi(), &mut result__).from_abi::<ICondition>(result__) } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_System_Search_Common"))] pub unsafe fn MakeLeaf<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param2: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param4: ::windows::core::IntoParam<'a, IRichChunk>, Param5: ::windows::core::IntoParam<'a, IRichChunk>, Param6: ::windows::core::IntoParam<'a, IRichChunk>, Param7: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>( &self, pszpropertyname: Param0, cop: Common::CONDITION_OPERATION, pszvaluetype: Param2, ppropvar: *const super::Com::StructuredStorage::PROPVARIANT, ppropertynameterm: Param4, poperationterm: Param5, pvalueterm: Param6, fexpand: Param7, ) -> ::windows::core::Result<ICondition> { let mut result__: <ICondition as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).5)( ::core::mem::transmute_copy(self), pszpropertyname.into_param().abi(), ::core::mem::transmute(cop), pszvaluetype.into_param().abi(), ::core::mem::transmute(ppropvar), ppropertynameterm.into_param().abi(), poperationterm.into_param().abi(), pvalueterm.into_param().abi(), fexpand.into_param().abi(), &mut result__, ) .from_abi::<ICondition>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn Resolve<'a, Param0: ::windows::core::IntoParam<'a, ICondition>>(&self, pc: Param0, sqro: STRUCTURED_QUERY_RESOLVE_OPTION, pstreferencetime: *const super::super::Foundation::SYSTEMTIME) -> ::windows::core::Result<ICondition> { let mut result__: <ICondition as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), pc.into_param().abi(), ::core::mem::transmute(sqro), ::core::mem::transmute(pstreferencetime), &mut result__).from_abi::<ICondition>(result__) } } unsafe impl ::windows::core::Interface for IConditionFactory { type Vtable = IConditionFactory_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xa5efe073_b16f_474f_9f3e_9f8b497a3e08); } impl ::core::convert::From<IConditionFactory> for ::windows::core::IUnknown { fn from(value: IConditionFactory) -> Self { value.0 } } impl ::core::convert::From<&IConditionFactory> for ::windows::core::IUnknown { fn from(value: &IConditionFactory) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IConditionFactory { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IConditionFactory { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IConditionFactory_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pcsub: ::windows::core::RawPtr, fsimplify: super::super::Foundation::BOOL, ppcresult: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Search_Common"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ct: Common::CONDITION_TYPE, peusubs: ::windows::core::RawPtr, fsimplify: super::super::Foundation::BOOL, ppcresult: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Search_Common")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_System_Search_Common"))] pub unsafe extern "system" fn( this: ::windows::core::RawPtr, pszpropertyname: super::super::Foundation::PWSTR, cop: Common::CONDITION_OPERATION, pszvaluetype: super::super::Foundation::PWSTR, ppropvar: *const ::core::mem::ManuallyDrop<super::Com::StructuredStorage::PROPVARIANT>, ppropertynameterm: ::windows::core::RawPtr, poperationterm: ::windows::core::RawPtr, pvalueterm: ::windows::core::RawPtr, fexpand: super::super::Foundation::BOOL, ppcresult: *mut ::windows::core::RawPtr, ) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_System_Search_Common")))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pc: ::windows::core::RawPtr, sqro: STRUCTURED_QUERY_RESOLVE_OPTION, pstreferencetime: *const super::super::Foundation::SYSTEMTIME, ppcresolved: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IConditionFactory2(pub ::windows::core::IUnknown); impl IConditionFactory2 { #[cfg(feature = "Win32_Foundation")] pub unsafe fn MakeNot<'a, Param0: ::windows::core::IntoParam<'a, ICondition>, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>(&self, pcsub: Param0, fsimplify: Param1) -> ::windows::core::Result<ICondition> { let mut result__: <ICondition as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), pcsub.into_param().abi(), fsimplify.into_param().abi(), &mut result__).from_abi::<ICondition>(result__) } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Search_Common"))] pub unsafe fn MakeAndOr<'a, Param1: ::windows::core::IntoParam<'a, super::Com::IEnumUnknown>, Param2: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>(&self, ct: Common::CONDITION_TYPE, peusubs: Param1, fsimplify: Param2) -> ::windows::core::Result<ICondition> { let mut result__: <ICondition as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(ct), peusubs.into_param().abi(), fsimplify.into_param().abi(), &mut result__).from_abi::<ICondition>(result__) } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_System_Search_Common"))] pub unsafe fn MakeLeaf<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param2: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param4: ::windows::core::IntoParam<'a, IRichChunk>, Param5: ::windows::core::IntoParam<'a, IRichChunk>, Param6: ::windows::core::IntoParam<'a, IRichChunk>, Param7: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>( &self, pszpropertyname: Param0, cop: Common::CONDITION_OPERATION, pszvaluetype: Param2, ppropvar: *const super::Com::StructuredStorage::PROPVARIANT, ppropertynameterm: Param4, poperationterm: Param5, pvalueterm: Param6, fexpand: Param7, ) -> ::windows::core::Result<ICondition> { let mut result__: <ICondition as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).5)( ::core::mem::transmute_copy(self), pszpropertyname.into_param().abi(), ::core::mem::transmute(cop), pszvaluetype.into_param().abi(), ::core::mem::transmute(ppropvar), ppropertynameterm.into_param().abi(), poperationterm.into_param().abi(), pvalueterm.into_param().abi(), fexpand.into_param().abi(), &mut result__, ) .from_abi::<ICondition>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn Resolve<'a, Param0: ::windows::core::IntoParam<'a, ICondition>>(&self, pc: Param0, sqro: STRUCTURED_QUERY_RESOLVE_OPTION, pstreferencetime: *const super::super::Foundation::SYSTEMTIME) -> ::windows::core::Result<ICondition> { let mut result__: <ICondition as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), pc.into_param().abi(), ::core::mem::transmute(sqro), ::core::mem::transmute(pstreferencetime), &mut result__).from_abi::<ICondition>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn CreateTrueFalse<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>, T: ::windows::core::Interface>(&self, fval: Param0, cco: CONDITION_CREATION_OPTIONS) -> ::windows::core::Result<T> { let mut result__ = ::core::option::Option::None; (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), fval.into_param().abi(), ::core::mem::transmute(cco), &<T as ::windows::core::Interface>::IID, &mut result__ as *mut _ as *mut _).and_some(result__) } pub unsafe fn CreateNegation<'a, Param0: ::windows::core::IntoParam<'a, ICondition>, T: ::windows::core::Interface>(&self, pcsub: Param0, cco: CONDITION_CREATION_OPTIONS) -> ::windows::core::Result<T> { let mut result__ = ::core::option::Option::None; (::windows::core::Interface::vtable(self).8)(::core::mem::transmute_copy(self), pcsub.into_param().abi(), ::core::mem::transmute(cco), &<T as ::windows::core::Interface>::IID, &mut result__ as *mut _ as *mut _).and_some(result__) } #[cfg(all(feature = "Win32_System_Search_Common", feature = "Win32_UI_Shell_Common"))] pub unsafe fn CreateCompoundFromObjectArray<'a, Param1: ::windows::core::IntoParam<'a, super::super::UI::Shell::Common::IObjectArray>, T: ::windows::core::Interface>(&self, ct: Common::CONDITION_TYPE, poasubs: Param1, cco: CONDITION_CREATION_OPTIONS) -> ::windows::core::Result<T> { let mut result__ = ::core::option::Option::None; (::windows::core::Interface::vtable(self).9)(::core::mem::transmute_copy(self), ::core::mem::transmute(ct), poasubs.into_param().abi(), ::core::mem::transmute(cco), &<T as ::windows::core::Interface>::IID, &mut result__ as *mut _ as *mut _).and_some(result__) } #[cfg(feature = "Win32_System_Search_Common")] pub unsafe fn CreateCompoundFromArray<T: ::windows::core::Interface>(&self, ct: Common::CONDITION_TYPE, ppcondsubs: *const ::core::option::Option<ICondition>, csubs: u32, cco: CONDITION_CREATION_OPTIONS) -> ::windows::core::Result<T> { let mut result__ = ::core::option::Option::None; (::windows::core::Interface::vtable(self).10)(::core::mem::transmute_copy(self), ::core::mem::transmute(ct), ::core::mem::transmute(ppcondsubs), ::core::mem::transmute(csubs), ::core::mem::transmute(cco), &<T as ::windows::core::Interface>::IID, &mut result__ as *mut _ as *mut _).and_some(result__) } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Search_Common", feature = "Win32_UI_Shell_PropertiesSystem"))] pub unsafe fn CreateStringLeaf<'a, Param2: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param3: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, T: ::windows::core::Interface>(&self, propkey: *const super::super::UI::Shell::PropertiesSystem::PROPERTYKEY, cop: Common::CONDITION_OPERATION, pszvalue: Param2, pszlocalename: Param3, cco: CONDITION_CREATION_OPTIONS) -> ::windows::core::Result<T> { let mut result__ = ::core::option::Option::None; (::windows::core::Interface::vtable(self).11)(::core::mem::transmute_copy(self), ::core::mem::transmute(propkey), ::core::mem::transmute(cop), pszvalue.into_param().abi(), pszlocalename.into_param().abi(), ::core::mem::transmute(cco), &<T as ::windows::core::Interface>::IID, &mut result__ as *mut _ as *mut _).and_some(result__) } #[cfg(all(feature = "Win32_System_Search_Common", feature = "Win32_UI_Shell_PropertiesSystem"))] pub unsafe fn CreateIntegerLeaf<T: ::windows::core::Interface>(&self, propkey: *const super::super::UI::Shell::PropertiesSystem::PROPERTYKEY, cop: Common::CONDITION_OPERATION, lvalue: i32, cco: CONDITION_CREATION_OPTIONS) -> ::windows::core::Result<T> { let mut result__ = ::core::option::Option::None; (::windows::core::Interface::vtable(self).12)(::core::mem::transmute_copy(self), ::core::mem::transmute(propkey), ::core::mem::transmute(cop), ::core::mem::transmute(lvalue), ::core::mem::transmute(cco), &<T as ::windows::core::Interface>::IID, &mut result__ as *mut _ as *mut _).and_some(result__) } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Search_Common", feature = "Win32_UI_Shell_PropertiesSystem"))] pub unsafe fn CreateBooleanLeaf<'a, Param2: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>, T: ::windows::core::Interface>(&self, propkey: *const super::super::UI::Shell::PropertiesSystem::PROPERTYKEY, cop: Common::CONDITION_OPERATION, fvalue: Param2, cco: CONDITION_CREATION_OPTIONS) -> ::windows::core::Result<T> { let mut result__ = ::core::option::Option::None; (::windows::core::Interface::vtable(self).13)(::core::mem::transmute_copy(self), ::core::mem::transmute(propkey), ::core::mem::transmute(cop), fvalue.into_param().abi(), ::core::mem::transmute(cco), &<T as ::windows::core::Interface>::IID, &mut result__ as *mut _ as *mut _).and_some(result__) } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_System_Search_Common", feature = "Win32_UI_Shell_PropertiesSystem"))] pub unsafe fn CreateLeaf<'a, Param3: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param4: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param5: ::windows::core::IntoParam<'a, IRichChunk>, Param6: ::windows::core::IntoParam<'a, IRichChunk>, Param7: ::windows::core::IntoParam<'a, IRichChunk>, T: ::windows::core::Interface>( &self, propkey: *const super::super::UI::Shell::PropertiesSystem::PROPERTYKEY, cop: Common::CONDITION_OPERATION, propvar: *const super::Com::StructuredStorage::PROPVARIANT, pszsemantictype: Param3, pszlocalename: Param4, ppropertynameterm: Param5, poperationterm: Param6, pvalueterm: Param7, cco: CONDITION_CREATION_OPTIONS, ) -> ::windows::core::Result<T> { let mut result__ = ::core::option::Option::None; (::windows::core::Interface::vtable(self).14)( ::core::mem::transmute_copy(self), ::core::mem::transmute(propkey), ::core::mem::transmute(cop), ::core::mem::transmute(propvar), pszsemantictype.into_param().abi(), pszlocalename.into_param().abi(), ppropertynameterm.into_param().abi(), poperationterm.into_param().abi(), pvalueterm.into_param().abi(), ::core::mem::transmute(cco), &<T as ::windows::core::Interface>::IID, &mut result__ as *mut _ as *mut _, ) .and_some(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn ResolveCondition<'a, Param0: ::windows::core::IntoParam<'a, ICondition>, T: ::windows::core::Interface>(&self, pc: Param0, sqro: STRUCTURED_QUERY_RESOLVE_OPTION, pstreferencetime: *const super::super::Foundation::SYSTEMTIME) -> ::windows::core::Result<T> { let mut result__ = ::core::option::Option::None; (::windows::core::Interface::vtable(self).15)(::core::mem::transmute_copy(self), pc.into_param().abi(), ::core::mem::transmute(sqro), ::core::mem::transmute(pstreferencetime), &<T as ::windows::core::Interface>::IID, &mut result__ as *mut _ as *mut _).and_some(result__) } } unsafe impl ::windows::core::Interface for IConditionFactory2 { type Vtable = IConditionFactory2_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x71d222e1_432f_429e_8c13_b6dafde5077a); } impl ::core::convert::From<IConditionFactory2> for ::windows::core::IUnknown { fn from(value: IConditionFactory2) -> Self { value.0 } } impl ::core::convert::From<&IConditionFactory2> for ::windows::core::IUnknown { fn from(value: &IConditionFactory2) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IConditionFactory2 { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IConditionFactory2 { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } impl ::core::convert::From<IConditionFactory2> for IConditionFactory { fn from(value: IConditionFactory2) -> Self { unsafe { ::core::mem::transmute(value) } } } impl ::core::convert::From<&IConditionFactory2> for IConditionFactory { fn from(value: &IConditionFactory2) -> Self { ::core::convert::From::from(::core::clone::Clone::clone(value)) } } impl<'a> ::windows::core::IntoParam<'a, IConditionFactory> for IConditionFactory2 { fn into_param(self) -> ::windows::core::Param<'a, IConditionFactory> { ::windows::core::Param::Owned(unsafe { ::core::mem::transmute(self) }) } } impl<'a> ::windows::core::IntoParam<'a, IConditionFactory> for &IConditionFactory2 { fn into_param(self) -> ::windows::core::Param<'a, IConditionFactory> { ::windows::core::Param::Borrowed(unsafe { ::core::mem::transmute(self) }) } } #[repr(C)] #[doc(hidden)] pub struct IConditionFactory2_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pcsub: ::windows::core::RawPtr, fsimplify: super::super::Foundation::BOOL, ppcresult: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Search_Common"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ct: Common::CONDITION_TYPE, peusubs: ::windows::core::RawPtr, fsimplify: super::super::Foundation::BOOL, ppcresult: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Search_Common")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_System_Search_Common"))] pub unsafe extern "system" fn( this: ::windows::core::RawPtr, pszpropertyname: super::super::Foundation::PWSTR, cop: Common::CONDITION_OPERATION, pszvaluetype: super::super::Foundation::PWSTR, ppropvar: *const ::core::mem::ManuallyDrop<super::Com::StructuredStorage::PROPVARIANT>, ppropertynameterm: ::windows::core::RawPtr, poperationterm: ::windows::core::RawPtr, pvalueterm: ::windows::core::RawPtr, fexpand: super::super::Foundation::BOOL, ppcresult: *mut ::windows::core::RawPtr, ) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_System_Search_Common")))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pc: ::windows::core::RawPtr, sqro: STRUCTURED_QUERY_RESOLVE_OPTION, pstreferencetime: *const super::super::Foundation::SYSTEMTIME, ppcresolved: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, fval: super::super::Foundation::BOOL, cco: CONDITION_CREATION_OPTIONS, riid: *const ::windows::core::GUID, ppv: *mut *mut ::core::ffi::c_void) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pcsub: ::windows::core::RawPtr, cco: CONDITION_CREATION_OPTIONS, riid: *const ::windows::core::GUID, ppv: *mut *mut ::core::ffi::c_void) -> ::windows::core::HRESULT, #[cfg(all(feature = "Win32_System_Search_Common", feature = "Win32_UI_Shell_Common"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ct: Common::CONDITION_TYPE, poasubs: ::windows::core::RawPtr, cco: CONDITION_CREATION_OPTIONS, riid: *const ::windows::core::GUID, ppv: *mut *mut ::core::ffi::c_void) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_System_Search_Common", feature = "Win32_UI_Shell_Common")))] usize, #[cfg(feature = "Win32_System_Search_Common")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ct: Common::CONDITION_TYPE, ppcondsubs: *const ::windows::core::RawPtr, csubs: u32, cco: CONDITION_CREATION_OPTIONS, riid: *const ::windows::core::GUID, ppv: *mut *mut ::core::ffi::c_void) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_System_Search_Common"))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Search_Common", feature = "Win32_UI_Shell_PropertiesSystem"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, propkey: *const super::super::UI::Shell::PropertiesSystem::PROPERTYKEY, cop: Common::CONDITION_OPERATION, pszvalue: super::super::Foundation::PWSTR, pszlocalename: super::super::Foundation::PWSTR, cco: CONDITION_CREATION_OPTIONS, riid: *const ::windows::core::GUID, ppv: *mut *mut ::core::ffi::c_void) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Search_Common", feature = "Win32_UI_Shell_PropertiesSystem")))] usize, #[cfg(all(feature = "Win32_System_Search_Common", feature = "Win32_UI_Shell_PropertiesSystem"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, propkey: *const super::super::UI::Shell::PropertiesSystem::PROPERTYKEY, cop: Common::CONDITION_OPERATION, lvalue: i32, cco: CONDITION_CREATION_OPTIONS, riid: *const ::windows::core::GUID, ppv: *mut *mut ::core::ffi::c_void) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_System_Search_Common", feature = "Win32_UI_Shell_PropertiesSystem")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Search_Common", feature = "Win32_UI_Shell_PropertiesSystem"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, propkey: *const super::super::UI::Shell::PropertiesSystem::PROPERTYKEY, cop: Common::CONDITION_OPERATION, fvalue: super::super::Foundation::BOOL, cco: CONDITION_CREATION_OPTIONS, riid: *const ::windows::core::GUID, ppv: *mut *mut ::core::ffi::c_void) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Search_Common", feature = "Win32_UI_Shell_PropertiesSystem")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_System_Search_Common", feature = "Win32_UI_Shell_PropertiesSystem"))] pub unsafe extern "system" fn( this: ::windows::core::RawPtr, propkey: *const super::super::UI::Shell::PropertiesSystem::PROPERTYKEY, cop: Common::CONDITION_OPERATION, propvar: *const ::core::mem::ManuallyDrop<super::Com::StructuredStorage::PROPVARIANT>, pszsemantictype: super::super::Foundation::PWSTR, pszlocalename: super::super::Foundation::PWSTR, ppropertynameterm: ::windows::core::RawPtr, poperationterm: ::windows::core::RawPtr, pvalueterm: ::windows::core::RawPtr, cco: CONDITION_CREATION_OPTIONS, riid: *const ::windows::core::GUID, ppv: *mut *mut ::core::ffi::c_void, ) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_System_Search_Common", feature = "Win32_UI_Shell_PropertiesSystem")))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pc: ::windows::core::RawPtr, sqro: STRUCTURED_QUERY_RESOLVE_OPTION, pstreferencetime: *const super::super::Foundation::SYSTEMTIME, riid: *const ::windows::core::GUID, ppv: *mut *mut ::core::ffi::c_void) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IConditionGenerator(pub ::windows::core::IUnknown); impl IConditionGenerator { pub unsafe fn Initialize<'a, Param0: ::windows::core::IntoParam<'a, ISchemaProvider>>(&self, pschemaprovider: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), pschemaprovider.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn RecognizeNamedEntities<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param2: ::windows::core::IntoParam<'a, ITokenCollection>, Param3: ::windows::core::IntoParam<'a, INamedEntityCollector>>(&self, pszinputstring: Param0, lciduserlocale: u32, ptokencollection: Param2, pnamedentities: Param3) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), pszinputstring.into_param().abi(), ::core::mem::transmute(lciduserlocale), ptokencollection.into_param().abi(), pnamedentities.into_param().abi()).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Search_Common"))] pub unsafe fn GenerateForLeaf< 'a, Param0: ::windows::core::IntoParam<'a, IConditionFactory>, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param3: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param4: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param5: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param6: ::windows::core::IntoParam<'a, IRichChunk>, Param7: ::windows::core::IntoParam<'a, IRichChunk>, Param8: ::windows::core::IntoParam<'a, IRichChunk>, Param9: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>, >( &self, pconditionfactory: Param0, pszpropertyname: Param1, cop: Common::CONDITION_OPERATION, pszvaluetype: Param3, pszvalue: Param4, pszvalue2: Param5, ppropertynameterm: Param6, poperationterm: Param7, pvalueterm: Param8, automaticwildcard: Param9, pnostringquery: *mut super::super::Foundation::BOOL, ppqueryexpression: *mut ::core::option::Option<ICondition>, ) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)( ::core::mem::transmute_copy(self), pconditionfactory.into_param().abi(), pszpropertyname.into_param().abi(), ::core::mem::transmute(cop), pszvaluetype.into_param().abi(), pszvalue.into_param().abi(), pszvalue2.into_param().abi(), ppropertynameterm.into_param().abi(), poperationterm.into_param().abi(), pvalueterm.into_param().abi(), automaticwildcard.into_param().abi(), ::core::mem::transmute(pnostringquery), ::core::mem::transmute(ppqueryexpression), ) .ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe fn DefaultPhrase<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param2: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>(&self, pszvaluetype: Param0, ppropvar: *const super::Com::StructuredStorage::PROPVARIANT, fuseenglish: Param2) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), pszvaluetype.into_param().abi(), ::core::mem::transmute(ppropvar), fuseenglish.into_param().abi(), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } } unsafe impl ::windows::core::Interface for IConditionGenerator { type Vtable = IConditionGenerator_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x92d2cc58_4386_45a3_b98c_7e0ce64a4117); } impl ::core::convert::From<IConditionGenerator> for ::windows::core::IUnknown { fn from(value: IConditionGenerator) -> Self { value.0 } } impl ::core::convert::From<&IConditionGenerator> for ::windows::core::IUnknown { fn from(value: &IConditionGenerator) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IConditionGenerator { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IConditionGenerator { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IConditionGenerator_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pschemaprovider: ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszinputstring: super::super::Foundation::PWSTR, lciduserlocale: u32, ptokencollection: ::windows::core::RawPtr, pnamedentities: ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Search_Common"))] pub unsafe extern "system" fn( this: ::windows::core::RawPtr, pconditionfactory: ::windows::core::RawPtr, pszpropertyname: super::super::Foundation::PWSTR, cop: Common::CONDITION_OPERATION, pszvaluetype: super::super::Foundation::PWSTR, pszvalue: super::super::Foundation::PWSTR, pszvalue2: super::super::Foundation::PWSTR, ppropertynameterm: ::windows::core::RawPtr, poperationterm: ::windows::core::RawPtr, pvalueterm: ::windows::core::RawPtr, automaticwildcard: super::super::Foundation::BOOL, pnostringquery: *mut super::super::Foundation::BOOL, ppqueryexpression: *mut ::windows::core::RawPtr, ) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Search_Common")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszvaluetype: super::super::Foundation::PWSTR, ppropvar: *const ::core::mem::ManuallyDrop<super::Com::StructuredStorage::PROPVARIANT>, fuseenglish: super::super::Foundation::BOOL, ppszphrase: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IConvertType(pub ::windows::core::IUnknown); impl IConvertType { pub unsafe fn CanConvert(&self, wfromtype: u16, wtotype: u16, dwconvertflags: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(wfromtype), ::core::mem::transmute(wtotype), ::core::mem::transmute(dwconvertflags)).ok() } } unsafe impl ::windows::core::Interface for IConvertType { type Vtable = IConvertType_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a88_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IConvertType> for ::windows::core::IUnknown { fn from(value: IConvertType) -> Self { value.0 } } impl ::core::convert::From<&IConvertType> for ::windows::core::IUnknown { fn from(value: &IConvertType) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IConvertType { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IConvertType { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IConvertType_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, wfromtype: u16, wtotype: u16, dwconvertflags: u32) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ICreateRow(pub ::windows::core::IUnknown); impl ICreateRow { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub unsafe fn CreateRow<'a, Param0: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param5: ::windows::core::IntoParam<'a, super::Com::IAuthenticate>>( &self, punkouter: Param0, pwszurl: Param1, dwbindurlflags: u32, rguid: *const ::windows::core::GUID, riid: *const ::windows::core::GUID, pauthenticate: Param5, pimplsession: *mut DBIMPLICITSESSION, pdwbindstatus: *mut u32, ppwsznewurl: *mut super::super::Foundation::PWSTR, ppunk: *mut ::core::option::Option<::windows::core::IUnknown>, ) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)( ::core::mem::transmute_copy(self), punkouter.into_param().abi(), pwszurl.into_param().abi(), ::core::mem::transmute(dwbindurlflags), ::core::mem::transmute(rguid), ::core::mem::transmute(riid), pauthenticate.into_param().abi(), ::core::mem::transmute(pimplsession), ::core::mem::transmute(pdwbindstatus), ::core::mem::transmute(ppwsznewurl), ::core::mem::transmute(ppunk), ) .ok() } } unsafe impl ::windows::core::Interface for ICreateRow { type Vtable = ICreateRow_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733ab2_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<ICreateRow> for ::windows::core::IUnknown { fn from(value: ICreateRow) -> Self { value.0 } } impl ::core::convert::From<&ICreateRow> for ::windows::core::IUnknown { fn from(value: &ICreateRow) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ICreateRow { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ICreateRow { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ICreateRow_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, punkouter: ::windows::core::RawPtr, pwszurl: super::super::Foundation::PWSTR, dwbindurlflags: u32, rguid: *const ::windows::core::GUID, riid: *const ::windows::core::GUID, pauthenticate: ::windows::core::RawPtr, pimplsession: *mut ::core::mem::ManuallyDrop<DBIMPLICITSESSION>, pdwbindstatus: *mut u32, ppwsznewurl: *mut super::super::Foundation::PWSTR, ppunk: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IDBAsynchNotify(pub ::windows::core::IUnknown); impl IDBAsynchNotify { pub unsafe fn OnLowResource(&self, dwreserved: usize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(dwreserved)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn OnProgress<'a, Param5: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, hchapter: usize, eoperation: u32, ulprogress: usize, ulprogressmax: usize, easynchphase: u32, pwszstatustext: Param5) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(hchapter), ::core::mem::transmute(eoperation), ::core::mem::transmute(ulprogress), ::core::mem::transmute(ulprogressmax), ::core::mem::transmute(easynchphase), pwszstatustext.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn OnStop<'a, Param3: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, hchapter: usize, eoperation: u32, hrstatus: ::windows::core::HRESULT, pwszstatustext: Param3) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(hchapter), ::core::mem::transmute(eoperation), ::core::mem::transmute(hrstatus), pwszstatustext.into_param().abi()).ok() } } unsafe impl ::windows::core::Interface for IDBAsynchNotify { type Vtable = IDBAsynchNotify_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a96_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IDBAsynchNotify> for ::windows::core::IUnknown { fn from(value: IDBAsynchNotify) -> Self { value.0 } } impl ::core::convert::From<&IDBAsynchNotify> for ::windows::core::IUnknown { fn from(value: &IDBAsynchNotify) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IDBAsynchNotify { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IDBAsynchNotify { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IDBAsynchNotify_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, dwreserved: usize) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hchapter: usize, eoperation: u32, ulprogress: usize, ulprogressmax: usize, easynchphase: u32, pwszstatustext: super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hchapter: usize, eoperation: u32, hrstatus: ::windows::core::HRESULT, pwszstatustext: super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IDBAsynchStatus(pub ::windows::core::IUnknown); impl IDBAsynchStatus { pub unsafe fn Abort(&self, hchapter: usize, eoperation: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(hchapter), ::core::mem::transmute(eoperation)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetStatus(&self, hchapter: usize, eoperation: u32, pulprogress: *mut usize, pulprogressmax: *mut usize, peasynchphase: *mut u32, ppwszstatustext: *mut super::super::Foundation::PWSTR) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(hchapter), ::core::mem::transmute(eoperation), ::core::mem::transmute(pulprogress), ::core::mem::transmute(pulprogressmax), ::core::mem::transmute(peasynchphase), ::core::mem::transmute(ppwszstatustext)).ok() } } unsafe impl ::windows::core::Interface for IDBAsynchStatus { type Vtable = IDBAsynchStatus_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a95_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IDBAsynchStatus> for ::windows::core::IUnknown { fn from(value: IDBAsynchStatus) -> Self { value.0 } } impl ::core::convert::From<&IDBAsynchStatus> for ::windows::core::IUnknown { fn from(value: &IDBAsynchStatus) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IDBAsynchStatus { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IDBAsynchStatus { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IDBAsynchStatus_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hchapter: usize, eoperation: u32) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hchapter: usize, eoperation: u32, pulprogress: *mut usize, pulprogressmax: *mut usize, peasynchphase: *mut u32, ppwszstatustext: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IDBBinderProperties(pub ::windows::core::IUnknown); impl IDBBinderProperties { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn GetProperties(&self, cpropertyidsets: u32, rgpropertyidsets: *const DBPROPIDSET, pcpropertysets: *mut u32, prgpropertysets: *mut *mut DBPROPSET) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(cpropertyidsets), ::core::mem::transmute(rgpropertyidsets), ::core::mem::transmute(pcpropertysets), ::core::mem::transmute(prgpropertysets)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn GetPropertyInfo(&self, cpropertyidsets: u32, rgpropertyidsets: *const DBPROPIDSET, pcpropertyinfosets: *mut u32, prgpropertyinfosets: *mut *mut DBPROPINFOSET, ppdescbuffer: *mut *mut u16) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(cpropertyidsets), ::core::mem::transmute(rgpropertyidsets), ::core::mem::transmute(pcpropertyinfosets), ::core::mem::transmute(prgpropertyinfosets), ::core::mem::transmute(ppdescbuffer)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn SetProperties(&self, cpropertysets: u32, rgpropertysets: *mut DBPROPSET) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(cpropertysets), ::core::mem::transmute(rgpropertysets)).ok() } pub unsafe fn Reset(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self)).ok() } } unsafe impl ::windows::core::Interface for IDBBinderProperties { type Vtable = IDBBinderProperties_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733ab3_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IDBBinderProperties> for ::windows::core::IUnknown { fn from(value: IDBBinderProperties) -> Self { value.0 } } impl ::core::convert::From<&IDBBinderProperties> for ::windows::core::IUnknown { fn from(value: &IDBBinderProperties) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IDBBinderProperties { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IDBBinderProperties { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } impl ::core::convert::From<IDBBinderProperties> for IDBProperties { fn from(value: IDBBinderProperties) -> Self { unsafe { ::core::mem::transmute(value) } } } impl ::core::convert::From<&IDBBinderProperties> for IDBProperties { fn from(value: &IDBBinderProperties) -> Self { ::core::convert::From::from(::core::clone::Clone::clone(value)) } } impl<'a> ::windows::core::IntoParam<'a, IDBProperties> for IDBBinderProperties { fn into_param(self) -> ::windows::core::Param<'a, IDBProperties> { ::windows::core::Param::Owned(unsafe { ::core::mem::transmute(self) }) } } impl<'a> ::windows::core::IntoParam<'a, IDBProperties> for &IDBBinderProperties { fn into_param(self) -> ::windows::core::Param<'a, IDBProperties> { ::windows::core::Param::Borrowed(unsafe { ::core::mem::transmute(self) }) } } #[repr(C)] #[doc(hidden)] pub struct IDBBinderProperties_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, cpropertyidsets: u32, rgpropertyidsets: *const DBPROPIDSET, pcpropertysets: *mut u32, prgpropertysets: *mut *mut DBPROPSET) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, cpropertyidsets: u32, rgpropertyidsets: *const DBPROPIDSET, pcpropertyinfosets: *mut u32, prgpropertyinfosets: *mut *mut DBPROPINFOSET, ppdescbuffer: *mut *mut u16) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, cpropertysets: u32, rgpropertysets: *mut DBPROPSET) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IDBCreateCommand(pub ::windows::core::IUnknown); impl IDBCreateCommand { pub unsafe fn CreateCommand<'a, Param0: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>>(&self, punkouter: Param0, riid: *const ::windows::core::GUID) -> ::windows::core::Result<::windows::core::IUnknown> { let mut result__: <::windows::core::IUnknown as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), punkouter.into_param().abi(), ::core::mem::transmute(riid), &mut result__).from_abi::<::windows::core::IUnknown>(result__) } } unsafe impl ::windows::core::Interface for IDBCreateCommand { type Vtable = IDBCreateCommand_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a1d_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IDBCreateCommand> for ::windows::core::IUnknown { fn from(value: IDBCreateCommand) -> Self { value.0 } } impl ::core::convert::From<&IDBCreateCommand> for ::windows::core::IUnknown { fn from(value: &IDBCreateCommand) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IDBCreateCommand { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IDBCreateCommand { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IDBCreateCommand_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, punkouter: ::windows::core::RawPtr, riid: *const ::windows::core::GUID, ppcommand: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IDBCreateSession(pub ::windows::core::IUnknown); impl IDBCreateSession { pub unsafe fn CreateSession<'a, Param0: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>>(&self, punkouter: Param0, riid: *const ::windows::core::GUID) -> ::windows::core::Result<::windows::core::IUnknown> { let mut result__: <::windows::core::IUnknown as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), punkouter.into_param().abi(), ::core::mem::transmute(riid), &mut result__).from_abi::<::windows::core::IUnknown>(result__) } } unsafe impl ::windows::core::Interface for IDBCreateSession { type Vtable = IDBCreateSession_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a5d_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IDBCreateSession> for ::windows::core::IUnknown { fn from(value: IDBCreateSession) -> Self { value.0 } } impl ::core::convert::From<&IDBCreateSession> for ::windows::core::IUnknown { fn from(value: &IDBCreateSession) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IDBCreateSession { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IDBCreateSession { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IDBCreateSession_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, punkouter: ::windows::core::RawPtr, riid: *const ::windows::core::GUID, ppdbsession: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IDBDataSourceAdmin(pub ::windows::core::IUnknown); impl IDBDataSourceAdmin { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn CreateDataSource<'a, Param2: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>>(&self, cpropertysets: u32, rgpropertysets: *mut DBPROPSET, punkouter: Param2, riid: *const ::windows::core::GUID, ppdbsession: *mut ::core::option::Option<::windows::core::IUnknown>) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(cpropertysets), ::core::mem::transmute(rgpropertysets), punkouter.into_param().abi(), ::core::mem::transmute(riid), ::core::mem::transmute(ppdbsession)).ok() } pub unsafe fn DestroyDataSource(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn GetCreationProperties(&self, cpropertyidsets: u32, rgpropertyidsets: *const DBPROPIDSET, pcpropertyinfosets: *mut u32, prgpropertyinfosets: *mut *mut DBPROPINFOSET, ppdescbuffer: *mut *mut u16) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(cpropertyidsets), ::core::mem::transmute(rgpropertyidsets), ::core::mem::transmute(pcpropertyinfosets), ::core::mem::transmute(prgpropertyinfosets), ::core::mem::transmute(ppdescbuffer)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn ModifyDataSource(&self, cpropertysets: u32, rgpropertysets: *mut DBPROPSET) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), ::core::mem::transmute(cpropertysets), ::core::mem::transmute(rgpropertysets)).ok() } } unsafe impl ::windows::core::Interface for IDBDataSourceAdmin { type Vtable = IDBDataSourceAdmin_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a7a_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IDBDataSourceAdmin> for ::windows::core::IUnknown { fn from(value: IDBDataSourceAdmin) -> Self { value.0 } } impl ::core::convert::From<&IDBDataSourceAdmin> for ::windows::core::IUnknown { fn from(value: &IDBDataSourceAdmin) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IDBDataSourceAdmin { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IDBDataSourceAdmin { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IDBDataSourceAdmin_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, cpropertysets: u32, rgpropertysets: *mut DBPROPSET, punkouter: ::windows::core::RawPtr, riid: *const ::windows::core::GUID, ppdbsession: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, cpropertyidsets: u32, rgpropertyidsets: *const DBPROPIDSET, pcpropertyinfosets: *mut u32, prgpropertyinfosets: *mut *mut DBPROPINFOSET, ppdescbuffer: *mut *mut u16) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, cpropertysets: u32, rgpropertysets: *mut DBPROPSET) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IDBInfo(pub ::windows::core::IUnknown); impl IDBInfo { #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetKeywords(&self) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetLiteralInfo(&self, cliterals: u32, rgliterals: *const u32, pcliteralinfo: *mut u32, prgliteralinfo: *mut *mut DBLITERALINFO, ppcharbuffer: *mut *mut u16) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(cliterals), ::core::mem::transmute(rgliterals), ::core::mem::transmute(pcliteralinfo), ::core::mem::transmute(prgliteralinfo), ::core::mem::transmute(ppcharbuffer)).ok() } } unsafe impl ::windows::core::Interface for IDBInfo { type Vtable = IDBInfo_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a89_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IDBInfo> for ::windows::core::IUnknown { fn from(value: IDBInfo) -> Self { value.0 } } impl ::core::convert::From<&IDBInfo> for ::windows::core::IUnknown { fn from(value: &IDBInfo) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IDBInfo { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IDBInfo { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IDBInfo_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppwszkeywords: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, cliterals: u32, rgliterals: *const u32, pcliteralinfo: *mut u32, prgliteralinfo: *mut *mut DBLITERALINFO, ppcharbuffer: *mut *mut u16) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IDBInitialize(pub ::windows::core::IUnknown); impl IDBInitialize { pub unsafe fn Initialize(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self)).ok() } pub unsafe fn Uninitialize(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self)).ok() } } unsafe impl ::windows::core::Interface for IDBInitialize { type Vtable = IDBInitialize_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a8b_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IDBInitialize> for ::windows::core::IUnknown { fn from(value: IDBInitialize) -> Self { value.0 } } impl ::core::convert::From<&IDBInitialize> for ::windows::core::IUnknown { fn from(value: &IDBInitialize) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IDBInitialize { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IDBInitialize { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IDBInitialize_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IDBPromptInitialize(pub ::windows::core::IUnknown); impl IDBPromptInitialize { #[cfg(feature = "Win32_Foundation")] pub unsafe fn PromptDataSource<'a, Param0: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::HWND>, Param5: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>( &self, punkouter: Param0, hwndparent: Param1, dwpromptoptions: u32, csourcetypefilter: u32, rgsourcetypefilter: *const u32, pwszszzproviderfilter: Param5, riid: *const ::windows::core::GUID, ppdatasource: *mut ::core::option::Option<::windows::core::IUnknown>, ) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)( ::core::mem::transmute_copy(self), punkouter.into_param().abi(), hwndparent.into_param().abi(), ::core::mem::transmute(dwpromptoptions), ::core::mem::transmute(csourcetypefilter), ::core::mem::transmute(rgsourcetypefilter), pwszszzproviderfilter.into_param().abi(), ::core::mem::transmute(riid), ::core::mem::transmute(ppdatasource), ) .ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn PromptFileName<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::HWND>, Param2: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param3: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, hwndparent: Param0, dwpromptoptions: u32, pwszinitialdirectory: Param2, pwszinitialfile: Param3) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), hwndparent.into_param().abi(), ::core::mem::transmute(dwpromptoptions), pwszinitialdirectory.into_param().abi(), pwszinitialfile.into_param().abi(), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } } unsafe impl ::windows::core::Interface for IDBPromptInitialize { type Vtable = IDBPromptInitialize_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x2206ccb0_19c1_11d1_89e0_00c04fd7a829); } impl ::core::convert::From<IDBPromptInitialize> for ::windows::core::IUnknown { fn from(value: IDBPromptInitialize) -> Self { value.0 } } impl ::core::convert::From<&IDBPromptInitialize> for ::windows::core::IUnknown { fn from(value: &IDBPromptInitialize) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IDBPromptInitialize { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IDBPromptInitialize { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IDBPromptInitialize_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, punkouter: ::windows::core::RawPtr, hwndparent: super::super::Foundation::HWND, dwpromptoptions: u32, csourcetypefilter: u32, rgsourcetypefilter: *const u32, pwszszzproviderfilter: super::super::Foundation::PWSTR, riid: *const ::windows::core::GUID, ppdatasource: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hwndparent: super::super::Foundation::HWND, dwpromptoptions: u32, pwszinitialdirectory: super::super::Foundation::PWSTR, pwszinitialfile: super::super::Foundation::PWSTR, ppwszselectedfile: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IDBProperties(pub ::windows::core::IUnknown); impl IDBProperties { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn GetProperties(&self, cpropertyidsets: u32, rgpropertyidsets: *const DBPROPIDSET, pcpropertysets: *mut u32, prgpropertysets: *mut *mut DBPROPSET) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(cpropertyidsets), ::core::mem::transmute(rgpropertyidsets), ::core::mem::transmute(pcpropertysets), ::core::mem::transmute(prgpropertysets)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn GetPropertyInfo(&self, cpropertyidsets: u32, rgpropertyidsets: *const DBPROPIDSET, pcpropertyinfosets: *mut u32, prgpropertyinfosets: *mut *mut DBPROPINFOSET, ppdescbuffer: *mut *mut u16) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(cpropertyidsets), ::core::mem::transmute(rgpropertyidsets), ::core::mem::transmute(pcpropertyinfosets), ::core::mem::transmute(prgpropertyinfosets), ::core::mem::transmute(ppdescbuffer)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn SetProperties(&self, cpropertysets: u32, rgpropertysets: *mut DBPROPSET) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(cpropertysets), ::core::mem::transmute(rgpropertysets)).ok() } } unsafe impl ::windows::core::Interface for IDBProperties { type Vtable = IDBProperties_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a8a_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IDBProperties> for ::windows::core::IUnknown { fn from(value: IDBProperties) -> Self { value.0 } } impl ::core::convert::From<&IDBProperties> for ::windows::core::IUnknown { fn from(value: &IDBProperties) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IDBProperties { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IDBProperties { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IDBProperties_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, cpropertyidsets: u32, rgpropertyidsets: *const DBPROPIDSET, pcpropertysets: *mut u32, prgpropertysets: *mut *mut DBPROPSET) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, cpropertyidsets: u32, rgpropertyidsets: *const DBPROPIDSET, pcpropertyinfosets: *mut u32, prgpropertyinfosets: *mut *mut DBPROPINFOSET, ppdescbuffer: *mut *mut u16) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, cpropertysets: u32, rgpropertysets: *mut DBPROPSET) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IDBSchemaCommand(pub ::windows::core::IUnknown); impl IDBSchemaCommand { pub unsafe fn GetCommand<'a, Param0: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>>(&self, punkouter: Param0, rguidschema: *const ::windows::core::GUID) -> ::windows::core::Result<ICommand> { let mut result__: <ICommand as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), punkouter.into_param().abi(), ::core::mem::transmute(rguidschema), &mut result__).from_abi::<ICommand>(result__) } pub unsafe fn GetSchemas(&self, pcschemas: *mut u32, prgschemas: *mut *mut ::windows::core::GUID) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(pcschemas), ::core::mem::transmute(prgschemas)).ok() } } unsafe impl ::windows::core::Interface for IDBSchemaCommand { type Vtable = IDBSchemaCommand_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a50_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IDBSchemaCommand> for ::windows::core::IUnknown { fn from(value: IDBSchemaCommand) -> Self { value.0 } } impl ::core::convert::From<&IDBSchemaCommand> for ::windows::core::IUnknown { fn from(value: &IDBSchemaCommand) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IDBSchemaCommand { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IDBSchemaCommand { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IDBSchemaCommand_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, punkouter: ::windows::core::RawPtr, rguidschema: *const ::windows::core::GUID, ppcommand: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pcschemas: *mut u32, prgschemas: *mut *mut ::windows::core::GUID) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IDBSchemaRowset(pub ::windows::core::IUnknown); impl IDBSchemaRowset { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn GetRowset<'a, Param0: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>>(&self, punkouter: Param0, rguidschema: *const ::windows::core::GUID, crestrictions: u32, rgrestrictions: *const super::Com::VARIANT, riid: *const ::windows::core::GUID, cpropertysets: u32, rgpropertysets: *mut DBPROPSET, pprowset: *mut ::core::option::Option<::windows::core::IUnknown>) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)( ::core::mem::transmute_copy(self), punkouter.into_param().abi(), ::core::mem::transmute(rguidschema), ::core::mem::transmute(crestrictions), ::core::mem::transmute(rgrestrictions), ::core::mem::transmute(riid), ::core::mem::transmute(cpropertysets), ::core::mem::transmute(rgpropertysets), ::core::mem::transmute(pprowset), ) .ok() } pub unsafe fn GetSchemas(&self, pcschemas: *mut u32, prgschemas: *mut *mut ::windows::core::GUID, prgrestrictionsupport: *mut *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(pcschemas), ::core::mem::transmute(prgschemas), ::core::mem::transmute(prgrestrictionsupport)).ok() } } unsafe impl ::windows::core::Interface for IDBSchemaRowset { type Vtable = IDBSchemaRowset_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a7b_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IDBSchemaRowset> for ::windows::core::IUnknown { fn from(value: IDBSchemaRowset) -> Self { value.0 } } impl ::core::convert::From<&IDBSchemaRowset> for ::windows::core::IUnknown { fn from(value: &IDBSchemaRowset) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IDBSchemaRowset { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IDBSchemaRowset { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IDBSchemaRowset_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, punkouter: ::windows::core::RawPtr, rguidschema: *const ::windows::core::GUID, crestrictions: u32, rgrestrictions: *const ::core::mem::ManuallyDrop<super::Com::VARIANT>, riid: *const ::windows::core::GUID, cpropertysets: u32, rgpropertysets: *mut DBPROPSET, pprowset: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pcschemas: *mut u32, prgschemas: *mut *mut ::windows::core::GUID, prgrestrictionsupport: *mut *mut u32) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IDCInfo(pub ::windows::core::IUnknown); impl IDCInfo { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn GetInfo(&self, cinfo: u32, rgeinfotype: *const u32, prginfo: *mut *mut DCINFO) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(cinfo), ::core::mem::transmute(rgeinfotype), ::core::mem::transmute(prginfo)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn SetInfo(&self, cinfo: u32, rginfo: *const DCINFO) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(cinfo), ::core::mem::transmute(rginfo)).ok() } } unsafe impl ::windows::core::Interface for IDCInfo { type Vtable = IDCInfo_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a9c_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IDCInfo> for ::windows::core::IUnknown { fn from(value: IDCInfo) -> Self { value.0 } } impl ::core::convert::From<&IDCInfo> for ::windows::core::IUnknown { fn from(value: &IDCInfo) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IDCInfo { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IDCInfo { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IDCInfo_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, cinfo: u32, rgeinfotype: *const u32, prginfo: *mut *mut DCINFO) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, cinfo: u32, rginfo: *const ::core::mem::ManuallyDrop<DCINFO>) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, ); pub const IDENTIFIER_SDK_ERROR: u32 = 268435456u32; pub const IDENTIFIER_SDK_MASK: u32 = 4026531840u32; pub const IDS_MON_BUILTIN_PROPERTY: ::windows::core::HRESULT = ::windows::core::HRESULT(264511i32 as _); pub const IDS_MON_BUILTIN_VIEW: ::windows::core::HRESULT = ::windows::core::HRESULT(264503i32 as _); pub const IDS_MON_CANNOT_CAST: ::windows::core::HRESULT = ::windows::core::HRESULT(264518i32 as _); pub const IDS_MON_CANNOT_CONVERT: ::windows::core::HRESULT = ::windows::core::HRESULT(264507i32 as _); pub const IDS_MON_COLUMN_NOT_DEFINED: ::windows::core::HRESULT = ::windows::core::HRESULT(264502i32 as _); pub const IDS_MON_DATE_OUT_OF_RANGE: ::windows::core::HRESULT = ::windows::core::HRESULT(264519i32 as _); pub const IDS_MON_DEFAULT_ERROR: ::windows::core::HRESULT = ::windows::core::HRESULT(264495i32 as _); pub const IDS_MON_ILLEGAL_PASSTHROUGH: ::windows::core::HRESULT = ::windows::core::HRESULT(264496i32 as _); pub const IDS_MON_INVALIDSELECT_COALESCE: ::windows::core::HRESULT = ::windows::core::HRESULT(264517i32 as _); pub const IDS_MON_INVALID_CATALOG: ::windows::core::HRESULT = ::windows::core::HRESULT(264516i32 as _); pub const IDS_MON_INVALID_IN_GROUP_CLAUSE: ::windows::core::HRESULT = ::windows::core::HRESULT(264520i32 as _); pub const IDS_MON_MATCH_STRING: ::windows::core::HRESULT = ::windows::core::HRESULT(264513i32 as _); pub const IDS_MON_NOT_COLUMN_OF_VIEW: ::windows::core::HRESULT = ::windows::core::HRESULT(264510i32 as _); pub const IDS_MON_ORDINAL_OUT_OF_RANGE: ::windows::core::HRESULT = ::windows::core::HRESULT(264500i32 as _); pub const IDS_MON_OR_NOT: ::windows::core::HRESULT = ::windows::core::HRESULT(264506i32 as _); pub const IDS_MON_OUT_OF_MEMORY: ::windows::core::HRESULT = ::windows::core::HRESULT(264504i32 as _); pub const IDS_MON_OUT_OF_RANGE: ::windows::core::HRESULT = ::windows::core::HRESULT(264508i32 as _); pub const IDS_MON_PARSE_ERR_1_PARAM: ::windows::core::HRESULT = ::windows::core::HRESULT(264497i32 as _); pub const IDS_MON_PARSE_ERR_2_PARAM: ::windows::core::HRESULT = ::windows::core::HRESULT(264498i32 as _); pub const IDS_MON_PROPERTY_NAME_IN_VIEW: ::windows::core::HRESULT = ::windows::core::HRESULT(264514i32 as _); pub const IDS_MON_RELATIVE_INTERVAL: ::windows::core::HRESULT = ::windows::core::HRESULT(264509i32 as _); pub const IDS_MON_SELECT_STAR: ::windows::core::HRESULT = ::windows::core::HRESULT(264505i32 as _); pub const IDS_MON_SEMI_COLON: ::windows::core::HRESULT = ::windows::core::HRESULT(264499i32 as _); pub const IDS_MON_VIEW_ALREADY_DEFINED: ::windows::core::HRESULT = ::windows::core::HRESULT(264515i32 as _); pub const IDS_MON_VIEW_NOT_DEFINED: ::windows::core::HRESULT = ::windows::core::HRESULT(264501i32 as _); pub const IDS_MON_WEIGHT_OUT_OF_RANGE: ::windows::core::HRESULT = ::windows::core::HRESULT(264512i32 as _); pub const IDX_E_BUILD_IN_PROGRESS: i32 = -2147217147i32; pub const IDX_E_CATALOG_DISMOUNTED: i32 = -2147217124i32; pub const IDX_E_CORRUPT_INDEX: i32 = -2147217136i32; pub const IDX_E_DISKFULL: i32 = -2147217138i32; pub const IDX_E_DOCUMENT_ABORTED: i32 = -2147217125i32; pub const IDX_E_DSS_NOT_CONNECTED: i32 = -2147217126i32; pub const IDX_E_IDXLSTFILE_CORRUPT: i32 = -2147217146i32; pub const IDX_E_INVALIDTAG: i32 = -2147217151i32; pub const IDX_E_INVALID_INDEX: i32 = -2147217137i32; pub const IDX_E_METAFILE_CORRUPT: i32 = -2147217150i32; pub const IDX_E_NOISELIST_NOTFOUND: i32 = -2147217141i32; pub const IDX_E_NOT_LOADED: i32 = -2147217129i32; pub const IDX_E_OBJECT_NOT_FOUND: i32 = -2147217144i32; pub const IDX_E_PROPSTORE_INIT_FAILED: i32 = -2147217134i32; pub const IDX_E_PROP_MAJOR_VERSION_MISMATCH: i32 = -2147217128i32; pub const IDX_E_PROP_MINOR_VERSION_MISMATCH: i32 = -2147217127i32; pub const IDX_E_PROP_STATE_CORRUPT: i32 = -2147217133i32; pub const IDX_E_PROP_STOPPED: i32 = -2147217139i32; pub const IDX_E_REGISTRY_ENTRY: i32 = -2147217145i32; pub const IDX_E_SEARCH_SERVER_ALREADY_EXISTS: i32 = -2147217148i32; pub const IDX_E_SEARCH_SERVER_NOT_FOUND: i32 = -2147217143i32; pub const IDX_E_STEMMER_NOTFOUND: i32 = -2147217140i32; pub const IDX_E_TOO_MANY_SEARCH_SERVERS: i32 = -2147217149i32; pub const IDX_E_USE_APPGLOBAL_PROPTABLE: i32 = -2147217120i32; pub const IDX_E_USE_DEFAULT_CONTENTCLASS: i32 = -2147217121i32; pub const IDX_E_WB_NOTFOUND: i32 = -2147217142i32; pub const IDX_S_DSS_NOT_AVAILABLE: i32 = 266525i32; pub const IDX_S_NO_BUILD_IN_PROGRESS: i32 = 266516i32; pub const IDX_S_SEARCH_SERVER_ALREADY_EXISTS: i32 = 266517i32; pub const IDX_S_SEARCH_SERVER_DOES_NOT_EXIST: i32 = 266518i32; #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IDataConvert(pub ::windows::core::IUnknown); impl IDataConvert { pub unsafe fn DataConvert(&self, wsrctype: u16, wdsttype: u16, cbsrclength: usize, pcbdstlength: *mut usize, psrc: *const ::core::ffi::c_void, pdst: *mut ::core::ffi::c_void, cbdstmaxlength: usize, dbssrcstatus: u32, pdbsstatus: *mut u32, bprecision: u8, bscale: u8, dwflags: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)( ::core::mem::transmute_copy(self), ::core::mem::transmute(wsrctype), ::core::mem::transmute(wdsttype), ::core::mem::transmute(cbsrclength), ::core::mem::transmute(pcbdstlength), ::core::mem::transmute(psrc), ::core::mem::transmute(pdst), ::core::mem::transmute(cbdstmaxlength), ::core::mem::transmute(dbssrcstatus), ::core::mem::transmute(pdbsstatus), ::core::mem::transmute(bprecision), ::core::mem::transmute(bscale), ::core::mem::transmute(dwflags), ) .ok() } pub unsafe fn CanConvert(&self, wsrctype: u16, wdsttype: u16) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(wsrctype), ::core::mem::transmute(wdsttype)).ok() } pub unsafe fn GetConversionSize(&self, wsrctype: u16, wdsttype: u16, pcbsrclength: *const usize, pcbdstlength: *mut usize, psrc: *const ::core::ffi::c_void) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(wsrctype), ::core::mem::transmute(wdsttype), ::core::mem::transmute(pcbsrclength), ::core::mem::transmute(pcbdstlength), ::core::mem::transmute(psrc)).ok() } } unsafe impl ::windows::core::Interface for IDataConvert { type Vtable = IDataConvert_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a8d_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IDataConvert> for ::windows::core::IUnknown { fn from(value: IDataConvert) -> Self { value.0 } } impl ::core::convert::From<&IDataConvert> for ::windows::core::IUnknown { fn from(value: &IDataConvert) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IDataConvert { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IDataConvert { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IDataConvert_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, wsrctype: u16, wdsttype: u16, cbsrclength: usize, pcbdstlength: *mut usize, psrc: *const ::core::ffi::c_void, pdst: *mut ::core::ffi::c_void, cbdstmaxlength: usize, dbssrcstatus: u32, pdbsstatus: *mut u32, bprecision: u8, bscale: u8, dwflags: u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, wsrctype: u16, wdsttype: u16) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, wsrctype: u16, wdsttype: u16, pcbsrclength: *const usize, pcbdstlength: *mut usize, psrc: *const ::core::ffi::c_void) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IDataInitialize(pub ::windows::core::IUnknown); impl IDataInitialize { #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetDataSource<'a, Param0: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>, Param2: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, punkouter: Param0, dwclsctx: u32, pwszinitializationstring: Param2, riid: *const ::windows::core::GUID, ppdatasource: *mut ::core::option::Option<::windows::core::IUnknown>) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), punkouter.into_param().abi(), ::core::mem::transmute(dwclsctx), pwszinitializationstring.into_param().abi(), ::core::mem::transmute(riid), ::core::mem::transmute(ppdatasource)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetInitializationString<'a, Param0: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>>(&self, pdatasource: Param0, fincludepassword: u8) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), pdatasource.into_param().abi(), ::core::mem::transmute(fincludepassword), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn CreateDBInstance<'a, Param1: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>, Param3: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, clsidprovider: *const ::windows::core::GUID, punkouter: Param1, dwclsctx: u32, pwszreserved: Param3, riid: *const ::windows::core::GUID) -> ::windows::core::Result<::windows::core::IUnknown> { let mut result__: <::windows::core::IUnknown as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(clsidprovider), punkouter.into_param().abi(), ::core::mem::transmute(dwclsctx), pwszreserved.into_param().abi(), ::core::mem::transmute(riid), &mut result__).from_abi::<::windows::core::IUnknown>(result__) } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub unsafe fn CreateDBInstanceEx<'a, Param1: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>, Param3: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, clsidprovider: *const ::windows::core::GUID, punkouter: Param1, dwclsctx: u32, pwszreserved: Param3, pserverinfo: *const super::Com::COSERVERINFO, cmq: u32, rgmqresults: *mut super::Com::MULTI_QI) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), ::core::mem::transmute(clsidprovider), punkouter.into_param().abi(), ::core::mem::transmute(dwclsctx), pwszreserved.into_param().abi(), ::core::mem::transmute(pserverinfo), ::core::mem::transmute(cmq), ::core::mem::transmute(rgmqresults)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn LoadStringFromStorage<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pwszfilename: Param0) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), pwszfilename.into_param().abi(), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn WriteStringToStorage<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pwszfilename: Param0, pwszinitializationstring: Param1, dwcreationdisposition: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).8)(::core::mem::transmute_copy(self), pwszfilename.into_param().abi(), pwszinitializationstring.into_param().abi(), ::core::mem::transmute(dwcreationdisposition)).ok() } } unsafe impl ::windows::core::Interface for IDataInitialize { type Vtable = IDataInitialize_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x2206ccb1_19c1_11d1_89e0_00c04fd7a829); } impl ::core::convert::From<IDataInitialize> for ::windows::core::IUnknown { fn from(value: IDataInitialize) -> Self { value.0 } } impl ::core::convert::From<&IDataInitialize> for ::windows::core::IUnknown { fn from(value: &IDataInitialize) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IDataInitialize { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IDataInitialize { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IDataInitialize_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, punkouter: ::windows::core::RawPtr, dwclsctx: u32, pwszinitializationstring: super::super::Foundation::PWSTR, riid: *const ::windows::core::GUID, ppdatasource: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pdatasource: ::windows::core::RawPtr, fincludepassword: u8, ppwszinitstring: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, clsidprovider: *const ::windows::core::GUID, punkouter: ::windows::core::RawPtr, dwclsctx: u32, pwszreserved: super::super::Foundation::PWSTR, riid: *const ::windows::core::GUID, ppdatasource: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, clsidprovider: *const ::windows::core::GUID, punkouter: ::windows::core::RawPtr, dwclsctx: u32, pwszreserved: super::super::Foundation::PWSTR, pserverinfo: *const super::Com::COSERVERINFO, cmq: u32, rgmqresults: *mut ::core::mem::ManuallyDrop<super::Com::MULTI_QI>) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com")))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pwszfilename: super::super::Foundation::PWSTR, ppwszinitializationstring: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pwszfilename: super::super::Foundation::PWSTR, pwszinitializationstring: super::super::Foundation::PWSTR, dwcreationdisposition: u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IDataSourceLocator(pub ::windows::core::IUnknown); impl IDataSourceLocator { pub unsafe fn hWnd(&self) -> ::windows::core::Result<i64> { let mut result__: <i64 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), &mut result__).from_abi::<i64>(result__) } pub unsafe fn SethWnd(&self, hwndparent: i64) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).8)(::core::mem::transmute_copy(self), ::core::mem::transmute(hwndparent)).ok() } #[cfg(feature = "Win32_System_Com")] pub unsafe fn PromptNew(&self) -> ::windows::core::Result<super::Com::IDispatch> { let mut result__: <super::Com::IDispatch as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).9)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::Com::IDispatch>(result__) } #[cfg(feature = "Win32_System_Com")] pub unsafe fn PromptEdit(&self, ppadoconnection: *mut ::core::option::Option<super::Com::IDispatch>, pbsuccess: *mut i16) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).10)(::core::mem::transmute_copy(self), ::core::mem::transmute(ppadoconnection), ::core::mem::transmute(pbsuccess)).ok() } } unsafe impl ::windows::core::Interface for IDataSourceLocator { type Vtable = IDataSourceLocator_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x2206ccb2_19c1_11d1_89e0_00c04fd7a829); } impl ::core::convert::From<IDataSourceLocator> for ::windows::core::IUnknown { fn from(value: IDataSourceLocator) -> Self { value.0 } } impl ::core::convert::From<&IDataSourceLocator> for ::windows::core::IUnknown { fn from(value: &IDataSourceLocator) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IDataSourceLocator { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IDataSourceLocator { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[cfg(feature = "Win32_System_Com")] impl ::core::convert::From<IDataSourceLocator> for super::Com::IDispatch { fn from(value: IDataSourceLocator) -> Self { unsafe { ::core::mem::transmute(value) } } } #[cfg(feature = "Win32_System_Com")] impl ::core::convert::From<&IDataSourceLocator> for super::Com::IDispatch { fn from(value: &IDataSourceLocator) -> Self { ::core::convert::From::from(::core::clone::Clone::clone(value)) } } #[cfg(feature = "Win32_System_Com")] impl<'a> ::windows::core::IntoParam<'a, super::Com::IDispatch> for IDataSourceLocator { fn into_param(self) -> ::windows::core::Param<'a, super::Com::IDispatch> { ::windows::core::Param::Owned(unsafe { ::core::mem::transmute(self) }) } } #[cfg(feature = "Win32_System_Com")] impl<'a> ::windows::core::IntoParam<'a, super::Com::IDispatch> for &IDataSourceLocator { fn into_param(self) -> ::windows::core::Param<'a, super::Com::IDispatch> { ::windows::core::Param::Borrowed(unsafe { ::core::mem::transmute(self) }) } } #[repr(C)] #[doc(hidden)] pub struct IDataSourceLocator_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pctinfo: *mut u32) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_System_Com")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, itinfo: u32, lcid: u32, pptinfo: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_System_Com"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, riid: *const ::windows::core::GUID, rgsznames: *const super::super::Foundation::PWSTR, cnames: u32, lcid: u32, rgdispid: *mut i32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, dispidmember: i32, riid: *const ::windows::core::GUID, lcid: u32, wflags: u16, pdispparams: *const super::Com::DISPPARAMS, pvarresult: *mut ::core::mem::ManuallyDrop<super::Com::VARIANT>, pexcepinfo: *mut ::core::mem::ManuallyDrop<super::Com::EXCEPINFO>, puargerr: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, phwndparent: *mut i64) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hwndparent: i64) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_System_Com")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppadoconnection: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_System_Com"))] usize, #[cfg(feature = "Win32_System_Com")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppadoconnection: *mut ::windows::core::RawPtr, pbsuccess: *mut i16) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_System_Com"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IEntity(pub ::windows::core::IUnknown); impl IEntity { #[cfg(feature = "Win32_Foundation")] pub unsafe fn Name(&self) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } pub unsafe fn Base(&self) -> ::windows::core::Result<IEntity> { let mut result__: <IEntity as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), &mut result__).from_abi::<IEntity>(result__) } pub unsafe fn Relationships<T: ::windows::core::Interface>(&self) -> ::windows::core::Result<T> { let mut result__ = ::core::option::Option::None; (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), &<T as ::windows::core::Interface>::IID, &mut result__ as *mut _ as *mut _).and_some(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetRelationship<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszrelationname: Param0) -> ::windows::core::Result<IRelationship> { let mut result__: <IRelationship as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), pszrelationname.into_param().abi(), &mut result__).from_abi::<IRelationship>(result__) } pub unsafe fn MetaData<T: ::windows::core::Interface>(&self) -> ::windows::core::Result<T> { let mut result__ = ::core::option::Option::None; (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), &<T as ::windows::core::Interface>::IID, &mut result__ as *mut _ as *mut _).and_some(result__) } pub unsafe fn NamedEntities<T: ::windows::core::Interface>(&self) -> ::windows::core::Result<T> { let mut result__ = ::core::option::Option::None; (::windows::core::Interface::vtable(self).8)(::core::mem::transmute_copy(self), &<T as ::windows::core::Interface>::IID, &mut result__ as *mut _ as *mut _).and_some(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetNamedEntity<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszvalue: Param0) -> ::windows::core::Result<INamedEntity> { let mut result__: <INamedEntity as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).9)(::core::mem::transmute_copy(self), pszvalue.into_param().abi(), &mut result__).from_abi::<INamedEntity>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn DefaultPhrase(&self) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).10)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } } unsafe impl ::windows::core::Interface for IEntity { type Vtable = IEntity_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x24264891_e80b_4fd3_b7ce_4ff2fae8931f); } impl ::core::convert::From<IEntity> for ::windows::core::IUnknown { fn from(value: IEntity) -> Self { value.0 } } impl ::core::convert::From<&IEntity> for ::windows::core::IUnknown { fn from(value: &IEntity) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IEntity { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IEntity { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IEntity_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppszname: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pbaseentity: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, riid: *const ::windows::core::GUID, prelationships: *mut *mut ::core::ffi::c_void) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszrelationname: super::super::Foundation::PWSTR, prelationship: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, riid: *const ::windows::core::GUID, pmetadata: *mut *mut ::core::ffi::c_void) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, riid: *const ::windows::core::GUID, pnamedentities: *mut *mut ::core::ffi::c_void) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszvalue: super::super::Foundation::PWSTR, ppnamedentity: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppszphrase: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IEnumItemProperties(pub ::windows::core::IUnknown); impl IEnumItemProperties { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn Next(&self, celt: u32, rgelt: *mut ITEMPROP, pceltfetched: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(celt), ::core::mem::transmute(rgelt), ::core::mem::transmute(pceltfetched)).ok() } pub unsafe fn Skip(&self, celt: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(celt)).ok() } pub unsafe fn Reset(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self)).ok() } pub unsafe fn Clone(&self) -> ::windows::core::Result<IEnumItemProperties> { let mut result__: <IEnumItemProperties as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), &mut result__).from_abi::<IEnumItemProperties>(result__) } pub unsafe fn GetCount(&self) -> ::windows::core::Result<u32> { let mut result__: <u32 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), &mut result__).from_abi::<u32>(result__) } } unsafe impl ::windows::core::Interface for IEnumItemProperties { type Vtable = IEnumItemProperties_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xf72c8d96_6dbd_11d1_a1e8_00c04fc2fbe1); } impl ::core::convert::From<IEnumItemProperties> for ::windows::core::IUnknown { fn from(value: IEnumItemProperties) -> Self { value.0 } } impl ::core::convert::From<&IEnumItemProperties> for ::windows::core::IUnknown { fn from(value: &IEnumItemProperties) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IEnumItemProperties { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IEnumItemProperties { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IEnumItemProperties_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, celt: u32, rgelt: *mut ::core::mem::ManuallyDrop<ITEMPROP>, pceltfetched: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, celt: u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppenum: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pncount: *mut u32) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IEnumSearchRoots(pub ::windows::core::IUnknown); impl IEnumSearchRoots { pub unsafe fn Next(&self, celt: u32, rgelt: *mut ::core::option::Option<ISearchRoot>, pceltfetched: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(celt), ::core::mem::transmute(rgelt), ::core::mem::transmute(pceltfetched)).ok() } pub unsafe fn Skip(&self, celt: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(celt)).ok() } pub unsafe fn Reset(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self)).ok() } pub unsafe fn Clone(&self) -> ::windows::core::Result<IEnumSearchRoots> { let mut result__: <IEnumSearchRoots as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), &mut result__).from_abi::<IEnumSearchRoots>(result__) } } unsafe impl ::windows::core::Interface for IEnumSearchRoots { type Vtable = IEnumSearchRoots_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xab310581_ac80_11d1_8df3_00c04fb6ef52); } impl ::core::convert::From<IEnumSearchRoots> for ::windows::core::IUnknown { fn from(value: IEnumSearchRoots) -> Self { value.0 } } impl ::core::convert::From<&IEnumSearchRoots> for ::windows::core::IUnknown { fn from(value: &IEnumSearchRoots) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IEnumSearchRoots { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IEnumSearchRoots { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IEnumSearchRoots_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, celt: u32, rgelt: *mut ::windows::core::RawPtr, pceltfetched: *mut u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, celt: u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppenum: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IEnumSearchScopeRules(pub ::windows::core::IUnknown); impl IEnumSearchScopeRules { pub unsafe fn Next(&self, celt: u32, pprgelt: *mut ::core::option::Option<ISearchScopeRule>, pceltfetched: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(celt), ::core::mem::transmute(pprgelt), ::core::mem::transmute(pceltfetched)).ok() } pub unsafe fn Skip(&self, celt: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(celt)).ok() } pub unsafe fn Reset(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self)).ok() } pub unsafe fn Clone(&self) -> ::windows::core::Result<IEnumSearchScopeRules> { let mut result__: <IEnumSearchScopeRules as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), &mut result__).from_abi::<IEnumSearchScopeRules>(result__) } } unsafe impl ::windows::core::Interface for IEnumSearchScopeRules { type Vtable = IEnumSearchScopeRules_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xab310581_ac80_11d1_8df3_00c04fb6ef54); } impl ::core::convert::From<IEnumSearchScopeRules> for ::windows::core::IUnknown { fn from(value: IEnumSearchScopeRules) -> Self { value.0 } } impl ::core::convert::From<&IEnumSearchScopeRules> for ::windows::core::IUnknown { fn from(value: &IEnumSearchScopeRules) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IEnumSearchScopeRules { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IEnumSearchScopeRules { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IEnumSearchScopeRules_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, celt: u32, pprgelt: *mut ::windows::core::RawPtr, pceltfetched: *mut u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, celt: u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppenum: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IEnumSubscription(pub ::windows::core::IUnknown); impl IEnumSubscription { pub unsafe fn Next(&self, celt: u32, rgelt: *mut ::windows::core::GUID, pceltfetched: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(celt), ::core::mem::transmute(rgelt), ::core::mem::transmute(pceltfetched)).ok() } pub unsafe fn Skip(&self, celt: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(celt)).ok() } pub unsafe fn Reset(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self)).ok() } pub unsafe fn Clone(&self) -> ::windows::core::Result<IEnumSubscription> { let mut result__: <IEnumSubscription as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), &mut result__).from_abi::<IEnumSubscription>(result__) } pub unsafe fn GetCount(&self) -> ::windows::core::Result<u32> { let mut result__: <u32 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), &mut result__).from_abi::<u32>(result__) } } unsafe impl ::windows::core::Interface for IEnumSubscription { type Vtable = IEnumSubscription_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xf72c8d97_6dbd_11d1_a1e8_00c04fc2fbe1); } impl ::core::convert::From<IEnumSubscription> for ::windows::core::IUnknown { fn from(value: IEnumSubscription) -> Self { value.0 } } impl ::core::convert::From<&IEnumSubscription> for ::windows::core::IUnknown { fn from(value: &IEnumSubscription) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IEnumSubscription { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IEnumSubscription { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IEnumSubscription_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, celt: u32, rgelt: *mut ::windows::core::GUID, pceltfetched: *mut u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, celt: u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppenum: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pncount: *mut u32) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IErrorLookup(pub ::windows::core::IUnknown); impl IErrorLookup { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn GetErrorDescription(&self, hrerror: ::windows::core::HRESULT, dwlookupid: u32, pdispparams: *const super::Com::DISPPARAMS, lcid: u32, pbstrsource: *mut super::super::Foundation::BSTR, pbstrdescription: *mut super::super::Foundation::BSTR) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(hrerror), ::core::mem::transmute(dwlookupid), ::core::mem::transmute(pdispparams), ::core::mem::transmute(lcid), ::core::mem::transmute(pbstrsource), ::core::mem::transmute(pbstrdescription)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetHelpInfo(&self, hrerror: ::windows::core::HRESULT, dwlookupid: u32, lcid: u32, pbstrhelpfile: *mut super::super::Foundation::BSTR, pdwhelpcontext: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(hrerror), ::core::mem::transmute(dwlookupid), ::core::mem::transmute(lcid), ::core::mem::transmute(pbstrhelpfile), ::core::mem::transmute(pdwhelpcontext)).ok() } pub unsafe fn ReleaseErrors(&self, dwdynamicerrorid: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(dwdynamicerrorid)).ok() } } unsafe impl ::windows::core::Interface for IErrorLookup { type Vtable = IErrorLookup_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a66_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IErrorLookup> for ::windows::core::IUnknown { fn from(value: IErrorLookup) -> Self { value.0 } } impl ::core::convert::From<&IErrorLookup> for ::windows::core::IUnknown { fn from(value: &IErrorLookup) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IErrorLookup { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IErrorLookup { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IErrorLookup_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hrerror: ::windows::core::HRESULT, dwlookupid: u32, pdispparams: *const super::Com::DISPPARAMS, lcid: u32, pbstrsource: *mut ::core::mem::ManuallyDrop<super::super::Foundation::BSTR>, pbstrdescription: *mut ::core::mem::ManuallyDrop<super::super::Foundation::BSTR>) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hrerror: ::windows::core::HRESULT, dwlookupid: u32, lcid: u32, pbstrhelpfile: *mut ::core::mem::ManuallyDrop<super::super::Foundation::BSTR>, pdwhelpcontext: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, dwdynamicerrorid: u32) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IErrorRecords(pub ::windows::core::IUnknown); impl IErrorRecords { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn AddErrorRecord<'a, Param3: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>>(&self, perrorinfo: *const ERRORINFO, dwlookupid: u32, pdispparams: *const super::Com::DISPPARAMS, punkcustomerror: Param3, dwdynamicerrorid: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(perrorinfo), ::core::mem::transmute(dwlookupid), ::core::mem::transmute(pdispparams), punkcustomerror.into_param().abi(), ::core::mem::transmute(dwdynamicerrorid)).ok() } pub unsafe fn GetBasicErrorInfo(&self, ulrecordnum: u32) -> ::windows::core::Result<ERRORINFO> { let mut result__: <ERRORINFO as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(ulrecordnum), &mut result__).from_abi::<ERRORINFO>(result__) } pub unsafe fn GetCustomErrorObject(&self, ulrecordnum: u32, riid: *const ::windows::core::GUID) -> ::windows::core::Result<::windows::core::IUnknown> { let mut result__: <::windows::core::IUnknown as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(ulrecordnum), ::core::mem::transmute(riid), &mut result__).from_abi::<::windows::core::IUnknown>(result__) } #[cfg(feature = "Win32_System_Com")] pub unsafe fn GetErrorInfo(&self, ulrecordnum: u32, lcid: u32) -> ::windows::core::Result<super::Com::IErrorInfo> { let mut result__: <super::Com::IErrorInfo as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), ::core::mem::transmute(ulrecordnum), ::core::mem::transmute(lcid), &mut result__).from_abi::<super::Com::IErrorInfo>(result__) } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn GetErrorParameters(&self, ulrecordnum: u32) -> ::windows::core::Result<super::Com::DISPPARAMS> { let mut result__: <super::Com::DISPPARAMS as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), ::core::mem::transmute(ulrecordnum), &mut result__).from_abi::<super::Com::DISPPARAMS>(result__) } pub unsafe fn GetRecordCount(&self) -> ::windows::core::Result<u32> { let mut result__: <u32 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).8)(::core::mem::transmute_copy(self), &mut result__).from_abi::<u32>(result__) } } unsafe impl ::windows::core::Interface for IErrorRecords { type Vtable = IErrorRecords_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a67_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IErrorRecords> for ::windows::core::IUnknown { fn from(value: IErrorRecords) -> Self { value.0 } } impl ::core::convert::From<&IErrorRecords> for ::windows::core::IUnknown { fn from(value: &IErrorRecords) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IErrorRecords { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IErrorRecords { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IErrorRecords_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, perrorinfo: *const ERRORINFO, dwlookupid: u32, pdispparams: *const super::Com::DISPPARAMS, punkcustomerror: ::windows::core::RawPtr, dwdynamicerrorid: u32) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ulrecordnum: u32, perrorinfo: *mut ERRORINFO) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ulrecordnum: u32, riid: *const ::windows::core::GUID, ppobject: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_System_Com")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ulrecordnum: u32, lcid: u32, pperrorinfo: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_System_Com"))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ulrecordnum: u32, pdispparams: *mut super::Com::DISPPARAMS) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pcrecords: *mut u32) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IGetDataSource(pub ::windows::core::IUnknown); impl IGetDataSource { pub unsafe fn GetDataSource(&self, riid: *const ::windows::core::GUID) -> ::windows::core::Result<::windows::core::IUnknown> { let mut result__: <::windows::core::IUnknown as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(riid), &mut result__).from_abi::<::windows::core::IUnknown>(result__) } } unsafe impl ::windows::core::Interface for IGetDataSource { type Vtable = IGetDataSource_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a75_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IGetDataSource> for ::windows::core::IUnknown { fn from(value: IGetDataSource) -> Self { value.0 } } impl ::core::convert::From<&IGetDataSource> for ::windows::core::IUnknown { fn from(value: &IGetDataSource) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IGetDataSource { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IGetDataSource { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IGetDataSource_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, riid: *const ::windows::core::GUID, ppdatasource: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IGetRow(pub ::windows::core::IUnknown); impl IGetRow { pub unsafe fn GetRowFromHROW<'a, Param0: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>>(&self, punkouter: Param0, hrow: usize, riid: *const ::windows::core::GUID) -> ::windows::core::Result<::windows::core::IUnknown> { let mut result__: <::windows::core::IUnknown as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), punkouter.into_param().abi(), ::core::mem::transmute(hrow), ::core::mem::transmute(riid), &mut result__).from_abi::<::windows::core::IUnknown>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetURLFromHROW(&self, hrow: usize) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(hrow), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } } unsafe impl ::windows::core::Interface for IGetRow { type Vtable = IGetRow_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733aaf_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IGetRow> for ::windows::core::IUnknown { fn from(value: IGetRow) -> Self { value.0 } } impl ::core::convert::From<&IGetRow> for ::windows::core::IUnknown { fn from(value: &IGetRow) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IGetRow { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IGetRow { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IGetRow_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, punkouter: ::windows::core::RawPtr, hrow: usize, riid: *const ::windows::core::GUID, ppunk: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hrow: usize, ppwszurl: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IGetSession(pub ::windows::core::IUnknown); impl IGetSession { pub unsafe fn GetSession(&self, riid: *const ::windows::core::GUID) -> ::windows::core::Result<::windows::core::IUnknown> { let mut result__: <::windows::core::IUnknown as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(riid), &mut result__).from_abi::<::windows::core::IUnknown>(result__) } } unsafe impl ::windows::core::Interface for IGetSession { type Vtable = IGetSession_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733aba_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IGetSession> for ::windows::core::IUnknown { fn from(value: IGetSession) -> Self { value.0 } } impl ::core::convert::From<&IGetSession> for ::windows::core::IUnknown { fn from(value: &IGetSession) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IGetSession { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IGetSession { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IGetSession_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, riid: *const ::windows::core::GUID, ppsession: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IGetSourceRow(pub ::windows::core::IUnknown); impl IGetSourceRow { pub unsafe fn GetSourceRow(&self, riid: *const ::windows::core::GUID) -> ::windows::core::Result<::windows::core::IUnknown> { let mut result__: <::windows::core::IUnknown as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(riid), &mut result__).from_abi::<::windows::core::IUnknown>(result__) } } unsafe impl ::windows::core::Interface for IGetSourceRow { type Vtable = IGetSourceRow_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733abb_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IGetSourceRow> for ::windows::core::IUnknown { fn from(value: IGetSourceRow) -> Self { value.0 } } impl ::core::convert::From<&IGetSourceRow> for ::windows::core::IUnknown { fn from(value: &IGetSourceRow) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IGetSourceRow { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IGetSourceRow { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IGetSourceRow_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, riid: *const ::windows::core::GUID, pprow: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IIndexDefinition(pub ::windows::core::IUnknown); impl IIndexDefinition { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn CreateIndex(&self, ptableid: *const super::super::Storage::IndexServer::DBID, pindexid: *const super::super::Storage::IndexServer::DBID, cindexcolumndescs: usize, rgindexcolumndescs: *const DBINDEXCOLUMNDESC, cpropertysets: u32, rgpropertysets: *mut DBPROPSET, ppindexid: *mut *mut super::super::Storage::IndexServer::DBID) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)( ::core::mem::transmute_copy(self), ::core::mem::transmute(ptableid), ::core::mem::transmute(pindexid), ::core::mem::transmute(cindexcolumndescs), ::core::mem::transmute(rgindexcolumndescs), ::core::mem::transmute(cpropertysets), ::core::mem::transmute(rgpropertysets), ::core::mem::transmute(ppindexid), ) .ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe fn DropIndex(&self, ptableid: *const super::super::Storage::IndexServer::DBID, pindexid: *const super::super::Storage::IndexServer::DBID) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(ptableid), ::core::mem::transmute(pindexid)).ok() } } unsafe impl ::windows::core::Interface for IIndexDefinition { type Vtable = IIndexDefinition_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a68_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IIndexDefinition> for ::windows::core::IUnknown { fn from(value: IIndexDefinition) -> Self { value.0 } } impl ::core::convert::From<&IIndexDefinition> for ::windows::core::IUnknown { fn from(value: &IIndexDefinition) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IIndexDefinition { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IIndexDefinition { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IIndexDefinition_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ptableid: *const super::super::Storage::IndexServer::DBID, pindexid: *const super::super::Storage::IndexServer::DBID, cindexcolumndescs: usize, rgindexcolumndescs: *const DBINDEXCOLUMNDESC, cpropertysets: u32, rgpropertysets: *mut DBPROPSET, ppindexid: *mut *mut super::super::Storage::IndexServer::DBID) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ptableid: *const super::super::Storage::IndexServer::DBID, pindexid: *const super::super::Storage::IndexServer::DBID) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IInterval(pub ::windows::core::IUnknown); impl IInterval { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe fn GetLimits(&self, pilklower: *mut INTERVAL_LIMIT_KIND, ppropvarlower: *mut super::Com::StructuredStorage::PROPVARIANT, pilkupper: *mut INTERVAL_LIMIT_KIND, ppropvarupper: *mut super::Com::StructuredStorage::PROPVARIANT) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(pilklower), ::core::mem::transmute(ppropvarlower), ::core::mem::transmute(pilkupper), ::core::mem::transmute(ppropvarupper)).ok() } } unsafe impl ::windows::core::Interface for IInterval { type Vtable = IInterval_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x6bf0a714_3c18_430b_8b5d_83b1c234d3db); } impl ::core::convert::From<IInterval> for ::windows::core::IUnknown { fn from(value: IInterval) -> Self { value.0 } } impl ::core::convert::From<&IInterval> for ::windows::core::IUnknown { fn from(value: &IInterval) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IInterval { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IInterval { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IInterval_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pilklower: *mut INTERVAL_LIMIT_KIND, ppropvarlower: *mut ::core::mem::ManuallyDrop<super::Com::StructuredStorage::PROPVARIANT>, pilkupper: *mut INTERVAL_LIMIT_KIND, ppropvarupper: *mut ::core::mem::ManuallyDrop<super::Com::StructuredStorage::PROPVARIANT>) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ILoadFilter(pub ::windows::core::IUnknown); impl ILoadFilter { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe fn LoadIFilter<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param2: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>, Param3: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>( &self, pwcspath: Param0, pfilteredsources: *const FILTERED_DATA_SOURCES, punkouter: Param2, fusedefault: Param3, pfilterclsid: *mut ::windows::core::GUID, searchdecsize: *mut i32, pwcssearchdesc: *mut *mut u16, ppifilt: *mut ::core::option::Option<super::super::Storage::IndexServer::IFilter>, ) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)( ::core::mem::transmute_copy(self), pwcspath.into_param().abi(), ::core::mem::transmute(pfilteredsources), punkouter.into_param().abi(), fusedefault.into_param().abi(), ::core::mem::transmute(pfilterclsid), ::core::mem::transmute(searchdecsize), ::core::mem::transmute(pwcssearchdesc), ::core::mem::transmute(ppifilt), ) .ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe fn LoadIFilterFromStorage<'a, Param0: ::windows::core::IntoParam<'a, super::Com::StructuredStorage::IStorage>, Param1: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>, Param2: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param3: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>( &self, pstg: Param0, punkouter: Param1, pwcsoverride: Param2, fusedefault: Param3, pfilterclsid: *mut ::windows::core::GUID, searchdecsize: *mut i32, pwcssearchdesc: *mut *mut u16, ppifilt: *mut ::core::option::Option<super::super::Storage::IndexServer::IFilter>, ) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)( ::core::mem::transmute_copy(self), pstg.into_param().abi(), punkouter.into_param().abi(), pwcsoverride.into_param().abi(), fusedefault.into_param().abi(), ::core::mem::transmute(pfilterclsid), ::core::mem::transmute(searchdecsize), ::core::mem::transmute(pwcssearchdesc), ::core::mem::transmute(ppifilt), ) .ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com"))] pub unsafe fn LoadIFilterFromStream<'a, Param0: ::windows::core::IntoParam<'a, super::Com::IStream>, Param2: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>, Param3: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>( &self, pstm: Param0, pfilteredsources: *const FILTERED_DATA_SOURCES, punkouter: Param2, fusedefault: Param3, pfilterclsid: *mut ::windows::core::GUID, searchdecsize: *mut i32, pwcssearchdesc: *mut *mut u16, ppifilt: *mut ::core::option::Option<super::super::Storage::IndexServer::IFilter>, ) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)( ::core::mem::transmute_copy(self), pstm.into_param().abi(), ::core::mem::transmute(pfilteredsources), punkouter.into_param().abi(), fusedefault.into_param().abi(), ::core::mem::transmute(pfilterclsid), ::core::mem::transmute(searchdecsize), ::core::mem::transmute(pwcssearchdesc), ::core::mem::transmute(ppifilt), ) .ok() } } unsafe impl ::windows::core::Interface for ILoadFilter { type Vtable = ILoadFilter_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xc7310722_ac80_11d1_8df3_00c04fb6ef4f); } impl ::core::convert::From<ILoadFilter> for ::windows::core::IUnknown { fn from(value: ILoadFilter) -> Self { value.0 } } impl ::core::convert::From<&ILoadFilter> for ::windows::core::IUnknown { fn from(value: &ILoadFilter) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ILoadFilter { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ILoadFilter { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ILoadFilter_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pwcspath: super::super::Foundation::PWSTR, pfilteredsources: *const FILTERED_DATA_SOURCES, punkouter: ::windows::core::RawPtr, fusedefault: super::super::Foundation::BOOL, pfilterclsid: *mut ::windows::core::GUID, searchdecsize: *mut i32, pwcssearchdesc: *mut *mut u16, ppifilt: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pstg: ::windows::core::RawPtr, punkouter: ::windows::core::RawPtr, pwcsoverride: super::super::Foundation::PWSTR, fusedefault: super::super::Foundation::BOOL, pfilterclsid: *mut ::windows::core::GUID, searchdecsize: *mut i32, pwcssearchdesc: *mut *mut u16, ppifilt: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pstm: ::windows::core::RawPtr, pfilteredsources: *const FILTERED_DATA_SOURCES, punkouter: ::windows::core::RawPtr, fusedefault: super::super::Foundation::BOOL, pfilterclsid: *mut ::windows::core::GUID, searchdecsize: *mut i32, pwcssearchdesc: *mut *mut u16, ppifilt: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ILoadFilterWithPrivateComActivation(pub ::windows::core::IUnknown); impl ILoadFilterWithPrivateComActivation { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe fn LoadIFilter<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param2: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>, Param3: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>( &self, pwcspath: Param0, pfilteredsources: *const FILTERED_DATA_SOURCES, punkouter: Param2, fusedefault: Param3, pfilterclsid: *mut ::windows::core::GUID, searchdecsize: *mut i32, pwcssearchdesc: *mut *mut u16, ppifilt: *mut ::core::option::Option<super::super::Storage::IndexServer::IFilter>, ) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)( ::core::mem::transmute_copy(self), pwcspath.into_param().abi(), ::core::mem::transmute(pfilteredsources), punkouter.into_param().abi(), fusedefault.into_param().abi(), ::core::mem::transmute(pfilterclsid), ::core::mem::transmute(searchdecsize), ::core::mem::transmute(pwcssearchdesc), ::core::mem::transmute(ppifilt), ) .ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe fn LoadIFilterFromStorage<'a, Param0: ::windows::core::IntoParam<'a, super::Com::StructuredStorage::IStorage>, Param1: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>, Param2: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param3: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>( &self, pstg: Param0, punkouter: Param1, pwcsoverride: Param2, fusedefault: Param3, pfilterclsid: *mut ::windows::core::GUID, searchdecsize: *mut i32, pwcssearchdesc: *mut *mut u16, ppifilt: *mut ::core::option::Option<super::super::Storage::IndexServer::IFilter>, ) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)( ::core::mem::transmute_copy(self), pstg.into_param().abi(), punkouter.into_param().abi(), pwcsoverride.into_param().abi(), fusedefault.into_param().abi(), ::core::mem::transmute(pfilterclsid), ::core::mem::transmute(searchdecsize), ::core::mem::transmute(pwcssearchdesc), ::core::mem::transmute(ppifilt), ) .ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com"))] pub unsafe fn LoadIFilterFromStream<'a, Param0: ::windows::core::IntoParam<'a, super::Com::IStream>, Param2: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>, Param3: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>( &self, pstm: Param0, pfilteredsources: *const FILTERED_DATA_SOURCES, punkouter: Param2, fusedefault: Param3, pfilterclsid: *mut ::windows::core::GUID, searchdecsize: *mut i32, pwcssearchdesc: *mut *mut u16, ppifilt: *mut ::core::option::Option<super::super::Storage::IndexServer::IFilter>, ) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)( ::core::mem::transmute_copy(self), pstm.into_param().abi(), ::core::mem::transmute(pfilteredsources), punkouter.into_param().abi(), fusedefault.into_param().abi(), ::core::mem::transmute(pfilterclsid), ::core::mem::transmute(searchdecsize), ::core::mem::transmute(pwcssearchdesc), ::core::mem::transmute(ppifilt), ) .ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe fn LoadIFilterWithPrivateComActivation<'a, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>(&self, filteredsources: *const FILTERED_DATA_SOURCES, usedefault: Param1, filterclsid: *mut ::windows::core::GUID, isfilterprivatecomactivated: *mut super::super::Foundation::BOOL, filterobj: *mut ::core::option::Option<super::super::Storage::IndexServer::IFilter>) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), ::core::mem::transmute(filteredsources), usedefault.into_param().abi(), ::core::mem::transmute(filterclsid), ::core::mem::transmute(isfilterprivatecomactivated), ::core::mem::transmute(filterobj)).ok() } } unsafe impl ::windows::core::Interface for ILoadFilterWithPrivateComActivation { type Vtable = ILoadFilterWithPrivateComActivation_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x40bdbd34_780b_48d3_9bb6_12ebd4ad2e75); } impl ::core::convert::From<ILoadFilterWithPrivateComActivation> for ::windows::core::IUnknown { fn from(value: ILoadFilterWithPrivateComActivation) -> Self { value.0 } } impl ::core::convert::From<&ILoadFilterWithPrivateComActivation> for ::windows::core::IUnknown { fn from(value: &ILoadFilterWithPrivateComActivation) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ILoadFilterWithPrivateComActivation { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ILoadFilterWithPrivateComActivation { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } impl ::core::convert::From<ILoadFilterWithPrivateComActivation> for ILoadFilter { fn from(value: ILoadFilterWithPrivateComActivation) -> Self { unsafe { ::core::mem::transmute(value) } } } impl ::core::convert::From<&ILoadFilterWithPrivateComActivation> for ILoadFilter { fn from(value: &ILoadFilterWithPrivateComActivation) -> Self { ::core::convert::From::from(::core::clone::Clone::clone(value)) } } impl<'a> ::windows::core::IntoParam<'a, ILoadFilter> for ILoadFilterWithPrivateComActivation { fn into_param(self) -> ::windows::core::Param<'a, ILoadFilter> { ::windows::core::Param::Owned(unsafe { ::core::mem::transmute(self) }) } } impl<'a> ::windows::core::IntoParam<'a, ILoadFilter> for &ILoadFilterWithPrivateComActivation { fn into_param(self) -> ::windows::core::Param<'a, ILoadFilter> { ::windows::core::Param::Borrowed(unsafe { ::core::mem::transmute(self) }) } } #[repr(C)] #[doc(hidden)] pub struct ILoadFilterWithPrivateComActivation_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pwcspath: super::super::Foundation::PWSTR, pfilteredsources: *const FILTERED_DATA_SOURCES, punkouter: ::windows::core::RawPtr, fusedefault: super::super::Foundation::BOOL, pfilterclsid: *mut ::windows::core::GUID, searchdecsize: *mut i32, pwcssearchdesc: *mut *mut u16, ppifilt: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pstg: ::windows::core::RawPtr, punkouter: ::windows::core::RawPtr, pwcsoverride: super::super::Foundation::PWSTR, fusedefault: super::super::Foundation::BOOL, pfilterclsid: *mut ::windows::core::GUID, searchdecsize: *mut i32, pwcssearchdesc: *mut *mut u16, ppifilt: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pstm: ::windows::core::RawPtr, pfilteredsources: *const FILTERED_DATA_SOURCES, punkouter: ::windows::core::RawPtr, fusedefault: super::super::Foundation::BOOL, pfilterclsid: *mut ::windows::core::GUID, searchdecsize: *mut i32, pwcssearchdesc: *mut *mut u16, ppifilt: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, filteredsources: *const FILTERED_DATA_SOURCES, usedefault: super::super::Foundation::BOOL, filterclsid: *mut ::windows::core::GUID, isfilterprivatecomactivated: *mut super::super::Foundation::BOOL, filterobj: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IMDDataset(pub ::windows::core::IUnknown); impl IMDDataset { #[cfg(feature = "Win32_Foundation")] pub unsafe fn FreeAxisInfo(&self, caxes: usize, rgaxisinfo: *mut MDAXISINFO) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(caxes), ::core::mem::transmute(rgaxisinfo)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetAxisInfo(&self, pcaxes: *mut usize, prgaxisinfo: *mut *mut MDAXISINFO) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(pcaxes), ::core::mem::transmute(prgaxisinfo)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn GetAxisRowset<'a, Param0: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>>(&self, punkouter: Param0, iaxis: usize, riid: *const ::windows::core::GUID, cpropertysets: u32, rgpropertysets: *mut DBPROPSET, pprowset: *mut ::core::option::Option<::windows::core::IUnknown>) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), punkouter.into_param().abi(), ::core::mem::transmute(iaxis), ::core::mem::transmute(riid), ::core::mem::transmute(cpropertysets), ::core::mem::transmute(rgpropertysets), ::core::mem::transmute(pprowset)).ok() } pub unsafe fn GetCellData(&self, haccessor: usize, ulstartcell: usize, ulendcell: usize, pdata: *mut ::core::ffi::c_void) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), ::core::mem::transmute(haccessor), ::core::mem::transmute(ulstartcell), ::core::mem::transmute(ulendcell), ::core::mem::transmute(pdata)).ok() } pub unsafe fn GetSpecification(&self, riid: *const ::windows::core::GUID) -> ::windows::core::Result<::windows::core::IUnknown> { let mut result__: <::windows::core::IUnknown as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), ::core::mem::transmute(riid), &mut result__).from_abi::<::windows::core::IUnknown>(result__) } } unsafe impl ::windows::core::Interface for IMDDataset { type Vtable = IMDDataset_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xa07cccd1_8148_11d0_87bb_00c04fc33942); } impl ::core::convert::From<IMDDataset> for ::windows::core::IUnknown { fn from(value: IMDDataset) -> Self { value.0 } } impl ::core::convert::From<&IMDDataset> for ::windows::core::IUnknown { fn from(value: &IMDDataset) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IMDDataset { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IMDDataset { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IMDDataset_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, caxes: usize, rgaxisinfo: *mut MDAXISINFO) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pcaxes: *mut usize, prgaxisinfo: *mut *mut MDAXISINFO) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, punkouter: ::windows::core::RawPtr, iaxis: usize, riid: *const ::windows::core::GUID, cpropertysets: u32, rgpropertysets: *mut DBPROPSET, pprowset: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, haccessor: usize, ulstartcell: usize, ulendcell: usize, pdata: *mut ::core::ffi::c_void) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, riid: *const ::windows::core::GUID, ppspecification: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IMDFind(pub ::windows::core::IUnknown); impl IMDFind { #[cfg(feature = "Win32_Foundation")] pub unsafe fn FindCell(&self, ulstartingordinal: usize, cmembers: usize, rgpwszmember: *mut super::super::Foundation::PWSTR, pulcellordinal: *mut usize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(ulstartingordinal), ::core::mem::transmute(cmembers), ::core::mem::transmute(rgpwszmember), ::core::mem::transmute(pulcellordinal)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn FindTuple(&self, ulaxisidentifier: u32, ulstartingordinal: usize, cmembers: usize, rgpwszmember: *mut super::super::Foundation::PWSTR, pultupleordinal: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(ulaxisidentifier), ::core::mem::transmute(ulstartingordinal), ::core::mem::transmute(cmembers), ::core::mem::transmute(rgpwszmember), ::core::mem::transmute(pultupleordinal)).ok() } } unsafe impl ::windows::core::Interface for IMDFind { type Vtable = IMDFind_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xa07cccd2_8148_11d0_87bb_00c04fc33942); } impl ::core::convert::From<IMDFind> for ::windows::core::IUnknown { fn from(value: IMDFind) -> Self { value.0 } } impl ::core::convert::From<&IMDFind> for ::windows::core::IUnknown { fn from(value: &IMDFind) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IMDFind { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IMDFind { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IMDFind_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ulstartingordinal: usize, cmembers: usize, rgpwszmember: *mut super::super::Foundation::PWSTR, pulcellordinal: *mut usize) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ulaxisidentifier: u32, ulstartingordinal: usize, cmembers: usize, rgpwszmember: *mut super::super::Foundation::PWSTR, pultupleordinal: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IMDRangeRowset(pub ::windows::core::IUnknown); impl IMDRangeRowset { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn GetRangeRowset<'a, Param0: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>>(&self, punkouter: Param0, ulstartcell: usize, ulendcell: usize, riid: *const ::windows::core::GUID, cpropertysets: u32, rgpropertysets: *mut DBPROPSET, pprowset: *mut ::core::option::Option<::windows::core::IUnknown>) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), punkouter.into_param().abi(), ::core::mem::transmute(ulstartcell), ::core::mem::transmute(ulendcell), ::core::mem::transmute(riid), ::core::mem::transmute(cpropertysets), ::core::mem::transmute(rgpropertysets), ::core::mem::transmute(pprowset)).ok() } } unsafe impl ::windows::core::Interface for IMDRangeRowset { type Vtable = IMDRangeRowset_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733aa0_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IMDRangeRowset> for ::windows::core::IUnknown { fn from(value: IMDRangeRowset) -> Self { value.0 } } impl ::core::convert::From<&IMDRangeRowset> for ::windows::core::IUnknown { fn from(value: &IMDRangeRowset) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IMDRangeRowset { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IMDRangeRowset { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IMDRangeRowset_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, punkouter: ::windows::core::RawPtr, ulstartcell: usize, ulendcell: usize, riid: *const ::windows::core::GUID, cpropertysets: u32, rgpropertysets: *mut DBPROPSET, pprowset: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IMetaData(pub ::windows::core::IUnknown); impl IMetaData { #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetData(&self, ppszkey: *mut super::super::Foundation::PWSTR, ppszvalue: *mut super::super::Foundation::PWSTR) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(ppszkey), ::core::mem::transmute(ppszvalue)).ok() } } unsafe impl ::windows::core::Interface for IMetaData { type Vtable = IMetaData_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x780102b0_c43b_4876_bc7b_5e9ba5c88794); } impl ::core::convert::From<IMetaData> for ::windows::core::IUnknown { fn from(value: IMetaData) -> Self { value.0 } } impl ::core::convert::From<&IMetaData> for ::windows::core::IUnknown { fn from(value: &IMetaData) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IMetaData { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IMetaData { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IMetaData_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppszkey: *mut super::super::Foundation::PWSTR, ppszvalue: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IMultipleResults(pub ::windows::core::IUnknown); impl IMultipleResults { pub unsafe fn GetResult<'a, Param0: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>>(&self, punkouter: Param0, lresultflag: isize, riid: *const ::windows::core::GUID, pcrowsaffected: *mut isize, pprowset: *mut ::core::option::Option<::windows::core::IUnknown>) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), punkouter.into_param().abi(), ::core::mem::transmute(lresultflag), ::core::mem::transmute(riid), ::core::mem::transmute(pcrowsaffected), ::core::mem::transmute(pprowset)).ok() } } unsafe impl ::windows::core::Interface for IMultipleResults { type Vtable = IMultipleResults_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a90_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IMultipleResults> for ::windows::core::IUnknown { fn from(value: IMultipleResults) -> Self { value.0 } } impl ::core::convert::From<&IMultipleResults> for ::windows::core::IUnknown { fn from(value: &IMultipleResults) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IMultipleResults { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IMultipleResults { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IMultipleResults_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, punkouter: ::windows::core::RawPtr, lresultflag: isize, riid: *const ::windows::core::GUID, pcrowsaffected: *mut isize, pprowset: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, ); #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(feature = "Win32_Foundation")] pub struct INCREMENTAL_ACCESS_INFO { pub dwSize: u32, pub ftLastModifiedTime: super::super::Foundation::FILETIME, } #[cfg(feature = "Win32_Foundation")] impl INCREMENTAL_ACCESS_INFO {} #[cfg(feature = "Win32_Foundation")] impl ::core::default::Default for INCREMENTAL_ACCESS_INFO { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(feature = "Win32_Foundation")] impl ::core::fmt::Debug for INCREMENTAL_ACCESS_INFO { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("INCREMENTAL_ACCESS_INFO").field("dwSize", &self.dwSize).field("ftLastModifiedTime", &self.ftLastModifiedTime).finish() } } #[cfg(feature = "Win32_Foundation")] impl ::core::cmp::PartialEq for INCREMENTAL_ACCESS_INFO { fn eq(&self, other: &Self) -> bool { self.dwSize == other.dwSize && self.ftLastModifiedTime == other.ftLastModifiedTime } } #[cfg(feature = "Win32_Foundation")] impl ::core::cmp::Eq for INCREMENTAL_ACCESS_INFO {} #[cfg(feature = "Win32_Foundation")] unsafe impl ::windows::core::Abi for INCREMENTAL_ACCESS_INFO { type Abi = Self; } pub const INET_E_AGENT_CACHE_SIZE_EXCEEDED: ::windows::core::HRESULT = ::windows::core::HRESULT(-2146693246i32 as _); pub const INET_E_AGENT_CONNECTION_FAILED: ::windows::core::HRESULT = ::windows::core::HRESULT(-2146693245i32 as _); pub const INET_E_AGENT_EXCEEDING_CACHE_SIZE: ::windows::core::HRESULT = ::windows::core::HRESULT(-2146693232i32 as _); pub const INET_E_AGENT_MAX_SIZE_EXCEEDED: ::windows::core::HRESULT = ::windows::core::HRESULT(-2146693248i32 as _); pub const INET_E_SCHEDULED_EXCLUDE_RANGE: ::windows::core::HRESULT = ::windows::core::HRESULT(-2146693241i32 as _); pub const INET_E_SCHEDULED_UPDATES_DISABLED: ::windows::core::HRESULT = ::windows::core::HRESULT(-2146693244i32 as _); pub const INET_E_SCHEDULED_UPDATES_RESTRICTED: ::windows::core::HRESULT = ::windows::core::HRESULT(-2146693243i32 as _); pub const INET_E_SCHEDULED_UPDATE_INTERVAL: ::windows::core::HRESULT = ::windows::core::HRESULT(-2146693242i32 as _); pub const INET_S_AGENT_INCREASED_CACHE_SIZE: ::windows::core::HRESULT = ::windows::core::HRESULT(790416i32 as _); pub const INET_S_AGENT_PART_FAIL: ::windows::core::HRESULT = ::windows::core::HRESULT(790401i32 as _); #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct INTERVAL_LIMIT_KIND(pub i32); pub const ILK_EXPLICIT_INCLUDED: INTERVAL_LIMIT_KIND = INTERVAL_LIMIT_KIND(0i32); pub const ILK_EXPLICIT_EXCLUDED: INTERVAL_LIMIT_KIND = INTERVAL_LIMIT_KIND(1i32); pub const ILK_NEGATIVE_INFINITY: INTERVAL_LIMIT_KIND = INTERVAL_LIMIT_KIND(2i32); pub const ILK_POSITIVE_INFINITY: INTERVAL_LIMIT_KIND = INTERVAL_LIMIT_KIND(3i32); impl ::core::convert::From<i32> for INTERVAL_LIMIT_KIND { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for INTERVAL_LIMIT_KIND { type Abi = Self; } #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct INamedEntity(pub ::windows::core::IUnknown); impl INamedEntity { #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetValue(&self) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn DefaultPhrase(&self) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } } unsafe impl ::windows::core::Interface for INamedEntity { type Vtable = INamedEntity_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xabdbd0b1_7d54_49fb_ab5c_bff4130004cd); } impl ::core::convert::From<INamedEntity> for ::windows::core::IUnknown { fn from(value: INamedEntity) -> Self { value.0 } } impl ::core::convert::From<&INamedEntity> for ::windows::core::IUnknown { fn from(value: &INamedEntity) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for INamedEntity { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a INamedEntity { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct INamedEntity_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppszvalue: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppszphrase: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct INamedEntityCollector(pub ::windows::core::IUnknown); impl INamedEntityCollector { #[cfg(feature = "Win32_Foundation")] pub unsafe fn Add<'a, Param4: ::windows::core::IntoParam<'a, IEntity>, Param5: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, beginspan: u32, endspan: u32, beginactual: u32, endactual: u32, ptype: Param4, pszvalue: Param5, certainty: NAMED_ENTITY_CERTAINTY) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(beginspan), ::core::mem::transmute(endspan), ::core::mem::transmute(beginactual), ::core::mem::transmute(endactual), ptype.into_param().abi(), pszvalue.into_param().abi(), ::core::mem::transmute(certainty)).ok() } } unsafe impl ::windows::core::Interface for INamedEntityCollector { type Vtable = INamedEntityCollector_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xaf2440f6_8afc_47d0_9a7f_396a0acfb43d); } impl ::core::convert::From<INamedEntityCollector> for ::windows::core::IUnknown { fn from(value: INamedEntityCollector) -> Self { value.0 } } impl ::core::convert::From<&INamedEntityCollector> for ::windows::core::IUnknown { fn from(value: &INamedEntityCollector) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for INamedEntityCollector { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a INamedEntityCollector { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct INamedEntityCollector_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, beginspan: u32, endspan: u32, beginactual: u32, endactual: u32, ptype: ::windows::core::RawPtr, pszvalue: super::super::Foundation::PWSTR, certainty: NAMED_ENTITY_CERTAINTY) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IObjectAccessControl(pub ::windows::core::IUnknown); impl IObjectAccessControl { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Security", feature = "Win32_Security_Authorization", feature = "Win32_Storage_IndexServer"))] pub unsafe fn GetObjectAccessRights(&self, pobject: *mut SEC_OBJECT, pcaccessentries: *mut u32, prgaccessentries: *mut *mut super::super::Security::Authorization::EXPLICIT_ACCESS_W) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(pobject), ::core::mem::transmute(pcaccessentries), ::core::mem::transmute(prgaccessentries)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization", feature = "Win32_Storage_IndexServer"))] pub unsafe fn GetObjectOwner(&self, pobject: *mut SEC_OBJECT, ppowner: *mut *mut super::super::Security::Authorization::TRUSTEE_W) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(pobject), ::core::mem::transmute(ppowner)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Security", feature = "Win32_Security_Authorization", feature = "Win32_Storage_IndexServer"))] pub unsafe fn IsObjectAccessAllowed(&self, pobject: *mut SEC_OBJECT, paccessentry: *mut super::super::Security::Authorization::EXPLICIT_ACCESS_W, pfresult: *mut super::super::Foundation::BOOL) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(pobject), ::core::mem::transmute(paccessentry), ::core::mem::transmute(pfresult)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Security", feature = "Win32_Security_Authorization", feature = "Win32_Storage_IndexServer"))] pub unsafe fn SetObjectAccessRights(&self, pobject: *mut SEC_OBJECT, caccessentries: u32, prgaccessentries: *mut super::super::Security::Authorization::EXPLICIT_ACCESS_W) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), ::core::mem::transmute(pobject), ::core::mem::transmute(caccessentries), ::core::mem::transmute(prgaccessentries)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization", feature = "Win32_Storage_IndexServer"))] pub unsafe fn SetObjectOwner(&self, pobject: *mut SEC_OBJECT, powner: *mut super::super::Security::Authorization::TRUSTEE_W) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), ::core::mem::transmute(pobject), ::core::mem::transmute(powner)).ok() } } unsafe impl ::windows::core::Interface for IObjectAccessControl { type Vtable = IObjectAccessControl_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733aa3_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IObjectAccessControl> for ::windows::core::IUnknown { fn from(value: IObjectAccessControl) -> Self { value.0 } } impl ::core::convert::From<&IObjectAccessControl> for ::windows::core::IUnknown { fn from(value: &IObjectAccessControl) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IObjectAccessControl { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IObjectAccessControl { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IObjectAccessControl_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Security", feature = "Win32_Security_Authorization", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pobject: *mut SEC_OBJECT, pcaccessentries: *mut u32, prgaccessentries: *mut *mut super::super::Security::Authorization::EXPLICIT_ACCESS_W) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Security", feature = "Win32_Security_Authorization", feature = "Win32_Storage_IndexServer")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pobject: *mut SEC_OBJECT, ppowner: *mut *mut super::super::Security::Authorization::TRUSTEE_W) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization", feature = "Win32_Storage_IndexServer")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Security", feature = "Win32_Security_Authorization", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pobject: *mut SEC_OBJECT, paccessentry: *mut super::super::Security::Authorization::EXPLICIT_ACCESS_W, pfresult: *mut super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Security", feature = "Win32_Security_Authorization", feature = "Win32_Storage_IndexServer")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Security", feature = "Win32_Security_Authorization", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pobject: *mut SEC_OBJECT, caccessentries: u32, prgaccessentries: *mut super::super::Security::Authorization::EXPLICIT_ACCESS_W) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Security", feature = "Win32_Security_Authorization", feature = "Win32_Storage_IndexServer")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pobject: *mut SEC_OBJECT, powner: *mut super::super::Security::Authorization::TRUSTEE_W) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization", feature = "Win32_Storage_IndexServer")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IOpLockStatus(pub ::windows::core::IUnknown); impl IOpLockStatus { #[cfg(feature = "Win32_Foundation")] pub unsafe fn IsOplockValid(&self) -> ::windows::core::Result<super::super::Foundation::BOOL> { let mut result__: <super::super::Foundation::BOOL as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::BOOL>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn IsOplockBroken(&self) -> ::windows::core::Result<super::super::Foundation::BOOL> { let mut result__: <super::super::Foundation::BOOL as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::BOOL>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetOplockEventHandle(&self) -> ::windows::core::Result<super::super::Foundation::HANDLE> { let mut result__: <super::super::Foundation::HANDLE as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::HANDLE>(result__) } } unsafe impl ::windows::core::Interface for IOpLockStatus { type Vtable = IOpLockStatus_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xc731065d_ac80_11d1_8df3_00c04fb6ef4f); } impl ::core::convert::From<IOpLockStatus> for ::windows::core::IUnknown { fn from(value: IOpLockStatus) -> Self { value.0 } } impl ::core::convert::From<&IOpLockStatus> for ::windows::core::IUnknown { fn from(value: &IOpLockStatus) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IOpLockStatus { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IOpLockStatus { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IOpLockStatus_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pfisoplockvalid: *mut super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pfisoplockbroken: *mut super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, phoplockev: *mut super::super::Foundation::HANDLE) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IOpenRowset(pub ::windows::core::IUnknown); impl IOpenRowset { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn OpenRowset<'a, Param0: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>>(&self, punkouter: Param0, ptableid: *const super::super::Storage::IndexServer::DBID, pindexid: *const super::super::Storage::IndexServer::DBID, riid: *const ::windows::core::GUID, cpropertysets: u32, rgpropertysets: *mut DBPROPSET, pprowset: *mut ::core::option::Option<::windows::core::IUnknown>) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), punkouter.into_param().abi(), ::core::mem::transmute(ptableid), ::core::mem::transmute(pindexid), ::core::mem::transmute(riid), ::core::mem::transmute(cpropertysets), ::core::mem::transmute(rgpropertysets), ::core::mem::transmute(pprowset)).ok() } } unsafe impl ::windows::core::Interface for IOpenRowset { type Vtable = IOpenRowset_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a69_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IOpenRowset> for ::windows::core::IUnknown { fn from(value: IOpenRowset) -> Self { value.0 } } impl ::core::convert::From<&IOpenRowset> for ::windows::core::IUnknown { fn from(value: &IOpenRowset) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IOpenRowset { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IOpenRowset { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IOpenRowset_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, punkouter: ::windows::core::RawPtr, ptableid: *const super::super::Storage::IndexServer::DBID, pindexid: *const super::super::Storage::IndexServer::DBID, riid: *const ::windows::core::GUID, cpropertysets: u32, rgpropertysets: *mut DBPROPSET, pprowset: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IParentRowset(pub ::windows::core::IUnknown); impl IParentRowset { pub unsafe fn GetChildRowset<'a, Param0: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>>(&self, punkouter: Param0, iordinal: usize, riid: *const ::windows::core::GUID) -> ::windows::core::Result<::windows::core::IUnknown> { let mut result__: <::windows::core::IUnknown as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), punkouter.into_param().abi(), ::core::mem::transmute(iordinal), ::core::mem::transmute(riid), &mut result__).from_abi::<::windows::core::IUnknown>(result__) } } unsafe impl ::windows::core::Interface for IParentRowset { type Vtable = IParentRowset_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733aaa_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IParentRowset> for ::windows::core::IUnknown { fn from(value: IParentRowset) -> Self { value.0 } } impl ::core::convert::From<&IParentRowset> for ::windows::core::IUnknown { fn from(value: &IParentRowset) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IParentRowset { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IParentRowset { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IParentRowset_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, punkouter: ::windows::core::RawPtr, iordinal: usize, riid: *const ::windows::core::GUID, pprowset: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IProtocolHandlerSite(pub ::windows::core::IUnknown); impl IProtocolHandlerSite { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe fn GetFilter<'a, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param2: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pclsidobj: *mut ::windows::core::GUID, pcwszcontenttype: Param1, pcwszextension: Param2, ppfilter: *mut ::core::option::Option<super::super::Storage::IndexServer::IFilter>) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(pclsidobj), pcwszcontenttype.into_param().abi(), pcwszextension.into_param().abi(), ::core::mem::transmute(ppfilter)).ok() } } unsafe impl ::windows::core::Interface for IProtocolHandlerSite { type Vtable = IProtocolHandlerSite_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0b63e385_9ccc_11d0_bcdb_00805fccce04); } impl ::core::convert::From<IProtocolHandlerSite> for ::windows::core::IUnknown { fn from(value: IProtocolHandlerSite) -> Self { value.0 } } impl ::core::convert::From<&IProtocolHandlerSite> for ::windows::core::IUnknown { fn from(value: &IProtocolHandlerSite) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IProtocolHandlerSite { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IProtocolHandlerSite { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IProtocolHandlerSite_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pclsidobj: *mut ::windows::core::GUID, pcwszcontenttype: super::super::Foundation::PWSTR, pcwszextension: super::super::Foundation::PWSTR, ppfilter: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IProvideMoniker(pub ::windows::core::IUnknown); impl IProvideMoniker { #[cfg(feature = "Win32_System_Com")] pub unsafe fn GetMoniker(&self) -> ::windows::core::Result<super::Com::IMoniker> { let mut result__: <super::Com::IMoniker as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::Com::IMoniker>(result__) } } unsafe impl ::windows::core::Interface for IProvideMoniker { type Vtable = IProvideMoniker_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a4d_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IProvideMoniker> for ::windows::core::IUnknown { fn from(value: IProvideMoniker) -> Self { value.0 } } impl ::core::convert::From<&IProvideMoniker> for ::windows::core::IUnknown { fn from(value: &IProvideMoniker) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IProvideMoniker { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IProvideMoniker { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IProvideMoniker_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_System_Com")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppimoniker: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_System_Com"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IQueryParser(pub ::windows::core::IUnknown); impl IQueryParser { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub unsafe fn Parse<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param1: ::windows::core::IntoParam<'a, super::Com::IEnumUnknown>>(&self, pszinputstring: Param0, pcustomproperties: Param1) -> ::windows::core::Result<IQuerySolution> { let mut result__: <IQuerySolution as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), pszinputstring.into_param().abi(), pcustomproperties.into_param().abi(), &mut result__).from_abi::<IQuerySolution>(result__) } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe fn SetOption(&self, option: STRUCTURED_QUERY_SINGLE_OPTION, poptionvalue: *const super::Com::StructuredStorage::PROPVARIANT) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(option), ::core::mem::transmute(poptionvalue)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe fn GetOption(&self, option: STRUCTURED_QUERY_SINGLE_OPTION) -> ::windows::core::Result<super::Com::StructuredStorage::PROPVARIANT> { let mut result__: <super::Com::StructuredStorage::PROPVARIANT as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(option), &mut result__).from_abi::<super::Com::StructuredStorage::PROPVARIANT>(result__) } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe fn SetMultiOption<'a, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, option: STRUCTURED_QUERY_MULTIOPTION, pszoptionkey: Param1, poptionvalue: *const super::Com::StructuredStorage::PROPVARIANT) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), ::core::mem::transmute(option), pszoptionkey.into_param().abi(), ::core::mem::transmute(poptionvalue)).ok() } pub unsafe fn GetSchemaProvider(&self) -> ::windows::core::Result<ISchemaProvider> { let mut result__: <ISchemaProvider as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), &mut result__).from_abi::<ISchemaProvider>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn RestateToString<'a, Param0: ::windows::core::IntoParam<'a, ICondition>, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>(&self, pcondition: Param0, fuseenglish: Param1) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).8)(::core::mem::transmute_copy(self), pcondition.into_param().abi(), fuseenglish.into_param().abi(), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn ParsePropertyValue<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszpropertyname: Param0, pszinputstring: Param1) -> ::windows::core::Result<IQuerySolution> { let mut result__: <IQuerySolution as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).9)(::core::mem::transmute_copy(self), pszpropertyname.into_param().abi(), pszinputstring.into_param().abi(), &mut result__).from_abi::<IQuerySolution>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn RestatePropertyValueToString<'a, Param0: ::windows::core::IntoParam<'a, ICondition>, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>(&self, pcondition: Param0, fuseenglish: Param1, ppszpropertyname: *mut super::super::Foundation::PWSTR, ppszquerystring: *mut super::super::Foundation::PWSTR) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).10)(::core::mem::transmute_copy(self), pcondition.into_param().abi(), fuseenglish.into_param().abi(), ::core::mem::transmute(ppszpropertyname), ::core::mem::transmute(ppszquerystring)).ok() } } unsafe impl ::windows::core::Interface for IQueryParser { type Vtable = IQueryParser_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x2ebdee67_3505_43f8_9946_ea44abc8e5b0); } impl ::core::convert::From<IQueryParser> for ::windows::core::IUnknown { fn from(value: IQueryParser) -> Self { value.0 } } impl ::core::convert::From<&IQueryParser> for ::windows::core::IUnknown { fn from(value: &IQueryParser) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IQueryParser { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IQueryParser { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IQueryParser_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszinputstring: super::super::Foundation::PWSTR, pcustomproperties: ::windows::core::RawPtr, ppsolution: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, option: STRUCTURED_QUERY_SINGLE_OPTION, poptionvalue: *const ::core::mem::ManuallyDrop<super::Com::StructuredStorage::PROPVARIANT>) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, option: STRUCTURED_QUERY_SINGLE_OPTION, poptionvalue: *mut ::core::mem::ManuallyDrop<super::Com::StructuredStorage::PROPVARIANT>) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, option: STRUCTURED_QUERY_MULTIOPTION, pszoptionkey: super::super::Foundation::PWSTR, poptionvalue: *const ::core::mem::ManuallyDrop<super::Com::StructuredStorage::PROPVARIANT>) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage")))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppschemaprovider: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pcondition: ::windows::core::RawPtr, fuseenglish: super::super::Foundation::BOOL, ppszquerystring: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszpropertyname: super::super::Foundation::PWSTR, pszinputstring: super::super::Foundation::PWSTR, ppsolution: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pcondition: ::windows::core::RawPtr, fuseenglish: super::super::Foundation::BOOL, ppszpropertyname: *mut super::super::Foundation::PWSTR, ppszquerystring: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IQueryParserManager(pub ::windows::core::IUnknown); impl IQueryParserManager { #[cfg(feature = "Win32_Foundation")] pub unsafe fn CreateLoadedParser<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, T: ::windows::core::Interface>(&self, pszcatalog: Param0, langidforkeywords: u16) -> ::windows::core::Result<T> { let mut result__ = ::core::option::Option::None; (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), pszcatalog.into_param().abi(), ::core::mem::transmute(langidforkeywords), &<T as ::windows::core::Interface>::IID, &mut result__ as *mut _ as *mut _).and_some(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn InitializeOptions<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>, Param2: ::windows::core::IntoParam<'a, IQueryParser>>(&self, funderstandnqs: Param0, fautowildcard: Param1, pqueryparser: Param2) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), funderstandnqs.into_param().abi(), fautowildcard.into_param().abi(), pqueryparser.into_param().abi()).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe fn SetOption(&self, option: QUERY_PARSER_MANAGER_OPTION, poptionvalue: *const super::Com::StructuredStorage::PROPVARIANT) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(option), ::core::mem::transmute(poptionvalue)).ok() } } unsafe impl ::windows::core::Interface for IQueryParserManager { type Vtable = IQueryParserManager_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xa879e3c4_af77_44fb_8f37_ebd1487cf920); } impl ::core::convert::From<IQueryParserManager> for ::windows::core::IUnknown { fn from(value: IQueryParserManager) -> Self { value.0 } } impl ::core::convert::From<&IQueryParserManager> for ::windows::core::IUnknown { fn from(value: &IQueryParserManager) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IQueryParserManager { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IQueryParserManager { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IQueryParserManager_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszcatalog: super::super::Foundation::PWSTR, langidforkeywords: u16, riid: *const ::windows::core::GUID, ppqueryparser: *mut *mut ::core::ffi::c_void) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, funderstandnqs: super::super::Foundation::BOOL, fautowildcard: super::super::Foundation::BOOL, pqueryparser: ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, option: QUERY_PARSER_MANAGER_OPTION, poptionvalue: *const ::core::mem::ManuallyDrop<super::Com::StructuredStorage::PROPVARIANT>) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IQuerySolution(pub ::windows::core::IUnknown); impl IQuerySolution { #[cfg(feature = "Win32_Foundation")] pub unsafe fn MakeNot<'a, Param0: ::windows::core::IntoParam<'a, ICondition>, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>(&self, pcsub: Param0, fsimplify: Param1) -> ::windows::core::Result<ICondition> { let mut result__: <ICondition as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), pcsub.into_param().abi(), fsimplify.into_param().abi(), &mut result__).from_abi::<ICondition>(result__) } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Search_Common"))] pub unsafe fn MakeAndOr<'a, Param1: ::windows::core::IntoParam<'a, super::Com::IEnumUnknown>, Param2: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>(&self, ct: Common::CONDITION_TYPE, peusubs: Param1, fsimplify: Param2) -> ::windows::core::Result<ICondition> { let mut result__: <ICondition as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(ct), peusubs.into_param().abi(), fsimplify.into_param().abi(), &mut result__).from_abi::<ICondition>(result__) } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_System_Search_Common"))] pub unsafe fn MakeLeaf<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param2: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param4: ::windows::core::IntoParam<'a, IRichChunk>, Param5: ::windows::core::IntoParam<'a, IRichChunk>, Param6: ::windows::core::IntoParam<'a, IRichChunk>, Param7: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>( &self, pszpropertyname: Param0, cop: Common::CONDITION_OPERATION, pszvaluetype: Param2, ppropvar: *const super::Com::StructuredStorage::PROPVARIANT, ppropertynameterm: Param4, poperationterm: Param5, pvalueterm: Param6, fexpand: Param7, ) -> ::windows::core::Result<ICondition> { let mut result__: <ICondition as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).5)( ::core::mem::transmute_copy(self), pszpropertyname.into_param().abi(), ::core::mem::transmute(cop), pszvaluetype.into_param().abi(), ::core::mem::transmute(ppropvar), ppropertynameterm.into_param().abi(), poperationterm.into_param().abi(), pvalueterm.into_param().abi(), fexpand.into_param().abi(), &mut result__, ) .from_abi::<ICondition>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn Resolve<'a, Param0: ::windows::core::IntoParam<'a, ICondition>>(&self, pc: Param0, sqro: STRUCTURED_QUERY_RESOLVE_OPTION, pstreferencetime: *const super::super::Foundation::SYSTEMTIME) -> ::windows::core::Result<ICondition> { let mut result__: <ICondition as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), pc.into_param().abi(), ::core::mem::transmute(sqro), ::core::mem::transmute(pstreferencetime), &mut result__).from_abi::<ICondition>(result__) } pub unsafe fn GetQuery(&self, ppquerynode: *mut ::core::option::Option<ICondition>, ppmaintype: *mut ::core::option::Option<IEntity>) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), ::core::mem::transmute(ppquerynode), ::core::mem::transmute(ppmaintype)).ok() } pub unsafe fn GetErrors<T: ::windows::core::Interface>(&self) -> ::windows::core::Result<T> { let mut result__ = ::core::option::Option::None; (::windows::core::Interface::vtable(self).8)(::core::mem::transmute_copy(self), &<T as ::windows::core::Interface>::IID, &mut result__ as *mut _ as *mut _).and_some(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetLexicalData(&self, ppszinputstring: *mut super::super::Foundation::PWSTR, pptokens: *mut ::core::option::Option<ITokenCollection>, plcid: *mut u32, ppwordbreaker: *mut ::core::option::Option<::windows::core::IUnknown>) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).9)(::core::mem::transmute_copy(self), ::core::mem::transmute(ppszinputstring), ::core::mem::transmute(pptokens), ::core::mem::transmute(plcid), ::core::mem::transmute(ppwordbreaker)).ok() } } unsafe impl ::windows::core::Interface for IQuerySolution { type Vtable = IQuerySolution_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xd6ebc66b_8921_4193_afdd_a1789fb7ff57); } impl ::core::convert::From<IQuerySolution> for ::windows::core::IUnknown { fn from(value: IQuerySolution) -> Self { value.0 } } impl ::core::convert::From<&IQuerySolution> for ::windows::core::IUnknown { fn from(value: &IQuerySolution) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IQuerySolution { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IQuerySolution { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } impl ::core::convert::From<IQuerySolution> for IConditionFactory { fn from(value: IQuerySolution) -> Self { unsafe { ::core::mem::transmute(value) } } } impl ::core::convert::From<&IQuerySolution> for IConditionFactory { fn from(value: &IQuerySolution) -> Self { ::core::convert::From::from(::core::clone::Clone::clone(value)) } } impl<'a> ::windows::core::IntoParam<'a, IConditionFactory> for IQuerySolution { fn into_param(self) -> ::windows::core::Param<'a, IConditionFactory> { ::windows::core::Param::Owned(unsafe { ::core::mem::transmute(self) }) } } impl<'a> ::windows::core::IntoParam<'a, IConditionFactory> for &IQuerySolution { fn into_param(self) -> ::windows::core::Param<'a, IConditionFactory> { ::windows::core::Param::Borrowed(unsafe { ::core::mem::transmute(self) }) } } #[repr(C)] #[doc(hidden)] pub struct IQuerySolution_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pcsub: ::windows::core::RawPtr, fsimplify: super::super::Foundation::BOOL, ppcresult: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Search_Common"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ct: Common::CONDITION_TYPE, peusubs: ::windows::core::RawPtr, fsimplify: super::super::Foundation::BOOL, ppcresult: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Search_Common")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_System_Search_Common"))] pub unsafe extern "system" fn( this: ::windows::core::RawPtr, pszpropertyname: super::super::Foundation::PWSTR, cop: Common::CONDITION_OPERATION, pszvaluetype: super::super::Foundation::PWSTR, ppropvar: *const ::core::mem::ManuallyDrop<super::Com::StructuredStorage::PROPVARIANT>, ppropertynameterm: ::windows::core::RawPtr, poperationterm: ::windows::core::RawPtr, pvalueterm: ::windows::core::RawPtr, fexpand: super::super::Foundation::BOOL, ppcresult: *mut ::windows::core::RawPtr, ) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_System_Search_Common")))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pc: ::windows::core::RawPtr, sqro: STRUCTURED_QUERY_RESOLVE_OPTION, pstreferencetime: *const super::super::Foundation::SYSTEMTIME, ppcresolved: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppquerynode: *mut ::windows::core::RawPtr, ppmaintype: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, riid: *const ::windows::core::GUID, ppparseerrors: *mut *mut ::core::ffi::c_void) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppszinputstring: *mut super::super::Foundation::PWSTR, pptokens: *mut ::windows::core::RawPtr, plcid: *mut u32, ppwordbreaker: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IReadData(pub ::windows::core::IUnknown); impl IReadData { pub unsafe fn ReadData(&self, hchapter: usize, cbbookmark: usize, pbookmark: *const u8, lrowsoffset: isize, haccessor: usize, crows: isize, pcrowsobtained: *mut usize, ppfixeddata: *mut *mut u8, pcbvariabletotal: *mut usize, ppvariabledata: *mut *mut u8) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)( ::core::mem::transmute_copy(self), ::core::mem::transmute(hchapter), ::core::mem::transmute(cbbookmark), ::core::mem::transmute(pbookmark), ::core::mem::transmute(lrowsoffset), ::core::mem::transmute(haccessor), ::core::mem::transmute(crows), ::core::mem::transmute(pcrowsobtained), ::core::mem::transmute(ppfixeddata), ::core::mem::transmute(pcbvariabletotal), ::core::mem::transmute(ppvariabledata), ) .ok() } pub unsafe fn ReleaseChapter(&self, hchapter: usize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(hchapter)).ok() } } unsafe impl ::windows::core::Interface for IReadData { type Vtable = IReadData_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a6a_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IReadData> for ::windows::core::IUnknown { fn from(value: IReadData) -> Self { value.0 } } impl ::core::convert::From<&IReadData> for ::windows::core::IUnknown { fn from(value: &IReadData) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IReadData { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IReadData { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IReadData_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hchapter: usize, cbbookmark: usize, pbookmark: *const u8, lrowsoffset: isize, haccessor: usize, crows: isize, pcrowsobtained: *mut usize, ppfixeddata: *mut *mut u8, pcbvariabletotal: *mut usize, ppvariabledata: *mut *mut u8) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hchapter: usize) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRegisterProvider(pub ::windows::core::IUnknown); impl IRegisterProvider { #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetURLMapping<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pwszurl: Param0, dwreserved: usize) -> ::windows::core::Result<::windows::core::GUID> { let mut result__: <::windows::core::GUID as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), pwszurl.into_param().abi(), ::core::mem::transmute(dwreserved), &mut result__).from_abi::<::windows::core::GUID>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn SetURLMapping<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pwszurl: Param0, dwreserved: usize, rclsidprovider: *const ::windows::core::GUID) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), pwszurl.into_param().abi(), ::core::mem::transmute(dwreserved), ::core::mem::transmute(rclsidprovider)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn UnregisterProvider<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pwszurl: Param0, dwreserved: usize, rclsidprovider: *const ::windows::core::GUID) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), pwszurl.into_param().abi(), ::core::mem::transmute(dwreserved), ::core::mem::transmute(rclsidprovider)).ok() } } unsafe impl ::windows::core::Interface for IRegisterProvider { type Vtable = IRegisterProvider_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733ab9_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IRegisterProvider> for ::windows::core::IUnknown { fn from(value: IRegisterProvider) -> Self { value.0 } } impl ::core::convert::From<&IRegisterProvider> for ::windows::core::IUnknown { fn from(value: &IRegisterProvider) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRegisterProvider { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRegisterProvider { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IRegisterProvider_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pwszurl: super::super::Foundation::PWSTR, dwreserved: usize, pclsidprovider: *mut ::windows::core::GUID) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pwszurl: super::super::Foundation::PWSTR, dwreserved: usize, rclsidprovider: *const ::windows::core::GUID) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pwszurl: super::super::Foundation::PWSTR, dwreserved: usize, rclsidprovider: *const ::windows::core::GUID) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRelationship(pub ::windows::core::IUnknown); impl IRelationship { #[cfg(feature = "Win32_Foundation")] pub unsafe fn Name(&self) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn IsReal(&self) -> ::windows::core::Result<super::super::Foundation::BOOL> { let mut result__: <super::super::Foundation::BOOL as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::BOOL>(result__) } pub unsafe fn Destination(&self) -> ::windows::core::Result<IEntity> { let mut result__: <IEntity as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), &mut result__).from_abi::<IEntity>(result__) } pub unsafe fn MetaData<T: ::windows::core::Interface>(&self) -> ::windows::core::Result<T> { let mut result__ = ::core::option::Option::None; (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), &<T as ::windows::core::Interface>::IID, &mut result__ as *mut _ as *mut _).and_some(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn DefaultPhrase(&self) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } } unsafe impl ::windows::core::Interface for IRelationship { type Vtable = IRelationship_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x2769280b_5108_498c_9c7f_a51239b63147); } impl ::core::convert::From<IRelationship> for ::windows::core::IUnknown { fn from(value: IRelationship) -> Self { value.0 } } impl ::core::convert::From<&IRelationship> for ::windows::core::IUnknown { fn from(value: &IRelationship) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRelationship { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRelationship { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IRelationship_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppszname: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pisreal: *mut super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pdestinationentity: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, riid: *const ::windows::core::GUID, pmetadata: *mut *mut ::core::ffi::c_void) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppszphrase: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRichChunk(pub ::windows::core::IUnknown); impl IRichChunk { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe fn GetData(&self, pfirstpos: *mut u32, plength: *mut u32, ppsz: *mut super::super::Foundation::PWSTR, pvalue: *mut super::Com::StructuredStorage::PROPVARIANT) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(pfirstpos), ::core::mem::transmute(plength), ::core::mem::transmute(ppsz), ::core::mem::transmute(pvalue)).ok() } } unsafe impl ::windows::core::Interface for IRichChunk { type Vtable = IRichChunk_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x4fdef69c_dbc9_454e_9910_b34f3c64b510); } impl ::core::convert::From<IRichChunk> for ::windows::core::IUnknown { fn from(value: IRichChunk) -> Self { value.0 } } impl ::core::convert::From<&IRichChunk> for ::windows::core::IUnknown { fn from(value: &IRichChunk) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRichChunk { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRichChunk { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IRichChunk_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pfirstpos: *mut u32, plength: *mut u32, ppsz: *mut super::super::Foundation::PWSTR, pvalue: *mut ::core::mem::ManuallyDrop<super::Com::StructuredStorage::PROPVARIANT>) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRow(pub ::windows::core::IUnknown); impl IRow { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe fn GetColumns(&self, ccolumns: usize, rgcolumns: *mut DBCOLUMNACCESS) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(ccolumns), ::core::mem::transmute(rgcolumns)).ok() } pub unsafe fn GetSourceRowset(&self, riid: *const ::windows::core::GUID, pprowset: *mut ::core::option::Option<::windows::core::IUnknown>, phrow: *mut usize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(riid), ::core::mem::transmute(pprowset), ::core::mem::transmute(phrow)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe fn Open<'a, Param0: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>>(&self, punkouter: Param0, pcolumnid: *const super::super::Storage::IndexServer::DBID, rguidcolumntype: *const ::windows::core::GUID, dwbindflags: u32, riid: *const ::windows::core::GUID) -> ::windows::core::Result<::windows::core::IUnknown> { let mut result__: <::windows::core::IUnknown as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), punkouter.into_param().abi(), ::core::mem::transmute(pcolumnid), ::core::mem::transmute(rguidcolumntype), ::core::mem::transmute(dwbindflags), ::core::mem::transmute(riid), &mut result__).from_abi::<::windows::core::IUnknown>(result__) } } unsafe impl ::windows::core::Interface for IRow { type Vtable = IRow_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733ab4_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IRow> for ::windows::core::IUnknown { fn from(value: IRow) -> Self { value.0 } } impl ::core::convert::From<&IRow> for ::windows::core::IUnknown { fn from(value: &IRow) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRow { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRow { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IRow_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ccolumns: usize, rgcolumns: *mut DBCOLUMNACCESS) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer")))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, riid: *const ::windows::core::GUID, pprowset: *mut ::windows::core::RawPtr, phrow: *mut usize) -> ::windows::core::HRESULT, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, punkouter: ::windows::core::RawPtr, pcolumnid: *const super::super::Storage::IndexServer::DBID, rguidcolumntype: *const ::windows::core::GUID, dwbindflags: u32, riid: *const ::windows::core::GUID, ppunk: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRowChange(pub ::windows::core::IUnknown); impl IRowChange { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe fn SetColumns(&self, ccolumns: usize, rgcolumns: *const DBCOLUMNACCESS) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(ccolumns), ::core::mem::transmute(rgcolumns)).ok() } } unsafe impl ::windows::core::Interface for IRowChange { type Vtable = IRowChange_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733ab5_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IRowChange> for ::windows::core::IUnknown { fn from(value: IRowChange) -> Self { value.0 } } impl ::core::convert::From<&IRowChange> for ::windows::core::IUnknown { fn from(value: &IRowChange) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRowChange { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRowChange { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IRowChange_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ccolumns: usize, rgcolumns: *const DBCOLUMNACCESS) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRowPosition(pub ::windows::core::IUnknown); impl IRowPosition { pub unsafe fn ClearRowPosition(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self)).ok() } pub unsafe fn GetRowPosition(&self, phchapter: *mut usize, phrow: *mut usize, pdwpositionflags: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(phchapter), ::core::mem::transmute(phrow), ::core::mem::transmute(pdwpositionflags)).ok() } pub unsafe fn GetRowset(&self, riid: *const ::windows::core::GUID) -> ::windows::core::Result<::windows::core::IUnknown> { let mut result__: <::windows::core::IUnknown as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(riid), &mut result__).from_abi::<::windows::core::IUnknown>(result__) } pub unsafe fn Initialize<'a, Param0: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>>(&self, prowset: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), prowset.into_param().abi()).ok() } pub unsafe fn SetRowPosition(&self, hchapter: usize, hrow: usize, dwpositionflags: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), ::core::mem::transmute(hchapter), ::core::mem::transmute(hrow), ::core::mem::transmute(dwpositionflags)).ok() } } unsafe impl ::windows::core::Interface for IRowPosition { type Vtable = IRowPosition_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a94_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IRowPosition> for ::windows::core::IUnknown { fn from(value: IRowPosition) -> Self { value.0 } } impl ::core::convert::From<&IRowPosition> for ::windows::core::IUnknown { fn from(value: &IRowPosition) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRowPosition { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRowPosition { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IRowPosition_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, phchapter: *mut usize, phrow: *mut usize, pdwpositionflags: *mut u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, riid: *const ::windows::core::GUID, pprowset: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, prowset: ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hchapter: usize, hrow: usize, dwpositionflags: u32) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRowPositionChange(pub ::windows::core::IUnknown); impl IRowPositionChange { #[cfg(feature = "Win32_Foundation")] pub unsafe fn OnRowPositionChange<'a, Param2: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>(&self, ereason: u32, ephase: u32, fcantdeny: Param2) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(ereason), ::core::mem::transmute(ephase), fcantdeny.into_param().abi()).ok() } } unsafe impl ::windows::core::Interface for IRowPositionChange { type Vtable = IRowPositionChange_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0997a571_126e_11d0_9f8a_00a0c9a0631e); } impl ::core::convert::From<IRowPositionChange> for ::windows::core::IUnknown { fn from(value: IRowPositionChange) -> Self { value.0 } } impl ::core::convert::From<&IRowPositionChange> for ::windows::core::IUnknown { fn from(value: &IRowPositionChange) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRowPositionChange { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRowPositionChange { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IRowPositionChange_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ereason: u32, ephase: u32, fcantdeny: super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRowSchemaChange(pub ::windows::core::IUnknown); impl IRowSchemaChange { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe fn SetColumns(&self, ccolumns: usize, rgcolumns: *const DBCOLUMNACCESS) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(ccolumns), ::core::mem::transmute(rgcolumns)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe fn DeleteColumns(&self, ccolumns: usize, rgcolumnids: *const super::super::Storage::IndexServer::DBID, rgdwstatus: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(ccolumns), ::core::mem::transmute(rgcolumnids), ::core::mem::transmute(rgdwstatus)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com"))] pub unsafe fn AddColumns(&self, ccolumns: usize, rgnewcolumninfo: *const DBCOLUMNINFO, rgcolumns: *mut DBCOLUMNACCESS) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(ccolumns), ::core::mem::transmute(rgnewcolumninfo), ::core::mem::transmute(rgcolumns)).ok() } } unsafe impl ::windows::core::Interface for IRowSchemaChange { type Vtable = IRowSchemaChange_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733aae_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IRowSchemaChange> for ::windows::core::IUnknown { fn from(value: IRowSchemaChange) -> Self { value.0 } } impl ::core::convert::From<&IRowSchemaChange> for ::windows::core::IUnknown { fn from(value: &IRowSchemaChange) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRowSchemaChange { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRowSchemaChange { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } impl ::core::convert::From<IRowSchemaChange> for IRowChange { fn from(value: IRowSchemaChange) -> Self { unsafe { ::core::mem::transmute(value) } } } impl ::core::convert::From<&IRowSchemaChange> for IRowChange { fn from(value: &IRowSchemaChange) -> Self { ::core::convert::From::from(::core::clone::Clone::clone(value)) } } impl<'a> ::windows::core::IntoParam<'a, IRowChange> for IRowSchemaChange { fn into_param(self) -> ::windows::core::Param<'a, IRowChange> { ::windows::core::Param::Owned(unsafe { ::core::mem::transmute(self) }) } } impl<'a> ::windows::core::IntoParam<'a, IRowChange> for &IRowSchemaChange { fn into_param(self) -> ::windows::core::Param<'a, IRowChange> { ::windows::core::Param::Borrowed(unsafe { ::core::mem::transmute(self) }) } } #[repr(C)] #[doc(hidden)] pub struct IRowSchemaChange_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ccolumns: usize, rgcolumns: *const DBCOLUMNACCESS) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ccolumns: usize, rgcolumnids: *const super::super::Storage::IndexServer::DBID, rgdwstatus: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ccolumns: usize, rgnewcolumninfo: *const ::core::mem::ManuallyDrop<DBCOLUMNINFO>, rgcolumns: *mut DBCOLUMNACCESS) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRowset(pub ::windows::core::IUnknown); impl IRowset { pub unsafe fn AddRefRows(&self, crows: usize, rghrows: *const usize, rgrefcounts: *mut u32, rgrowstatus: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(crows), ::core::mem::transmute(rghrows), ::core::mem::transmute(rgrefcounts), ::core::mem::transmute(rgrowstatus)).ok() } pub unsafe fn GetData(&self, hrow: usize, haccessor: usize, pdata: *mut ::core::ffi::c_void) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(hrow), ::core::mem::transmute(haccessor), ::core::mem::transmute(pdata)).ok() } pub unsafe fn GetNextRows(&self, hreserved: usize, lrowsoffset: isize, crows: isize, pcrowsobtained: *mut usize, prghrows: *mut *mut usize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(hreserved), ::core::mem::transmute(lrowsoffset), ::core::mem::transmute(crows), ::core::mem::transmute(pcrowsobtained), ::core::mem::transmute(prghrows)).ok() } pub unsafe fn ReleaseRows(&self, crows: usize, rghrows: *const usize, rgrowoptions: *mut u32, rgrefcounts: *mut u32, rgrowstatus: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), ::core::mem::transmute(crows), ::core::mem::transmute(rghrows), ::core::mem::transmute(rgrowoptions), ::core::mem::transmute(rgrefcounts), ::core::mem::transmute(rgrowstatus)).ok() } pub unsafe fn RestartPosition(&self, hreserved: usize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), ::core::mem::transmute(hreserved)).ok() } } unsafe impl ::windows::core::Interface for IRowset { type Vtable = IRowset_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a7c_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IRowset> for ::windows::core::IUnknown { fn from(value: IRowset) -> Self { value.0 } } impl ::core::convert::From<&IRowset> for ::windows::core::IUnknown { fn from(value: &IRowset) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRowset { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRowset { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IRowset_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, crows: usize, rghrows: *const usize, rgrefcounts: *mut u32, rgrowstatus: *mut u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hrow: usize, haccessor: usize, pdata: *mut ::core::ffi::c_void) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hreserved: usize, lrowsoffset: isize, crows: isize, pcrowsobtained: *mut usize, prghrows: *mut *mut usize) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, crows: usize, rghrows: *const usize, rgrowoptions: *mut u32, rgrefcounts: *mut u32, rgrowstatus: *mut u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hreserved: usize) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRowsetAsynch(pub ::windows::core::IUnknown); impl IRowsetAsynch { #[cfg(feature = "Win32_Foundation")] pub unsafe fn RatioFinished(&self, puldenominator: *mut usize, pulnumerator: *mut usize, pcrows: *mut usize, pfnewrows: *mut super::super::Foundation::BOOL) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(puldenominator), ::core::mem::transmute(pulnumerator), ::core::mem::transmute(pcrows), ::core::mem::transmute(pfnewrows)).ok() } pub unsafe fn Stop(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self)).ok() } } unsafe impl ::windows::core::Interface for IRowsetAsynch { type Vtable = IRowsetAsynch_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a0f_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IRowsetAsynch> for ::windows::core::IUnknown { fn from(value: IRowsetAsynch) -> Self { value.0 } } impl ::core::convert::From<&IRowsetAsynch> for ::windows::core::IUnknown { fn from(value: &IRowsetAsynch) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRowsetAsynch { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRowsetAsynch { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IRowsetAsynch_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, puldenominator: *mut usize, pulnumerator: *mut usize, pcrows: *mut usize, pfnewrows: *mut super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRowsetBookmark(pub ::windows::core::IUnknown); impl IRowsetBookmark { pub unsafe fn PositionOnBookmark(&self, hchapter: usize, cbbookmark: usize, pbookmark: *const u8) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(hchapter), ::core::mem::transmute(cbbookmark), ::core::mem::transmute(pbookmark)).ok() } } unsafe impl ::windows::core::Interface for IRowsetBookmark { type Vtable = IRowsetBookmark_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733ac2_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IRowsetBookmark> for ::windows::core::IUnknown { fn from(value: IRowsetBookmark) -> Self { value.0 } } impl ::core::convert::From<&IRowsetBookmark> for ::windows::core::IUnknown { fn from(value: &IRowsetBookmark) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRowsetBookmark { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRowsetBookmark { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IRowsetBookmark_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hchapter: usize, cbbookmark: usize, pbookmark: *const u8) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRowsetChange(pub ::windows::core::IUnknown); impl IRowsetChange { pub unsafe fn DeleteRows(&self, hreserved: usize, crows: usize, rghrows: *const usize, rgrowstatus: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(hreserved), ::core::mem::transmute(crows), ::core::mem::transmute(rghrows), ::core::mem::transmute(rgrowstatus)).ok() } pub unsafe fn SetData(&self, hrow: usize, haccessor: usize, pdata: *mut ::core::ffi::c_void) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(hrow), ::core::mem::transmute(haccessor), ::core::mem::transmute(pdata)).ok() } pub unsafe fn InsertRow(&self, hreserved: usize, haccessor: usize, pdata: *mut ::core::ffi::c_void, phrow: *mut usize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(hreserved), ::core::mem::transmute(haccessor), ::core::mem::transmute(pdata), ::core::mem::transmute(phrow)).ok() } } unsafe impl ::windows::core::Interface for IRowsetChange { type Vtable = IRowsetChange_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a05_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IRowsetChange> for ::windows::core::IUnknown { fn from(value: IRowsetChange) -> Self { value.0 } } impl ::core::convert::From<&IRowsetChange> for ::windows::core::IUnknown { fn from(value: &IRowsetChange) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRowsetChange { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRowsetChange { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IRowsetChange_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hreserved: usize, crows: usize, rghrows: *const usize, rgrowstatus: *mut u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hrow: usize, haccessor: usize, pdata: *mut ::core::ffi::c_void) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hreserved: usize, haccessor: usize, pdata: *mut ::core::ffi::c_void, phrow: *mut usize) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRowsetChangeExtInfo(pub ::windows::core::IUnknown); impl IRowsetChangeExtInfo { pub unsafe fn GetOriginalRow(&self, hreserved: usize, hrow: usize, phroworiginal: *mut usize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(hreserved), ::core::mem::transmute(hrow), ::core::mem::transmute(phroworiginal)).ok() } pub unsafe fn GetPendingColumns(&self, hreserved: usize, hrow: usize, ccolumnordinals: u32, rgiordinals: *const u32, rgcolumnstatus: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(hreserved), ::core::mem::transmute(hrow), ::core::mem::transmute(ccolumnordinals), ::core::mem::transmute(rgiordinals), ::core::mem::transmute(rgcolumnstatus)).ok() } } unsafe impl ::windows::core::Interface for IRowsetChangeExtInfo { type Vtable = IRowsetChangeExtInfo_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a8f_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IRowsetChangeExtInfo> for ::windows::core::IUnknown { fn from(value: IRowsetChangeExtInfo) -> Self { value.0 } } impl ::core::convert::From<&IRowsetChangeExtInfo> for ::windows::core::IUnknown { fn from(value: &IRowsetChangeExtInfo) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRowsetChangeExtInfo { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRowsetChangeExtInfo { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IRowsetChangeExtInfo_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hreserved: usize, hrow: usize, phroworiginal: *mut usize) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hreserved: usize, hrow: usize, ccolumnordinals: u32, rgiordinals: *const u32, rgcolumnstatus: *mut u32) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRowsetChapterMember(pub ::windows::core::IUnknown); impl IRowsetChapterMember { pub unsafe fn IsRowInChapter(&self, hchapter: usize, hrow: usize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(hchapter), ::core::mem::transmute(hrow)).ok() } } unsafe impl ::windows::core::Interface for IRowsetChapterMember { type Vtable = IRowsetChapterMember_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733aa8_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IRowsetChapterMember> for ::windows::core::IUnknown { fn from(value: IRowsetChapterMember) -> Self { value.0 } } impl ::core::convert::From<&IRowsetChapterMember> for ::windows::core::IUnknown { fn from(value: &IRowsetChapterMember) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRowsetChapterMember { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRowsetChapterMember { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IRowsetChapterMember_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hchapter: usize, hrow: usize) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRowsetCopyRows(pub ::windows::core::IUnknown); impl IRowsetCopyRows { pub unsafe fn CloseSource(&self, hsourceid: u16) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(hsourceid)).ok() } pub unsafe fn CopyByHROWS(&self, hsourceid: u16, hreserved: usize, crows: isize, rghrows: *const usize, bflags: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(hsourceid), ::core::mem::transmute(hreserved), ::core::mem::transmute(crows), ::core::mem::transmute(rghrows), ::core::mem::transmute(bflags)).ok() } pub unsafe fn CopyRows(&self, hsourceid: u16, hreserved: usize, crows: isize, bflags: u32, pcrowscopied: *mut usize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(hsourceid), ::core::mem::transmute(hreserved), ::core::mem::transmute(crows), ::core::mem::transmute(bflags), ::core::mem::transmute(pcrowscopied)).ok() } pub unsafe fn DefineSource<'a, Param0: ::windows::core::IntoParam<'a, IRowset>>(&self, prowsetsource: Param0, ccolids: usize, rgsourcecolumns: *const isize, rgtargetcolumns: *const isize, phsourceid: *mut u16) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), prowsetsource.into_param().abi(), ::core::mem::transmute(ccolids), ::core::mem::transmute(rgsourcecolumns), ::core::mem::transmute(rgtargetcolumns), ::core::mem::transmute(phsourceid)).ok() } } unsafe impl ::windows::core::Interface for IRowsetCopyRows { type Vtable = IRowsetCopyRows_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a6b_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IRowsetCopyRows> for ::windows::core::IUnknown { fn from(value: IRowsetCopyRows) -> Self { value.0 } } impl ::core::convert::From<&IRowsetCopyRows> for ::windows::core::IUnknown { fn from(value: &IRowsetCopyRows) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRowsetCopyRows { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRowsetCopyRows { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IRowsetCopyRows_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hsourceid: u16) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hsourceid: u16, hreserved: usize, crows: isize, rghrows: *const usize, bflags: u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hsourceid: u16, hreserved: usize, crows: isize, bflags: u32, pcrowscopied: *mut usize) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, prowsetsource: ::windows::core::RawPtr, ccolids: usize, rgsourcecolumns: *const isize, rgtargetcolumns: *const isize, phsourceid: *mut u16) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRowsetCurrentIndex(pub ::windows::core::IUnknown); impl IRowsetCurrentIndex { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn GetIndexInfo(&self, pckeycolumns: *mut usize, prgindexcolumndesc: *mut *mut DBINDEXCOLUMNDESC, pcindexpropertysets: *mut u32, prgindexpropertysets: *mut *mut DBPROPSET) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(pckeycolumns), ::core::mem::transmute(prgindexcolumndesc), ::core::mem::transmute(pcindexpropertysets), ::core::mem::transmute(prgindexpropertysets)).ok() } pub unsafe fn Seek(&self, haccessor: usize, ckeyvalues: usize, pdata: *mut ::core::ffi::c_void, dwseekoptions: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(haccessor), ::core::mem::transmute(ckeyvalues), ::core::mem::transmute(pdata), ::core::mem::transmute(dwseekoptions)).ok() } pub unsafe fn SetRange(&self, haccessor: usize, cstartkeycolumns: usize, pstartdata: *mut ::core::ffi::c_void, cendkeycolumns: usize, penddata: *mut ::core::ffi::c_void, dwrangeoptions: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(haccessor), ::core::mem::transmute(cstartkeycolumns), ::core::mem::transmute(pstartdata), ::core::mem::transmute(cendkeycolumns), ::core::mem::transmute(penddata), ::core::mem::transmute(dwrangeoptions)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe fn GetIndex(&self, ppindexid: *mut *mut super::super::Storage::IndexServer::DBID) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), ::core::mem::transmute(ppindexid)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe fn SetIndex(&self, pindexid: *mut super::super::Storage::IndexServer::DBID) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), ::core::mem::transmute(pindexid)).ok() } } unsafe impl ::windows::core::Interface for IRowsetCurrentIndex { type Vtable = IRowsetCurrentIndex_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733abd_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IRowsetCurrentIndex> for ::windows::core::IUnknown { fn from(value: IRowsetCurrentIndex) -> Self { value.0 } } impl ::core::convert::From<&IRowsetCurrentIndex> for ::windows::core::IUnknown { fn from(value: &IRowsetCurrentIndex) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRowsetCurrentIndex { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRowsetCurrentIndex { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } impl ::core::convert::From<IRowsetCurrentIndex> for IRowsetIndex { fn from(value: IRowsetCurrentIndex) -> Self { unsafe { ::core::mem::transmute(value) } } } impl ::core::convert::From<&IRowsetCurrentIndex> for IRowsetIndex { fn from(value: &IRowsetCurrentIndex) -> Self { ::core::convert::From::from(::core::clone::Clone::clone(value)) } } impl<'a> ::windows::core::IntoParam<'a, IRowsetIndex> for IRowsetCurrentIndex { fn into_param(self) -> ::windows::core::Param<'a, IRowsetIndex> { ::windows::core::Param::Owned(unsafe { ::core::mem::transmute(self) }) } } impl<'a> ::windows::core::IntoParam<'a, IRowsetIndex> for &IRowsetCurrentIndex { fn into_param(self) -> ::windows::core::Param<'a, IRowsetIndex> { ::windows::core::Param::Borrowed(unsafe { ::core::mem::transmute(self) }) } } #[repr(C)] #[doc(hidden)] pub struct IRowsetCurrentIndex_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pckeycolumns: *mut usize, prgindexcolumndesc: *mut *mut DBINDEXCOLUMNDESC, pcindexpropertysets: *mut u32, prgindexpropertysets: *mut *mut DBPROPSET) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, haccessor: usize, ckeyvalues: usize, pdata: *mut ::core::ffi::c_void, dwseekoptions: u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, haccessor: usize, cstartkeycolumns: usize, pstartdata: *mut ::core::ffi::c_void, cendkeycolumns: usize, penddata: *mut ::core::ffi::c_void, dwrangeoptions: u32) -> ::windows::core::HRESULT, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppindexid: *mut *mut super::super::Storage::IndexServer::DBID) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pindexid: *mut super::super::Storage::IndexServer::DBID) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRowsetEvents(pub ::windows::core::IUnknown); impl IRowsetEvents { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe fn OnNewItem(&self, itemid: *const super::Com::StructuredStorage::PROPVARIANT, newitemstate: ROWSETEVENT_ITEMSTATE) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(itemid), ::core::mem::transmute(newitemstate)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe fn OnChangedItem(&self, itemid: *const super::Com::StructuredStorage::PROPVARIANT, rowsetitemstate: ROWSETEVENT_ITEMSTATE, changeditemstate: ROWSETEVENT_ITEMSTATE) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(itemid), ::core::mem::transmute(rowsetitemstate), ::core::mem::transmute(changeditemstate)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe fn OnDeletedItem(&self, itemid: *const super::Com::StructuredStorage::PROPVARIANT, deleteditemstate: ROWSETEVENT_ITEMSTATE) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(itemid), ::core::mem::transmute(deleteditemstate)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe fn OnRowsetEvent(&self, eventtype: ROWSETEVENT_TYPE, eventdata: *const super::Com::StructuredStorage::PROPVARIANT) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), ::core::mem::transmute(eventtype), ::core::mem::transmute(eventdata)).ok() } } unsafe impl ::windows::core::Interface for IRowsetEvents { type Vtable = IRowsetEvents_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x1551aea5_5d66_4b11_86f5_d5634cb211b9); } impl ::core::convert::From<IRowsetEvents> for ::windows::core::IUnknown { fn from(value: IRowsetEvents) -> Self { value.0 } } impl ::core::convert::From<&IRowsetEvents> for ::windows::core::IUnknown { fn from(value: &IRowsetEvents) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRowsetEvents { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRowsetEvents { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IRowsetEvents_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, itemid: *const ::core::mem::ManuallyDrop<super::Com::StructuredStorage::PROPVARIANT>, newitemstate: ROWSETEVENT_ITEMSTATE) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, itemid: *const ::core::mem::ManuallyDrop<super::Com::StructuredStorage::PROPVARIANT>, rowsetitemstate: ROWSETEVENT_ITEMSTATE, changeditemstate: ROWSETEVENT_ITEMSTATE) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, itemid: *const ::core::mem::ManuallyDrop<super::Com::StructuredStorage::PROPVARIANT>, deleteditemstate: ROWSETEVENT_ITEMSTATE) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, eventtype: ROWSETEVENT_TYPE, eventdata: *const ::core::mem::ManuallyDrop<super::Com::StructuredStorage::PROPVARIANT>) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage")))] usize, ); #[repr(C)] #[derive(:: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug, :: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy)] pub struct IRowsetExactScroll(pub u8); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRowsetFastLoad(pub ::windows::core::IUnknown); impl IRowsetFastLoad { pub unsafe fn InsertRow(&self, haccessor: usize, pdata: *mut ::core::ffi::c_void) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(haccessor), ::core::mem::transmute(pdata)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn Commit<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>(&self, fdone: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), fdone.into_param().abi()).ok() } } unsafe impl ::windows::core::Interface for IRowsetFastLoad { type Vtable = IRowsetFastLoad_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x5cf4ca13_ef21_11d0_97e7_00c04fc2ad98); } impl ::core::convert::From<IRowsetFastLoad> for ::windows::core::IUnknown { fn from(value: IRowsetFastLoad) -> Self { value.0 } } impl ::core::convert::From<&IRowsetFastLoad> for ::windows::core::IUnknown { fn from(value: &IRowsetFastLoad) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRowsetFastLoad { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRowsetFastLoad { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IRowsetFastLoad_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, haccessor: usize, pdata: *mut ::core::ffi::c_void) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, fdone: super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRowsetFind(pub ::windows::core::IUnknown); impl IRowsetFind { pub unsafe fn FindNextRow(&self, hchapter: usize, haccessor: usize, pfindvalue: *mut ::core::ffi::c_void, compareop: u32, cbbookmark: usize, pbookmark: *const u8, lrowsoffset: isize, crows: isize, pcrowsobtained: *mut usize, prghrows: *mut *mut usize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)( ::core::mem::transmute_copy(self), ::core::mem::transmute(hchapter), ::core::mem::transmute(haccessor), ::core::mem::transmute(pfindvalue), ::core::mem::transmute(compareop), ::core::mem::transmute(cbbookmark), ::core::mem::transmute(pbookmark), ::core::mem::transmute(lrowsoffset), ::core::mem::transmute(crows), ::core::mem::transmute(pcrowsobtained), ::core::mem::transmute(prghrows), ) .ok() } } unsafe impl ::windows::core::Interface for IRowsetFind { type Vtable = IRowsetFind_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a9d_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IRowsetFind> for ::windows::core::IUnknown { fn from(value: IRowsetFind) -> Self { value.0 } } impl ::core::convert::From<&IRowsetFind> for ::windows::core::IUnknown { fn from(value: &IRowsetFind) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRowsetFind { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRowsetFind { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IRowsetFind_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hchapter: usize, haccessor: usize, pfindvalue: *mut ::core::ffi::c_void, compareop: u32, cbbookmark: usize, pbookmark: *const u8, lrowsoffset: isize, crows: isize, pcrowsobtained: *mut usize, prghrows: *mut *mut usize) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRowsetIdentity(pub ::windows::core::IUnknown); impl IRowsetIdentity { pub unsafe fn IsSameRow(&self, hthisrow: usize, hthatrow: usize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(hthisrow), ::core::mem::transmute(hthatrow)).ok() } } unsafe impl ::windows::core::Interface for IRowsetIdentity { type Vtable = IRowsetIdentity_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a09_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IRowsetIdentity> for ::windows::core::IUnknown { fn from(value: IRowsetIdentity) -> Self { value.0 } } impl ::core::convert::From<&IRowsetIdentity> for ::windows::core::IUnknown { fn from(value: &IRowsetIdentity) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRowsetIdentity { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRowsetIdentity { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IRowsetIdentity_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hthisrow: usize, hthatrow: usize) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRowsetIndex(pub ::windows::core::IUnknown); impl IRowsetIndex { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn GetIndexInfo(&self, pckeycolumns: *mut usize, prgindexcolumndesc: *mut *mut DBINDEXCOLUMNDESC, pcindexpropertysets: *mut u32, prgindexpropertysets: *mut *mut DBPROPSET) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(pckeycolumns), ::core::mem::transmute(prgindexcolumndesc), ::core::mem::transmute(pcindexpropertysets), ::core::mem::transmute(prgindexpropertysets)).ok() } pub unsafe fn Seek(&self, haccessor: usize, ckeyvalues: usize, pdata: *mut ::core::ffi::c_void, dwseekoptions: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(haccessor), ::core::mem::transmute(ckeyvalues), ::core::mem::transmute(pdata), ::core::mem::transmute(dwseekoptions)).ok() } pub unsafe fn SetRange(&self, haccessor: usize, cstartkeycolumns: usize, pstartdata: *mut ::core::ffi::c_void, cendkeycolumns: usize, penddata: *mut ::core::ffi::c_void, dwrangeoptions: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(haccessor), ::core::mem::transmute(cstartkeycolumns), ::core::mem::transmute(pstartdata), ::core::mem::transmute(cendkeycolumns), ::core::mem::transmute(penddata), ::core::mem::transmute(dwrangeoptions)).ok() } } unsafe impl ::windows::core::Interface for IRowsetIndex { type Vtable = IRowsetIndex_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a82_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IRowsetIndex> for ::windows::core::IUnknown { fn from(value: IRowsetIndex) -> Self { value.0 } } impl ::core::convert::From<&IRowsetIndex> for ::windows::core::IUnknown { fn from(value: &IRowsetIndex) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRowsetIndex { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRowsetIndex { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IRowsetIndex_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pckeycolumns: *mut usize, prgindexcolumndesc: *mut *mut DBINDEXCOLUMNDESC, pcindexpropertysets: *mut u32, prgindexpropertysets: *mut *mut DBPROPSET) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, haccessor: usize, ckeyvalues: usize, pdata: *mut ::core::ffi::c_void, dwseekoptions: u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, haccessor: usize, cstartkeycolumns: usize, pstartdata: *mut ::core::ffi::c_void, cendkeycolumns: usize, penddata: *mut ::core::ffi::c_void, dwrangeoptions: u32) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRowsetInfo(pub ::windows::core::IUnknown); impl IRowsetInfo { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn GetProperties(&self, cpropertyidsets: u32, rgpropertyidsets: *const DBPROPIDSET, pcpropertysets: *mut u32, prgpropertysets: *mut *mut DBPROPSET) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(cpropertyidsets), ::core::mem::transmute(rgpropertyidsets), ::core::mem::transmute(pcpropertysets), ::core::mem::transmute(prgpropertysets)).ok() } pub unsafe fn GetReferencedRowset(&self, iordinal: usize, riid: *const ::windows::core::GUID) -> ::windows::core::Result<::windows::core::IUnknown> { let mut result__: <::windows::core::IUnknown as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(iordinal), ::core::mem::transmute(riid), &mut result__).from_abi::<::windows::core::IUnknown>(result__) } pub unsafe fn GetSpecification(&self, riid: *const ::windows::core::GUID) -> ::windows::core::Result<::windows::core::IUnknown> { let mut result__: <::windows::core::IUnknown as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(riid), &mut result__).from_abi::<::windows::core::IUnknown>(result__) } } unsafe impl ::windows::core::Interface for IRowsetInfo { type Vtable = IRowsetInfo_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a55_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IRowsetInfo> for ::windows::core::IUnknown { fn from(value: IRowsetInfo) -> Self { value.0 } } impl ::core::convert::From<&IRowsetInfo> for ::windows::core::IUnknown { fn from(value: &IRowsetInfo) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRowsetInfo { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRowsetInfo { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IRowsetInfo_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, cpropertyidsets: u32, rgpropertyidsets: *const DBPROPIDSET, pcpropertysets: *mut u32, prgpropertysets: *mut *mut DBPROPSET) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iordinal: usize, riid: *const ::windows::core::GUID, ppreferencedrowset: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, riid: *const ::windows::core::GUID, ppspecification: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRowsetKeys(pub ::windows::core::IUnknown); impl IRowsetKeys { pub unsafe fn ListKeys(&self, pccolumns: *mut usize, prgcolumns: *mut *mut usize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(pccolumns), ::core::mem::transmute(prgcolumns)).ok() } } unsafe impl ::windows::core::Interface for IRowsetKeys { type Vtable = IRowsetKeys_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a12_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IRowsetKeys> for ::windows::core::IUnknown { fn from(value: IRowsetKeys) -> Self { value.0 } } impl ::core::convert::From<&IRowsetKeys> for ::windows::core::IUnknown { fn from(value: &IRowsetKeys) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRowsetKeys { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRowsetKeys { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IRowsetKeys_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pccolumns: *mut usize, prgcolumns: *mut *mut usize) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRowsetLocate(pub ::windows::core::IUnknown); impl IRowsetLocate { pub unsafe fn AddRefRows(&self, crows: usize, rghrows: *const usize, rgrefcounts: *mut u32, rgrowstatus: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(crows), ::core::mem::transmute(rghrows), ::core::mem::transmute(rgrefcounts), ::core::mem::transmute(rgrowstatus)).ok() } pub unsafe fn GetData(&self, hrow: usize, haccessor: usize, pdata: *mut ::core::ffi::c_void) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(hrow), ::core::mem::transmute(haccessor), ::core::mem::transmute(pdata)).ok() } pub unsafe fn GetNextRows(&self, hreserved: usize, lrowsoffset: isize, crows: isize, pcrowsobtained: *mut usize, prghrows: *mut *mut usize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(hreserved), ::core::mem::transmute(lrowsoffset), ::core::mem::transmute(crows), ::core::mem::transmute(pcrowsobtained), ::core::mem::transmute(prghrows)).ok() } pub unsafe fn ReleaseRows(&self, crows: usize, rghrows: *const usize, rgrowoptions: *mut u32, rgrefcounts: *mut u32, rgrowstatus: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), ::core::mem::transmute(crows), ::core::mem::transmute(rghrows), ::core::mem::transmute(rgrowoptions), ::core::mem::transmute(rgrefcounts), ::core::mem::transmute(rgrowstatus)).ok() } pub unsafe fn RestartPosition(&self, hreserved: usize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), ::core::mem::transmute(hreserved)).ok() } pub unsafe fn Compare(&self, hreserved: usize, cbbookmark1: usize, pbookmark1: *const u8, cbbookmark2: usize, pbookmark2: *const u8, pcomparison: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).8)(::core::mem::transmute_copy(self), ::core::mem::transmute(hreserved), ::core::mem::transmute(cbbookmark1), ::core::mem::transmute(pbookmark1), ::core::mem::transmute(cbbookmark2), ::core::mem::transmute(pbookmark2), ::core::mem::transmute(pcomparison)).ok() } pub unsafe fn GetRowsAt(&self, hreserved1: usize, hreserved2: usize, cbbookmark: usize, pbookmark: *const u8, lrowsoffset: isize, crows: isize, pcrowsobtained: *mut usize, prghrows: *mut *mut usize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).9)( ::core::mem::transmute_copy(self), ::core::mem::transmute(hreserved1), ::core::mem::transmute(hreserved2), ::core::mem::transmute(cbbookmark), ::core::mem::transmute(pbookmark), ::core::mem::transmute(lrowsoffset), ::core::mem::transmute(crows), ::core::mem::transmute(pcrowsobtained), ::core::mem::transmute(prghrows), ) .ok() } pub unsafe fn GetRowsByBookmark(&self, hreserved: usize, crows: usize, rgcbbookmarks: *const usize, rgpbookmarks: *const *const u8, rghrows: *mut usize, rgrowstatus: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).10)(::core::mem::transmute_copy(self), ::core::mem::transmute(hreserved), ::core::mem::transmute(crows), ::core::mem::transmute(rgcbbookmarks), ::core::mem::transmute(rgpbookmarks), ::core::mem::transmute(rghrows), ::core::mem::transmute(rgrowstatus)).ok() } pub unsafe fn Hash(&self, hreserved: usize, cbookmarks: usize, rgcbbookmarks: *const usize, rgpbookmarks: *const *const u8, rghashedvalues: *mut usize, rgbookmarkstatus: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).11)(::core::mem::transmute_copy(self), ::core::mem::transmute(hreserved), ::core::mem::transmute(cbookmarks), ::core::mem::transmute(rgcbbookmarks), ::core::mem::transmute(rgpbookmarks), ::core::mem::transmute(rghashedvalues), ::core::mem::transmute(rgbookmarkstatus)).ok() } } unsafe impl ::windows::core::Interface for IRowsetLocate { type Vtable = IRowsetLocate_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a7d_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IRowsetLocate> for ::windows::core::IUnknown { fn from(value: IRowsetLocate) -> Self { value.0 } } impl ::core::convert::From<&IRowsetLocate> for ::windows::core::IUnknown { fn from(value: &IRowsetLocate) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRowsetLocate { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRowsetLocate { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } impl ::core::convert::From<IRowsetLocate> for IRowset { fn from(value: IRowsetLocate) -> Self { unsafe { ::core::mem::transmute(value) } } } impl ::core::convert::From<&IRowsetLocate> for IRowset { fn from(value: &IRowsetLocate) -> Self { ::core::convert::From::from(::core::clone::Clone::clone(value)) } } impl<'a> ::windows::core::IntoParam<'a, IRowset> for IRowsetLocate { fn into_param(self) -> ::windows::core::Param<'a, IRowset> { ::windows::core::Param::Owned(unsafe { ::core::mem::transmute(self) }) } } impl<'a> ::windows::core::IntoParam<'a, IRowset> for &IRowsetLocate { fn into_param(self) -> ::windows::core::Param<'a, IRowset> { ::windows::core::Param::Borrowed(unsafe { ::core::mem::transmute(self) }) } } #[repr(C)] #[doc(hidden)] pub struct IRowsetLocate_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, crows: usize, rghrows: *const usize, rgrefcounts: *mut u32, rgrowstatus: *mut u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hrow: usize, haccessor: usize, pdata: *mut ::core::ffi::c_void) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hreserved: usize, lrowsoffset: isize, crows: isize, pcrowsobtained: *mut usize, prghrows: *mut *mut usize) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, crows: usize, rghrows: *const usize, rgrowoptions: *mut u32, rgrefcounts: *mut u32, rgrowstatus: *mut u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hreserved: usize) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hreserved: usize, cbbookmark1: usize, pbookmark1: *const u8, cbbookmark2: usize, pbookmark2: *const u8, pcomparison: *mut u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hreserved1: usize, hreserved2: usize, cbbookmark: usize, pbookmark: *const u8, lrowsoffset: isize, crows: isize, pcrowsobtained: *mut usize, prghrows: *mut *mut usize) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hreserved: usize, crows: usize, rgcbbookmarks: *const usize, rgpbookmarks: *const *const u8, rghrows: *mut usize, rgrowstatus: *mut u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hreserved: usize, cbookmarks: usize, rgcbbookmarks: *const usize, rgpbookmarks: *const *const u8, rghashedvalues: *mut usize, rgbookmarkstatus: *mut u32) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRowsetNewRowAfter(pub ::windows::core::IUnknown); impl IRowsetNewRowAfter { pub unsafe fn SetNewDataAfter(&self, hchapter: usize, cbbmprevious: u32, pbmprevious: *const u8, haccessor: usize, pdata: *mut u8, phrow: *mut usize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(hchapter), ::core::mem::transmute(cbbmprevious), ::core::mem::transmute(pbmprevious), ::core::mem::transmute(haccessor), ::core::mem::transmute(pdata), ::core::mem::transmute(phrow)).ok() } } unsafe impl ::windows::core::Interface for IRowsetNewRowAfter { type Vtable = IRowsetNewRowAfter_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a71_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IRowsetNewRowAfter> for ::windows::core::IUnknown { fn from(value: IRowsetNewRowAfter) -> Self { value.0 } } impl ::core::convert::From<&IRowsetNewRowAfter> for ::windows::core::IUnknown { fn from(value: &IRowsetNewRowAfter) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRowsetNewRowAfter { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRowsetNewRowAfter { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IRowsetNewRowAfter_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hchapter: usize, cbbmprevious: u32, pbmprevious: *const u8, haccessor: usize, pdata: *mut u8, phrow: *mut usize) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRowsetNextRowset(pub ::windows::core::IUnknown); impl IRowsetNextRowset { pub unsafe fn GetNextRowset<'a, Param0: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>>(&self, punkouter: Param0, riid: *const ::windows::core::GUID) -> ::windows::core::Result<::windows::core::IUnknown> { let mut result__: <::windows::core::IUnknown as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), punkouter.into_param().abi(), ::core::mem::transmute(riid), &mut result__).from_abi::<::windows::core::IUnknown>(result__) } } unsafe impl ::windows::core::Interface for IRowsetNextRowset { type Vtable = IRowsetNextRowset_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a72_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IRowsetNextRowset> for ::windows::core::IUnknown { fn from(value: IRowsetNextRowset) -> Self { value.0 } } impl ::core::convert::From<&IRowsetNextRowset> for ::windows::core::IUnknown { fn from(value: &IRowsetNextRowset) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRowsetNextRowset { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRowsetNextRowset { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IRowsetNextRowset_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, punkouter: ::windows::core::RawPtr, riid: *const ::windows::core::GUID, ppnextrowset: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRowsetNotify(pub ::windows::core::IUnknown); impl IRowsetNotify { #[cfg(feature = "Win32_Foundation")] pub unsafe fn OnFieldChange<'a, Param0: ::windows::core::IntoParam<'a, IRowset>, Param6: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>(&self, prowset: Param0, hrow: usize, ccolumns: usize, rgcolumns: *const usize, ereason: u32, ephase: u32, fcantdeny: Param6) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), prowset.into_param().abi(), ::core::mem::transmute(hrow), ::core::mem::transmute(ccolumns), ::core::mem::transmute(rgcolumns), ::core::mem::transmute(ereason), ::core::mem::transmute(ephase), fcantdeny.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn OnRowChange<'a, Param0: ::windows::core::IntoParam<'a, IRowset>, Param5: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>(&self, prowset: Param0, crows: usize, rghrows: *const usize, ereason: u32, ephase: u32, fcantdeny: Param5) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), prowset.into_param().abi(), ::core::mem::transmute(crows), ::core::mem::transmute(rghrows), ::core::mem::transmute(ereason), ::core::mem::transmute(ephase), fcantdeny.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn OnRowsetChange<'a, Param0: ::windows::core::IntoParam<'a, IRowset>, Param3: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>(&self, prowset: Param0, ereason: u32, ephase: u32, fcantdeny: Param3) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), prowset.into_param().abi(), ::core::mem::transmute(ereason), ::core::mem::transmute(ephase), fcantdeny.into_param().abi()).ok() } } unsafe impl ::windows::core::Interface for IRowsetNotify { type Vtable = IRowsetNotify_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a83_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IRowsetNotify> for ::windows::core::IUnknown { fn from(value: IRowsetNotify) -> Self { value.0 } } impl ::core::convert::From<&IRowsetNotify> for ::windows::core::IUnknown { fn from(value: &IRowsetNotify) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRowsetNotify { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRowsetNotify { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IRowsetNotify_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, prowset: ::windows::core::RawPtr, hrow: usize, ccolumns: usize, rgcolumns: *const usize, ereason: u32, ephase: u32, fcantdeny: super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, prowset: ::windows::core::RawPtr, crows: usize, rghrows: *const usize, ereason: u32, ephase: u32, fcantdeny: super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, prowset: ::windows::core::RawPtr, ereason: u32, ephase: u32, fcantdeny: super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRowsetPrioritization(pub ::windows::core::IUnknown); impl IRowsetPrioritization { pub unsafe fn SetScopePriority(&self, priority: PRIORITY_LEVEL, scopestatisticseventfrequency: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(priority), ::core::mem::transmute(scopestatisticseventfrequency)).ok() } pub unsafe fn GetScopePriority(&self, priority: *mut PRIORITY_LEVEL, scopestatisticseventfrequency: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(priority), ::core::mem::transmute(scopestatisticseventfrequency)).ok() } pub unsafe fn GetScopeStatistics(&self, indexeddocumentcount: *mut u32, oustandingaddcount: *mut u32, oustandingmodifycount: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(indexeddocumentcount), ::core::mem::transmute(oustandingaddcount), ::core::mem::transmute(oustandingmodifycount)).ok() } } unsafe impl ::windows::core::Interface for IRowsetPrioritization { type Vtable = IRowsetPrioritization_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x42811652_079d_481b_87a2_09a69ecc5f44); } impl ::core::convert::From<IRowsetPrioritization> for ::windows::core::IUnknown { fn from(value: IRowsetPrioritization) -> Self { value.0 } } impl ::core::convert::From<&IRowsetPrioritization> for ::windows::core::IUnknown { fn from(value: &IRowsetPrioritization) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRowsetPrioritization { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRowsetPrioritization { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IRowsetPrioritization_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, priority: PRIORITY_LEVEL, scopestatisticseventfrequency: u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, priority: *mut PRIORITY_LEVEL, scopestatisticseventfrequency: *mut u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, indexeddocumentcount: *mut u32, oustandingaddcount: *mut u32, oustandingmodifycount: *mut u32) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRowsetQueryStatus(pub ::windows::core::IUnknown); impl IRowsetQueryStatus { pub unsafe fn GetStatus(&self, pdwstatus: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(pdwstatus)).ok() } pub unsafe fn GetStatusEx(&self, pdwstatus: *mut u32, pcfiltereddocuments: *mut u32, pcdocumentstofilter: *mut u32, pdwratiofinisheddenominator: *mut usize, pdwratiofinishednumerator: *mut usize, cbbmk: usize, pbmk: *const u8, pirowbmk: *mut usize, pcrowstotal: *mut usize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)( ::core::mem::transmute_copy(self), ::core::mem::transmute(pdwstatus), ::core::mem::transmute(pcfiltereddocuments), ::core::mem::transmute(pcdocumentstofilter), ::core::mem::transmute(pdwratiofinisheddenominator), ::core::mem::transmute(pdwratiofinishednumerator), ::core::mem::transmute(cbbmk), ::core::mem::transmute(pbmk), ::core::mem::transmute(pirowbmk), ::core::mem::transmute(pcrowstotal), ) .ok() } } unsafe impl ::windows::core::Interface for IRowsetQueryStatus { type Vtable = IRowsetQueryStatus_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xa7ac77ed_f8d7_11ce_a798_0020f8008024); } impl ::core::convert::From<IRowsetQueryStatus> for ::windows::core::IUnknown { fn from(value: IRowsetQueryStatus) -> Self { value.0 } } impl ::core::convert::From<&IRowsetQueryStatus> for ::windows::core::IUnknown { fn from(value: &IRowsetQueryStatus) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRowsetQueryStatus { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRowsetQueryStatus { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IRowsetQueryStatus_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pdwstatus: *mut u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pdwstatus: *mut u32, pcfiltereddocuments: *mut u32, pcdocumentstofilter: *mut u32, pdwratiofinisheddenominator: *mut usize, pdwratiofinishednumerator: *mut usize, cbbmk: usize, pbmk: *const u8, pirowbmk: *mut usize, pcrowstotal: *mut usize) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRowsetRefresh(pub ::windows::core::IUnknown); impl IRowsetRefresh { #[cfg(feature = "Win32_Foundation")] pub unsafe fn RefreshVisibleData<'a, Param3: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>(&self, hchapter: usize, crows: usize, rghrows: *const usize, foverwrite: Param3, pcrowsrefreshed: *mut usize, prghrowsrefreshed: *mut *mut usize, prgrowstatus: *mut *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(hchapter), ::core::mem::transmute(crows), ::core::mem::transmute(rghrows), foverwrite.into_param().abi(), ::core::mem::transmute(pcrowsrefreshed), ::core::mem::transmute(prghrowsrefreshed), ::core::mem::transmute(prgrowstatus)).ok() } pub unsafe fn GetLastVisibleData(&self, hrow: usize, haccessor: usize, pdata: *mut ::core::ffi::c_void) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(hrow), ::core::mem::transmute(haccessor), ::core::mem::transmute(pdata)).ok() } } unsafe impl ::windows::core::Interface for IRowsetRefresh { type Vtable = IRowsetRefresh_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733aa9_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IRowsetRefresh> for ::windows::core::IUnknown { fn from(value: IRowsetRefresh) -> Self { value.0 } } impl ::core::convert::From<&IRowsetRefresh> for ::windows::core::IUnknown { fn from(value: &IRowsetRefresh) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRowsetRefresh { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRowsetRefresh { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IRowsetRefresh_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hchapter: usize, crows: usize, rghrows: *const usize, foverwrite: super::super::Foundation::BOOL, pcrowsrefreshed: *mut usize, prghrowsrefreshed: *mut *mut usize, prgrowstatus: *mut *mut u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hrow: usize, haccessor: usize, pdata: *mut ::core::ffi::c_void) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRowsetResynch(pub ::windows::core::IUnknown); impl IRowsetResynch { pub unsafe fn GetVisibleData(&self, hrow: usize, haccessor: usize, pdata: *mut ::core::ffi::c_void) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(hrow), ::core::mem::transmute(haccessor), ::core::mem::transmute(pdata)).ok() } pub unsafe fn ResynchRows(&self, crows: usize, rghrows: *const usize, pcrowsresynched: *mut usize, prghrowsresynched: *mut *mut usize, prgrowstatus: *mut *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(crows), ::core::mem::transmute(rghrows), ::core::mem::transmute(pcrowsresynched), ::core::mem::transmute(prghrowsresynched), ::core::mem::transmute(prgrowstatus)).ok() } } unsafe impl ::windows::core::Interface for IRowsetResynch { type Vtable = IRowsetResynch_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a84_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IRowsetResynch> for ::windows::core::IUnknown { fn from(value: IRowsetResynch) -> Self { value.0 } } impl ::core::convert::From<&IRowsetResynch> for ::windows::core::IUnknown { fn from(value: &IRowsetResynch) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRowsetResynch { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRowsetResynch { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IRowsetResynch_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hrow: usize, haccessor: usize, pdata: *mut ::core::ffi::c_void) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, crows: usize, rghrows: *const usize, pcrowsresynched: *mut usize, prghrowsresynched: *mut *mut usize, prgrowstatus: *mut *mut u32) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRowsetScroll(pub ::windows::core::IUnknown); impl IRowsetScroll { pub unsafe fn AddRefRows(&self, crows: usize, rghrows: *const usize, rgrefcounts: *mut u32, rgrowstatus: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(crows), ::core::mem::transmute(rghrows), ::core::mem::transmute(rgrefcounts), ::core::mem::transmute(rgrowstatus)).ok() } pub unsafe fn GetData(&self, hrow: usize, haccessor: usize, pdata: *mut ::core::ffi::c_void) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(hrow), ::core::mem::transmute(haccessor), ::core::mem::transmute(pdata)).ok() } pub unsafe fn GetNextRows(&self, hreserved: usize, lrowsoffset: isize, crows: isize, pcrowsobtained: *mut usize, prghrows: *mut *mut usize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(hreserved), ::core::mem::transmute(lrowsoffset), ::core::mem::transmute(crows), ::core::mem::transmute(pcrowsobtained), ::core::mem::transmute(prghrows)).ok() } pub unsafe fn ReleaseRows(&self, crows: usize, rghrows: *const usize, rgrowoptions: *mut u32, rgrefcounts: *mut u32, rgrowstatus: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), ::core::mem::transmute(crows), ::core::mem::transmute(rghrows), ::core::mem::transmute(rgrowoptions), ::core::mem::transmute(rgrefcounts), ::core::mem::transmute(rgrowstatus)).ok() } pub unsafe fn RestartPosition(&self, hreserved: usize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), ::core::mem::transmute(hreserved)).ok() } pub unsafe fn Compare(&self, hreserved: usize, cbbookmark1: usize, pbookmark1: *const u8, cbbookmark2: usize, pbookmark2: *const u8, pcomparison: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).8)(::core::mem::transmute_copy(self), ::core::mem::transmute(hreserved), ::core::mem::transmute(cbbookmark1), ::core::mem::transmute(pbookmark1), ::core::mem::transmute(cbbookmark2), ::core::mem::transmute(pbookmark2), ::core::mem::transmute(pcomparison)).ok() } pub unsafe fn GetRowsAt(&self, hreserved1: usize, hreserved2: usize, cbbookmark: usize, pbookmark: *const u8, lrowsoffset: isize, crows: isize, pcrowsobtained: *mut usize, prghrows: *mut *mut usize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).9)( ::core::mem::transmute_copy(self), ::core::mem::transmute(hreserved1), ::core::mem::transmute(hreserved2), ::core::mem::transmute(cbbookmark), ::core::mem::transmute(pbookmark), ::core::mem::transmute(lrowsoffset), ::core::mem::transmute(crows), ::core::mem::transmute(pcrowsobtained), ::core::mem::transmute(prghrows), ) .ok() } pub unsafe fn GetRowsByBookmark(&self, hreserved: usize, crows: usize, rgcbbookmarks: *const usize, rgpbookmarks: *const *const u8, rghrows: *mut usize, rgrowstatus: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).10)(::core::mem::transmute_copy(self), ::core::mem::transmute(hreserved), ::core::mem::transmute(crows), ::core::mem::transmute(rgcbbookmarks), ::core::mem::transmute(rgpbookmarks), ::core::mem::transmute(rghrows), ::core::mem::transmute(rgrowstatus)).ok() } pub unsafe fn Hash(&self, hreserved: usize, cbookmarks: usize, rgcbbookmarks: *const usize, rgpbookmarks: *const *const u8, rghashedvalues: *mut usize, rgbookmarkstatus: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).11)(::core::mem::transmute_copy(self), ::core::mem::transmute(hreserved), ::core::mem::transmute(cbookmarks), ::core::mem::transmute(rgcbbookmarks), ::core::mem::transmute(rgpbookmarks), ::core::mem::transmute(rghashedvalues), ::core::mem::transmute(rgbookmarkstatus)).ok() } pub unsafe fn GetApproximatePosition(&self, hreserved: usize, cbbookmark: usize, pbookmark: *const u8, pulposition: *mut usize, pcrows: *mut usize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).12)(::core::mem::transmute_copy(self), ::core::mem::transmute(hreserved), ::core::mem::transmute(cbbookmark), ::core::mem::transmute(pbookmark), ::core::mem::transmute(pulposition), ::core::mem::transmute(pcrows)).ok() } pub unsafe fn GetRowsAtRatio(&self, hreserved1: usize, hreserved2: usize, ulnumerator: usize, uldenominator: usize, crows: isize, pcrowsobtained: *mut usize, prghrows: *mut *mut usize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).13)(::core::mem::transmute_copy(self), ::core::mem::transmute(hreserved1), ::core::mem::transmute(hreserved2), ::core::mem::transmute(ulnumerator), ::core::mem::transmute(uldenominator), ::core::mem::transmute(crows), ::core::mem::transmute(pcrowsobtained), ::core::mem::transmute(prghrows)).ok() } } unsafe impl ::windows::core::Interface for IRowsetScroll { type Vtable = IRowsetScroll_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a7e_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IRowsetScroll> for ::windows::core::IUnknown { fn from(value: IRowsetScroll) -> Self { value.0 } } impl ::core::convert::From<&IRowsetScroll> for ::windows::core::IUnknown { fn from(value: &IRowsetScroll) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRowsetScroll { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRowsetScroll { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } impl ::core::convert::From<IRowsetScroll> for IRowsetLocate { fn from(value: IRowsetScroll) -> Self { unsafe { ::core::mem::transmute(value) } } } impl ::core::convert::From<&IRowsetScroll> for IRowsetLocate { fn from(value: &IRowsetScroll) -> Self { ::core::convert::From::from(::core::clone::Clone::clone(value)) } } impl<'a> ::windows::core::IntoParam<'a, IRowsetLocate> for IRowsetScroll { fn into_param(self) -> ::windows::core::Param<'a, IRowsetLocate> { ::windows::core::Param::Owned(unsafe { ::core::mem::transmute(self) }) } } impl<'a> ::windows::core::IntoParam<'a, IRowsetLocate> for &IRowsetScroll { fn into_param(self) -> ::windows::core::Param<'a, IRowsetLocate> { ::windows::core::Param::Borrowed(unsafe { ::core::mem::transmute(self) }) } } impl ::core::convert::From<IRowsetScroll> for IRowset { fn from(value: IRowsetScroll) -> Self { unsafe { ::core::mem::transmute(value) } } } impl ::core::convert::From<&IRowsetScroll> for IRowset { fn from(value: &IRowsetScroll) -> Self { ::core::convert::From::from(::core::clone::Clone::clone(value)) } } impl<'a> ::windows::core::IntoParam<'a, IRowset> for IRowsetScroll { fn into_param(self) -> ::windows::core::Param<'a, IRowset> { ::windows::core::Param::Owned(unsafe { ::core::mem::transmute(self) }) } } impl<'a> ::windows::core::IntoParam<'a, IRowset> for &IRowsetScroll { fn into_param(self) -> ::windows::core::Param<'a, IRowset> { ::windows::core::Param::Borrowed(unsafe { ::core::mem::transmute(self) }) } } #[repr(C)] #[doc(hidden)] pub struct IRowsetScroll_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, crows: usize, rghrows: *const usize, rgrefcounts: *mut u32, rgrowstatus: *mut u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hrow: usize, haccessor: usize, pdata: *mut ::core::ffi::c_void) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hreserved: usize, lrowsoffset: isize, crows: isize, pcrowsobtained: *mut usize, prghrows: *mut *mut usize) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, crows: usize, rghrows: *const usize, rgrowoptions: *mut u32, rgrefcounts: *mut u32, rgrowstatus: *mut u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hreserved: usize) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hreserved: usize, cbbookmark1: usize, pbookmark1: *const u8, cbbookmark2: usize, pbookmark2: *const u8, pcomparison: *mut u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hreserved1: usize, hreserved2: usize, cbbookmark: usize, pbookmark: *const u8, lrowsoffset: isize, crows: isize, pcrowsobtained: *mut usize, prghrows: *mut *mut usize) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hreserved: usize, crows: usize, rgcbbookmarks: *const usize, rgpbookmarks: *const *const u8, rghrows: *mut usize, rgrowstatus: *mut u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hreserved: usize, cbookmarks: usize, rgcbbookmarks: *const usize, rgpbookmarks: *const *const u8, rghashedvalues: *mut usize, rgbookmarkstatus: *mut u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hreserved: usize, cbbookmark: usize, pbookmark: *const u8, pulposition: *mut usize, pcrows: *mut usize) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hreserved1: usize, hreserved2: usize, ulnumerator: usize, uldenominator: usize, crows: isize, pcrowsobtained: *mut usize, prghrows: *mut *mut usize) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRowsetUpdate(pub ::windows::core::IUnknown); impl IRowsetUpdate { pub unsafe fn DeleteRows(&self, hreserved: usize, crows: usize, rghrows: *const usize, rgrowstatus: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(hreserved), ::core::mem::transmute(crows), ::core::mem::transmute(rghrows), ::core::mem::transmute(rgrowstatus)).ok() } pub unsafe fn SetData(&self, hrow: usize, haccessor: usize, pdata: *mut ::core::ffi::c_void) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(hrow), ::core::mem::transmute(haccessor), ::core::mem::transmute(pdata)).ok() } pub unsafe fn InsertRow(&self, hreserved: usize, haccessor: usize, pdata: *mut ::core::ffi::c_void, phrow: *mut usize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(hreserved), ::core::mem::transmute(haccessor), ::core::mem::transmute(pdata), ::core::mem::transmute(phrow)).ok() } pub unsafe fn GetOriginalData(&self, hrow: usize, haccessor: usize, pdata: *mut ::core::ffi::c_void) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), ::core::mem::transmute(hrow), ::core::mem::transmute(haccessor), ::core::mem::transmute(pdata)).ok() } pub unsafe fn GetPendingRows(&self, hreserved: usize, dwrowstatus: u32, pcpendingrows: *mut usize, prgpendingrows: *mut *mut usize, prgpendingstatus: *mut *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), ::core::mem::transmute(hreserved), ::core::mem::transmute(dwrowstatus), ::core::mem::transmute(pcpendingrows), ::core::mem::transmute(prgpendingrows), ::core::mem::transmute(prgpendingstatus)).ok() } pub unsafe fn GetRowStatus(&self, hreserved: usize, crows: usize, rghrows: *const usize, rgpendingstatus: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).8)(::core::mem::transmute_copy(self), ::core::mem::transmute(hreserved), ::core::mem::transmute(crows), ::core::mem::transmute(rghrows), ::core::mem::transmute(rgpendingstatus)).ok() } pub unsafe fn Undo(&self, hreserved: usize, crows: usize, rghrows: *const usize, pcrowsundone: *mut usize, prgrowsundone: *mut *mut usize, prgrowstatus: *mut *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).9)(::core::mem::transmute_copy(self), ::core::mem::transmute(hreserved), ::core::mem::transmute(crows), ::core::mem::transmute(rghrows), ::core::mem::transmute(pcrowsundone), ::core::mem::transmute(prgrowsundone), ::core::mem::transmute(prgrowstatus)).ok() } pub unsafe fn Update(&self, hreserved: usize, crows: usize, rghrows: *const usize, pcrows: *mut usize, prgrows: *mut *mut usize, prgrowstatus: *mut *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).10)(::core::mem::transmute_copy(self), ::core::mem::transmute(hreserved), ::core::mem::transmute(crows), ::core::mem::transmute(rghrows), ::core::mem::transmute(pcrows), ::core::mem::transmute(prgrows), ::core::mem::transmute(prgrowstatus)).ok() } } unsafe impl ::windows::core::Interface for IRowsetUpdate { type Vtable = IRowsetUpdate_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a6d_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IRowsetUpdate> for ::windows::core::IUnknown { fn from(value: IRowsetUpdate) -> Self { value.0 } } impl ::core::convert::From<&IRowsetUpdate> for ::windows::core::IUnknown { fn from(value: &IRowsetUpdate) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRowsetUpdate { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRowsetUpdate { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } impl ::core::convert::From<IRowsetUpdate> for IRowsetChange { fn from(value: IRowsetUpdate) -> Self { unsafe { ::core::mem::transmute(value) } } } impl ::core::convert::From<&IRowsetUpdate> for IRowsetChange { fn from(value: &IRowsetUpdate) -> Self { ::core::convert::From::from(::core::clone::Clone::clone(value)) } } impl<'a> ::windows::core::IntoParam<'a, IRowsetChange> for IRowsetUpdate { fn into_param(self) -> ::windows::core::Param<'a, IRowsetChange> { ::windows::core::Param::Owned(unsafe { ::core::mem::transmute(self) }) } } impl<'a> ::windows::core::IntoParam<'a, IRowsetChange> for &IRowsetUpdate { fn into_param(self) -> ::windows::core::Param<'a, IRowsetChange> { ::windows::core::Param::Borrowed(unsafe { ::core::mem::transmute(self) }) } } #[repr(C)] #[doc(hidden)] pub struct IRowsetUpdate_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hreserved: usize, crows: usize, rghrows: *const usize, rgrowstatus: *mut u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hrow: usize, haccessor: usize, pdata: *mut ::core::ffi::c_void) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hreserved: usize, haccessor: usize, pdata: *mut ::core::ffi::c_void, phrow: *mut usize) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hrow: usize, haccessor: usize, pdata: *mut ::core::ffi::c_void) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hreserved: usize, dwrowstatus: u32, pcpendingrows: *mut usize, prgpendingrows: *mut *mut usize, prgpendingstatus: *mut *mut u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hreserved: usize, crows: usize, rghrows: *const usize, rgpendingstatus: *mut u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hreserved: usize, crows: usize, rghrows: *const usize, pcrowsundone: *mut usize, prgrowsundone: *mut *mut usize, prgrowstatus: *mut *mut u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hreserved: usize, crows: usize, rghrows: *const usize, pcrows: *mut usize, prgrows: *mut *mut usize, prgrowstatus: *mut *mut u32) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRowsetView(pub ::windows::core::IUnknown); impl IRowsetView { pub unsafe fn CreateView<'a, Param0: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>>(&self, punkouter: Param0, riid: *const ::windows::core::GUID) -> ::windows::core::Result<::windows::core::IUnknown> { let mut result__: <::windows::core::IUnknown as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), punkouter.into_param().abi(), ::core::mem::transmute(riid), &mut result__).from_abi::<::windows::core::IUnknown>(result__) } pub unsafe fn GetView(&self, hchapter: usize, riid: *const ::windows::core::GUID, phchaptersource: *mut usize, ppview: *mut ::core::option::Option<::windows::core::IUnknown>) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(hchapter), ::core::mem::transmute(riid), ::core::mem::transmute(phchaptersource), ::core::mem::transmute(ppview)).ok() } } unsafe impl ::windows::core::Interface for IRowsetView { type Vtable = IRowsetView_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a99_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IRowsetView> for ::windows::core::IUnknown { fn from(value: IRowsetView) -> Self { value.0 } } impl ::core::convert::From<&IRowsetView> for ::windows::core::IUnknown { fn from(value: &IRowsetView) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRowsetView { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRowsetView { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IRowsetView_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, punkouter: ::windows::core::RawPtr, riid: *const ::windows::core::GUID, ppview: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hchapter: usize, riid: *const ::windows::core::GUID, phchaptersource: *mut usize, ppview: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRowsetWatchAll(pub ::windows::core::IUnknown); impl IRowsetWatchAll { pub unsafe fn Acknowledge(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self)).ok() } pub unsafe fn Start(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self)).ok() } pub unsafe fn StopWatching(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self)).ok() } } unsafe impl ::windows::core::Interface for IRowsetWatchAll { type Vtable = IRowsetWatchAll_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a73_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IRowsetWatchAll> for ::windows::core::IUnknown { fn from(value: IRowsetWatchAll) -> Self { value.0 } } impl ::core::convert::From<&IRowsetWatchAll> for ::windows::core::IUnknown { fn from(value: &IRowsetWatchAll) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRowsetWatchAll { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRowsetWatchAll { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IRowsetWatchAll_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRowsetWatchNotify(pub ::windows::core::IUnknown); impl IRowsetWatchNotify { pub unsafe fn OnChange<'a, Param0: ::windows::core::IntoParam<'a, IRowset>>(&self, prowset: Param0, echangereason: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), prowset.into_param().abi(), ::core::mem::transmute(echangereason)).ok() } } unsafe impl ::windows::core::Interface for IRowsetWatchNotify { type Vtable = IRowsetWatchNotify_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a44_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IRowsetWatchNotify> for ::windows::core::IUnknown { fn from(value: IRowsetWatchNotify) -> Self { value.0 } } impl ::core::convert::From<&IRowsetWatchNotify> for ::windows::core::IUnknown { fn from(value: &IRowsetWatchNotify) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRowsetWatchNotify { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRowsetWatchNotify { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IRowsetWatchNotify_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, prowset: ::windows::core::RawPtr, echangereason: u32) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRowsetWatchRegion(pub ::windows::core::IUnknown); impl IRowsetWatchRegion { pub unsafe fn Acknowledge(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self)).ok() } pub unsafe fn Start(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self)).ok() } pub unsafe fn StopWatching(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self)).ok() } pub unsafe fn CreateWatchRegion(&self, dwwatchmode: u32, phregion: *mut usize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), ::core::mem::transmute(dwwatchmode), ::core::mem::transmute(phregion)).ok() } pub unsafe fn ChangeWatchMode(&self, hregion: usize, dwwatchmode: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), ::core::mem::transmute(hregion), ::core::mem::transmute(dwwatchmode)).ok() } pub unsafe fn DeleteWatchRegion(&self, hregion: usize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).8)(::core::mem::transmute_copy(self), ::core::mem::transmute(hregion)).ok() } pub unsafe fn GetWatchRegionInfo(&self, hregion: usize, pdwwatchmode: *mut u32, phchapter: *mut usize, pcbbookmark: *mut usize, ppbookmark: *mut *mut u8, pcrows: *mut isize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).9)(::core::mem::transmute_copy(self), ::core::mem::transmute(hregion), ::core::mem::transmute(pdwwatchmode), ::core::mem::transmute(phchapter), ::core::mem::transmute(pcbbookmark), ::core::mem::transmute(ppbookmark), ::core::mem::transmute(pcrows)).ok() } pub unsafe fn Refresh(&self, pcchangesobtained: *mut usize, prgchanges: *mut *mut tagDBROWWATCHRANGE) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).10)(::core::mem::transmute_copy(self), ::core::mem::transmute(pcchangesobtained), ::core::mem::transmute(prgchanges)).ok() } pub unsafe fn ShrinkWatchRegion(&self, hregion: usize, hchapter: usize, cbbookmark: usize, pbookmark: *mut u8, crows: isize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).11)(::core::mem::transmute_copy(self), ::core::mem::transmute(hregion), ::core::mem::transmute(hchapter), ::core::mem::transmute(cbbookmark), ::core::mem::transmute(pbookmark), ::core::mem::transmute(crows)).ok() } } unsafe impl ::windows::core::Interface for IRowsetWatchRegion { type Vtable = IRowsetWatchRegion_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a45_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IRowsetWatchRegion> for ::windows::core::IUnknown { fn from(value: IRowsetWatchRegion) -> Self { value.0 } } impl ::core::convert::From<&IRowsetWatchRegion> for ::windows::core::IUnknown { fn from(value: &IRowsetWatchRegion) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRowsetWatchRegion { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRowsetWatchRegion { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } impl ::core::convert::From<IRowsetWatchRegion> for IRowsetWatchAll { fn from(value: IRowsetWatchRegion) -> Self { unsafe { ::core::mem::transmute(value) } } } impl ::core::convert::From<&IRowsetWatchRegion> for IRowsetWatchAll { fn from(value: &IRowsetWatchRegion) -> Self { ::core::convert::From::from(::core::clone::Clone::clone(value)) } } impl<'a> ::windows::core::IntoParam<'a, IRowsetWatchAll> for IRowsetWatchRegion { fn into_param(self) -> ::windows::core::Param<'a, IRowsetWatchAll> { ::windows::core::Param::Owned(unsafe { ::core::mem::transmute(self) }) } } impl<'a> ::windows::core::IntoParam<'a, IRowsetWatchAll> for &IRowsetWatchRegion { fn into_param(self) -> ::windows::core::Param<'a, IRowsetWatchAll> { ::windows::core::Param::Borrowed(unsafe { ::core::mem::transmute(self) }) } } #[repr(C)] #[doc(hidden)] pub struct IRowsetWatchRegion_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, dwwatchmode: u32, phregion: *mut usize) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hregion: usize, dwwatchmode: u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hregion: usize) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hregion: usize, pdwwatchmode: *mut u32, phchapter: *mut usize, pcbbookmark: *mut usize, ppbookmark: *mut *mut u8, pcrows: *mut isize) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pcchangesobtained: *mut usize, prgchanges: *mut *mut tagDBROWWATCHRANGE) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hregion: usize, hchapter: usize, cbbookmark: usize, pbookmark: *mut u8, crows: isize) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IRowsetWithParameters(pub ::windows::core::IUnknown); impl IRowsetWithParameters { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub unsafe fn GetParameterInfo(&self, pcparams: *mut usize, prgparaminfo: *mut *mut DBPARAMINFO, ppnamesbuffer: *mut *mut u16) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(pcparams), ::core::mem::transmute(prgparaminfo), ::core::mem::transmute(ppnamesbuffer)).ok() } pub unsafe fn Requery(&self, pparams: *mut DBPARAMS, pulerrorparam: *mut u32, phreserved: *mut usize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(pparams), ::core::mem::transmute(pulerrorparam), ::core::mem::transmute(phreserved)).ok() } } unsafe impl ::windows::core::Interface for IRowsetWithParameters { type Vtable = IRowsetWithParameters_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a6e_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IRowsetWithParameters> for ::windows::core::IUnknown { fn from(value: IRowsetWithParameters) -> Self { value.0 } } impl ::core::convert::From<&IRowsetWithParameters> for ::windows::core::IUnknown { fn from(value: &IRowsetWithParameters) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IRowsetWithParameters { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IRowsetWithParameters { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IRowsetWithParameters_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pcparams: *mut usize, prgparaminfo: *mut *mut DBPARAMINFO, ppnamesbuffer: *mut *mut u16) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com")))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pparams: *mut DBPARAMS, pulerrorparam: *mut u32, phreserved: *mut usize) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ISQLErrorInfo(pub ::windows::core::IUnknown); impl ISQLErrorInfo { #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetSQLInfo(&self, pbstrsqlstate: *mut super::super::Foundation::BSTR, plnativeerror: *mut i32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(pbstrsqlstate), ::core::mem::transmute(plnativeerror)).ok() } } unsafe impl ::windows::core::Interface for ISQLErrorInfo { type Vtable = ISQLErrorInfo_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a74_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<ISQLErrorInfo> for ::windows::core::IUnknown { fn from(value: ISQLErrorInfo) -> Self { value.0 } } impl ::core::convert::From<&ISQLErrorInfo> for ::windows::core::IUnknown { fn from(value: &ISQLErrorInfo) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ISQLErrorInfo { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ISQLErrorInfo { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ISQLErrorInfo_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pbstrsqlstate: *mut ::core::mem::ManuallyDrop<super::super::Foundation::BSTR>, plnativeerror: *mut i32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ISQLGetDiagField(pub ::windows::core::IUnknown); impl ISQLGetDiagField { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn GetDiagField(&self, pdiaginfo: *mut KAGGETDIAG) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(pdiaginfo)).ok() } } unsafe impl ::windows::core::Interface for ISQLGetDiagField { type Vtable = ISQLGetDiagField_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x228972f1_b5ff_11d0_8a80_00c04fd611cd); } impl ::core::convert::From<ISQLGetDiagField> for ::windows::core::IUnknown { fn from(value: ISQLGetDiagField) -> Self { value.0 } } impl ::core::convert::From<&ISQLGetDiagField> for ::windows::core::IUnknown { fn from(value: &ISQLGetDiagField) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ISQLGetDiagField { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ISQLGetDiagField { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ISQLGetDiagField_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pdiaginfo: *mut ::core::mem::ManuallyDrop<KAGGETDIAG>) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ISQLRequestDiagFields(pub ::windows::core::IUnknown); impl ISQLRequestDiagFields { pub unsafe fn RequestDiagFields(&self, cdiagfields: u32, rgdiagfields: *const KAGREQDIAG) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(cdiagfields), ::core::mem::transmute(rgdiagfields)).ok() } } unsafe impl ::windows::core::Interface for ISQLRequestDiagFields { type Vtable = ISQLRequestDiagFields_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x228972f0_b5ff_11d0_8a80_00c04fd611cd); } impl ::core::convert::From<ISQLRequestDiagFields> for ::windows::core::IUnknown { fn from(value: ISQLRequestDiagFields) -> Self { value.0 } } impl ::core::convert::From<&ISQLRequestDiagFields> for ::windows::core::IUnknown { fn from(value: &ISQLRequestDiagFields) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ISQLRequestDiagFields { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ISQLRequestDiagFields { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ISQLRequestDiagFields_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, cdiagfields: u32, rgdiagfields: *const KAGREQDIAG) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ISQLServerErrorInfo(pub ::windows::core::IUnknown); impl ISQLServerErrorInfo { #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetErrorInfo(&self, pperrorinfo: *mut *mut tagSSErrorInfo, ppstringsbuffer: *mut *mut u16) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(pperrorinfo), ::core::mem::transmute(ppstringsbuffer)).ok() } } unsafe impl ::windows::core::Interface for ISQLServerErrorInfo { type Vtable = ISQLServerErrorInfo_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x5cf4ca12_ef21_11d0_97e7_00c04fc2ad98); } impl ::core::convert::From<ISQLServerErrorInfo> for ::windows::core::IUnknown { fn from(value: ISQLServerErrorInfo) -> Self { value.0 } } impl ::core::convert::From<&ISQLServerErrorInfo> for ::windows::core::IUnknown { fn from(value: &ISQLServerErrorInfo) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ISQLServerErrorInfo { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ISQLServerErrorInfo { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ISQLServerErrorInfo_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pperrorinfo: *mut *mut tagSSErrorInfo, ppstringsbuffer: *mut *mut u16) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ISchemaLocalizerSupport(pub ::windows::core::IUnknown); impl ISchemaLocalizerSupport { #[cfg(feature = "Win32_Foundation")] pub unsafe fn Localize<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszglobalstring: Param0) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), pszglobalstring.into_param().abi(), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } } unsafe impl ::windows::core::Interface for ISchemaLocalizerSupport { type Vtable = ISchemaLocalizerSupport_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xca3fdca2_bfbe_4eed_90d7_0caef0a1bda1); } impl ::core::convert::From<ISchemaLocalizerSupport> for ::windows::core::IUnknown { fn from(value: ISchemaLocalizerSupport) -> Self { value.0 } } impl ::core::convert::From<&ISchemaLocalizerSupport> for ::windows::core::IUnknown { fn from(value: &ISchemaLocalizerSupport) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ISchemaLocalizerSupport { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ISchemaLocalizerSupport { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ISchemaLocalizerSupport_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszglobalstring: super::super::Foundation::PWSTR, ppszlocalstring: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ISchemaLock(pub ::windows::core::IUnknown); impl ISchemaLock { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe fn GetSchemaLock(&self, ptableid: *mut super::super::Storage::IndexServer::DBID, lmmode: u32, phlockhandle: *mut super::super::Foundation::HANDLE, ptableversion: *mut u64) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(ptableid), ::core::mem::transmute(lmmode), ::core::mem::transmute(phlockhandle), ::core::mem::transmute(ptableversion)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn ReleaseSchemaLock<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::HANDLE>>(&self, hlockhandle: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), hlockhandle.into_param().abi()).ok() } } unsafe impl ::windows::core::Interface for ISchemaLock { type Vtable = ISchemaLock_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x4c2389fb_2511_11d4_b258_00c04f7971ce); } impl ::core::convert::From<ISchemaLock> for ::windows::core::IUnknown { fn from(value: ISchemaLock) -> Self { value.0 } } impl ::core::convert::From<&ISchemaLock> for ::windows::core::IUnknown { fn from(value: &ISchemaLock) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ISchemaLock { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ISchemaLock { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ISchemaLock_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ptableid: *mut super::super::Storage::IndexServer::DBID, lmmode: u32, phlockhandle: *mut super::super::Foundation::HANDLE, ptableversion: *mut u64) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer")))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hlockhandle: super::super::Foundation::HANDLE) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ISchemaProvider(pub ::windows::core::IUnknown); impl ISchemaProvider { pub unsafe fn Entities<T: ::windows::core::Interface>(&self) -> ::windows::core::Result<T> { let mut result__ = ::core::option::Option::None; (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), &<T as ::windows::core::Interface>::IID, &mut result__ as *mut _ as *mut _).and_some(result__) } pub unsafe fn RootEntity(&self) -> ::windows::core::Result<IEntity> { let mut result__: <IEntity as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), &mut result__).from_abi::<IEntity>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetEntity<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszentityname: Param0) -> ::windows::core::Result<IEntity> { let mut result__: <IEntity as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), pszentityname.into_param().abi(), &mut result__).from_abi::<IEntity>(result__) } pub unsafe fn MetaData<T: ::windows::core::Interface>(&self) -> ::windows::core::Result<T> { let mut result__ = ::core::option::Option::None; (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), &<T as ::windows::core::Interface>::IID, &mut result__ as *mut _ as *mut _).and_some(result__) } pub unsafe fn Localize<'a, Param1: ::windows::core::IntoParam<'a, ISchemaLocalizerSupport>>(&self, lcid: u32, pschemalocalizersupport: Param1) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), ::core::mem::transmute(lcid), pschemalocalizersupport.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn SaveBinary<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszschemabinarypath: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).8)(::core::mem::transmute_copy(self), pszschemabinarypath.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn LookupAuthoredNamedEntity<'a, Param0: ::windows::core::IntoParam<'a, IEntity>, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param2: ::windows::core::IntoParam<'a, ITokenCollection>>(&self, pentity: Param0, pszinputstring: Param1, ptokencollection: Param2, ctokensbegin: u32, pctokenslength: *mut u32, ppszvalue: *mut super::super::Foundation::PWSTR) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).9)(::core::mem::transmute_copy(self), pentity.into_param().abi(), pszinputstring.into_param().abi(), ptokencollection.into_param().abi(), ::core::mem::transmute(ctokensbegin), ::core::mem::transmute(pctokenslength), ::core::mem::transmute(ppszvalue)).ok() } } unsafe impl ::windows::core::Interface for ISchemaProvider { type Vtable = ISchemaProvider_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x8cf89bcb_394c_49b2_ae28_a59dd4ed7f68); } impl ::core::convert::From<ISchemaProvider> for ::windows::core::IUnknown { fn from(value: ISchemaProvider) -> Self { value.0 } } impl ::core::convert::From<&ISchemaProvider> for ::windows::core::IUnknown { fn from(value: &ISchemaProvider) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ISchemaProvider { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ISchemaProvider { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ISchemaProvider_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, riid: *const ::windows::core::GUID, pentities: *mut *mut ::core::ffi::c_void) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, prootentity: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszentityname: super::super::Foundation::PWSTR, pentity: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, riid: *const ::windows::core::GUID, pmetadata: *mut *mut ::core::ffi::c_void) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, lcid: u32, pschemalocalizersupport: ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszschemabinarypath: super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pentity: ::windows::core::RawPtr, pszinputstring: super::super::Foundation::PWSTR, ptokencollection: ::windows::core::RawPtr, ctokensbegin: u32, pctokenslength: *mut u32, ppszvalue: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IScopedOperations(pub ::windows::core::IUnknown); impl IScopedOperations { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub unsafe fn Bind<'a, Param0: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param5: ::windows::core::IntoParam<'a, super::Com::IAuthenticate>>( &self, punkouter: Param0, pwszurl: Param1, dwbindurlflags: u32, rguid: *const ::windows::core::GUID, riid: *const ::windows::core::GUID, pauthenticate: Param5, pimplsession: *mut DBIMPLICITSESSION, pdwbindstatus: *mut u32, ppunk: *mut ::core::option::Option<::windows::core::IUnknown>, ) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)( ::core::mem::transmute_copy(self), punkouter.into_param().abi(), pwszurl.into_param().abi(), ::core::mem::transmute(dwbindurlflags), ::core::mem::transmute(rguid), ::core::mem::transmute(riid), pauthenticate.into_param().abi(), ::core::mem::transmute(pimplsession), ::core::mem::transmute(pdwbindstatus), ::core::mem::transmute(ppunk), ) .ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub unsafe fn Copy<'a, Param4: ::windows::core::IntoParam<'a, super::Com::IAuthenticate>>(&self, crows: usize, rgpwszsourceurls: *const super::super::Foundation::PWSTR, rgpwszdesturls: *const super::super::Foundation::PWSTR, dwcopyflags: u32, pauthenticate: Param4, rgdwstatus: *mut u32, rgpwsznewurls: *mut super::super::Foundation::PWSTR, ppstringsbuffer: *mut *mut u16) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)( ::core::mem::transmute_copy(self), ::core::mem::transmute(crows), ::core::mem::transmute(rgpwszsourceurls), ::core::mem::transmute(rgpwszdesturls), ::core::mem::transmute(dwcopyflags), pauthenticate.into_param().abi(), ::core::mem::transmute(rgdwstatus), ::core::mem::transmute(rgpwsznewurls), ::core::mem::transmute(ppstringsbuffer), ) .ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub unsafe fn Move<'a, Param4: ::windows::core::IntoParam<'a, super::Com::IAuthenticate>>(&self, crows: usize, rgpwszsourceurls: *const super::super::Foundation::PWSTR, rgpwszdesturls: *const super::super::Foundation::PWSTR, dwmoveflags: u32, pauthenticate: Param4, rgdwstatus: *mut u32, rgpwsznewurls: *mut super::super::Foundation::PWSTR, ppstringsbuffer: *mut *mut u16) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)( ::core::mem::transmute_copy(self), ::core::mem::transmute(crows), ::core::mem::transmute(rgpwszsourceurls), ::core::mem::transmute(rgpwszdesturls), ::core::mem::transmute(dwmoveflags), pauthenticate.into_param().abi(), ::core::mem::transmute(rgdwstatus), ::core::mem::transmute(rgpwsznewurls), ::core::mem::transmute(ppstringsbuffer), ) .ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn Delete(&self, crows: usize, rgpwszurls: *const super::super::Foundation::PWSTR, dwdeleteflags: u32, rgdwstatus: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), ::core::mem::transmute(crows), ::core::mem::transmute(rgpwszurls), ::core::mem::transmute(dwdeleteflags), ::core::mem::transmute(rgdwstatus)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn OpenRowset<'a, Param0: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>>(&self, punkouter: Param0, ptableid: *const super::super::Storage::IndexServer::DBID, pindexid: *const super::super::Storage::IndexServer::DBID, riid: *const ::windows::core::GUID, cpropertysets: u32, rgpropertysets: *mut DBPROPSET, pprowset: *mut ::core::option::Option<::windows::core::IUnknown>) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), punkouter.into_param().abi(), ::core::mem::transmute(ptableid), ::core::mem::transmute(pindexid), ::core::mem::transmute(riid), ::core::mem::transmute(cpropertysets), ::core::mem::transmute(rgpropertysets), ::core::mem::transmute(pprowset)).ok() } } unsafe impl ::windows::core::Interface for IScopedOperations { type Vtable = IScopedOperations_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733ab0_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IScopedOperations> for ::windows::core::IUnknown { fn from(value: IScopedOperations) -> Self { value.0 } } impl ::core::convert::From<&IScopedOperations> for ::windows::core::IUnknown { fn from(value: &IScopedOperations) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IScopedOperations { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IScopedOperations { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } impl ::core::convert::From<IScopedOperations> for IBindResource { fn from(value: IScopedOperations) -> Self { unsafe { ::core::mem::transmute(value) } } } impl ::core::convert::From<&IScopedOperations> for IBindResource { fn from(value: &IScopedOperations) -> Self { ::core::convert::From::from(::core::clone::Clone::clone(value)) } } impl<'a> ::windows::core::IntoParam<'a, IBindResource> for IScopedOperations { fn into_param(self) -> ::windows::core::Param<'a, IBindResource> { ::windows::core::Param::Owned(unsafe { ::core::mem::transmute(self) }) } } impl<'a> ::windows::core::IntoParam<'a, IBindResource> for &IScopedOperations { fn into_param(self) -> ::windows::core::Param<'a, IBindResource> { ::windows::core::Param::Borrowed(unsafe { ::core::mem::transmute(self) }) } } #[repr(C)] #[doc(hidden)] pub struct IScopedOperations_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, punkouter: ::windows::core::RawPtr, pwszurl: super::super::Foundation::PWSTR, dwbindurlflags: u32, rguid: *const ::windows::core::GUID, riid: *const ::windows::core::GUID, pauthenticate: ::windows::core::RawPtr, pimplsession: *mut ::core::mem::ManuallyDrop<DBIMPLICITSESSION>, pdwbindstatus: *mut u32, ppunk: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, crows: usize, rgpwszsourceurls: *const super::super::Foundation::PWSTR, rgpwszdesturls: *const super::super::Foundation::PWSTR, dwcopyflags: u32, pauthenticate: ::windows::core::RawPtr, rgdwstatus: *mut u32, rgpwsznewurls: *mut super::super::Foundation::PWSTR, ppstringsbuffer: *mut *mut u16) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, crows: usize, rgpwszsourceurls: *const super::super::Foundation::PWSTR, rgpwszdesturls: *const super::super::Foundation::PWSTR, dwmoveflags: u32, pauthenticate: ::windows::core::RawPtr, rgdwstatus: *mut u32, rgpwsznewurls: *mut super::super::Foundation::PWSTR, ppstringsbuffer: *mut *mut u16) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com")))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, crows: usize, rgpwszurls: *const super::super::Foundation::PWSTR, dwdeleteflags: u32, rgdwstatus: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, punkouter: ::windows::core::RawPtr, ptableid: *const super::super::Storage::IndexServer::DBID, pindexid: *const super::super::Storage::IndexServer::DBID, riid: *const ::windows::core::GUID, cpropertysets: u32, rgpropertysets: *mut DBPROPSET, pprowset: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ISearchCatalogManager(pub ::windows::core::IUnknown); impl ISearchCatalogManager { #[cfg(feature = "Win32_Foundation")] pub unsafe fn Name(&self) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe fn GetParameter<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszname: Param0) -> ::windows::core::Result<*mut super::Com::StructuredStorage::PROPVARIANT> { let mut result__: <*mut super::Com::StructuredStorage::PROPVARIANT as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), pszname.into_param().abi(), &mut result__).from_abi::<*mut super::Com::StructuredStorage::PROPVARIANT>(result__) } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe fn SetParameter<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszname: Param0, pvalue: *const super::Com::StructuredStorage::PROPVARIANT) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), pszname.into_param().abi(), ::core::mem::transmute(pvalue)).ok() } pub unsafe fn GetCatalogStatus(&self, pstatus: *mut CatalogStatus, ppausedreason: *mut CatalogPausedReason) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), ::core::mem::transmute(pstatus), ::core::mem::transmute(ppausedreason)).ok() } pub unsafe fn Reset(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self)).ok() } pub unsafe fn Reindex(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).8)(::core::mem::transmute_copy(self)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn ReindexMatchingURLs<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszpattern: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).9)(::core::mem::transmute_copy(self), pszpattern.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn ReindexSearchRoot<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszrooturl: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).10)(::core::mem::transmute_copy(self), pszrooturl.into_param().abi()).ok() } pub unsafe fn SetConnectTimeout(&self, dwconnecttimeout: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).11)(::core::mem::transmute_copy(self), ::core::mem::transmute(dwconnecttimeout)).ok() } pub unsafe fn ConnectTimeout(&self) -> ::windows::core::Result<u32> { let mut result__: <u32 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).12)(::core::mem::transmute_copy(self), &mut result__).from_abi::<u32>(result__) } pub unsafe fn SetDataTimeout(&self, dwdatatimeout: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).13)(::core::mem::transmute_copy(self), ::core::mem::transmute(dwdatatimeout)).ok() } pub unsafe fn DataTimeout(&self) -> ::windows::core::Result<u32> { let mut result__: <u32 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).14)(::core::mem::transmute_copy(self), &mut result__).from_abi::<u32>(result__) } pub unsafe fn NumberOfItems(&self) -> ::windows::core::Result<i32> { let mut result__: <i32 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).15)(::core::mem::transmute_copy(self), &mut result__).from_abi::<i32>(result__) } pub unsafe fn NumberOfItemsToIndex(&self, plincrementalcount: *mut i32, plnotificationqueue: *mut i32, plhighpriorityqueue: *mut i32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).16)(::core::mem::transmute_copy(self), ::core::mem::transmute(plincrementalcount), ::core::mem::transmute(plnotificationqueue), ::core::mem::transmute(plhighpriorityqueue)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn URLBeingIndexed(&self) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).17)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetURLIndexingState<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszurl: Param0) -> ::windows::core::Result<u32> { let mut result__: <u32 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).18)(::core::mem::transmute_copy(self), pszurl.into_param().abi(), &mut result__).from_abi::<u32>(result__) } pub unsafe fn GetPersistentItemsChangedSink(&self) -> ::windows::core::Result<ISearchPersistentItemsChangedSink> { let mut result__: <ISearchPersistentItemsChangedSink as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).19)(::core::mem::transmute_copy(self), &mut result__).from_abi::<ISearchPersistentItemsChangedSink>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn RegisterViewForNotification<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param1: ::windows::core::IntoParam<'a, ISearchViewChangedSink>>(&self, pszview: Param0, pviewchangedsink: Param1) -> ::windows::core::Result<u32> { let mut result__: <u32 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).20)(::core::mem::transmute_copy(self), pszview.into_param().abi(), pviewchangedsink.into_param().abi(), &mut result__).from_abi::<u32>(result__) } pub unsafe fn GetItemsChangedSink<'a, Param0: ::windows::core::IntoParam<'a, ISearchNotifyInlineSite>>(&self, pisearchnotifyinlinesite: Param0, riid: *const ::windows::core::GUID, ppv: *mut *mut ::core::ffi::c_void, pguidcatalogresetsignature: *mut ::windows::core::GUID, pguidcheckpointsignature: *mut ::windows::core::GUID, pdwlastcheckpointnumber: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).21)(::core::mem::transmute_copy(self), pisearchnotifyinlinesite.into_param().abi(), ::core::mem::transmute(riid), ::core::mem::transmute(ppv), ::core::mem::transmute(pguidcatalogresetsignature), ::core::mem::transmute(pguidcheckpointsignature), ::core::mem::transmute(pdwlastcheckpointnumber)).ok() } pub unsafe fn UnregisterViewForNotification(&self, dwcookie: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).22)(::core::mem::transmute_copy(self), ::core::mem::transmute(dwcookie)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn SetExtensionClusion<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>(&self, pszextension: Param0, fexclude: Param1) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).23)(::core::mem::transmute_copy(self), pszextension.into_param().abi(), fexclude.into_param().abi()).ok() } #[cfg(feature = "Win32_System_Com")] pub unsafe fn EnumerateExcludedExtensions(&self) -> ::windows::core::Result<super::Com::IEnumString> { let mut result__: <super::Com::IEnumString as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).24)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::Com::IEnumString>(result__) } pub unsafe fn GetQueryHelper(&self) -> ::windows::core::Result<ISearchQueryHelper> { let mut result__: <ISearchQueryHelper as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).25)(::core::mem::transmute_copy(self), &mut result__).from_abi::<ISearchQueryHelper>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn SetDiacriticSensitivity<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>(&self, fdiacriticsensitive: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).26)(::core::mem::transmute_copy(self), fdiacriticsensitive.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn DiacriticSensitivity(&self) -> ::windows::core::Result<super::super::Foundation::BOOL> { let mut result__: <super::super::Foundation::BOOL as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).27)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::BOOL>(result__) } pub unsafe fn GetCrawlScopeManager(&self) -> ::windows::core::Result<ISearchCrawlScopeManager> { let mut result__: <ISearchCrawlScopeManager as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).28)(::core::mem::transmute_copy(self), &mut result__).from_abi::<ISearchCrawlScopeManager>(result__) } } unsafe impl ::windows::core::Interface for ISearchCatalogManager { type Vtable = ISearchCatalogManager_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xab310581_ac80_11d1_8df3_00c04fb6ef50); } impl ::core::convert::From<ISearchCatalogManager> for ::windows::core::IUnknown { fn from(value: ISearchCatalogManager) -> Self { value.0 } } impl ::core::convert::From<&ISearchCatalogManager> for ::windows::core::IUnknown { fn from(value: &ISearchCatalogManager) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ISearchCatalogManager { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ISearchCatalogManager { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ISearchCatalogManager_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszname: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszname: super::super::Foundation::PWSTR, ppvalue: *mut *mut super::Com::StructuredStorage::PROPVARIANT) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszname: super::super::Foundation::PWSTR, pvalue: *const ::core::mem::ManuallyDrop<super::Com::StructuredStorage::PROPVARIANT>) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage")))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pstatus: *mut CatalogStatus, ppausedreason: *mut CatalogPausedReason) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszpattern: super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszrooturl: super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, dwconnecttimeout: u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pdwconnecttimeout: *mut u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, dwdatatimeout: u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pdwdatatimeout: *mut u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, plcount: *mut i32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, plincrementalcount: *mut i32, plnotificationqueue: *mut i32, plhighpriorityqueue: *mut i32) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszurl: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszurl: super::super::Foundation::PWSTR, pdwstate: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppisearchpersistentitemschangedsink: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszview: super::super::Foundation::PWSTR, pviewchangedsink: ::windows::core::RawPtr, pdwcookie: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pisearchnotifyinlinesite: ::windows::core::RawPtr, riid: *const ::windows::core::GUID, ppv: *mut *mut ::core::ffi::c_void, pguidcatalogresetsignature: *mut ::windows::core::GUID, pguidcheckpointsignature: *mut ::windows::core::GUID, pdwlastcheckpointnumber: *mut u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, dwcookie: u32) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszextension: super::super::Foundation::PWSTR, fexclude: super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_System_Com")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppextensions: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_System_Com"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppsearchqueryhelper: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, fdiacriticsensitive: super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pfdiacriticsensitive: *mut super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppcrawlscopemanager: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ISearchCatalogManager2(pub ::windows::core::IUnknown); impl ISearchCatalogManager2 { #[cfg(feature = "Win32_Foundation")] pub unsafe fn Name(&self) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe fn GetParameter<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszname: Param0) -> ::windows::core::Result<*mut super::Com::StructuredStorage::PROPVARIANT> { let mut result__: <*mut super::Com::StructuredStorage::PROPVARIANT as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), pszname.into_param().abi(), &mut result__).from_abi::<*mut super::Com::StructuredStorage::PROPVARIANT>(result__) } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe fn SetParameter<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszname: Param0, pvalue: *const super::Com::StructuredStorage::PROPVARIANT) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), pszname.into_param().abi(), ::core::mem::transmute(pvalue)).ok() } pub unsafe fn GetCatalogStatus(&self, pstatus: *mut CatalogStatus, ppausedreason: *mut CatalogPausedReason) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), ::core::mem::transmute(pstatus), ::core::mem::transmute(ppausedreason)).ok() } pub unsafe fn Reset(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self)).ok() } pub unsafe fn Reindex(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).8)(::core::mem::transmute_copy(self)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn ReindexMatchingURLs<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszpattern: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).9)(::core::mem::transmute_copy(self), pszpattern.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn ReindexSearchRoot<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszrooturl: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).10)(::core::mem::transmute_copy(self), pszrooturl.into_param().abi()).ok() } pub unsafe fn SetConnectTimeout(&self, dwconnecttimeout: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).11)(::core::mem::transmute_copy(self), ::core::mem::transmute(dwconnecttimeout)).ok() } pub unsafe fn ConnectTimeout(&self) -> ::windows::core::Result<u32> { let mut result__: <u32 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).12)(::core::mem::transmute_copy(self), &mut result__).from_abi::<u32>(result__) } pub unsafe fn SetDataTimeout(&self, dwdatatimeout: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).13)(::core::mem::transmute_copy(self), ::core::mem::transmute(dwdatatimeout)).ok() } pub unsafe fn DataTimeout(&self) -> ::windows::core::Result<u32> { let mut result__: <u32 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).14)(::core::mem::transmute_copy(self), &mut result__).from_abi::<u32>(result__) } pub unsafe fn NumberOfItems(&self) -> ::windows::core::Result<i32> { let mut result__: <i32 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).15)(::core::mem::transmute_copy(self), &mut result__).from_abi::<i32>(result__) } pub unsafe fn NumberOfItemsToIndex(&self, plincrementalcount: *mut i32, plnotificationqueue: *mut i32, plhighpriorityqueue: *mut i32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).16)(::core::mem::transmute_copy(self), ::core::mem::transmute(plincrementalcount), ::core::mem::transmute(plnotificationqueue), ::core::mem::transmute(plhighpriorityqueue)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn URLBeingIndexed(&self) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).17)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetURLIndexingState<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszurl: Param0) -> ::windows::core::Result<u32> { let mut result__: <u32 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).18)(::core::mem::transmute_copy(self), pszurl.into_param().abi(), &mut result__).from_abi::<u32>(result__) } pub unsafe fn GetPersistentItemsChangedSink(&self) -> ::windows::core::Result<ISearchPersistentItemsChangedSink> { let mut result__: <ISearchPersistentItemsChangedSink as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).19)(::core::mem::transmute_copy(self), &mut result__).from_abi::<ISearchPersistentItemsChangedSink>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn RegisterViewForNotification<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param1: ::windows::core::IntoParam<'a, ISearchViewChangedSink>>(&self, pszview: Param0, pviewchangedsink: Param1) -> ::windows::core::Result<u32> { let mut result__: <u32 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).20)(::core::mem::transmute_copy(self), pszview.into_param().abi(), pviewchangedsink.into_param().abi(), &mut result__).from_abi::<u32>(result__) } pub unsafe fn GetItemsChangedSink<'a, Param0: ::windows::core::IntoParam<'a, ISearchNotifyInlineSite>>(&self, pisearchnotifyinlinesite: Param0, riid: *const ::windows::core::GUID, ppv: *mut *mut ::core::ffi::c_void, pguidcatalogresetsignature: *mut ::windows::core::GUID, pguidcheckpointsignature: *mut ::windows::core::GUID, pdwlastcheckpointnumber: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).21)(::core::mem::transmute_copy(self), pisearchnotifyinlinesite.into_param().abi(), ::core::mem::transmute(riid), ::core::mem::transmute(ppv), ::core::mem::transmute(pguidcatalogresetsignature), ::core::mem::transmute(pguidcheckpointsignature), ::core::mem::transmute(pdwlastcheckpointnumber)).ok() } pub unsafe fn UnregisterViewForNotification(&self, dwcookie: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).22)(::core::mem::transmute_copy(self), ::core::mem::transmute(dwcookie)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn SetExtensionClusion<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>(&self, pszextension: Param0, fexclude: Param1) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).23)(::core::mem::transmute_copy(self), pszextension.into_param().abi(), fexclude.into_param().abi()).ok() } #[cfg(feature = "Win32_System_Com")] pub unsafe fn EnumerateExcludedExtensions(&self) -> ::windows::core::Result<super::Com::IEnumString> { let mut result__: <super::Com::IEnumString as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).24)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::Com::IEnumString>(result__) } pub unsafe fn GetQueryHelper(&self) -> ::windows::core::Result<ISearchQueryHelper> { let mut result__: <ISearchQueryHelper as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).25)(::core::mem::transmute_copy(self), &mut result__).from_abi::<ISearchQueryHelper>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn SetDiacriticSensitivity<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>(&self, fdiacriticsensitive: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).26)(::core::mem::transmute_copy(self), fdiacriticsensitive.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn DiacriticSensitivity(&self) -> ::windows::core::Result<super::super::Foundation::BOOL> { let mut result__: <super::super::Foundation::BOOL as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).27)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::BOOL>(result__) } pub unsafe fn GetCrawlScopeManager(&self) -> ::windows::core::Result<ISearchCrawlScopeManager> { let mut result__: <ISearchCrawlScopeManager as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).28)(::core::mem::transmute_copy(self), &mut result__).from_abi::<ISearchCrawlScopeManager>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn PrioritizeMatchingURLs<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszpattern: Param0, dwprioritizeflags: PRIORITIZE_FLAGS) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).29)(::core::mem::transmute_copy(self), pszpattern.into_param().abi(), ::core::mem::transmute(dwprioritizeflags)).ok() } } unsafe impl ::windows::core::Interface for ISearchCatalogManager2 { type Vtable = ISearchCatalogManager2_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x7ac3286d_4d1d_4817_84fc_c1c85e3af0d9); } impl ::core::convert::From<ISearchCatalogManager2> for ::windows::core::IUnknown { fn from(value: ISearchCatalogManager2) -> Self { value.0 } } impl ::core::convert::From<&ISearchCatalogManager2> for ::windows::core::IUnknown { fn from(value: &ISearchCatalogManager2) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ISearchCatalogManager2 { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ISearchCatalogManager2 { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } impl ::core::convert::From<ISearchCatalogManager2> for ISearchCatalogManager { fn from(value: ISearchCatalogManager2) -> Self { unsafe { ::core::mem::transmute(value) } } } impl ::core::convert::From<&ISearchCatalogManager2> for ISearchCatalogManager { fn from(value: &ISearchCatalogManager2) -> Self { ::core::convert::From::from(::core::clone::Clone::clone(value)) } } impl<'a> ::windows::core::IntoParam<'a, ISearchCatalogManager> for ISearchCatalogManager2 { fn into_param(self) -> ::windows::core::Param<'a, ISearchCatalogManager> { ::windows::core::Param::Owned(unsafe { ::core::mem::transmute(self) }) } } impl<'a> ::windows::core::IntoParam<'a, ISearchCatalogManager> for &ISearchCatalogManager2 { fn into_param(self) -> ::windows::core::Param<'a, ISearchCatalogManager> { ::windows::core::Param::Borrowed(unsafe { ::core::mem::transmute(self) }) } } #[repr(C)] #[doc(hidden)] pub struct ISearchCatalogManager2_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszname: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszname: super::super::Foundation::PWSTR, ppvalue: *mut *mut super::Com::StructuredStorage::PROPVARIANT) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszname: super::super::Foundation::PWSTR, pvalue: *const ::core::mem::ManuallyDrop<super::Com::StructuredStorage::PROPVARIANT>) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage")))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pstatus: *mut CatalogStatus, ppausedreason: *mut CatalogPausedReason) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszpattern: super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszrooturl: super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, dwconnecttimeout: u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pdwconnecttimeout: *mut u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, dwdatatimeout: u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pdwdatatimeout: *mut u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, plcount: *mut i32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, plincrementalcount: *mut i32, plnotificationqueue: *mut i32, plhighpriorityqueue: *mut i32) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszurl: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszurl: super::super::Foundation::PWSTR, pdwstate: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppisearchpersistentitemschangedsink: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszview: super::super::Foundation::PWSTR, pviewchangedsink: ::windows::core::RawPtr, pdwcookie: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pisearchnotifyinlinesite: ::windows::core::RawPtr, riid: *const ::windows::core::GUID, ppv: *mut *mut ::core::ffi::c_void, pguidcatalogresetsignature: *mut ::windows::core::GUID, pguidcheckpointsignature: *mut ::windows::core::GUID, pdwlastcheckpointnumber: *mut u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, dwcookie: u32) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszextension: super::super::Foundation::PWSTR, fexclude: super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_System_Com")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppextensions: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_System_Com"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppsearchqueryhelper: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, fdiacriticsensitive: super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pfdiacriticsensitive: *mut super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppcrawlscopemanager: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszpattern: super::super::Foundation::PWSTR, dwprioritizeflags: PRIORITIZE_FLAGS) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ISearchCrawlScopeManager(pub ::windows::core::IUnknown); impl ISearchCrawlScopeManager { #[cfg(feature = "Win32_Foundation")] pub unsafe fn AddDefaultScopeRule<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>(&self, pszurl: Param0, finclude: Param1, ffollowflags: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), pszurl.into_param().abi(), finclude.into_param().abi(), ::core::mem::transmute(ffollowflags)).ok() } pub unsafe fn AddRoot<'a, Param0: ::windows::core::IntoParam<'a, ISearchRoot>>(&self, psearchroot: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), psearchroot.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn RemoveRoot<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszurl: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), pszurl.into_param().abi()).ok() } pub unsafe fn EnumerateRoots(&self) -> ::windows::core::Result<IEnumSearchRoots> { let mut result__: <IEnumSearchRoots as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), &mut result__).from_abi::<IEnumSearchRoots>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn AddHierarchicalScope<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>, Param2: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>, Param3: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>(&self, pszurl: Param0, finclude: Param1, fdefault: Param2, foverridechildren: Param3) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), pszurl.into_param().abi(), finclude.into_param().abi(), fdefault.into_param().abi(), foverridechildren.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn AddUserScopeRule<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>, Param2: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>(&self, pszurl: Param0, finclude: Param1, foverridechildren: Param2, ffollowflags: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).8)(::core::mem::transmute_copy(self), pszurl.into_param().abi(), finclude.into_param().abi(), foverridechildren.into_param().abi(), ::core::mem::transmute(ffollowflags)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn RemoveScopeRule<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszrule: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).9)(::core::mem::transmute_copy(self), pszrule.into_param().abi()).ok() } pub unsafe fn EnumerateScopeRules(&self) -> ::windows::core::Result<IEnumSearchScopeRules> { let mut result__: <IEnumSearchScopeRules as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).10)(::core::mem::transmute_copy(self), &mut result__).from_abi::<IEnumSearchScopeRules>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn HasParentScopeRule<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszurl: Param0) -> ::windows::core::Result<super::super::Foundation::BOOL> { let mut result__: <super::super::Foundation::BOOL as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).11)(::core::mem::transmute_copy(self), pszurl.into_param().abi(), &mut result__).from_abi::<super::super::Foundation::BOOL>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn HasChildScopeRule<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszurl: Param0) -> ::windows::core::Result<super::super::Foundation::BOOL> { let mut result__: <super::super::Foundation::BOOL as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).12)(::core::mem::transmute_copy(self), pszurl.into_param().abi(), &mut result__).from_abi::<super::super::Foundation::BOOL>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn IncludedInCrawlScope<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszurl: Param0) -> ::windows::core::Result<super::super::Foundation::BOOL> { let mut result__: <super::super::Foundation::BOOL as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).13)(::core::mem::transmute_copy(self), pszurl.into_param().abi(), &mut result__).from_abi::<super::super::Foundation::BOOL>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn IncludedInCrawlScopeEx<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszurl: Param0, pfisincluded: *mut super::super::Foundation::BOOL, preason: *mut CLUSION_REASON) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).14)(::core::mem::transmute_copy(self), pszurl.into_param().abi(), ::core::mem::transmute(pfisincluded), ::core::mem::transmute(preason)).ok() } pub unsafe fn RevertToDefaultScopes(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).15)(::core::mem::transmute_copy(self)).ok() } pub unsafe fn SaveAll(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).16)(::core::mem::transmute_copy(self)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetParentScopeVersionId<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszurl: Param0) -> ::windows::core::Result<i32> { let mut result__: <i32 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).17)(::core::mem::transmute_copy(self), pszurl.into_param().abi(), &mut result__).from_abi::<i32>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn RemoveDefaultScopeRule<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszurl: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).18)(::core::mem::transmute_copy(self), pszurl.into_param().abi()).ok() } } unsafe impl ::windows::core::Interface for ISearchCrawlScopeManager { type Vtable = ISearchCrawlScopeManager_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xab310581_ac80_11d1_8df3_00c04fb6ef55); } impl ::core::convert::From<ISearchCrawlScopeManager> for ::windows::core::IUnknown { fn from(value: ISearchCrawlScopeManager) -> Self { value.0 } } impl ::core::convert::From<&ISearchCrawlScopeManager> for ::windows::core::IUnknown { fn from(value: &ISearchCrawlScopeManager) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ISearchCrawlScopeManager { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ISearchCrawlScopeManager { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ISearchCrawlScopeManager_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszurl: super::super::Foundation::PWSTR, finclude: super::super::Foundation::BOOL, ffollowflags: u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, psearchroot: ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszurl: super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppsearchroots: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszurl: super::super::Foundation::PWSTR, finclude: super::super::Foundation::BOOL, fdefault: super::super::Foundation::BOOL, foverridechildren: super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszurl: super::super::Foundation::PWSTR, finclude: super::super::Foundation::BOOL, foverridechildren: super::super::Foundation::BOOL, ffollowflags: u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszrule: super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppsearchscoperules: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszurl: super::super::Foundation::PWSTR, pfhasparentrule: *mut super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszurl: super::super::Foundation::PWSTR, pfhaschildrule: *mut super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszurl: super::super::Foundation::PWSTR, pfisincluded: *mut super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszurl: super::super::Foundation::PWSTR, pfisincluded: *mut super::super::Foundation::BOOL, preason: *mut CLUSION_REASON) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszurl: super::super::Foundation::PWSTR, plscopeid: *mut i32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszurl: super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ISearchCrawlScopeManager2(pub ::windows::core::IUnknown); impl ISearchCrawlScopeManager2 { #[cfg(feature = "Win32_Foundation")] pub unsafe fn AddDefaultScopeRule<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>(&self, pszurl: Param0, finclude: Param1, ffollowflags: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), pszurl.into_param().abi(), finclude.into_param().abi(), ::core::mem::transmute(ffollowflags)).ok() } pub unsafe fn AddRoot<'a, Param0: ::windows::core::IntoParam<'a, ISearchRoot>>(&self, psearchroot: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), psearchroot.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn RemoveRoot<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszurl: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), pszurl.into_param().abi()).ok() } pub unsafe fn EnumerateRoots(&self) -> ::windows::core::Result<IEnumSearchRoots> { let mut result__: <IEnumSearchRoots as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), &mut result__).from_abi::<IEnumSearchRoots>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn AddHierarchicalScope<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>, Param2: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>, Param3: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>(&self, pszurl: Param0, finclude: Param1, fdefault: Param2, foverridechildren: Param3) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), pszurl.into_param().abi(), finclude.into_param().abi(), fdefault.into_param().abi(), foverridechildren.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn AddUserScopeRule<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>, Param2: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>(&self, pszurl: Param0, finclude: Param1, foverridechildren: Param2, ffollowflags: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).8)(::core::mem::transmute_copy(self), pszurl.into_param().abi(), finclude.into_param().abi(), foverridechildren.into_param().abi(), ::core::mem::transmute(ffollowflags)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn RemoveScopeRule<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszrule: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).9)(::core::mem::transmute_copy(self), pszrule.into_param().abi()).ok() } pub unsafe fn EnumerateScopeRules(&self) -> ::windows::core::Result<IEnumSearchScopeRules> { let mut result__: <IEnumSearchScopeRules as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).10)(::core::mem::transmute_copy(self), &mut result__).from_abi::<IEnumSearchScopeRules>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn HasParentScopeRule<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszurl: Param0) -> ::windows::core::Result<super::super::Foundation::BOOL> { let mut result__: <super::super::Foundation::BOOL as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).11)(::core::mem::transmute_copy(self), pszurl.into_param().abi(), &mut result__).from_abi::<super::super::Foundation::BOOL>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn HasChildScopeRule<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszurl: Param0) -> ::windows::core::Result<super::super::Foundation::BOOL> { let mut result__: <super::super::Foundation::BOOL as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).12)(::core::mem::transmute_copy(self), pszurl.into_param().abi(), &mut result__).from_abi::<super::super::Foundation::BOOL>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn IncludedInCrawlScope<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszurl: Param0) -> ::windows::core::Result<super::super::Foundation::BOOL> { let mut result__: <super::super::Foundation::BOOL as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).13)(::core::mem::transmute_copy(self), pszurl.into_param().abi(), &mut result__).from_abi::<super::super::Foundation::BOOL>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn IncludedInCrawlScopeEx<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszurl: Param0, pfisincluded: *mut super::super::Foundation::BOOL, preason: *mut CLUSION_REASON) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).14)(::core::mem::transmute_copy(self), pszurl.into_param().abi(), ::core::mem::transmute(pfisincluded), ::core::mem::transmute(preason)).ok() } pub unsafe fn RevertToDefaultScopes(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).15)(::core::mem::transmute_copy(self)).ok() } pub unsafe fn SaveAll(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).16)(::core::mem::transmute_copy(self)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetParentScopeVersionId<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszurl: Param0) -> ::windows::core::Result<i32> { let mut result__: <i32 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).17)(::core::mem::transmute_copy(self), pszurl.into_param().abi(), &mut result__).from_abi::<i32>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn RemoveDefaultScopeRule<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszurl: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).18)(::core::mem::transmute_copy(self), pszurl.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetVersion(&self, plversion: *mut *mut i32, phfilemapping: *mut super::super::Foundation::HANDLE) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).19)(::core::mem::transmute_copy(self), ::core::mem::transmute(plversion), ::core::mem::transmute(phfilemapping)).ok() } } unsafe impl ::windows::core::Interface for ISearchCrawlScopeManager2 { type Vtable = ISearchCrawlScopeManager2_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x6292f7ad_4e19_4717_a534_8fc22bcd5ccd); } impl ::core::convert::From<ISearchCrawlScopeManager2> for ::windows::core::IUnknown { fn from(value: ISearchCrawlScopeManager2) -> Self { value.0 } } impl ::core::convert::From<&ISearchCrawlScopeManager2> for ::windows::core::IUnknown { fn from(value: &ISearchCrawlScopeManager2) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ISearchCrawlScopeManager2 { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ISearchCrawlScopeManager2 { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } impl ::core::convert::From<ISearchCrawlScopeManager2> for ISearchCrawlScopeManager { fn from(value: ISearchCrawlScopeManager2) -> Self { unsafe { ::core::mem::transmute(value) } } } impl ::core::convert::From<&ISearchCrawlScopeManager2> for ISearchCrawlScopeManager { fn from(value: &ISearchCrawlScopeManager2) -> Self { ::core::convert::From::from(::core::clone::Clone::clone(value)) } } impl<'a> ::windows::core::IntoParam<'a, ISearchCrawlScopeManager> for ISearchCrawlScopeManager2 { fn into_param(self) -> ::windows::core::Param<'a, ISearchCrawlScopeManager> { ::windows::core::Param::Owned(unsafe { ::core::mem::transmute(self) }) } } impl<'a> ::windows::core::IntoParam<'a, ISearchCrawlScopeManager> for &ISearchCrawlScopeManager2 { fn into_param(self) -> ::windows::core::Param<'a, ISearchCrawlScopeManager> { ::windows::core::Param::Borrowed(unsafe { ::core::mem::transmute(self) }) } } #[repr(C)] #[doc(hidden)] pub struct ISearchCrawlScopeManager2_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszurl: super::super::Foundation::PWSTR, finclude: super::super::Foundation::BOOL, ffollowflags: u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, psearchroot: ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszurl: super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppsearchroots: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszurl: super::super::Foundation::PWSTR, finclude: super::super::Foundation::BOOL, fdefault: super::super::Foundation::BOOL, foverridechildren: super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszurl: super::super::Foundation::PWSTR, finclude: super::super::Foundation::BOOL, foverridechildren: super::super::Foundation::BOOL, ffollowflags: u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszrule: super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppsearchscoperules: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszurl: super::super::Foundation::PWSTR, pfhasparentrule: *mut super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszurl: super::super::Foundation::PWSTR, pfhaschildrule: *mut super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszurl: super::super::Foundation::PWSTR, pfisincluded: *mut super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszurl: super::super::Foundation::PWSTR, pfisincluded: *mut super::super::Foundation::BOOL, preason: *mut CLUSION_REASON) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszurl: super::super::Foundation::PWSTR, plscopeid: *mut i32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszurl: super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, plversion: *mut *mut i32, phfilemapping: *mut super::super::Foundation::HANDLE) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ISearchItemsChangedSink(pub ::windows::core::IUnknown); impl ISearchItemsChangedSink { #[cfg(feature = "Win32_Foundation")] pub unsafe fn StartedMonitoringScope<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszurl: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), pszurl.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn StoppedMonitoringScope<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszurl: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), pszurl.into_param().abi()).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub unsafe fn OnItemsChanged(&self, dwnumberofchanges: u32, rgdatachangeentries: *const SEARCH_ITEM_CHANGE, rgdwdocids: *mut u32, rghrcompletioncodes: *mut ::windows::core::HRESULT) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(dwnumberofchanges), ::core::mem::transmute(rgdatachangeentries), ::core::mem::transmute(rgdwdocids), ::core::mem::transmute(rghrcompletioncodes)).ok() } } unsafe impl ::windows::core::Interface for ISearchItemsChangedSink { type Vtable = ISearchItemsChangedSink_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xab310581_ac80_11d1_8df3_00c04fb6ef58); } impl ::core::convert::From<ISearchItemsChangedSink> for ::windows::core::IUnknown { fn from(value: ISearchItemsChangedSink) -> Self { value.0 } } impl ::core::convert::From<&ISearchItemsChangedSink> for ::windows::core::IUnknown { fn from(value: &ISearchItemsChangedSink) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ISearchItemsChangedSink { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ISearchItemsChangedSink { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ISearchItemsChangedSink_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszurl: super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszurl: super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, dwnumberofchanges: u32, rgdatachangeentries: *const SEARCH_ITEM_CHANGE, rgdwdocids: *mut u32, rghrcompletioncodes: *mut ::windows::core::HRESULT) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ISearchLanguageSupport(pub ::windows::core::IUnknown); impl ISearchLanguageSupport { #[cfg(feature = "Win32_Foundation")] pub unsafe fn SetDiacriticSensitivity<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>(&self, fdiacriticsensitive: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), fdiacriticsensitive.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetDiacriticSensitivity(&self) -> ::windows::core::Result<super::super::Foundation::BOOL> { let mut result__: <super::super::Foundation::BOOL as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::BOOL>(result__) } pub unsafe fn LoadWordBreaker(&self, lcid: u32, riid: *const ::windows::core::GUID, ppwordbreaker: *mut *mut ::core::ffi::c_void, plcidused: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(lcid), ::core::mem::transmute(riid), ::core::mem::transmute(ppwordbreaker), ::core::mem::transmute(plcidused)).ok() } pub unsafe fn LoadStemmer(&self, lcid: u32, riid: *const ::windows::core::GUID, ppstemmer: *mut *mut ::core::ffi::c_void, plcidused: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), ::core::mem::transmute(lcid), ::core::mem::transmute(riid), ::core::mem::transmute(ppstemmer), ::core::mem::transmute(plcidused)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn IsPrefixNormalized<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param2: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pwcsquerytoken: Param0, cwcquerytoken: u32, pwcsdocumenttoken: Param2, cwcdocumenttoken: u32) -> ::windows::core::Result<u32> { let mut result__: <u32 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), pwcsquerytoken.into_param().abi(), ::core::mem::transmute(cwcquerytoken), pwcsdocumenttoken.into_param().abi(), ::core::mem::transmute(cwcdocumenttoken), &mut result__).from_abi::<u32>(result__) } } unsafe impl ::windows::core::Interface for ISearchLanguageSupport { type Vtable = ISearchLanguageSupport_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x24c3cbaa_ebc1_491a_9ef1_9f6d8deb1b8f); } impl ::core::convert::From<ISearchLanguageSupport> for ::windows::core::IUnknown { fn from(value: ISearchLanguageSupport) -> Self { value.0 } } impl ::core::convert::From<&ISearchLanguageSupport> for ::windows::core::IUnknown { fn from(value: &ISearchLanguageSupport) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ISearchLanguageSupport { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ISearchLanguageSupport { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ISearchLanguageSupport_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, fdiacriticsensitive: super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pfdiacriticsensitive: *mut super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, lcid: u32, riid: *const ::windows::core::GUID, ppwordbreaker: *mut *mut ::core::ffi::c_void, plcidused: *mut u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, lcid: u32, riid: *const ::windows::core::GUID, ppstemmer: *mut *mut ::core::ffi::c_void, plcidused: *mut u32) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pwcsquerytoken: super::super::Foundation::PWSTR, cwcquerytoken: u32, pwcsdocumenttoken: super::super::Foundation::PWSTR, cwcdocumenttoken: u32, pulprefixlength: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ISearchManager(pub ::windows::core::IUnknown); impl ISearchManager { #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetIndexerVersionStr(&self) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } pub unsafe fn GetIndexerVersion(&self, pdwmajor: *mut u32, pdwminor: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(pdwmajor), ::core::mem::transmute(pdwminor)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe fn GetParameter<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszname: Param0) -> ::windows::core::Result<*mut super::Com::StructuredStorage::PROPVARIANT> { let mut result__: <*mut super::Com::StructuredStorage::PROPVARIANT as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), pszname.into_param().abi(), &mut result__).from_abi::<*mut super::Com::StructuredStorage::PROPVARIANT>(result__) } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe fn SetParameter<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszname: Param0, pvalue: *const super::Com::StructuredStorage::PROPVARIANT) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), pszname.into_param().abi(), ::core::mem::transmute(pvalue)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn ProxyName(&self) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn BypassList(&self) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).8)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn SetProxy<'a, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>, Param3: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param4: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, suseproxy: PROXY_ACCESS, flocalbypassproxy: Param1, dwportnumber: u32, pszproxyname: Param3, pszbypasslist: Param4) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).9)(::core::mem::transmute_copy(self), ::core::mem::transmute(suseproxy), flocalbypassproxy.into_param().abi(), ::core::mem::transmute(dwportnumber), pszproxyname.into_param().abi(), pszbypasslist.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetCatalog<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszcatalog: Param0) -> ::windows::core::Result<ISearchCatalogManager> { let mut result__: <ISearchCatalogManager as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).10)(::core::mem::transmute_copy(self), pszcatalog.into_param().abi(), &mut result__).from_abi::<ISearchCatalogManager>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn UserAgent(&self) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).11)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn SetUserAgent<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszuseragent: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).12)(::core::mem::transmute_copy(self), pszuseragent.into_param().abi()).ok() } pub unsafe fn UseProxy(&self) -> ::windows::core::Result<PROXY_ACCESS> { let mut result__: <PROXY_ACCESS as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).13)(::core::mem::transmute_copy(self), &mut result__).from_abi::<PROXY_ACCESS>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn LocalBypass(&self) -> ::windows::core::Result<super::super::Foundation::BOOL> { let mut result__: <super::super::Foundation::BOOL as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).14)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::BOOL>(result__) } pub unsafe fn PortNumber(&self) -> ::windows::core::Result<u32> { let mut result__: <u32 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).15)(::core::mem::transmute_copy(self), &mut result__).from_abi::<u32>(result__) } } unsafe impl ::windows::core::Interface for ISearchManager { type Vtable = ISearchManager_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xab310581_ac80_11d1_8df3_00c04fb6ef69); } impl ::core::convert::From<ISearchManager> for ::windows::core::IUnknown { fn from(value: ISearchManager) -> Self { value.0 } } impl ::core::convert::From<&ISearchManager> for ::windows::core::IUnknown { fn from(value: &ISearchManager) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ISearchManager { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ISearchManager { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ISearchManager_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppszversionstring: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pdwmajor: *mut u32, pdwminor: *mut u32) -> ::windows::core::HRESULT, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszname: super::super::Foundation::PWSTR, ppvalue: *mut *mut super::Com::StructuredStorage::PROPVARIANT) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszname: super::super::Foundation::PWSTR, pvalue: *const ::core::mem::ManuallyDrop<super::Com::StructuredStorage::PROPVARIANT>) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage")))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppszproxyname: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppszbypasslist: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, suseproxy: PROXY_ACCESS, flocalbypassproxy: super::super::Foundation::BOOL, dwportnumber: u32, pszproxyname: super::super::Foundation::PWSTR, pszbypasslist: super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszcatalog: super::super::Foundation::PWSTR, ppcatalogmanager: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppszuseragent: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszuseragent: super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, puseproxy: *mut PROXY_ACCESS) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pflocalbypass: *mut super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pdwportnumber: *mut u32) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ISearchManager2(pub ::windows::core::IUnknown); impl ISearchManager2 { #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetIndexerVersionStr(&self) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } pub unsafe fn GetIndexerVersion(&self, pdwmajor: *mut u32, pdwminor: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(pdwmajor), ::core::mem::transmute(pdwminor)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe fn GetParameter<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszname: Param0) -> ::windows::core::Result<*mut super::Com::StructuredStorage::PROPVARIANT> { let mut result__: <*mut super::Com::StructuredStorage::PROPVARIANT as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), pszname.into_param().abi(), &mut result__).from_abi::<*mut super::Com::StructuredStorage::PROPVARIANT>(result__) } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe fn SetParameter<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszname: Param0, pvalue: *const super::Com::StructuredStorage::PROPVARIANT) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), pszname.into_param().abi(), ::core::mem::transmute(pvalue)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn ProxyName(&self) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn BypassList(&self) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).8)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn SetProxy<'a, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>, Param3: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param4: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, suseproxy: PROXY_ACCESS, flocalbypassproxy: Param1, dwportnumber: u32, pszproxyname: Param3, pszbypasslist: Param4) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).9)(::core::mem::transmute_copy(self), ::core::mem::transmute(suseproxy), flocalbypassproxy.into_param().abi(), ::core::mem::transmute(dwportnumber), pszproxyname.into_param().abi(), pszbypasslist.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetCatalog<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszcatalog: Param0) -> ::windows::core::Result<ISearchCatalogManager> { let mut result__: <ISearchCatalogManager as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).10)(::core::mem::transmute_copy(self), pszcatalog.into_param().abi(), &mut result__).from_abi::<ISearchCatalogManager>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn UserAgent(&self) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).11)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn SetUserAgent<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszuseragent: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).12)(::core::mem::transmute_copy(self), pszuseragent.into_param().abi()).ok() } pub unsafe fn UseProxy(&self) -> ::windows::core::Result<PROXY_ACCESS> { let mut result__: <PROXY_ACCESS as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).13)(::core::mem::transmute_copy(self), &mut result__).from_abi::<PROXY_ACCESS>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn LocalBypass(&self) -> ::windows::core::Result<super::super::Foundation::BOOL> { let mut result__: <super::super::Foundation::BOOL as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).14)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::BOOL>(result__) } pub unsafe fn PortNumber(&self) -> ::windows::core::Result<u32> { let mut result__: <u32 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).15)(::core::mem::transmute_copy(self), &mut result__).from_abi::<u32>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn CreateCatalog<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszcatalog: Param0) -> ::windows::core::Result<ISearchCatalogManager> { let mut result__: <ISearchCatalogManager as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).16)(::core::mem::transmute_copy(self), pszcatalog.into_param().abi(), &mut result__).from_abi::<ISearchCatalogManager>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn DeleteCatalog<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszcatalog: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).17)(::core::mem::transmute_copy(self), pszcatalog.into_param().abi()).ok() } } unsafe impl ::windows::core::Interface for ISearchManager2 { type Vtable = ISearchManager2_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xdbab3f73_db19_4a79_bfc0_a61a93886ddf); } impl ::core::convert::From<ISearchManager2> for ::windows::core::IUnknown { fn from(value: ISearchManager2) -> Self { value.0 } } impl ::core::convert::From<&ISearchManager2> for ::windows::core::IUnknown { fn from(value: &ISearchManager2) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ISearchManager2 { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ISearchManager2 { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } impl ::core::convert::From<ISearchManager2> for ISearchManager { fn from(value: ISearchManager2) -> Self { unsafe { ::core::mem::transmute(value) } } } impl ::core::convert::From<&ISearchManager2> for ISearchManager { fn from(value: &ISearchManager2) -> Self { ::core::convert::From::from(::core::clone::Clone::clone(value)) } } impl<'a> ::windows::core::IntoParam<'a, ISearchManager> for ISearchManager2 { fn into_param(self) -> ::windows::core::Param<'a, ISearchManager> { ::windows::core::Param::Owned(unsafe { ::core::mem::transmute(self) }) } } impl<'a> ::windows::core::IntoParam<'a, ISearchManager> for &ISearchManager2 { fn into_param(self) -> ::windows::core::Param<'a, ISearchManager> { ::windows::core::Param::Borrowed(unsafe { ::core::mem::transmute(self) }) } } #[repr(C)] #[doc(hidden)] pub struct ISearchManager2_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppszversionstring: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pdwmajor: *mut u32, pdwminor: *mut u32) -> ::windows::core::HRESULT, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszname: super::super::Foundation::PWSTR, ppvalue: *mut *mut super::Com::StructuredStorage::PROPVARIANT) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszname: super::super::Foundation::PWSTR, pvalue: *const ::core::mem::ManuallyDrop<super::Com::StructuredStorage::PROPVARIANT>) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage")))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppszproxyname: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppszbypasslist: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, suseproxy: PROXY_ACCESS, flocalbypassproxy: super::super::Foundation::BOOL, dwportnumber: u32, pszproxyname: super::super::Foundation::PWSTR, pszbypasslist: super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszcatalog: super::super::Foundation::PWSTR, ppcatalogmanager: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppszuseragent: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszuseragent: super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, puseproxy: *mut PROXY_ACCESS) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pflocalbypass: *mut super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pdwportnumber: *mut u32) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszcatalog: super::super::Foundation::PWSTR, ppcatalogmanager: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszcatalog: super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ISearchNotifyInlineSite(pub ::windows::core::IUnknown); impl ISearchNotifyInlineSite { pub unsafe fn OnItemIndexedStatusChange(&self, sipstatus: SEARCH_INDEXING_PHASE, dwnumentries: u32, rgitemstatusentries: *const SEARCH_ITEM_INDEXING_STATUS) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(sipstatus), ::core::mem::transmute(dwnumentries), ::core::mem::transmute(rgitemstatusentries)).ok() } pub unsafe fn OnCatalogStatusChange(&self, guidcatalogresetsignature: *const ::windows::core::GUID, guidcheckpointsignature: *const ::windows::core::GUID, dwlastcheckpointnumber: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(guidcatalogresetsignature), ::core::mem::transmute(guidcheckpointsignature), ::core::mem::transmute(dwlastcheckpointnumber)).ok() } } unsafe impl ::windows::core::Interface for ISearchNotifyInlineSite { type Vtable = ISearchNotifyInlineSite_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xb5702e61_e75c_4b64_82a1_6cb4f832fccf); } impl ::core::convert::From<ISearchNotifyInlineSite> for ::windows::core::IUnknown { fn from(value: ISearchNotifyInlineSite) -> Self { value.0 } } impl ::core::convert::From<&ISearchNotifyInlineSite> for ::windows::core::IUnknown { fn from(value: &ISearchNotifyInlineSite) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ISearchNotifyInlineSite { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ISearchNotifyInlineSite { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ISearchNotifyInlineSite_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, sipstatus: SEARCH_INDEXING_PHASE, dwnumentries: u32, rgitemstatusentries: *const SEARCH_ITEM_INDEXING_STATUS) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, guidcatalogresetsignature: *const ::windows::core::GUID, guidcheckpointsignature: *const ::windows::core::GUID, dwlastcheckpointnumber: u32) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ISearchPersistentItemsChangedSink(pub ::windows::core::IUnknown); impl ISearchPersistentItemsChangedSink { #[cfg(feature = "Win32_Foundation")] pub unsafe fn StartedMonitoringScope<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszurl: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), pszurl.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn StoppedMonitoringScope<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszurl: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), pszurl.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn OnItemsChanged(&self, dwnumberofchanges: u32, datachangeentries: *const SEARCH_ITEM_PERSISTENT_CHANGE, hrcompletioncodes: *mut ::windows::core::HRESULT) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(dwnumberofchanges), ::core::mem::transmute(datachangeentries), ::core::mem::transmute(hrcompletioncodes)).ok() } } unsafe impl ::windows::core::Interface for ISearchPersistentItemsChangedSink { type Vtable = ISearchPersistentItemsChangedSink_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xa2ffdf9b_4758_4f84_b729_df81a1a0612f); } impl ::core::convert::From<ISearchPersistentItemsChangedSink> for ::windows::core::IUnknown { fn from(value: ISearchPersistentItemsChangedSink) -> Self { value.0 } } impl ::core::convert::From<&ISearchPersistentItemsChangedSink> for ::windows::core::IUnknown { fn from(value: &ISearchPersistentItemsChangedSink) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ISearchPersistentItemsChangedSink { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ISearchPersistentItemsChangedSink { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ISearchPersistentItemsChangedSink_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszurl: super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszurl: super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, dwnumberofchanges: u32, datachangeentries: *const SEARCH_ITEM_PERSISTENT_CHANGE, hrcompletioncodes: *mut ::windows::core::HRESULT) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ISearchProtocol(pub ::windows::core::IUnknown); impl ISearchProtocol { #[cfg(feature = "Win32_Foundation")] pub unsafe fn Init<'a, Param1: ::windows::core::IntoParam<'a, IProtocolHandlerSite>>(&self, ptimeoutinfo: *mut TIMEOUT_INFO, pprotocolhandlersite: Param1, pproxyinfo: *mut PROXY_INFO) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(ptimeoutinfo), pprotocolhandlersite.into_param().abi(), ::core::mem::transmute(pproxyinfo)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn CreateAccessor<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pcwszurl: Param0, pauthenticationinfo: *mut AUTHENTICATION_INFO, pincrementalaccessinfo: *mut INCREMENTAL_ACCESS_INFO, piteminfo: *mut ITEM_INFO, ppaccessor: *mut ::core::option::Option<IUrlAccessor>) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), pcwszurl.into_param().abi(), ::core::mem::transmute(pauthenticationinfo), ::core::mem::transmute(pincrementalaccessinfo), ::core::mem::transmute(piteminfo), ::core::mem::transmute(ppaccessor)).ok() } pub unsafe fn CloseAccessor<'a, Param0: ::windows::core::IntoParam<'a, IUrlAccessor>>(&self, paccessor: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), paccessor.into_param().abi()).ok() } pub unsafe fn ShutDown(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self)).ok() } } unsafe impl ::windows::core::Interface for ISearchProtocol { type Vtable = ISearchProtocol_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xc73106ba_ac80_11d1_8df3_00c04fb6ef4f); } impl ::core::convert::From<ISearchProtocol> for ::windows::core::IUnknown { fn from(value: ISearchProtocol) -> Self { value.0 } } impl ::core::convert::From<&ISearchProtocol> for ::windows::core::IUnknown { fn from(value: &ISearchProtocol) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ISearchProtocol { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ISearchProtocol { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ISearchProtocol_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ptimeoutinfo: *mut TIMEOUT_INFO, pprotocolhandlersite: ::windows::core::RawPtr, pproxyinfo: *mut PROXY_INFO) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pcwszurl: super::super::Foundation::PWSTR, pauthenticationinfo: *mut AUTHENTICATION_INFO, pincrementalaccessinfo: *mut INCREMENTAL_ACCESS_INFO, piteminfo: *mut ITEM_INFO, ppaccessor: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, paccessor: ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ISearchProtocol2(pub ::windows::core::IUnknown); impl ISearchProtocol2 { #[cfg(feature = "Win32_Foundation")] pub unsafe fn Init<'a, Param1: ::windows::core::IntoParam<'a, IProtocolHandlerSite>>(&self, ptimeoutinfo: *mut TIMEOUT_INFO, pprotocolhandlersite: Param1, pproxyinfo: *mut PROXY_INFO) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(ptimeoutinfo), pprotocolhandlersite.into_param().abi(), ::core::mem::transmute(pproxyinfo)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn CreateAccessor<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pcwszurl: Param0, pauthenticationinfo: *mut AUTHENTICATION_INFO, pincrementalaccessinfo: *mut INCREMENTAL_ACCESS_INFO, piteminfo: *mut ITEM_INFO, ppaccessor: *mut ::core::option::Option<IUrlAccessor>) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), pcwszurl.into_param().abi(), ::core::mem::transmute(pauthenticationinfo), ::core::mem::transmute(pincrementalaccessinfo), ::core::mem::transmute(piteminfo), ::core::mem::transmute(ppaccessor)).ok() } pub unsafe fn CloseAccessor<'a, Param0: ::windows::core::IntoParam<'a, IUrlAccessor>>(&self, paccessor: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), paccessor.into_param().abi()).ok() } pub unsafe fn ShutDown(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub unsafe fn CreateAccessorEx<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pcwszurl: Param0, pauthenticationinfo: *mut AUTHENTICATION_INFO, pincrementalaccessinfo: *mut INCREMENTAL_ACCESS_INFO, piteminfo: *mut ITEM_INFO, puserdata: *const super::Com::BLOB, ppaccessor: *mut ::core::option::Option<IUrlAccessor>) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), pcwszurl.into_param().abi(), ::core::mem::transmute(pauthenticationinfo), ::core::mem::transmute(pincrementalaccessinfo), ::core::mem::transmute(piteminfo), ::core::mem::transmute(puserdata), ::core::mem::transmute(ppaccessor)).ok() } } unsafe impl ::windows::core::Interface for ISearchProtocol2 { type Vtable = ISearchProtocol2_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x7789f0b2_b5b2_4722_8b65_5dbd150697a9); } impl ::core::convert::From<ISearchProtocol2> for ::windows::core::IUnknown { fn from(value: ISearchProtocol2) -> Self { value.0 } } impl ::core::convert::From<&ISearchProtocol2> for ::windows::core::IUnknown { fn from(value: &ISearchProtocol2) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ISearchProtocol2 { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ISearchProtocol2 { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } impl ::core::convert::From<ISearchProtocol2> for ISearchProtocol { fn from(value: ISearchProtocol2) -> Self { unsafe { ::core::mem::transmute(value) } } } impl ::core::convert::From<&ISearchProtocol2> for ISearchProtocol { fn from(value: &ISearchProtocol2) -> Self { ::core::convert::From::from(::core::clone::Clone::clone(value)) } } impl<'a> ::windows::core::IntoParam<'a, ISearchProtocol> for ISearchProtocol2 { fn into_param(self) -> ::windows::core::Param<'a, ISearchProtocol> { ::windows::core::Param::Owned(unsafe { ::core::mem::transmute(self) }) } } impl<'a> ::windows::core::IntoParam<'a, ISearchProtocol> for &ISearchProtocol2 { fn into_param(self) -> ::windows::core::Param<'a, ISearchProtocol> { ::windows::core::Param::Borrowed(unsafe { ::core::mem::transmute(self) }) } } #[repr(C)] #[doc(hidden)] pub struct ISearchProtocol2_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ptimeoutinfo: *mut TIMEOUT_INFO, pprotocolhandlersite: ::windows::core::RawPtr, pproxyinfo: *mut PROXY_INFO) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pcwszurl: super::super::Foundation::PWSTR, pauthenticationinfo: *mut AUTHENTICATION_INFO, pincrementalaccessinfo: *mut INCREMENTAL_ACCESS_INFO, piteminfo: *mut ITEM_INFO, ppaccessor: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, paccessor: ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pcwszurl: super::super::Foundation::PWSTR, pauthenticationinfo: *mut AUTHENTICATION_INFO, pincrementalaccessinfo: *mut INCREMENTAL_ACCESS_INFO, piteminfo: *mut ITEM_INFO, puserdata: *const super::Com::BLOB, ppaccessor: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ISearchProtocolThreadContext(pub ::windows::core::IUnknown); impl ISearchProtocolThreadContext { pub unsafe fn ThreadInit(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self)).ok() } pub unsafe fn ThreadShutdown(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self)).ok() } pub unsafe fn ThreadIdle(&self, dwtimeelaspedsincelastcallinms: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(dwtimeelaspedsincelastcallinms)).ok() } } unsafe impl ::windows::core::Interface for ISearchProtocolThreadContext { type Vtable = ISearchProtocolThreadContext_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xc73106e1_ac80_11d1_8df3_00c04fb6ef4f); } impl ::core::convert::From<ISearchProtocolThreadContext> for ::windows::core::IUnknown { fn from(value: ISearchProtocolThreadContext) -> Self { value.0 } } impl ::core::convert::From<&ISearchProtocolThreadContext> for ::windows::core::IUnknown { fn from(value: &ISearchProtocolThreadContext) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ISearchProtocolThreadContext { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ISearchProtocolThreadContext { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ISearchProtocolThreadContext_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, dwtimeelaspedsincelastcallinms: u32) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ISearchQueryHelper(pub ::windows::core::IUnknown); impl ISearchQueryHelper { #[cfg(feature = "Win32_Foundation")] pub unsafe fn ConnectionString(&self) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } pub unsafe fn SetQueryContentLocale(&self, lcid: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(lcid)).ok() } pub unsafe fn QueryContentLocale(&self) -> ::windows::core::Result<u32> { let mut result__: <u32 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), &mut result__).from_abi::<u32>(result__) } pub unsafe fn SetQueryKeywordLocale(&self, lcid: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), ::core::mem::transmute(lcid)).ok() } pub unsafe fn QueryKeywordLocale(&self) -> ::windows::core::Result<u32> { let mut result__: <u32 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), &mut result__).from_abi::<u32>(result__) } pub unsafe fn SetQueryTermExpansion(&self, expandterms: SEARCH_TERM_EXPANSION) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).8)(::core::mem::transmute_copy(self), ::core::mem::transmute(expandterms)).ok() } pub unsafe fn QueryTermExpansion(&self) -> ::windows::core::Result<SEARCH_TERM_EXPANSION> { let mut result__: <SEARCH_TERM_EXPANSION as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).9)(::core::mem::transmute_copy(self), &mut result__).from_abi::<SEARCH_TERM_EXPANSION>(result__) } pub unsafe fn SetQuerySyntax(&self, querysyntax: SEARCH_QUERY_SYNTAX) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).10)(::core::mem::transmute_copy(self), ::core::mem::transmute(querysyntax)).ok() } pub unsafe fn QuerySyntax(&self) -> ::windows::core::Result<SEARCH_QUERY_SYNTAX> { let mut result__: <SEARCH_QUERY_SYNTAX as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).11)(::core::mem::transmute_copy(self), &mut result__).from_abi::<SEARCH_QUERY_SYNTAX>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn SetQueryContentProperties<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszcontentproperties: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).12)(::core::mem::transmute_copy(self), pszcontentproperties.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn QueryContentProperties(&self) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).13)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn SetQuerySelectColumns<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszselectcolumns: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).14)(::core::mem::transmute_copy(self), pszselectcolumns.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn QuerySelectColumns(&self) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).15)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn SetQueryWhereRestrictions<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszrestrictions: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).16)(::core::mem::transmute_copy(self), pszrestrictions.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn QueryWhereRestrictions(&self) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).17)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn SetQuerySorting<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszsorting: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).18)(::core::mem::transmute_copy(self), pszsorting.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn QuerySorting(&self) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).19)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GenerateSQLFromUserQuery<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszquery: Param0) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).20)(::core::mem::transmute_copy(self), pszquery.into_param().abi(), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_UI_Shell_PropertiesSystem"))] pub unsafe fn WriteProperties(&self, itemid: i32, dwnumberofcolumns: u32, pcolumns: *const super::super::UI::Shell::PropertiesSystem::PROPERTYKEY, pvalues: *const SEARCH_COLUMN_PROPERTIES, pftgathermodifiedtime: *const super::super::Foundation::FILETIME) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).21)(::core::mem::transmute_copy(self), ::core::mem::transmute(itemid), ::core::mem::transmute(dwnumberofcolumns), ::core::mem::transmute(pcolumns), ::core::mem::transmute(pvalues), ::core::mem::transmute(pftgathermodifiedtime)).ok() } pub unsafe fn SetQueryMaxResults(&self, cmaxresults: i32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).22)(::core::mem::transmute_copy(self), ::core::mem::transmute(cmaxresults)).ok() } pub unsafe fn QueryMaxResults(&self) -> ::windows::core::Result<i32> { let mut result__: <i32 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).23)(::core::mem::transmute_copy(self), &mut result__).from_abi::<i32>(result__) } } unsafe impl ::windows::core::Interface for ISearchQueryHelper { type Vtable = ISearchQueryHelper_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xab310581_ac80_11d1_8df3_00c04fb6ef63); } impl ::core::convert::From<ISearchQueryHelper> for ::windows::core::IUnknown { fn from(value: ISearchQueryHelper) -> Self { value.0 } } impl ::core::convert::From<&ISearchQueryHelper> for ::windows::core::IUnknown { fn from(value: &ISearchQueryHelper) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ISearchQueryHelper { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ISearchQueryHelper { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ISearchQueryHelper_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszconnectionstring: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, lcid: u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, plcid: *mut u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, lcid: u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, plcid: *mut u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, expandterms: SEARCH_TERM_EXPANSION) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pexpandterms: *mut SEARCH_TERM_EXPANSION) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, querysyntax: SEARCH_QUERY_SYNTAX) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pquerysyntax: *mut SEARCH_QUERY_SYNTAX) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszcontentproperties: super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppszcontentproperties: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszselectcolumns: super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppszselectcolumns: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszrestrictions: super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppszrestrictions: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszsorting: super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppszsorting: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszquery: super::super::Foundation::PWSTR, ppszsql: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_UI_Shell_PropertiesSystem"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, itemid: i32, dwnumberofcolumns: u32, pcolumns: *const super::super::UI::Shell::PropertiesSystem::PROPERTYKEY, pvalues: *const ::core::mem::ManuallyDrop<SEARCH_COLUMN_PROPERTIES>, pftgathermodifiedtime: *const super::super::Foundation::FILETIME) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_UI_Shell_PropertiesSystem")))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, cmaxresults: i32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pcmaxresults: *mut i32) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ISearchQueryHits(pub ::windows::core::IUnknown); impl ISearchQueryHits { #[cfg(feature = "Win32_Storage_IndexServer")] pub unsafe fn Init<'a, Param0: ::windows::core::IntoParam<'a, super::super::Storage::IndexServer::IFilter>>(&self, pflt: Param0, ulflags: u32) -> i32 { ::core::mem::transmute((::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), pflt.into_param().abi(), ::core::mem::transmute(ulflags))) } #[cfg(feature = "Win32_System_Com")] pub unsafe fn NextHitMoniker(&self, pcmnk: *mut u32, papmnk: *mut *mut ::core::option::Option<super::Com::IMoniker>) -> i32 { ::core::mem::transmute((::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(pcmnk), ::core::mem::transmute(papmnk))) } #[cfg(feature = "Win32_Storage_IndexServer")] pub unsafe fn NextHitOffset(&self, pcregion: *mut u32, paregion: *mut *mut super::super::Storage::IndexServer::FILTERREGION) -> i32 { ::core::mem::transmute((::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(pcregion), ::core::mem::transmute(paregion))) } } unsafe impl ::windows::core::Interface for ISearchQueryHits { type Vtable = ISearchQueryHits_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xed8ce7e0_106c_11ce_84e2_00aa004b9986); } impl ::core::convert::From<ISearchQueryHits> for ::windows::core::IUnknown { fn from(value: ISearchQueryHits) -> Self { value.0 } } impl ::core::convert::From<&ISearchQueryHits> for ::windows::core::IUnknown { fn from(value: &ISearchQueryHits) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ISearchQueryHits { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ISearchQueryHits { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ISearchQueryHits_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Storage_IndexServer")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pflt: ::windows::core::RawPtr, ulflags: u32) -> i32, #[cfg(not(feature = "Win32_Storage_IndexServer"))] usize, #[cfg(feature = "Win32_System_Com")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pcmnk: *mut u32, papmnk: *mut *mut ::windows::core::RawPtr) -> i32, #[cfg(not(feature = "Win32_System_Com"))] usize, #[cfg(feature = "Win32_Storage_IndexServer")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pcregion: *mut u32, paregion: *mut *mut super::super::Storage::IndexServer::FILTERREGION) -> i32, #[cfg(not(feature = "Win32_Storage_IndexServer"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ISearchRoot(pub ::windows::core::IUnknown); impl ISearchRoot { #[cfg(feature = "Win32_Foundation")] pub unsafe fn SetSchedule<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, psztaskarg: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), psztaskarg.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn Schedule(&self) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn SetRootURL<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszurl: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), pszurl.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn RootURL(&self) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn SetIsHierarchical<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>(&self, fishierarchical: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), fishierarchical.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn IsHierarchical(&self) -> ::windows::core::Result<super::super::Foundation::BOOL> { let mut result__: <super::super::Foundation::BOOL as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).8)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::BOOL>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn SetProvidesNotifications<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>(&self, fprovidesnotifications: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).9)(::core::mem::transmute_copy(self), fprovidesnotifications.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn ProvidesNotifications(&self) -> ::windows::core::Result<super::super::Foundation::BOOL> { let mut result__: <super::super::Foundation::BOOL as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).10)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::BOOL>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn SetUseNotificationsOnly<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>(&self, fusenotificationsonly: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).11)(::core::mem::transmute_copy(self), fusenotificationsonly.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn UseNotificationsOnly(&self) -> ::windows::core::Result<super::super::Foundation::BOOL> { let mut result__: <super::super::Foundation::BOOL as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).12)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::BOOL>(result__) } pub unsafe fn SetEnumerationDepth(&self, dwdepth: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).13)(::core::mem::transmute_copy(self), ::core::mem::transmute(dwdepth)).ok() } pub unsafe fn EnumerationDepth(&self) -> ::windows::core::Result<u32> { let mut result__: <u32 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).14)(::core::mem::transmute_copy(self), &mut result__).from_abi::<u32>(result__) } pub unsafe fn SetHostDepth(&self, dwdepth: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).15)(::core::mem::transmute_copy(self), ::core::mem::transmute(dwdepth)).ok() } pub unsafe fn HostDepth(&self) -> ::windows::core::Result<u32> { let mut result__: <u32 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).16)(::core::mem::transmute_copy(self), &mut result__).from_abi::<u32>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn SetFollowDirectories<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>(&self, ffollowdirectories: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).17)(::core::mem::transmute_copy(self), ffollowdirectories.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn FollowDirectories(&self) -> ::windows::core::Result<super::super::Foundation::BOOL> { let mut result__: <super::super::Foundation::BOOL as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).18)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::BOOL>(result__) } pub unsafe fn SetAuthenticationType(&self, authtype: AUTH_TYPE) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).19)(::core::mem::transmute_copy(self), ::core::mem::transmute(authtype)).ok() } pub unsafe fn AuthenticationType(&self) -> ::windows::core::Result<AUTH_TYPE> { let mut result__: <AUTH_TYPE as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).20)(::core::mem::transmute_copy(self), &mut result__).from_abi::<AUTH_TYPE>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn SetUser<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszuser: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).21)(::core::mem::transmute_copy(self), pszuser.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn User(&self) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).22)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn SetPassword<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pszpassword: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).23)(::core::mem::transmute_copy(self), pszpassword.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn Password(&self) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).24)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } } unsafe impl ::windows::core::Interface for ISearchRoot { type Vtable = ISearchRoot_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x04c18ccf_1f57_4cbd_88cc_3900f5195ce3); } impl ::core::convert::From<ISearchRoot> for ::windows::core::IUnknown { fn from(value: ISearchRoot) -> Self { value.0 } } impl ::core::convert::From<&ISearchRoot> for ::windows::core::IUnknown { fn from(value: &ISearchRoot) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ISearchRoot { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ISearchRoot { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ISearchRoot_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, psztaskarg: super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppsztaskarg: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszurl: super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppszurl: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, fishierarchical: super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pfishierarchical: *mut super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, fprovidesnotifications: super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pfprovidesnotifications: *mut super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, fusenotificationsonly: super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pfusenotificationsonly: *mut super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, dwdepth: u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pdwdepth: *mut u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, dwdepth: u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pdwdepth: *mut u32) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ffollowdirectories: super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pffollowdirectories: *mut super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, authtype: AUTH_TYPE) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pauthtype: *mut AUTH_TYPE) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszuser: super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppszuser: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pszpassword: super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppszpassword: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ISearchScopeRule(pub ::windows::core::IUnknown); impl ISearchScopeRule { #[cfg(feature = "Win32_Foundation")] pub unsafe fn PatternOrURL(&self) -> ::windows::core::Result<super::super::Foundation::PWSTR> { let mut result__: <super::super::Foundation::PWSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::PWSTR>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn IsIncluded(&self) -> ::windows::core::Result<super::super::Foundation::BOOL> { let mut result__: <super::super::Foundation::BOOL as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::BOOL>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn IsDefault(&self) -> ::windows::core::Result<super::super::Foundation::BOOL> { let mut result__: <super::super::Foundation::BOOL as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::BOOL>(result__) } pub unsafe fn FollowFlags(&self) -> ::windows::core::Result<u32> { let mut result__: <u32 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), &mut result__).from_abi::<u32>(result__) } } unsafe impl ::windows::core::Interface for ISearchScopeRule { type Vtable = ISearchScopeRule_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xab310581_ac80_11d1_8df3_00c04fb6ef53); } impl ::core::convert::From<ISearchScopeRule> for ::windows::core::IUnknown { fn from(value: ISearchScopeRule) -> Self { value.0 } } impl ::core::convert::From<&ISearchScopeRule> for ::windows::core::IUnknown { fn from(value: &ISearchScopeRule) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ISearchScopeRule { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ISearchScopeRule { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ISearchScopeRule_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppszpatternorurl: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pfisincluded: *mut super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pfisdefault: *mut super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pfollowflags: *mut u32) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ISearchViewChangedSink(pub ::windows::core::IUnknown); impl ISearchViewChangedSink { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub unsafe fn OnChange(&self, pdwdocid: *const i32, pchange: *const SEARCH_ITEM_CHANGE, pfinview: *const super::super::Foundation::BOOL) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(pdwdocid), ::core::mem::transmute(pchange), ::core::mem::transmute(pfinview)).ok() } } unsafe impl ::windows::core::Interface for ISearchViewChangedSink { type Vtable = ISearchViewChangedSink_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xab310581_ac80_11d1_8df3_00c04fb6ef65); } impl ::core::convert::From<ISearchViewChangedSink> for ::windows::core::IUnknown { fn from(value: ISearchViewChangedSink) -> Self { value.0 } } impl ::core::convert::From<&ISearchViewChangedSink> for ::windows::core::IUnknown { fn from(value: &ISearchViewChangedSink) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ISearchViewChangedSink { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ISearchViewChangedSink { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ISearchViewChangedSink_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pdwdocid: *const i32, pchange: *const SEARCH_ITEM_CHANGE, pfinview: *const super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ISecurityInfo(pub ::windows::core::IUnknown); impl ISecurityInfo { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization"))] pub unsafe fn GetCurrentTrustee(&self, pptrustee: *mut *mut super::super::Security::Authorization::TRUSTEE_W) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(pptrustee)).ok() } pub unsafe fn GetObjectTypes(&self, cobjecttypes: *mut u32, rgobjecttypes: *mut *mut ::windows::core::GUID) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(cobjecttypes), ::core::mem::transmute(rgobjecttypes)).ok() } pub unsafe fn GetPermissions<'a, Param0: ::windows::core::IntoParam<'a, ::windows::core::GUID>>(&self, objecttype: Param0, ppermissions: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), objecttype.into_param().abi(), ::core::mem::transmute(ppermissions)).ok() } } unsafe impl ::windows::core::Interface for ISecurityInfo { type Vtable = ISecurityInfo_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733aa4_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<ISecurityInfo> for ::windows::core::IUnknown { fn from(value: ISecurityInfo) -> Self { value.0 } } impl ::core::convert::From<&ISecurityInfo> for ::windows::core::IUnknown { fn from(value: &ISecurityInfo) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ISecurityInfo { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ISecurityInfo { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ISecurityInfo_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pptrustee: *mut *mut super::super::Security::Authorization::TRUSTEE_W) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization")))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, cobjecttypes: *mut u32, rgobjecttypes: *mut *mut ::windows::core::GUID) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, objecttype: ::windows::core::GUID, ppermissions: *mut u32) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IService(pub ::windows::core::IUnknown); impl IService { pub unsafe fn InvokeService<'a, Param0: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>>(&self, punkinner: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), punkinner.into_param().abi()).ok() } } unsafe impl ::windows::core::Interface for IService { type Vtable = IService_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x06210e88_01f5_11d1_b512_0080c781c384); } impl ::core::convert::From<IService> for ::windows::core::IUnknown { fn from(value: IService) -> Self { value.0 } } impl ::core::convert::From<&IService> for ::windows::core::IUnknown { fn from(value: &IService) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IService { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IService { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IService_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, punkinner: ::windows::core::RawPtr) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ISessionProperties(pub ::windows::core::IUnknown); impl ISessionProperties { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn GetProperties(&self, cpropertyidsets: u32, rgpropertyidsets: *const DBPROPIDSET, pcpropertysets: *mut u32, prgpropertysets: *mut *mut DBPROPSET) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(cpropertyidsets), ::core::mem::transmute(rgpropertyidsets), ::core::mem::transmute(pcpropertysets), ::core::mem::transmute(prgpropertysets)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn SetProperties(&self, cpropertysets: u32, rgpropertysets: *mut DBPROPSET) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(cpropertysets), ::core::mem::transmute(rgpropertysets)).ok() } } unsafe impl ::windows::core::Interface for ISessionProperties { type Vtable = ISessionProperties_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a85_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<ISessionProperties> for ::windows::core::IUnknown { fn from(value: ISessionProperties) -> Self { value.0 } } impl ::core::convert::From<&ISessionProperties> for ::windows::core::IUnknown { fn from(value: &ISessionProperties) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ISessionProperties { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ISessionProperties { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ISessionProperties_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, cpropertyidsets: u32, rgpropertyidsets: *const DBPROPIDSET, pcpropertysets: *mut u32, prgpropertysets: *mut *mut DBPROPSET) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, cpropertysets: u32, rgpropertysets: *mut DBPROPSET) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ISimpleCommandCreator(pub ::windows::core::IUnknown); impl ISimpleCommandCreator { pub unsafe fn CreateICommand<'a, Param1: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>>(&self, ppiunknown: *mut ::core::option::Option<::windows::core::IUnknown>, pouterunk: Param1) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(ppiunknown), pouterunk.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn VerifyCatalog<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pwszmachine: Param0, pwszcatalogname: Param1) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), pwszmachine.into_param().abi(), pwszcatalogname.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetDefaultCatalog<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pwszcatalogname: Param0, cwcin: u32, pcwcout: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), pwszcatalogname.into_param().abi(), ::core::mem::transmute(cwcin), ::core::mem::transmute(pcwcout)).ok() } } unsafe impl ::windows::core::Interface for ISimpleCommandCreator { type Vtable = ISimpleCommandCreator_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x5e341ab7_02d0_11d1_900c_00a0c9063796); } impl ::core::convert::From<ISimpleCommandCreator> for ::windows::core::IUnknown { fn from(value: ISimpleCommandCreator) -> Self { value.0 } } impl ::core::convert::From<&ISimpleCommandCreator> for ::windows::core::IUnknown { fn from(value: &ISimpleCommandCreator) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ISimpleCommandCreator { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ISimpleCommandCreator { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ISimpleCommandCreator_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppiunknown: *mut ::windows::core::RawPtr, pouterunk: ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pwszmachine: super::super::Foundation::PWSTR, pwszcatalogname: super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pwszcatalogname: super::super::Foundation::PWSTR, cwcin: u32, pcwcout: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ISourcesRowset(pub ::windows::core::IUnknown); impl ISourcesRowset { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn GetSourcesRowset<'a, Param0: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>>(&self, punkouter: Param0, riid: *const ::windows::core::GUID, cpropertysets: u32, rgproperties: *mut DBPROPSET, ppsourcesrowset: *mut ::core::option::Option<::windows::core::IUnknown>) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), punkouter.into_param().abi(), ::core::mem::transmute(riid), ::core::mem::transmute(cpropertysets), ::core::mem::transmute(rgproperties), ::core::mem::transmute(ppsourcesrowset)).ok() } } unsafe impl ::windows::core::Interface for ISourcesRowset { type Vtable = ISourcesRowset_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a1e_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<ISourcesRowset> for ::windows::core::IUnknown { fn from(value: ISourcesRowset) -> Self { value.0 } } impl ::core::convert::From<&ISourcesRowset> for ::windows::core::IUnknown { fn from(value: &ISourcesRowset) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ISourcesRowset { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ISourcesRowset { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ISourcesRowset_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, punkouter: ::windows::core::RawPtr, riid: *const ::windows::core::GUID, cpropertysets: u32, rgproperties: *mut DBPROPSET, ppsourcesrowset: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IStemmer(pub ::windows::core::IUnknown); impl IStemmer { #[cfg(feature = "Win32_Foundation")] pub unsafe fn Init(&self, ulmaxtokensize: u32, pflicense: *mut super::super::Foundation::BOOL) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(ulmaxtokensize), ::core::mem::transmute(pflicense)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GenerateWordForms<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param2: ::windows::core::IntoParam<'a, IWordFormSink>>(&self, pwcinbuf: Param0, cwc: u32, pstemsink: Param2) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), pwcinbuf.into_param().abi(), ::core::mem::transmute(cwc), pstemsink.into_param().abi()).ok() } pub unsafe fn GetLicenseToUse(&self, ppwcslicense: *const *const u16) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(ppwcslicense)).ok() } } unsafe impl ::windows::core::Interface for IStemmer { type Vtable = IStemmer_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xefbaf140_7f42_11ce_be57_00aa0051fe20); } impl ::core::convert::From<IStemmer> for ::windows::core::IUnknown { fn from(value: IStemmer) -> Self { value.0 } } impl ::core::convert::From<&IStemmer> for ::windows::core::IUnknown { fn from(value: &IStemmer) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IStemmer { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IStemmer { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IStemmer_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ulmaxtokensize: u32, pflicense: *mut super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pwcinbuf: super::super::Foundation::PWSTR, cwc: u32, pstemsink: ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppwcslicense: *const *const u16) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ISubscriptionItem(pub ::windows::core::IUnknown); impl ISubscriptionItem { pub unsafe fn GetCookie(&self) -> ::windows::core::Result<::windows::core::GUID> { let mut result__: <::windows::core::GUID as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), &mut result__).from_abi::<::windows::core::GUID>(result__) } pub unsafe fn GetSubscriptionItemInfo(&self) -> ::windows::core::Result<SUBSCRIPTIONITEMINFO> { let mut result__: <SUBSCRIPTIONITEMINFO as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), &mut result__).from_abi::<SUBSCRIPTIONITEMINFO>(result__) } pub unsafe fn SetSubscriptionItemInfo(&self, psubscriptioniteminfo: *const SUBSCRIPTIONITEMINFO) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(psubscriptioniteminfo)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn ReadProperties(&self, ncount: u32, rgwszname: *const super::super::Foundation::PWSTR, rgvalue: *mut super::Com::VARIANT) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), ::core::mem::transmute(ncount), ::core::mem::transmute(rgwszname), ::core::mem::transmute(rgvalue)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn WriteProperties(&self, ncount: u32, rgwszname: *const super::super::Foundation::PWSTR, rgvalue: *const super::Com::VARIANT) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), ::core::mem::transmute(ncount), ::core::mem::transmute(rgwszname), ::core::mem::transmute(rgvalue)).ok() } pub unsafe fn EnumProperties(&self) -> ::windows::core::Result<IEnumItemProperties> { let mut result__: <IEnumItemProperties as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).8)(::core::mem::transmute_copy(self), &mut result__).from_abi::<IEnumItemProperties>(result__) } pub unsafe fn NotifyChanged(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).9)(::core::mem::transmute_copy(self)).ok() } } unsafe impl ::windows::core::Interface for ISubscriptionItem { type Vtable = ISubscriptionItem_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xa97559f8_6c4a_11d1_a1e8_00c04fc2fbe1); } impl ::core::convert::From<ISubscriptionItem> for ::windows::core::IUnknown { fn from(value: ISubscriptionItem) -> Self { value.0 } } impl ::core::convert::From<&ISubscriptionItem> for ::windows::core::IUnknown { fn from(value: &ISubscriptionItem) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ISubscriptionItem { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ISubscriptionItem { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ISubscriptionItem_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pcookie: *mut ::windows::core::GUID) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, psubscriptioniteminfo: *mut SUBSCRIPTIONITEMINFO) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, psubscriptioniteminfo: *const SUBSCRIPTIONITEMINFO) -> ::windows::core::HRESULT, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ncount: u32, rgwszname: *const super::super::Foundation::PWSTR, rgvalue: *mut ::core::mem::ManuallyDrop<super::Com::VARIANT>) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ncount: u32, rgwszname: *const super::super::Foundation::PWSTR, rgvalue: *const ::core::mem::ManuallyDrop<super::Com::VARIANT>) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppenumitemproperties: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ISubscriptionMgr(pub ::windows::core::IUnknown); impl ISubscriptionMgr { #[cfg(feature = "Win32_Foundation")] pub unsafe fn DeleteSubscription<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::HWND>>(&self, pwszurl: Param0, hwnd: Param1) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), pwszurl.into_param().abi(), hwnd.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn UpdateSubscription<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pwszurl: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), pwszurl.into_param().abi()).ok() } pub unsafe fn UpdateAll(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn IsSubscribed<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pwszurl: Param0) -> ::windows::core::Result<super::super::Foundation::BOOL> { let mut result__: <super::super::Foundation::BOOL as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), pwszurl.into_param().abi(), &mut result__).from_abi::<super::super::Foundation::BOOL>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetSubscriptionInfo<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pwszurl: Param0) -> ::windows::core::Result<SUBSCRIPTIONINFO> { let mut result__: <SUBSCRIPTIONINFO as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), pwszurl.into_param().abi(), &mut result__).from_abi::<SUBSCRIPTIONINFO>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetDefaultInfo(&self, subtype: SUBSCRIPTIONTYPE) -> ::windows::core::Result<SUBSCRIPTIONINFO> { let mut result__: <SUBSCRIPTIONINFO as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).8)(::core::mem::transmute_copy(self), ::core::mem::transmute(subtype), &mut result__).from_abi::<SUBSCRIPTIONINFO>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn ShowSubscriptionProperties<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::HWND>>(&self, pwszurl: Param0, hwnd: Param1) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).9)(::core::mem::transmute_copy(self), pwszurl.into_param().abi(), hwnd.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn CreateSubscription<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::HWND>, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param2: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, hwnd: Param0, pwszurl: Param1, pwszfriendlyname: Param2, dwflags: u32, substype: SUBSCRIPTIONTYPE, pinfo: *mut SUBSCRIPTIONINFO) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).10)(::core::mem::transmute_copy(self), hwnd.into_param().abi(), pwszurl.into_param().abi(), pwszfriendlyname.into_param().abi(), ::core::mem::transmute(dwflags), ::core::mem::transmute(substype), ::core::mem::transmute(pinfo)).ok() } } unsafe impl ::windows::core::Interface for ISubscriptionMgr { type Vtable = ISubscriptionMgr_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x085fb2c0_0df8_11d1_8f4b_00a0c905413f); } impl ::core::convert::From<ISubscriptionMgr> for ::windows::core::IUnknown { fn from(value: ISubscriptionMgr) -> Self { value.0 } } impl ::core::convert::From<&ISubscriptionMgr> for ::windows::core::IUnknown { fn from(value: &ISubscriptionMgr) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ISubscriptionMgr { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ISubscriptionMgr { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ISubscriptionMgr_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pwszurl: super::super::Foundation::PWSTR, hwnd: super::super::Foundation::HWND) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pwszurl: super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pwszurl: super::super::Foundation::PWSTR, pfsubscribed: *mut super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pwszurl: super::super::Foundation::PWSTR, pinfo: *mut ::core::mem::ManuallyDrop<SUBSCRIPTIONINFO>) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, subtype: SUBSCRIPTIONTYPE, pinfo: *mut ::core::mem::ManuallyDrop<SUBSCRIPTIONINFO>) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pwszurl: super::super::Foundation::PWSTR, hwnd: super::super::Foundation::HWND) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hwnd: super::super::Foundation::HWND, pwszurl: super::super::Foundation::PWSTR, pwszfriendlyname: super::super::Foundation::PWSTR, dwflags: u32, substype: SUBSCRIPTIONTYPE, pinfo: *mut ::core::mem::ManuallyDrop<SUBSCRIPTIONINFO>) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ISubscriptionMgr2(pub ::windows::core::IUnknown); impl ISubscriptionMgr2 { #[cfg(feature = "Win32_Foundation")] pub unsafe fn DeleteSubscription<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::HWND>>(&self, pwszurl: Param0, hwnd: Param1) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), pwszurl.into_param().abi(), hwnd.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn UpdateSubscription<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pwszurl: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), pwszurl.into_param().abi()).ok() } pub unsafe fn UpdateAll(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn IsSubscribed<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pwszurl: Param0) -> ::windows::core::Result<super::super::Foundation::BOOL> { let mut result__: <super::super::Foundation::BOOL as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), pwszurl.into_param().abi(), &mut result__).from_abi::<super::super::Foundation::BOOL>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetSubscriptionInfo<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pwszurl: Param0) -> ::windows::core::Result<SUBSCRIPTIONINFO> { let mut result__: <SUBSCRIPTIONINFO as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), pwszurl.into_param().abi(), &mut result__).from_abi::<SUBSCRIPTIONINFO>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetDefaultInfo(&self, subtype: SUBSCRIPTIONTYPE) -> ::windows::core::Result<SUBSCRIPTIONINFO> { let mut result__: <SUBSCRIPTIONINFO as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).8)(::core::mem::transmute_copy(self), ::core::mem::transmute(subtype), &mut result__).from_abi::<SUBSCRIPTIONINFO>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn ShowSubscriptionProperties<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::HWND>>(&self, pwszurl: Param0, hwnd: Param1) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).9)(::core::mem::transmute_copy(self), pwszurl.into_param().abi(), hwnd.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn CreateSubscription<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::HWND>, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param2: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, hwnd: Param0, pwszurl: Param1, pwszfriendlyname: Param2, dwflags: u32, substype: SUBSCRIPTIONTYPE, pinfo: *mut SUBSCRIPTIONINFO) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).10)(::core::mem::transmute_copy(self), hwnd.into_param().abi(), pwszurl.into_param().abi(), pwszfriendlyname.into_param().abi(), ::core::mem::transmute(dwflags), ::core::mem::transmute(substype), ::core::mem::transmute(pinfo)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetItemFromURL<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pwszurl: Param0) -> ::windows::core::Result<ISubscriptionItem> { let mut result__: <ISubscriptionItem as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).11)(::core::mem::transmute_copy(self), pwszurl.into_param().abi(), &mut result__).from_abi::<ISubscriptionItem>(result__) } pub unsafe fn GetItemFromCookie(&self, psubscriptioncookie: *const ::windows::core::GUID) -> ::windows::core::Result<ISubscriptionItem> { let mut result__: <ISubscriptionItem as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).12)(::core::mem::transmute_copy(self), ::core::mem::transmute(psubscriptioncookie), &mut result__).from_abi::<ISubscriptionItem>(result__) } pub unsafe fn GetSubscriptionRunState(&self, dwnumcookies: u32, pcookies: *const ::windows::core::GUID, pdwrunstate: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).13)(::core::mem::transmute_copy(self), ::core::mem::transmute(dwnumcookies), ::core::mem::transmute(pcookies), ::core::mem::transmute(pdwrunstate)).ok() } pub unsafe fn EnumSubscriptions(&self, dwflags: u32) -> ::windows::core::Result<IEnumSubscription> { let mut result__: <IEnumSubscription as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).14)(::core::mem::transmute_copy(self), ::core::mem::transmute(dwflags), &mut result__).from_abi::<IEnumSubscription>(result__) } pub unsafe fn UpdateItems(&self, dwflags: u32, dwnumcookies: u32, pcookies: *const ::windows::core::GUID) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).15)(::core::mem::transmute_copy(self), ::core::mem::transmute(dwflags), ::core::mem::transmute(dwnumcookies), ::core::mem::transmute(pcookies)).ok() } pub unsafe fn AbortItems(&self, dwnumcookies: u32, pcookies: *const ::windows::core::GUID) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).16)(::core::mem::transmute_copy(self), ::core::mem::transmute(dwnumcookies), ::core::mem::transmute(pcookies)).ok() } pub unsafe fn AbortAll(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).17)(::core::mem::transmute_copy(self)).ok() } } unsafe impl ::windows::core::Interface for ISubscriptionMgr2 { type Vtable = ISubscriptionMgr2_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x614bc270_aedf_11d1_a1f9_00c04fc2fbe1); } impl ::core::convert::From<ISubscriptionMgr2> for ::windows::core::IUnknown { fn from(value: ISubscriptionMgr2) -> Self { value.0 } } impl ::core::convert::From<&ISubscriptionMgr2> for ::windows::core::IUnknown { fn from(value: &ISubscriptionMgr2) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ISubscriptionMgr2 { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ISubscriptionMgr2 { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } impl ::core::convert::From<ISubscriptionMgr2> for ISubscriptionMgr { fn from(value: ISubscriptionMgr2) -> Self { unsafe { ::core::mem::transmute(value) } } } impl ::core::convert::From<&ISubscriptionMgr2> for ISubscriptionMgr { fn from(value: &ISubscriptionMgr2) -> Self { ::core::convert::From::from(::core::clone::Clone::clone(value)) } } impl<'a> ::windows::core::IntoParam<'a, ISubscriptionMgr> for ISubscriptionMgr2 { fn into_param(self) -> ::windows::core::Param<'a, ISubscriptionMgr> { ::windows::core::Param::Owned(unsafe { ::core::mem::transmute(self) }) } } impl<'a> ::windows::core::IntoParam<'a, ISubscriptionMgr> for &ISubscriptionMgr2 { fn into_param(self) -> ::windows::core::Param<'a, ISubscriptionMgr> { ::windows::core::Param::Borrowed(unsafe { ::core::mem::transmute(self) }) } } #[repr(C)] #[doc(hidden)] pub struct ISubscriptionMgr2_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pwszurl: super::super::Foundation::PWSTR, hwnd: super::super::Foundation::HWND) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pwszurl: super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pwszurl: super::super::Foundation::PWSTR, pfsubscribed: *mut super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pwszurl: super::super::Foundation::PWSTR, pinfo: *mut ::core::mem::ManuallyDrop<SUBSCRIPTIONINFO>) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, subtype: SUBSCRIPTIONTYPE, pinfo: *mut ::core::mem::ManuallyDrop<SUBSCRIPTIONINFO>) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pwszurl: super::super::Foundation::PWSTR, hwnd: super::super::Foundation::HWND) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hwnd: super::super::Foundation::HWND, pwszurl: super::super::Foundation::PWSTR, pwszfriendlyname: super::super::Foundation::PWSTR, dwflags: u32, substype: SUBSCRIPTIONTYPE, pinfo: *mut ::core::mem::ManuallyDrop<SUBSCRIPTIONINFO>) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pwszurl: super::super::Foundation::PWSTR, ppsubscriptionitem: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, psubscriptioncookie: *const ::windows::core::GUID, ppsubscriptionitem: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, dwnumcookies: u32, pcookies: *const ::windows::core::GUID, pdwrunstate: *mut u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, dwflags: u32, ppenumsubscriptions: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, dwflags: u32, dwnumcookies: u32, pcookies: *const ::windows::core::GUID) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, dwnumcookies: u32, pcookies: *const ::windows::core::GUID) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, ); #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::clone::Clone for ITEMPROP { fn clone(&self) -> Self { unimplemented!() } } #[repr(C)] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub struct ITEMPROP { pub variantValue: super::Com::VARIANT, pub pwszName: super::super::Foundation::PWSTR, } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ITEMPROP {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::default::Default for ITEMPROP { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::cmp::PartialEq for ITEMPROP { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::cmp::Eq for ITEMPROP {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] unsafe impl ::windows::core::Abi for ITEMPROP { type Abi = ::core::mem::ManuallyDrop<Self>; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(feature = "Win32_Foundation")] pub struct ITEM_INFO { pub dwSize: u32, pub pcwszFromEMail: super::super::Foundation::PWSTR, pub pcwszApplicationName: super::super::Foundation::PWSTR, pub pcwszCatalogName: super::super::Foundation::PWSTR, pub pcwszContentClass: super::super::Foundation::PWSTR, } #[cfg(feature = "Win32_Foundation")] impl ITEM_INFO {} #[cfg(feature = "Win32_Foundation")] impl ::core::default::Default for ITEM_INFO { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(feature = "Win32_Foundation")] impl ::core::fmt::Debug for ITEM_INFO { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("ITEM_INFO").field("dwSize", &self.dwSize).field("pcwszFromEMail", &self.pcwszFromEMail).field("pcwszApplicationName", &self.pcwszApplicationName).field("pcwszCatalogName", &self.pcwszCatalogName).field("pcwszContentClass", &self.pcwszContentClass).finish() } } #[cfg(feature = "Win32_Foundation")] impl ::core::cmp::PartialEq for ITEM_INFO { fn eq(&self, other: &Self) -> bool { self.dwSize == other.dwSize && self.pcwszFromEMail == other.pcwszFromEMail && self.pcwszApplicationName == other.pcwszApplicationName && self.pcwszCatalogName == other.pcwszCatalogName && self.pcwszContentClass == other.pcwszContentClass } } #[cfg(feature = "Win32_Foundation")] impl ::core::cmp::Eq for ITEM_INFO {} #[cfg(feature = "Win32_Foundation")] unsafe impl ::windows::core::Abi for ITEM_INFO { type Abi = Self; } #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ITableCreation(pub ::windows::core::IUnknown); impl ITableCreation { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn CreateTable<'a, Param0: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>>(&self, punkouter: Param0, ptableid: *const super::super::Storage::IndexServer::DBID, ccolumndescs: usize, rgcolumndescs: *const DBCOLUMNDESC, riid: *const ::windows::core::GUID, cpropertysets: u32, rgpropertysets: *mut DBPROPSET, pptableid: *mut *mut super::super::Storage::IndexServer::DBID, pprowset: *mut ::core::option::Option<::windows::core::IUnknown>) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)( ::core::mem::transmute_copy(self), punkouter.into_param().abi(), ::core::mem::transmute(ptableid), ::core::mem::transmute(ccolumndescs), ::core::mem::transmute(rgcolumndescs), ::core::mem::transmute(riid), ::core::mem::transmute(cpropertysets), ::core::mem::transmute(rgpropertysets), ::core::mem::transmute(pptableid), ::core::mem::transmute(pprowset), ) .ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe fn DropTable(&self, ptableid: *const super::super::Storage::IndexServer::DBID) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(ptableid)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn AddColumn(&self, ptableid: *const super::super::Storage::IndexServer::DBID, pcolumndesc: *const DBCOLUMNDESC) -> ::windows::core::Result<*mut super::super::Storage::IndexServer::DBID> { let mut result__: <*mut super::super::Storage::IndexServer::DBID as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(ptableid), ::core::mem::transmute(pcolumndesc), &mut result__).from_abi::<*mut super::super::Storage::IndexServer::DBID>(result__) } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe fn DropColumn(&self, ptableid: *const super::super::Storage::IndexServer::DBID, pcolumnid: *const super::super::Storage::IndexServer::DBID) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), ::core::mem::transmute(ptableid), ::core::mem::transmute(pcolumnid)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn GetTableDefinition(&self, ptableid: *const super::super::Storage::IndexServer::DBID, pccolumndescs: *mut usize, prgcolumndescs: *mut *mut DBCOLUMNDESC, pcpropertysets: *mut u32, prgpropertysets: *mut *mut DBPROPSET, pcconstraintdescs: *mut u32, prgconstraintdescs: *mut *mut DBCONSTRAINTDESC, ppwszstringbuffer: *mut *mut u16) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).7)( ::core::mem::transmute_copy(self), ::core::mem::transmute(ptableid), ::core::mem::transmute(pccolumndescs), ::core::mem::transmute(prgcolumndescs), ::core::mem::transmute(pcpropertysets), ::core::mem::transmute(prgpropertysets), ::core::mem::transmute(pcconstraintdescs), ::core::mem::transmute(prgconstraintdescs), ::core::mem::transmute(ppwszstringbuffer), ) .ok() } } unsafe impl ::windows::core::Interface for ITableCreation { type Vtable = ITableCreation_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733abc_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<ITableCreation> for ::windows::core::IUnknown { fn from(value: ITableCreation) -> Self { value.0 } } impl ::core::convert::From<&ITableCreation> for ::windows::core::IUnknown { fn from(value: &ITableCreation) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ITableCreation { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ITableCreation { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } impl ::core::convert::From<ITableCreation> for ITableDefinition { fn from(value: ITableCreation) -> Self { unsafe { ::core::mem::transmute(value) } } } impl ::core::convert::From<&ITableCreation> for ITableDefinition { fn from(value: &ITableCreation) -> Self { ::core::convert::From::from(::core::clone::Clone::clone(value)) } } impl<'a> ::windows::core::IntoParam<'a, ITableDefinition> for ITableCreation { fn into_param(self) -> ::windows::core::Param<'a, ITableDefinition> { ::windows::core::Param::Owned(unsafe { ::core::mem::transmute(self) }) } } impl<'a> ::windows::core::IntoParam<'a, ITableDefinition> for &ITableCreation { fn into_param(self) -> ::windows::core::Param<'a, ITableDefinition> { ::windows::core::Param::Borrowed(unsafe { ::core::mem::transmute(self) }) } } #[repr(C)] #[doc(hidden)] pub struct ITableCreation_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, punkouter: ::windows::core::RawPtr, ptableid: *const super::super::Storage::IndexServer::DBID, ccolumndescs: usize, rgcolumndescs: *const ::core::mem::ManuallyDrop<DBCOLUMNDESC>, riid: *const ::windows::core::GUID, cpropertysets: u32, rgpropertysets: *mut DBPROPSET, pptableid: *mut *mut super::super::Storage::IndexServer::DBID, pprowset: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ptableid: *const super::super::Storage::IndexServer::DBID) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ptableid: *const super::super::Storage::IndexServer::DBID, pcolumndesc: *const ::core::mem::ManuallyDrop<DBCOLUMNDESC>, ppcolumnid: *mut *mut super::super::Storage::IndexServer::DBID) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ptableid: *const super::super::Storage::IndexServer::DBID, pcolumnid: *const super::super::Storage::IndexServer::DBID) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ptableid: *const super::super::Storage::IndexServer::DBID, pccolumndescs: *mut usize, prgcolumndescs: *mut *mut DBCOLUMNDESC, pcpropertysets: *mut u32, prgpropertysets: *mut *mut DBPROPSET, pcconstraintdescs: *mut u32, prgconstraintdescs: *mut *mut DBCONSTRAINTDESC, ppwszstringbuffer: *mut *mut u16) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ITableDefinition(pub ::windows::core::IUnknown); impl ITableDefinition { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn CreateTable<'a, Param0: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>>(&self, punkouter: Param0, ptableid: *const super::super::Storage::IndexServer::DBID, ccolumndescs: usize, rgcolumndescs: *const DBCOLUMNDESC, riid: *const ::windows::core::GUID, cpropertysets: u32, rgpropertysets: *mut DBPROPSET, pptableid: *mut *mut super::super::Storage::IndexServer::DBID, pprowset: *mut ::core::option::Option<::windows::core::IUnknown>) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)( ::core::mem::transmute_copy(self), punkouter.into_param().abi(), ::core::mem::transmute(ptableid), ::core::mem::transmute(ccolumndescs), ::core::mem::transmute(rgcolumndescs), ::core::mem::transmute(riid), ::core::mem::transmute(cpropertysets), ::core::mem::transmute(rgpropertysets), ::core::mem::transmute(pptableid), ::core::mem::transmute(pprowset), ) .ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe fn DropTable(&self, ptableid: *const super::super::Storage::IndexServer::DBID) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(ptableid)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn AddColumn(&self, ptableid: *const super::super::Storage::IndexServer::DBID, pcolumndesc: *const DBCOLUMNDESC) -> ::windows::core::Result<*mut super::super::Storage::IndexServer::DBID> { let mut result__: <*mut super::super::Storage::IndexServer::DBID as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(ptableid), ::core::mem::transmute(pcolumndesc), &mut result__).from_abi::<*mut super::super::Storage::IndexServer::DBID>(result__) } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe fn DropColumn(&self, ptableid: *const super::super::Storage::IndexServer::DBID, pcolumnid: *const super::super::Storage::IndexServer::DBID) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), ::core::mem::transmute(ptableid), ::core::mem::transmute(pcolumnid)).ok() } } unsafe impl ::windows::core::Interface for ITableDefinition { type Vtable = ITableDefinition_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a86_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<ITableDefinition> for ::windows::core::IUnknown { fn from(value: ITableDefinition) -> Self { value.0 } } impl ::core::convert::From<&ITableDefinition> for ::windows::core::IUnknown { fn from(value: &ITableDefinition) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ITableDefinition { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ITableDefinition { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ITableDefinition_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, punkouter: ::windows::core::RawPtr, ptableid: *const super::super::Storage::IndexServer::DBID, ccolumndescs: usize, rgcolumndescs: *const ::core::mem::ManuallyDrop<DBCOLUMNDESC>, riid: *const ::windows::core::GUID, cpropertysets: u32, rgpropertysets: *mut DBPROPSET, pptableid: *mut *mut super::super::Storage::IndexServer::DBID, pprowset: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ptableid: *const super::super::Storage::IndexServer::DBID) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ptableid: *const super::super::Storage::IndexServer::DBID, pcolumndesc: *const ::core::mem::ManuallyDrop<DBCOLUMNDESC>, ppcolumnid: *mut *mut super::super::Storage::IndexServer::DBID) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ptableid: *const super::super::Storage::IndexServer::DBID, pcolumnid: *const super::super::Storage::IndexServer::DBID) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ITableDefinitionWithConstraints(pub ::windows::core::IUnknown); impl ITableDefinitionWithConstraints { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn CreateTable<'a, Param0: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>>(&self, punkouter: Param0, ptableid: *const super::super::Storage::IndexServer::DBID, ccolumndescs: usize, rgcolumndescs: *const DBCOLUMNDESC, riid: *const ::windows::core::GUID, cpropertysets: u32, rgpropertysets: *mut DBPROPSET, pptableid: *mut *mut super::super::Storage::IndexServer::DBID, pprowset: *mut ::core::option::Option<::windows::core::IUnknown>) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)( ::core::mem::transmute_copy(self), punkouter.into_param().abi(), ::core::mem::transmute(ptableid), ::core::mem::transmute(ccolumndescs), ::core::mem::transmute(rgcolumndescs), ::core::mem::transmute(riid), ::core::mem::transmute(cpropertysets), ::core::mem::transmute(rgpropertysets), ::core::mem::transmute(pptableid), ::core::mem::transmute(pprowset), ) .ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe fn DropTable(&self, ptableid: *const super::super::Storage::IndexServer::DBID) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(ptableid)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn AddColumn(&self, ptableid: *const super::super::Storage::IndexServer::DBID, pcolumndesc: *const DBCOLUMNDESC) -> ::windows::core::Result<*mut super::super::Storage::IndexServer::DBID> { let mut result__: <*mut super::super::Storage::IndexServer::DBID as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(ptableid), ::core::mem::transmute(pcolumndesc), &mut result__).from_abi::<*mut super::super::Storage::IndexServer::DBID>(result__) } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe fn DropColumn(&self, ptableid: *const super::super::Storage::IndexServer::DBID, pcolumnid: *const super::super::Storage::IndexServer::DBID) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), ::core::mem::transmute(ptableid), ::core::mem::transmute(pcolumnid)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn GetTableDefinition(&self, ptableid: *const super::super::Storage::IndexServer::DBID, pccolumndescs: *mut usize, prgcolumndescs: *mut *mut DBCOLUMNDESC, pcpropertysets: *mut u32, prgpropertysets: *mut *mut DBPROPSET, pcconstraintdescs: *mut u32, prgconstraintdescs: *mut *mut DBCONSTRAINTDESC, ppwszstringbuffer: *mut *mut u16) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).7)( ::core::mem::transmute_copy(self), ::core::mem::transmute(ptableid), ::core::mem::transmute(pccolumndescs), ::core::mem::transmute(prgcolumndescs), ::core::mem::transmute(pcpropertysets), ::core::mem::transmute(prgpropertysets), ::core::mem::transmute(pcconstraintdescs), ::core::mem::transmute(prgconstraintdescs), ::core::mem::transmute(ppwszstringbuffer), ) .ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn AddConstraint(&self, ptableid: *mut super::super::Storage::IndexServer::DBID, pconstraintdesc: *mut DBCONSTRAINTDESC) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).8)(::core::mem::transmute_copy(self), ::core::mem::transmute(ptableid), ::core::mem::transmute(pconstraintdesc)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn CreateTableWithConstraints<'a, Param0: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>>( &self, punkouter: Param0, ptableid: *mut super::super::Storage::IndexServer::DBID, ccolumndescs: usize, rgcolumndescs: *mut DBCOLUMNDESC, cconstraintdescs: u32, rgconstraintdescs: *mut DBCONSTRAINTDESC, riid: *const ::windows::core::GUID, cpropertysets: u32, rgpropertysets: *mut DBPROPSET, pptableid: *mut *mut super::super::Storage::IndexServer::DBID, pprowset: *mut ::core::option::Option<::windows::core::IUnknown>, ) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).9)( ::core::mem::transmute_copy(self), punkouter.into_param().abi(), ::core::mem::transmute(ptableid), ::core::mem::transmute(ccolumndescs), ::core::mem::transmute(rgcolumndescs), ::core::mem::transmute(cconstraintdescs), ::core::mem::transmute(rgconstraintdescs), ::core::mem::transmute(riid), ::core::mem::transmute(cpropertysets), ::core::mem::transmute(rgpropertysets), ::core::mem::transmute(pptableid), ::core::mem::transmute(pprowset), ) .ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe fn DropConstraint(&self, ptableid: *mut super::super::Storage::IndexServer::DBID, pconstraintid: *mut super::super::Storage::IndexServer::DBID) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).10)(::core::mem::transmute_copy(self), ::core::mem::transmute(ptableid), ::core::mem::transmute(pconstraintid)).ok() } } unsafe impl ::windows::core::Interface for ITableDefinitionWithConstraints { type Vtable = ITableDefinitionWithConstraints_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733aab_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<ITableDefinitionWithConstraints> for ::windows::core::IUnknown { fn from(value: ITableDefinitionWithConstraints) -> Self { value.0 } } impl ::core::convert::From<&ITableDefinitionWithConstraints> for ::windows::core::IUnknown { fn from(value: &ITableDefinitionWithConstraints) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ITableDefinitionWithConstraints { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ITableDefinitionWithConstraints { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } impl ::core::convert::From<ITableDefinitionWithConstraints> for ITableCreation { fn from(value: ITableDefinitionWithConstraints) -> Self { unsafe { ::core::mem::transmute(value) } } } impl ::core::convert::From<&ITableDefinitionWithConstraints> for ITableCreation { fn from(value: &ITableDefinitionWithConstraints) -> Self { ::core::convert::From::from(::core::clone::Clone::clone(value)) } } impl<'a> ::windows::core::IntoParam<'a, ITableCreation> for ITableDefinitionWithConstraints { fn into_param(self) -> ::windows::core::Param<'a, ITableCreation> { ::windows::core::Param::Owned(unsafe { ::core::mem::transmute(self) }) } } impl<'a> ::windows::core::IntoParam<'a, ITableCreation> for &ITableDefinitionWithConstraints { fn into_param(self) -> ::windows::core::Param<'a, ITableCreation> { ::windows::core::Param::Borrowed(unsafe { ::core::mem::transmute(self) }) } } impl ::core::convert::From<ITableDefinitionWithConstraints> for ITableDefinition { fn from(value: ITableDefinitionWithConstraints) -> Self { unsafe { ::core::mem::transmute(value) } } } impl ::core::convert::From<&ITableDefinitionWithConstraints> for ITableDefinition { fn from(value: &ITableDefinitionWithConstraints) -> Self { ::core::convert::From::from(::core::clone::Clone::clone(value)) } } impl<'a> ::windows::core::IntoParam<'a, ITableDefinition> for ITableDefinitionWithConstraints { fn into_param(self) -> ::windows::core::Param<'a, ITableDefinition> { ::windows::core::Param::Owned(unsafe { ::core::mem::transmute(self) }) } } impl<'a> ::windows::core::IntoParam<'a, ITableDefinition> for &ITableDefinitionWithConstraints { fn into_param(self) -> ::windows::core::Param<'a, ITableDefinition> { ::windows::core::Param::Borrowed(unsafe { ::core::mem::transmute(self) }) } } #[repr(C)] #[doc(hidden)] pub struct ITableDefinitionWithConstraints_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, punkouter: ::windows::core::RawPtr, ptableid: *const super::super::Storage::IndexServer::DBID, ccolumndescs: usize, rgcolumndescs: *const ::core::mem::ManuallyDrop<DBCOLUMNDESC>, riid: *const ::windows::core::GUID, cpropertysets: u32, rgpropertysets: *mut DBPROPSET, pptableid: *mut *mut super::super::Storage::IndexServer::DBID, pprowset: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ptableid: *const super::super::Storage::IndexServer::DBID) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ptableid: *const super::super::Storage::IndexServer::DBID, pcolumndesc: *const ::core::mem::ManuallyDrop<DBCOLUMNDESC>, ppcolumnid: *mut *mut super::super::Storage::IndexServer::DBID) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ptableid: *const super::super::Storage::IndexServer::DBID, pcolumnid: *const super::super::Storage::IndexServer::DBID) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ptableid: *const super::super::Storage::IndexServer::DBID, pccolumndescs: *mut usize, prgcolumndescs: *mut *mut DBCOLUMNDESC, pcpropertysets: *mut u32, prgpropertysets: *mut *mut DBPROPSET, pcconstraintdescs: *mut u32, prgconstraintdescs: *mut *mut DBCONSTRAINTDESC, ppwszstringbuffer: *mut *mut u16) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ptableid: *mut super::super::Storage::IndexServer::DBID, pconstraintdesc: *mut DBCONSTRAINTDESC) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn( this: ::windows::core::RawPtr, punkouter: ::windows::core::RawPtr, ptableid: *mut super::super::Storage::IndexServer::DBID, ccolumndescs: usize, rgcolumndescs: *mut ::core::mem::ManuallyDrop<DBCOLUMNDESC>, cconstraintdescs: u32, rgconstraintdescs: *mut DBCONSTRAINTDESC, riid: *const ::windows::core::GUID, cpropertysets: u32, rgpropertysets: *mut DBPROPSET, pptableid: *mut *mut super::super::Storage::IndexServer::DBID, pprowset: *mut ::windows::core::RawPtr, ) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ptableid: *mut super::super::Storage::IndexServer::DBID, pconstraintid: *mut super::super::Storage::IndexServer::DBID) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ITableRename(pub ::windows::core::IUnknown); impl ITableRename { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe fn RenameColumn(&self, ptableid: *mut super::super::Storage::IndexServer::DBID, poldcolumnid: *mut super::super::Storage::IndexServer::DBID, pnewcolumnid: *mut super::super::Storage::IndexServer::DBID) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(ptableid), ::core::mem::transmute(poldcolumnid), ::core::mem::transmute(pnewcolumnid)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe fn RenameTable(&self, poldtableid: *mut super::super::Storage::IndexServer::DBID, poldindexid: *mut super::super::Storage::IndexServer::DBID, pnewtableid: *mut super::super::Storage::IndexServer::DBID, pnewindexid: *mut super::super::Storage::IndexServer::DBID) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(poldtableid), ::core::mem::transmute(poldindexid), ::core::mem::transmute(pnewtableid), ::core::mem::transmute(pnewindexid)).ok() } } unsafe impl ::windows::core::Interface for ITableRename { type Vtable = ITableRename_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a77_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<ITableRename> for ::windows::core::IUnknown { fn from(value: ITableRename) -> Self { value.0 } } impl ::core::convert::From<&ITableRename> for ::windows::core::IUnknown { fn from(value: &ITableRename) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ITableRename { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ITableRename { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ITableRename_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ptableid: *mut super::super::Storage::IndexServer::DBID, poldcolumnid: *mut super::super::Storage::IndexServer::DBID, pnewcolumnid: *mut super::super::Storage::IndexServer::DBID) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, poldtableid: *mut super::super::Storage::IndexServer::DBID, poldindexid: *mut super::super::Storage::IndexServer::DBID, pnewtableid: *mut super::super::Storage::IndexServer::DBID, pnewindexid: *mut super::super::Storage::IndexServer::DBID) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ITokenCollection(pub ::windows::core::IUnknown); impl ITokenCollection { pub unsafe fn NumberOfTokens(&self, pcount: *const u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(pcount)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetToken(&self, i: u32, pbegin: *mut u32, plength: *mut u32, ppsz: *mut super::super::Foundation::PWSTR) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(i), ::core::mem::transmute(pbegin), ::core::mem::transmute(plength), ::core::mem::transmute(ppsz)).ok() } } unsafe impl ::windows::core::Interface for ITokenCollection { type Vtable = ITokenCollection_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x22d8b4f2_f577_4adb_a335_c2ae88416fab); } impl ::core::convert::From<ITokenCollection> for ::windows::core::IUnknown { fn from(value: ITokenCollection) -> Self { value.0 } } impl ::core::convert::From<&ITokenCollection> for ::windows::core::IUnknown { fn from(value: &ITokenCollection) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ITokenCollection { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ITokenCollection { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ITokenCollection_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pcount: *const u32) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, i: u32, pbegin: *mut u32, plength: *mut u32, ppsz: *mut super::super::Foundation::PWSTR) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ITransactionJoin(pub ::windows::core::IUnknown); impl ITransactionJoin { #[cfg(feature = "Win32_System_DistributedTransactionCoordinator")] pub unsafe fn GetOptionsObject(&self) -> ::windows::core::Result<super::DistributedTransactionCoordinator::ITransactionOptions> { let mut result__: <super::DistributedTransactionCoordinator::ITransactionOptions as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::DistributedTransactionCoordinator::ITransactionOptions>(result__) } #[cfg(feature = "Win32_System_DistributedTransactionCoordinator")] pub unsafe fn JoinTransaction<'a, Param0: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>, Param3: ::windows::core::IntoParam<'a, super::DistributedTransactionCoordinator::ITransactionOptions>>(&self, punktransactioncoord: Param0, isolevel: i32, isoflags: u32, potheroptions: Param3) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), punktransactioncoord.into_param().abi(), ::core::mem::transmute(isolevel), ::core::mem::transmute(isoflags), potheroptions.into_param().abi()).ok() } } unsafe impl ::windows::core::Interface for ITransactionJoin { type Vtable = ITransactionJoin_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a5e_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<ITransactionJoin> for ::windows::core::IUnknown { fn from(value: ITransactionJoin) -> Self { value.0 } } impl ::core::convert::From<&ITransactionJoin> for ::windows::core::IUnknown { fn from(value: &ITransactionJoin) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ITransactionJoin { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ITransactionJoin { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ITransactionJoin_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_System_DistributedTransactionCoordinator")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppoptions: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_System_DistributedTransactionCoordinator"))] usize, #[cfg(feature = "Win32_System_DistributedTransactionCoordinator")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, punktransactioncoord: ::windows::core::RawPtr, isolevel: i32, isoflags: u32, potheroptions: ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_System_DistributedTransactionCoordinator"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ITransactionLocal(pub ::windows::core::IUnknown); impl ITransactionLocal { #[cfg(feature = "Win32_Foundation")] pub unsafe fn Commit<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>(&self, fretaining: Param0, grftc: u32, grfrm: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), fretaining.into_param().abi(), ::core::mem::transmute(grftc), ::core::mem::transmute(grfrm)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_DistributedTransactionCoordinator"))] pub unsafe fn Abort<'a, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>, Param2: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>(&self, pboidreason: *const super::DistributedTransactionCoordinator::BOID, fretaining: Param1, fasync: Param2) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(pboidreason), fretaining.into_param().abi(), fasync.into_param().abi()).ok() } #[cfg(feature = "Win32_System_DistributedTransactionCoordinator")] pub unsafe fn GetTransactionInfo(&self) -> ::windows::core::Result<super::DistributedTransactionCoordinator::XACTTRANSINFO> { let mut result__: <super::DistributedTransactionCoordinator::XACTTRANSINFO as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::DistributedTransactionCoordinator::XACTTRANSINFO>(result__) } #[cfg(feature = "Win32_System_DistributedTransactionCoordinator")] pub unsafe fn GetOptionsObject(&self) -> ::windows::core::Result<super::DistributedTransactionCoordinator::ITransactionOptions> { let mut result__: <super::DistributedTransactionCoordinator::ITransactionOptions as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::DistributedTransactionCoordinator::ITransactionOptions>(result__) } #[cfg(feature = "Win32_System_DistributedTransactionCoordinator")] pub unsafe fn StartTransaction<'a, Param2: ::windows::core::IntoParam<'a, super::DistributedTransactionCoordinator::ITransactionOptions>>(&self, isolevel: i32, isoflags: u32, potheroptions: Param2) -> ::windows::core::Result<u32> { let mut result__: <u32 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), ::core::mem::transmute(isolevel), ::core::mem::transmute(isoflags), potheroptions.into_param().abi(), &mut result__).from_abi::<u32>(result__) } } unsafe impl ::windows::core::Interface for ITransactionLocal { type Vtable = ITransactionLocal_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a5f_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<ITransactionLocal> for ::windows::core::IUnknown { fn from(value: ITransactionLocal) -> Self { value.0 } } impl ::core::convert::From<&ITransactionLocal> for ::windows::core::IUnknown { fn from(value: &ITransactionLocal) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ITransactionLocal { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ITransactionLocal { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[cfg(feature = "Win32_System_DistributedTransactionCoordinator")] impl ::core::convert::From<ITransactionLocal> for super::DistributedTransactionCoordinator::ITransaction { fn from(value: ITransactionLocal) -> Self { unsafe { ::core::mem::transmute(value) } } } #[cfg(feature = "Win32_System_DistributedTransactionCoordinator")] impl ::core::convert::From<&ITransactionLocal> for super::DistributedTransactionCoordinator::ITransaction { fn from(value: &ITransactionLocal) -> Self { ::core::convert::From::from(::core::clone::Clone::clone(value)) } } #[cfg(feature = "Win32_System_DistributedTransactionCoordinator")] impl<'a> ::windows::core::IntoParam<'a, super::DistributedTransactionCoordinator::ITransaction> for ITransactionLocal { fn into_param(self) -> ::windows::core::Param<'a, super::DistributedTransactionCoordinator::ITransaction> { ::windows::core::Param::Owned(unsafe { ::core::mem::transmute(self) }) } } #[cfg(feature = "Win32_System_DistributedTransactionCoordinator")] impl<'a> ::windows::core::IntoParam<'a, super::DistributedTransactionCoordinator::ITransaction> for &ITransactionLocal { fn into_param(self) -> ::windows::core::Param<'a, super::DistributedTransactionCoordinator::ITransaction> { ::windows::core::Param::Borrowed(unsafe { ::core::mem::transmute(self) }) } } #[repr(C)] #[doc(hidden)] pub struct ITransactionLocal_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, fretaining: super::super::Foundation::BOOL, grftc: u32, grfrm: u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_DistributedTransactionCoordinator"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pboidreason: *const super::DistributedTransactionCoordinator::BOID, fretaining: super::super::Foundation::BOOL, fasync: super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_DistributedTransactionCoordinator")))] usize, #[cfg(feature = "Win32_System_DistributedTransactionCoordinator")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pinfo: *mut super::DistributedTransactionCoordinator::XACTTRANSINFO) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_System_DistributedTransactionCoordinator"))] usize, #[cfg(feature = "Win32_System_DistributedTransactionCoordinator")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppoptions: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_System_DistributedTransactionCoordinator"))] usize, #[cfg(feature = "Win32_System_DistributedTransactionCoordinator")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, isolevel: i32, isoflags: u32, potheroptions: ::windows::core::RawPtr, pultransactionlevel: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_System_DistributedTransactionCoordinator"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ITransactionObject(pub ::windows::core::IUnknown); impl ITransactionObject { #[cfg(feature = "Win32_System_DistributedTransactionCoordinator")] pub unsafe fn GetTransactionObject(&self, ultransactionlevel: u32) -> ::windows::core::Result<super::DistributedTransactionCoordinator::ITransaction> { let mut result__: <super::DistributedTransactionCoordinator::ITransaction as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(ultransactionlevel), &mut result__).from_abi::<super::DistributedTransactionCoordinator::ITransaction>(result__) } } unsafe impl ::windows::core::Interface for ITransactionObject { type Vtable = ITransactionObject_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a60_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<ITransactionObject> for ::windows::core::IUnknown { fn from(value: ITransactionObject) -> Self { value.0 } } impl ::core::convert::From<&ITransactionObject> for ::windows::core::IUnknown { fn from(value: &ITransactionObject) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ITransactionObject { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ITransactionObject { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ITransactionObject_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_System_DistributedTransactionCoordinator")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ultransactionlevel: u32, pptransactionobject: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_System_DistributedTransactionCoordinator"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ITrusteeAdmin(pub ::windows::core::IUnknown); impl ITrusteeAdmin { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization"))] pub unsafe fn CompareTrustees(&self, ptrustee1: *mut super::super::Security::Authorization::TRUSTEE_W, ptrustee2: *mut super::super::Security::Authorization::TRUSTEE_W) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(ptrustee1), ::core::mem::transmute(ptrustee2)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn CreateTrustee(&self, ptrustee: *mut super::super::Security::Authorization::TRUSTEE_W, cpropertysets: u32, rgpropertysets: *mut DBPROPSET) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(ptrustee), ::core::mem::transmute(cpropertysets), ::core::mem::transmute(rgpropertysets)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization"))] pub unsafe fn DeleteTrustee(&self, ptrustee: *mut super::super::Security::Authorization::TRUSTEE_W) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(ptrustee)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn SetTrusteeProperties(&self, ptrustee: *mut super::super::Security::Authorization::TRUSTEE_W, cpropertysets: u32, rgpropertysets: *mut DBPROPSET) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), ::core::mem::transmute(ptrustee), ::core::mem::transmute(cpropertysets), ::core::mem::transmute(rgpropertysets)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn GetTrusteeProperties(&self, ptrustee: *mut super::super::Security::Authorization::TRUSTEE_W, cpropertyidsets: u32, rgpropertyidsets: *const DBPROPIDSET, pcpropertysets: *mut u32, prgpropertysets: *mut *mut DBPROPSET) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), ::core::mem::transmute(ptrustee), ::core::mem::transmute(cpropertyidsets), ::core::mem::transmute(rgpropertyidsets), ::core::mem::transmute(pcpropertysets), ::core::mem::transmute(prgpropertysets)).ok() } } unsafe impl ::windows::core::Interface for ITrusteeAdmin { type Vtable = ITrusteeAdmin_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733aa1_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<ITrusteeAdmin> for ::windows::core::IUnknown { fn from(value: ITrusteeAdmin) -> Self { value.0 } } impl ::core::convert::From<&ITrusteeAdmin> for ::windows::core::IUnknown { fn from(value: &ITrusteeAdmin) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ITrusteeAdmin { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ITrusteeAdmin { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ITrusteeAdmin_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ptrustee1: *mut super::super::Security::Authorization::TRUSTEE_W, ptrustee2: *mut super::super::Security::Authorization::TRUSTEE_W) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ptrustee: *mut super::super::Security::Authorization::TRUSTEE_W, cpropertysets: u32, rgpropertysets: *mut DBPROPSET) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ptrustee: *mut super::super::Security::Authorization::TRUSTEE_W) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ptrustee: *mut super::super::Security::Authorization::TRUSTEE_W, cpropertysets: u32, rgpropertysets: *mut DBPROPSET) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ptrustee: *mut super::super::Security::Authorization::TRUSTEE_W, cpropertyidsets: u32, rgpropertyidsets: *const DBPROPIDSET, pcpropertysets: *mut u32, prgpropertysets: *mut *mut DBPROPSET) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct ITrusteeGroupAdmin(pub ::windows::core::IUnknown); impl ITrusteeGroupAdmin { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization"))] pub unsafe fn AddMember(&self, pmembershiptrustee: *mut super::super::Security::Authorization::TRUSTEE_W, pmembertrustee: *mut super::super::Security::Authorization::TRUSTEE_W) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(pmembershiptrustee), ::core::mem::transmute(pmembertrustee)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization"))] pub unsafe fn DeleteMember(&self, pmembershiptrustee: *mut super::super::Security::Authorization::TRUSTEE_W, pmembertrustee: *mut super::super::Security::Authorization::TRUSTEE_W) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(pmembershiptrustee), ::core::mem::transmute(pmembertrustee)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization"))] pub unsafe fn IsMember(&self, pmembershiptrustee: *mut super::super::Security::Authorization::TRUSTEE_W, pmembertrustee: *mut super::super::Security::Authorization::TRUSTEE_W, pfstatus: *mut super::super::Foundation::BOOL) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(pmembershiptrustee), ::core::mem::transmute(pmembertrustee), ::core::mem::transmute(pfstatus)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization"))] pub unsafe fn GetMembers(&self, pmembershiptrustee: *mut super::super::Security::Authorization::TRUSTEE_W, pcmembers: *mut u32, prgmembers: *mut *mut super::super::Security::Authorization::TRUSTEE_W) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), ::core::mem::transmute(pmembershiptrustee), ::core::mem::transmute(pcmembers), ::core::mem::transmute(prgmembers)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization"))] pub unsafe fn GetMemberships(&self, ptrustee: *mut super::super::Security::Authorization::TRUSTEE_W, pcmemberships: *mut u32, prgmemberships: *mut *mut super::super::Security::Authorization::TRUSTEE_W) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), ::core::mem::transmute(ptrustee), ::core::mem::transmute(pcmemberships), ::core::mem::transmute(prgmemberships)).ok() } } unsafe impl ::windows::core::Interface for ITrusteeGroupAdmin { type Vtable = ITrusteeGroupAdmin_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733aa2_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<ITrusteeGroupAdmin> for ::windows::core::IUnknown { fn from(value: ITrusteeGroupAdmin) -> Self { value.0 } } impl ::core::convert::From<&ITrusteeGroupAdmin> for ::windows::core::IUnknown { fn from(value: &ITrusteeGroupAdmin) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for ITrusteeGroupAdmin { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a ITrusteeGroupAdmin { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct ITrusteeGroupAdmin_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pmembershiptrustee: *mut super::super::Security::Authorization::TRUSTEE_W, pmembertrustee: *mut super::super::Security::Authorization::TRUSTEE_W) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pmembershiptrustee: *mut super::super::Security::Authorization::TRUSTEE_W, pmembertrustee: *mut super::super::Security::Authorization::TRUSTEE_W) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pmembershiptrustee: *mut super::super::Security::Authorization::TRUSTEE_W, pmembertrustee: *mut super::super::Security::Authorization::TRUSTEE_W, pfstatus: *mut super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pmembershiptrustee: *mut super::super::Security::Authorization::TRUSTEE_W, pcmembers: *mut u32, prgmembers: *mut *mut super::super::Security::Authorization::TRUSTEE_W) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ptrustee: *mut super::super::Security::Authorization::TRUSTEE_W, pcmemberships: *mut u32, prgmemberships: *mut *mut super::super::Security::Authorization::TRUSTEE_W) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Security_Authorization")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IUMS(pub ::windows::core::IUnknown); impl IUMS { pub unsafe fn SqlUmsSuspend(&self, ticks: u32) { ::core::mem::transmute((::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(ticks))) } pub unsafe fn SqlUmsYield(&self, ticks: u32) { ::core::mem::transmute((::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(ticks))) } pub unsafe fn SqlUmsSwitchPremptive(&self) { ::core::mem::transmute((::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self))) } pub unsafe fn SqlUmsSwitchNonPremptive(&self) { ::core::mem::transmute((::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self))) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn SqlUmsFIsPremptive(&self) -> super::super::Foundation::BOOL { ::core::mem::transmute((::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self))) } } unsafe impl ::windows::core::Interface for IUMS { type Vtable = IUMS_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::zeroed(); } impl ::core::convert::From<IUMS> for ::windows::core::IUnknown { fn from(value: IUMS) -> Self { value.0 } } impl ::core::convert::From<&IUMS> for ::windows::core::IUnknown { fn from(value: &IUMS) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IUMS { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IUMS { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IUMS_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ticks: u32), pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ticks: u32), pub unsafe extern "system" fn(this: ::windows::core::RawPtr), pub unsafe extern "system" fn(this: ::windows::core::RawPtr), #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> super::super::Foundation::BOOL, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IUMSInitialize(pub ::windows::core::IUnknown); impl IUMSInitialize { pub unsafe fn Initialize(&self, pums: *mut ::core::ffi::c_void) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(pums)).ok() } } unsafe impl ::windows::core::Interface for IUMSInitialize { type Vtable = IUMSInitialize_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x5cf4ca14_ef21_11d0_97e7_00c04fc2ad98); } impl ::core::convert::From<IUMSInitialize> for ::windows::core::IUnknown { fn from(value: IUMSInitialize) -> Self { value.0 } } impl ::core::convert::From<&IUMSInitialize> for ::windows::core::IUnknown { fn from(value: &IUMSInitialize) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IUMSInitialize { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IUMSInitialize { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IUMSInitialize_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pums: *mut ::core::ffi::c_void) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IUrlAccessor(pub ::windows::core::IUnknown); impl IUrlAccessor { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe fn AddRequestParameter(&self, pspec: *const super::Com::StructuredStorage::PROPSPEC, pvar: *const super::Com::StructuredStorage::PROPVARIANT) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(pspec), ::core::mem::transmute(pvar)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetDocFormat(&self, wszdocformat: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(wszdocformat), ::core::mem::transmute(dwsize), ::core::mem::transmute(pdwlength)).ok() } pub unsafe fn GetCLSID(&self) -> ::windows::core::Result<::windows::core::GUID> { let mut result__: <::windows::core::GUID as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), &mut result__).from_abi::<::windows::core::GUID>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetHost(&self, wszhost: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), ::core::mem::transmute(wszhost), ::core::mem::transmute(dwsize), ::core::mem::transmute(pdwlength)).ok() } pub unsafe fn IsDirectory(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self)).ok() } pub unsafe fn GetSize(&self) -> ::windows::core::Result<u64> { let mut result__: <u64 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).8)(::core::mem::transmute_copy(self), &mut result__).from_abi::<u64>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetLastModified(&self) -> ::windows::core::Result<super::super::Foundation::FILETIME> { let mut result__: <super::super::Foundation::FILETIME as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).9)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::FILETIME>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetFileName(&self, wszfilename: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).10)(::core::mem::transmute_copy(self), ::core::mem::transmute(wszfilename), ::core::mem::transmute(dwsize), ::core::mem::transmute(pdwlength)).ok() } pub unsafe fn GetSecurityDescriptor(&self, psd: *mut u8, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).11)(::core::mem::transmute_copy(self), ::core::mem::transmute(psd), ::core::mem::transmute(dwsize), ::core::mem::transmute(pdwlength)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetRedirectedURL(&self, wszredirectedurl: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).12)(::core::mem::transmute_copy(self), ::core::mem::transmute(wszredirectedurl), ::core::mem::transmute(dwsize), ::core::mem::transmute(pdwlength)).ok() } pub unsafe fn GetSecurityProvider(&self) -> ::windows::core::Result<::windows::core::GUID> { let mut result__: <::windows::core::GUID as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).13)(::core::mem::transmute_copy(self), &mut result__).from_abi::<::windows::core::GUID>(result__) } #[cfg(feature = "Win32_System_Com")] pub unsafe fn BindToStream(&self) -> ::windows::core::Result<super::Com::IStream> { let mut result__: <super::Com::IStream as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).14)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::Com::IStream>(result__) } #[cfg(feature = "Win32_Storage_IndexServer")] pub unsafe fn BindToFilter(&self) -> ::windows::core::Result<super::super::Storage::IndexServer::IFilter> { let mut result__: <super::super::Storage::IndexServer::IFilter as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).15)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Storage::IndexServer::IFilter>(result__) } } unsafe impl ::windows::core::Interface for IUrlAccessor { type Vtable = IUrlAccessor_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0b63e318_9ccc_11d0_bcdb_00805fccce04); } impl ::core::convert::From<IUrlAccessor> for ::windows::core::IUnknown { fn from(value: IUrlAccessor) -> Self { value.0 } } impl ::core::convert::From<&IUrlAccessor> for ::windows::core::IUnknown { fn from(value: &IUrlAccessor) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IUrlAccessor { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IUrlAccessor { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IUrlAccessor_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pspec: *const super::Com::StructuredStorage::PROPSPEC, pvar: *const ::core::mem::ManuallyDrop<super::Com::StructuredStorage::PROPVARIANT>) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage")))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, wszdocformat: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pclsid: *mut ::windows::core::GUID) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, wszhost: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pllsize: *mut u64) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pftlastmodified: *mut super::super::Foundation::FILETIME) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, wszfilename: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, psd: *mut u8, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, wszredirectedurl: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pspclsid: *mut ::windows::core::GUID) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_System_Com")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppstream: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_System_Com"))] usize, #[cfg(feature = "Win32_Storage_IndexServer")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppfilter: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Storage_IndexServer"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IUrlAccessor2(pub ::windows::core::IUnknown); impl IUrlAccessor2 { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe fn AddRequestParameter(&self, pspec: *const super::Com::StructuredStorage::PROPSPEC, pvar: *const super::Com::StructuredStorage::PROPVARIANT) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(pspec), ::core::mem::transmute(pvar)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetDocFormat(&self, wszdocformat: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(wszdocformat), ::core::mem::transmute(dwsize), ::core::mem::transmute(pdwlength)).ok() } pub unsafe fn GetCLSID(&self) -> ::windows::core::Result<::windows::core::GUID> { let mut result__: <::windows::core::GUID as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), &mut result__).from_abi::<::windows::core::GUID>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetHost(&self, wszhost: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), ::core::mem::transmute(wszhost), ::core::mem::transmute(dwsize), ::core::mem::transmute(pdwlength)).ok() } pub unsafe fn IsDirectory(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self)).ok() } pub unsafe fn GetSize(&self) -> ::windows::core::Result<u64> { let mut result__: <u64 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).8)(::core::mem::transmute_copy(self), &mut result__).from_abi::<u64>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetLastModified(&self) -> ::windows::core::Result<super::super::Foundation::FILETIME> { let mut result__: <super::super::Foundation::FILETIME as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).9)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::FILETIME>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetFileName(&self, wszfilename: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).10)(::core::mem::transmute_copy(self), ::core::mem::transmute(wszfilename), ::core::mem::transmute(dwsize), ::core::mem::transmute(pdwlength)).ok() } pub unsafe fn GetSecurityDescriptor(&self, psd: *mut u8, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).11)(::core::mem::transmute_copy(self), ::core::mem::transmute(psd), ::core::mem::transmute(dwsize), ::core::mem::transmute(pdwlength)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetRedirectedURL(&self, wszredirectedurl: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).12)(::core::mem::transmute_copy(self), ::core::mem::transmute(wszredirectedurl), ::core::mem::transmute(dwsize), ::core::mem::transmute(pdwlength)).ok() } pub unsafe fn GetSecurityProvider(&self) -> ::windows::core::Result<::windows::core::GUID> { let mut result__: <::windows::core::GUID as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).13)(::core::mem::transmute_copy(self), &mut result__).from_abi::<::windows::core::GUID>(result__) } #[cfg(feature = "Win32_System_Com")] pub unsafe fn BindToStream(&self) -> ::windows::core::Result<super::Com::IStream> { let mut result__: <super::Com::IStream as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).14)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::Com::IStream>(result__) } #[cfg(feature = "Win32_Storage_IndexServer")] pub unsafe fn BindToFilter(&self) -> ::windows::core::Result<super::super::Storage::IndexServer::IFilter> { let mut result__: <super::super::Storage::IndexServer::IFilter as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).15)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Storage::IndexServer::IFilter>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetDisplayUrl(&self, wszdocurl: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).16)(::core::mem::transmute_copy(self), ::core::mem::transmute(wszdocurl), ::core::mem::transmute(dwsize), ::core::mem::transmute(pdwlength)).ok() } pub unsafe fn IsDocument(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).17)(::core::mem::transmute_copy(self)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetCodePage(&self, wszcodepage: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).18)(::core::mem::transmute_copy(self), ::core::mem::transmute(wszcodepage), ::core::mem::transmute(dwsize), ::core::mem::transmute(pdwlength)).ok() } } unsafe impl ::windows::core::Interface for IUrlAccessor2 { type Vtable = IUrlAccessor2_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xc7310734_ac80_11d1_8df3_00c04fb6ef4f); } impl ::core::convert::From<IUrlAccessor2> for ::windows::core::IUnknown { fn from(value: IUrlAccessor2) -> Self { value.0 } } impl ::core::convert::From<&IUrlAccessor2> for ::windows::core::IUnknown { fn from(value: &IUrlAccessor2) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IUrlAccessor2 { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IUrlAccessor2 { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } impl ::core::convert::From<IUrlAccessor2> for IUrlAccessor { fn from(value: IUrlAccessor2) -> Self { unsafe { ::core::mem::transmute(value) } } } impl ::core::convert::From<&IUrlAccessor2> for IUrlAccessor { fn from(value: &IUrlAccessor2) -> Self { ::core::convert::From::from(::core::clone::Clone::clone(value)) } } impl<'a> ::windows::core::IntoParam<'a, IUrlAccessor> for IUrlAccessor2 { fn into_param(self) -> ::windows::core::Param<'a, IUrlAccessor> { ::windows::core::Param::Owned(unsafe { ::core::mem::transmute(self) }) } } impl<'a> ::windows::core::IntoParam<'a, IUrlAccessor> for &IUrlAccessor2 { fn into_param(self) -> ::windows::core::Param<'a, IUrlAccessor> { ::windows::core::Param::Borrowed(unsafe { ::core::mem::transmute(self) }) } } #[repr(C)] #[doc(hidden)] pub struct IUrlAccessor2_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pspec: *const super::Com::StructuredStorage::PROPSPEC, pvar: *const ::core::mem::ManuallyDrop<super::Com::StructuredStorage::PROPVARIANT>) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage")))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, wszdocformat: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pclsid: *mut ::windows::core::GUID) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, wszhost: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pllsize: *mut u64) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pftlastmodified: *mut super::super::Foundation::FILETIME) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, wszfilename: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, psd: *mut u8, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, wszredirectedurl: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pspclsid: *mut ::windows::core::GUID) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_System_Com")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppstream: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_System_Com"))] usize, #[cfg(feature = "Win32_Storage_IndexServer")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppfilter: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Storage_IndexServer"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, wszdocurl: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, wszcodepage: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IUrlAccessor3(pub ::windows::core::IUnknown); impl IUrlAccessor3 { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe fn AddRequestParameter(&self, pspec: *const super::Com::StructuredStorage::PROPSPEC, pvar: *const super::Com::StructuredStorage::PROPVARIANT) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(pspec), ::core::mem::transmute(pvar)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetDocFormat(&self, wszdocformat: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(wszdocformat), ::core::mem::transmute(dwsize), ::core::mem::transmute(pdwlength)).ok() } pub unsafe fn GetCLSID(&self) -> ::windows::core::Result<::windows::core::GUID> { let mut result__: <::windows::core::GUID as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), &mut result__).from_abi::<::windows::core::GUID>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetHost(&self, wszhost: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), ::core::mem::transmute(wszhost), ::core::mem::transmute(dwsize), ::core::mem::transmute(pdwlength)).ok() } pub unsafe fn IsDirectory(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self)).ok() } pub unsafe fn GetSize(&self) -> ::windows::core::Result<u64> { let mut result__: <u64 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).8)(::core::mem::transmute_copy(self), &mut result__).from_abi::<u64>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetLastModified(&self) -> ::windows::core::Result<super::super::Foundation::FILETIME> { let mut result__: <super::super::Foundation::FILETIME as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).9)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::FILETIME>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetFileName(&self, wszfilename: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).10)(::core::mem::transmute_copy(self), ::core::mem::transmute(wszfilename), ::core::mem::transmute(dwsize), ::core::mem::transmute(pdwlength)).ok() } pub unsafe fn GetSecurityDescriptor(&self, psd: *mut u8, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).11)(::core::mem::transmute_copy(self), ::core::mem::transmute(psd), ::core::mem::transmute(dwsize), ::core::mem::transmute(pdwlength)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetRedirectedURL(&self, wszredirectedurl: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).12)(::core::mem::transmute_copy(self), ::core::mem::transmute(wszredirectedurl), ::core::mem::transmute(dwsize), ::core::mem::transmute(pdwlength)).ok() } pub unsafe fn GetSecurityProvider(&self) -> ::windows::core::Result<::windows::core::GUID> { let mut result__: <::windows::core::GUID as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).13)(::core::mem::transmute_copy(self), &mut result__).from_abi::<::windows::core::GUID>(result__) } #[cfg(feature = "Win32_System_Com")] pub unsafe fn BindToStream(&self) -> ::windows::core::Result<super::Com::IStream> { let mut result__: <super::Com::IStream as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).14)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::Com::IStream>(result__) } #[cfg(feature = "Win32_Storage_IndexServer")] pub unsafe fn BindToFilter(&self) -> ::windows::core::Result<super::super::Storage::IndexServer::IFilter> { let mut result__: <super::super::Storage::IndexServer::IFilter as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).15)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Storage::IndexServer::IFilter>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetDisplayUrl(&self, wszdocurl: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).16)(::core::mem::transmute_copy(self), ::core::mem::transmute(wszdocurl), ::core::mem::transmute(dwsize), ::core::mem::transmute(pdwlength)).ok() } pub unsafe fn IsDocument(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).17)(::core::mem::transmute_copy(self)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetCodePage(&self, wszcodepage: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).18)(::core::mem::transmute_copy(self), ::core::mem::transmute(wszcodepage), ::core::mem::transmute(dwsize), ::core::mem::transmute(pdwlength)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub unsafe fn GetImpersonationSidBlobs<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pcwszurl: Param0, pcsidcount: *mut u32, ppsidblobs: *mut *mut super::Com::BLOB) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).19)(::core::mem::transmute_copy(self), pcwszurl.into_param().abi(), ::core::mem::transmute(pcsidcount), ::core::mem::transmute(ppsidblobs)).ok() } } unsafe impl ::windows::core::Interface for IUrlAccessor3 { type Vtable = IUrlAccessor3_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x6fbc7005_0455_4874_b8ff_7439450241a3); } impl ::core::convert::From<IUrlAccessor3> for ::windows::core::IUnknown { fn from(value: IUrlAccessor3) -> Self { value.0 } } impl ::core::convert::From<&IUrlAccessor3> for ::windows::core::IUnknown { fn from(value: &IUrlAccessor3) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IUrlAccessor3 { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IUrlAccessor3 { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } impl ::core::convert::From<IUrlAccessor3> for IUrlAccessor2 { fn from(value: IUrlAccessor3) -> Self { unsafe { ::core::mem::transmute(value) } } } impl ::core::convert::From<&IUrlAccessor3> for IUrlAccessor2 { fn from(value: &IUrlAccessor3) -> Self { ::core::convert::From::from(::core::clone::Clone::clone(value)) } } impl<'a> ::windows::core::IntoParam<'a, IUrlAccessor2> for IUrlAccessor3 { fn into_param(self) -> ::windows::core::Param<'a, IUrlAccessor2> { ::windows::core::Param::Owned(unsafe { ::core::mem::transmute(self) }) } } impl<'a> ::windows::core::IntoParam<'a, IUrlAccessor2> for &IUrlAccessor3 { fn into_param(self) -> ::windows::core::Param<'a, IUrlAccessor2> { ::windows::core::Param::Borrowed(unsafe { ::core::mem::transmute(self) }) } } impl ::core::convert::From<IUrlAccessor3> for IUrlAccessor { fn from(value: IUrlAccessor3) -> Self { unsafe { ::core::mem::transmute(value) } } } impl ::core::convert::From<&IUrlAccessor3> for IUrlAccessor { fn from(value: &IUrlAccessor3) -> Self { ::core::convert::From::from(::core::clone::Clone::clone(value)) } } impl<'a> ::windows::core::IntoParam<'a, IUrlAccessor> for IUrlAccessor3 { fn into_param(self) -> ::windows::core::Param<'a, IUrlAccessor> { ::windows::core::Param::Owned(unsafe { ::core::mem::transmute(self) }) } } impl<'a> ::windows::core::IntoParam<'a, IUrlAccessor> for &IUrlAccessor3 { fn into_param(self) -> ::windows::core::Param<'a, IUrlAccessor> { ::windows::core::Param::Borrowed(unsafe { ::core::mem::transmute(self) }) } } #[repr(C)] #[doc(hidden)] pub struct IUrlAccessor3_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pspec: *const super::Com::StructuredStorage::PROPSPEC, pvar: *const ::core::mem::ManuallyDrop<super::Com::StructuredStorage::PROPVARIANT>) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage")))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, wszdocformat: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pclsid: *mut ::windows::core::GUID) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, wszhost: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pllsize: *mut u64) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pftlastmodified: *mut super::super::Foundation::FILETIME) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, wszfilename: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, psd: *mut u8, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, wszredirectedurl: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pspclsid: *mut ::windows::core::GUID) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_System_Com")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppstream: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_System_Com"))] usize, #[cfg(feature = "Win32_Storage_IndexServer")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppfilter: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Storage_IndexServer"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, wszdocurl: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, wszcodepage: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pcwszurl: super::super::Foundation::PWSTR, pcsidcount: *mut u32, ppsidblobs: *mut *mut super::Com::BLOB) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IUrlAccessor4(pub ::windows::core::IUnknown); impl IUrlAccessor4 { #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe fn AddRequestParameter(&self, pspec: *const super::Com::StructuredStorage::PROPSPEC, pvar: *const super::Com::StructuredStorage::PROPVARIANT) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(pspec), ::core::mem::transmute(pvar)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetDocFormat(&self, wszdocformat: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(wszdocformat), ::core::mem::transmute(dwsize), ::core::mem::transmute(pdwlength)).ok() } pub unsafe fn GetCLSID(&self) -> ::windows::core::Result<::windows::core::GUID> { let mut result__: <::windows::core::GUID as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), &mut result__).from_abi::<::windows::core::GUID>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetHost(&self, wszhost: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), ::core::mem::transmute(wszhost), ::core::mem::transmute(dwsize), ::core::mem::transmute(pdwlength)).ok() } pub unsafe fn IsDirectory(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self)).ok() } pub unsafe fn GetSize(&self) -> ::windows::core::Result<u64> { let mut result__: <u64 as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).8)(::core::mem::transmute_copy(self), &mut result__).from_abi::<u64>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetLastModified(&self) -> ::windows::core::Result<super::super::Foundation::FILETIME> { let mut result__: <super::super::Foundation::FILETIME as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).9)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::FILETIME>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetFileName(&self, wszfilename: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).10)(::core::mem::transmute_copy(self), ::core::mem::transmute(wszfilename), ::core::mem::transmute(dwsize), ::core::mem::transmute(pdwlength)).ok() } pub unsafe fn GetSecurityDescriptor(&self, psd: *mut u8, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).11)(::core::mem::transmute_copy(self), ::core::mem::transmute(psd), ::core::mem::transmute(dwsize), ::core::mem::transmute(pdwlength)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetRedirectedURL(&self, wszredirectedurl: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).12)(::core::mem::transmute_copy(self), ::core::mem::transmute(wszredirectedurl), ::core::mem::transmute(dwsize), ::core::mem::transmute(pdwlength)).ok() } pub unsafe fn GetSecurityProvider(&self) -> ::windows::core::Result<::windows::core::GUID> { let mut result__: <::windows::core::GUID as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).13)(::core::mem::transmute_copy(self), &mut result__).from_abi::<::windows::core::GUID>(result__) } #[cfg(feature = "Win32_System_Com")] pub unsafe fn BindToStream(&self) -> ::windows::core::Result<super::Com::IStream> { let mut result__: <super::Com::IStream as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).14)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::Com::IStream>(result__) } #[cfg(feature = "Win32_Storage_IndexServer")] pub unsafe fn BindToFilter(&self) -> ::windows::core::Result<super::super::Storage::IndexServer::IFilter> { let mut result__: <super::super::Storage::IndexServer::IFilter as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).15)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Storage::IndexServer::IFilter>(result__) } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetDisplayUrl(&self, wszdocurl: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).16)(::core::mem::transmute_copy(self), ::core::mem::transmute(wszdocurl), ::core::mem::transmute(dwsize), ::core::mem::transmute(pdwlength)).ok() } pub unsafe fn IsDocument(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).17)(::core::mem::transmute_copy(self)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn GetCodePage(&self, wszcodepage: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).18)(::core::mem::transmute_copy(self), ::core::mem::transmute(wszcodepage), ::core::mem::transmute(dwsize), ::core::mem::transmute(pdwlength)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub unsafe fn GetImpersonationSidBlobs<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pcwszurl: Param0, pcsidcount: *mut u32, ppsidblobs: *mut *mut super::Com::BLOB) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).19)(::core::mem::transmute_copy(self), pcwszurl.into_param().abi(), ::core::mem::transmute(pcsidcount), ::core::mem::transmute(ppsidblobs)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn ShouldIndexItemContent(&self) -> ::windows::core::Result<super::super::Foundation::BOOL> { let mut result__: <super::super::Foundation::BOOL as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).20)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::BOOL>(result__) } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_UI_Shell_PropertiesSystem"))] pub unsafe fn ShouldIndexProperty(&self, key: *const super::super::UI::Shell::PropertiesSystem::PROPERTYKEY) -> ::windows::core::Result<super::super::Foundation::BOOL> { let mut result__: <super::super::Foundation::BOOL as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).21)(::core::mem::transmute_copy(self), ::core::mem::transmute(key), &mut result__).from_abi::<super::super::Foundation::BOOL>(result__) } } unsafe impl ::windows::core::Interface for IUrlAccessor4 { type Vtable = IUrlAccessor4_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x5cc51041_c8d2_41d7_bca3_9e9e286297dc); } impl ::core::convert::From<IUrlAccessor4> for ::windows::core::IUnknown { fn from(value: IUrlAccessor4) -> Self { value.0 } } impl ::core::convert::From<&IUrlAccessor4> for ::windows::core::IUnknown { fn from(value: &IUrlAccessor4) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IUrlAccessor4 { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IUrlAccessor4 { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } impl ::core::convert::From<IUrlAccessor4> for IUrlAccessor3 { fn from(value: IUrlAccessor4) -> Self { unsafe { ::core::mem::transmute(value) } } } impl ::core::convert::From<&IUrlAccessor4> for IUrlAccessor3 { fn from(value: &IUrlAccessor4) -> Self { ::core::convert::From::from(::core::clone::Clone::clone(value)) } } impl<'a> ::windows::core::IntoParam<'a, IUrlAccessor3> for IUrlAccessor4 { fn into_param(self) -> ::windows::core::Param<'a, IUrlAccessor3> { ::windows::core::Param::Owned(unsafe { ::core::mem::transmute(self) }) } } impl<'a> ::windows::core::IntoParam<'a, IUrlAccessor3> for &IUrlAccessor4 { fn into_param(self) -> ::windows::core::Param<'a, IUrlAccessor3> { ::windows::core::Param::Borrowed(unsafe { ::core::mem::transmute(self) }) } } impl ::core::convert::From<IUrlAccessor4> for IUrlAccessor2 { fn from(value: IUrlAccessor4) -> Self { unsafe { ::core::mem::transmute(value) } } } impl ::core::convert::From<&IUrlAccessor4> for IUrlAccessor2 { fn from(value: &IUrlAccessor4) -> Self { ::core::convert::From::from(::core::clone::Clone::clone(value)) } } impl<'a> ::windows::core::IntoParam<'a, IUrlAccessor2> for IUrlAccessor4 { fn into_param(self) -> ::windows::core::Param<'a, IUrlAccessor2> { ::windows::core::Param::Owned(unsafe { ::core::mem::transmute(self) }) } } impl<'a> ::windows::core::IntoParam<'a, IUrlAccessor2> for &IUrlAccessor4 { fn into_param(self) -> ::windows::core::Param<'a, IUrlAccessor2> { ::windows::core::Param::Borrowed(unsafe { ::core::mem::transmute(self) }) } } impl ::core::convert::From<IUrlAccessor4> for IUrlAccessor { fn from(value: IUrlAccessor4) -> Self { unsafe { ::core::mem::transmute(value) } } } impl ::core::convert::From<&IUrlAccessor4> for IUrlAccessor { fn from(value: &IUrlAccessor4) -> Self { ::core::convert::From::from(::core::clone::Clone::clone(value)) } } impl<'a> ::windows::core::IntoParam<'a, IUrlAccessor> for IUrlAccessor4 { fn into_param(self) -> ::windows::core::Param<'a, IUrlAccessor> { ::windows::core::Param::Owned(unsafe { ::core::mem::transmute(self) }) } } impl<'a> ::windows::core::IntoParam<'a, IUrlAccessor> for &IUrlAccessor4 { fn into_param(self) -> ::windows::core::Param<'a, IUrlAccessor> { ::windows::core::Param::Borrowed(unsafe { ::core::mem::transmute(self) }) } } #[repr(C)] #[doc(hidden)] pub struct IUrlAccessor4_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pspec: *const super::Com::StructuredStorage::PROPSPEC, pvar: *const ::core::mem::ManuallyDrop<super::Com::StructuredStorage::PROPVARIANT>) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage")))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, wszdocformat: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pclsid: *mut ::windows::core::GUID) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, wszhost: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pllsize: *mut u64) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pftlastmodified: *mut super::super::Foundation::FILETIME) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, wszfilename: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, psd: *mut u8, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, wszredirectedurl: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pspclsid: *mut ::windows::core::GUID) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_System_Com")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppstream: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_System_Com"))] usize, #[cfg(feature = "Win32_Storage_IndexServer")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppfilter: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Storage_IndexServer"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, wszdocurl: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, wszcodepage: super::super::Foundation::PWSTR, dwsize: u32, pdwlength: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pcwszurl: super::super::Foundation::PWSTR, pcsidcount: *mut u32, ppsidblobs: *mut *mut super::Com::BLOB) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com")))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pfindexcontent: *mut super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_UI_Shell_PropertiesSystem"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, key: *const super::super::UI::Shell::PropertiesSystem::PROPERTYKEY, pfindexproperty: *mut super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_UI_Shell_PropertiesSystem")))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IViewChapter(pub ::windows::core::IUnknown); impl IViewChapter { pub unsafe fn GetSpecification(&self, riid: *const ::windows::core::GUID) -> ::windows::core::Result<::windows::core::IUnknown> { let mut result__: <::windows::core::IUnknown as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(riid), &mut result__).from_abi::<::windows::core::IUnknown>(result__) } pub unsafe fn OpenViewChapter(&self, hsource: usize) -> ::windows::core::Result<usize> { let mut result__: <usize as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(hsource), &mut result__).from_abi::<usize>(result__) } } unsafe impl ::windows::core::Interface for IViewChapter { type Vtable = IViewChapter_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a98_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IViewChapter> for ::windows::core::IUnknown { fn from(value: IViewChapter) -> Self { value.0 } } impl ::core::convert::From<&IViewChapter> for ::windows::core::IUnknown { fn from(value: &IViewChapter) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IViewChapter { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IViewChapter { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IViewChapter_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, riid: *const ::windows::core::GUID, pprowset: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, hsource: usize, phviewchapter: *mut usize) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IViewFilter(pub ::windows::core::IUnknown); impl IViewFilter { pub unsafe fn GetFilter(&self, haccessor: usize, pcrows: *mut usize, pcompareops: *mut *mut u32, pcriteriadata: *mut ::core::ffi::c_void) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(haccessor), ::core::mem::transmute(pcrows), ::core::mem::transmute(pcompareops), ::core::mem::transmute(pcriteriadata)).ok() } #[cfg(feature = "Win32_System_Com")] pub unsafe fn GetFilterBindings(&self, pcbindings: *mut usize, prgbindings: *mut *mut DBBINDING) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(pcbindings), ::core::mem::transmute(prgbindings)).ok() } pub unsafe fn SetFilter(&self, haccessor: usize, crows: usize, compareops: *const u32, pcriteriadata: *const ::core::ffi::c_void) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(haccessor), ::core::mem::transmute(crows), ::core::mem::transmute(compareops), ::core::mem::transmute(pcriteriadata)).ok() } } unsafe impl ::windows::core::Interface for IViewFilter { type Vtable = IViewFilter_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a9b_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IViewFilter> for ::windows::core::IUnknown { fn from(value: IViewFilter) -> Self { value.0 } } impl ::core::convert::From<&IViewFilter> for ::windows::core::IUnknown { fn from(value: &IViewFilter) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IViewFilter { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IViewFilter { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IViewFilter_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, haccessor: usize, pcrows: *mut usize, pcompareops: *mut *mut u32, pcriteriadata: *mut ::core::ffi::c_void) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_System_Com")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pcbindings: *mut usize, prgbindings: *mut *mut DBBINDING) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_System_Com"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, haccessor: usize, crows: usize, compareops: *const u32, pcriteriadata: *const ::core::ffi::c_void) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IViewRowset(pub ::windows::core::IUnknown); impl IViewRowset { pub unsafe fn GetSpecification(&self, riid: *const ::windows::core::GUID) -> ::windows::core::Result<::windows::core::IUnknown> { let mut result__: <::windows::core::IUnknown as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(riid), &mut result__).from_abi::<::windows::core::IUnknown>(result__) } pub unsafe fn OpenViewRowset<'a, Param0: ::windows::core::IntoParam<'a, ::windows::core::IUnknown>>(&self, punkouter: Param0, riid: *const ::windows::core::GUID) -> ::windows::core::Result<::windows::core::IUnknown> { let mut result__: <::windows::core::IUnknown as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), punkouter.into_param().abi(), ::core::mem::transmute(riid), &mut result__).from_abi::<::windows::core::IUnknown>(result__) } } unsafe impl ::windows::core::Interface for IViewRowset { type Vtable = IViewRowset_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a97_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IViewRowset> for ::windows::core::IUnknown { fn from(value: IViewRowset) -> Self { value.0 } } impl ::core::convert::From<&IViewRowset> for ::windows::core::IUnknown { fn from(value: &IViewRowset) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IViewRowset { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IViewRowset { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IViewRowset_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, riid: *const ::windows::core::GUID, ppobject: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, punkouter: ::windows::core::RawPtr, riid: *const ::windows::core::GUID, pprowset: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IViewSort(pub ::windows::core::IUnknown); impl IViewSort { pub unsafe fn GetSortOrder(&self, pcvalues: *mut usize, prgcolumns: *mut *mut usize, prgorders: *mut *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(pcvalues), ::core::mem::transmute(prgcolumns), ::core::mem::transmute(prgorders)).ok() } pub unsafe fn SetSortOrder(&self, cvalues: usize, rgcolumns: *const usize, rgorders: *const u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(cvalues), ::core::mem::transmute(rgcolumns), ::core::mem::transmute(rgorders)).ok() } } unsafe impl ::windows::core::Interface for IViewSort { type Vtable = IViewSort_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x0c733a9a_2a1c_11ce_ade5_00aa0044773d); } impl ::core::convert::From<IViewSort> for ::windows::core::IUnknown { fn from(value: IViewSort) -> Self { value.0 } } impl ::core::convert::From<&IViewSort> for ::windows::core::IUnknown { fn from(value: &IViewSort) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IViewSort { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IViewSort { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IViewSort_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pcvalues: *mut usize, prgcolumns: *mut *mut usize, prgorders: *mut *mut u32) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, cvalues: usize, rgcolumns: *const usize, rgorders: *const u32) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IWordBreaker(pub ::windows::core::IUnknown); impl IWordBreaker { #[cfg(feature = "Win32_Foundation")] pub unsafe fn Init<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::BOOL>>(&self, fquery: Param0, ulmaxtokensize: u32, pflicense: *mut super::super::Foundation::BOOL) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), fquery.into_param().abi(), ::core::mem::transmute(ulmaxtokensize), ::core::mem::transmute(pflicense)).ok() } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe fn BreakText<'a, Param1: ::windows::core::IntoParam<'a, IWordSink>, Param2: ::windows::core::IntoParam<'a, super::super::Storage::IndexServer::IPhraseSink>>(&self, ptextsource: *mut TEXT_SOURCE, pwordsink: Param1, pphrasesink: Param2) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(ptextsource), pwordsink.into_param().abi(), pphrasesink.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn ComposePhrase<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param2: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param5: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pwcnoun: Param0, cwcnoun: u32, pwcmodifier: Param2, cwcmodifier: u32, ulattachmenttype: u32, pwcphrase: Param5, pcwcphrase: *mut u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), pwcnoun.into_param().abi(), ::core::mem::transmute(cwcnoun), pwcmodifier.into_param().abi(), ::core::mem::transmute(cwcmodifier), ::core::mem::transmute(ulattachmenttype), pwcphrase.into_param().abi(), ::core::mem::transmute(pcwcphrase)).ok() } pub unsafe fn GetLicenseToUse(&self, ppwcslicense: *const *const u16) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), ::core::mem::transmute(ppwcslicense)).ok() } } unsafe impl ::windows::core::Interface for IWordBreaker { type Vtable = IWordBreaker_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xd53552c8_77e3_101a_b552_08002b33b0e6); } impl ::core::convert::From<IWordBreaker> for ::windows::core::IUnknown { fn from(value: IWordBreaker) -> Self { value.0 } } impl ::core::convert::From<&IWordBreaker> for ::windows::core::IUnknown { fn from(value: &IWordBreaker) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IWordBreaker { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IWordBreaker { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IWordBreaker_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, fquery: super::super::Foundation::BOOL, ulmaxtokensize: u32, pflicense: *mut super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ptextsource: *mut ::core::mem::ManuallyDrop<TEXT_SOURCE>, pwordsink: ::windows::core::RawPtr, pphrasesink: ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer")))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pwcnoun: super::super::Foundation::PWSTR, cwcnoun: u32, pwcmodifier: super::super::Foundation::PWSTR, cwcmodifier: u32, ulattachmenttype: u32, pwcphrase: super::super::Foundation::PWSTR, pcwcphrase: *mut u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, ppwcslicense: *const *const u16) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IWordFormSink(pub ::windows::core::IUnknown); impl IWordFormSink { #[cfg(feature = "Win32_Foundation")] pub unsafe fn PutAltWord<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pwcinbuf: Param0, cwc: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), pwcinbuf.into_param().abi(), ::core::mem::transmute(cwc)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn PutWord<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, pwcinbuf: Param0, cwc: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), pwcinbuf.into_param().abi(), ::core::mem::transmute(cwc)).ok() } } unsafe impl ::windows::core::Interface for IWordFormSink { type Vtable = IWordFormSink_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xfe77c330_7f42_11ce_be57_00aa0051fe20); } impl ::core::convert::From<IWordFormSink> for ::windows::core::IUnknown { fn from(value: IWordFormSink) -> Self { value.0 } } impl ::core::convert::From<&IWordFormSink> for ::windows::core::IUnknown { fn from(value: &IWordFormSink) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IWordFormSink { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IWordFormSink { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IWordFormSink_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pwcinbuf: super::super::Foundation::PWSTR, cwc: u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pwcinbuf: super::super::Foundation::PWSTR, cwc: u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct IWordSink(pub ::windows::core::IUnknown); impl IWordSink { #[cfg(feature = "Win32_Foundation")] pub unsafe fn PutWord<'a, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, cwc: u32, pwcinbuf: Param1, cwcsrclen: u32, cwcsrcpos: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(cwc), pwcinbuf.into_param().abi(), ::core::mem::transmute(cwcsrclen), ::core::mem::transmute(cwcsrcpos)).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn PutAltWord<'a, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(&self, cwc: u32, pwcinbuf: Param1, cwcsrclen: u32, cwcsrcpos: u32) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(cwc), pwcinbuf.into_param().abi(), ::core::mem::transmute(cwcsrclen), ::core::mem::transmute(cwcsrcpos)).ok() } pub unsafe fn StartAltPhrase(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self)).ok() } pub unsafe fn EndAltPhrase(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self)).ok() } #[cfg(feature = "Win32_Storage_IndexServer")] pub unsafe fn PutBreak(&self, breaktype: super::super::Storage::IndexServer::WORDREP_BREAK_TYPE) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), ::core::mem::transmute(breaktype)).ok() } } unsafe impl ::windows::core::Interface for IWordSink { type Vtable = IWordSink_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xcc907054_c058_101a_b554_08002b33b0e6); } impl ::core::convert::From<IWordSink> for ::windows::core::IUnknown { fn from(value: IWordSink) -> Self { value.0 } } impl ::core::convert::From<&IWordSink> for ::windows::core::IUnknown { fn from(value: &IWordSink) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for IWordSink { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a IWordSink { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct IWordSink_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, cwc: u32, pwcinbuf: super::super::Foundation::PWSTR, cwcsrclen: u32, cwcsrcpos: u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, cwc: u32, pwcinbuf: super::super::Foundation::PWSTR, cwcsrclen: u32, cwcsrcpos: u32) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Storage_IndexServer")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, breaktype: super::super::Storage::IndexServer::WORDREP_BREAK_TYPE) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Storage_IndexServer"))] usize, ); pub const Interval: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xd957171f_4bf9_4de2_bcd5_c70a7ca55836); pub const JET_GET_PROP_STORE_ERROR: i32 = -1073732822i32; pub const JET_INIT_ERROR: i32 = -1073732824i32; pub const JET_MULTIINSTANCE_DISABLED: i32 = -2147474645i32; pub const JET_NEW_PROP_STORE_ERROR: i32 = -1073732823i32; pub const JPS_E_CATALOG_DECSRIPTION_MISSING: i32 = -2147217023i32; pub const JPS_E_INSUFFICIENT_DATABASE_RESOURCES: i32 = -2147217019i32; pub const JPS_E_INSUFFICIENT_DATABASE_SESSIONS: i32 = -2147217020i32; pub const JPS_E_INSUFFICIENT_VERSION_STORAGE: i32 = -2147217021i32; pub const JPS_E_JET_ERR: i32 = -2147217025i32; pub const JPS_E_MISSING_INFORMATION: i32 = -2147217022i32; pub const JPS_E_PROPAGATION_CORRUPTION: i32 = -2147217016i32; pub const JPS_E_PROPAGATION_FILE: i32 = -2147217017i32; pub const JPS_E_PROPAGATION_VERSION_MISMATCH: i32 = -2147217015i32; pub const JPS_E_SCHEMA_ERROR: i32 = -2147217018i32; pub const JPS_E_SHARING_VIOLATION: i32 = -2147217014i32; pub const JPS_S_DUPLICATE_DOC_DETECTED: i32 = 266624i32; #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::clone::Clone for KAGGETDIAG { fn clone(&self) -> Self { unimplemented!() } } #[repr(C)] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub struct KAGGETDIAG { pub ulSize: u32, pub vDiagInfo: super::Com::VARIANT, pub sDiagField: i16, } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl KAGGETDIAG {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::default::Default for KAGGETDIAG { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::cmp::PartialEq for KAGGETDIAG { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] impl ::core::cmp::Eq for KAGGETDIAG {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] unsafe impl ::windows::core::Abi for KAGGETDIAG { type Abi = ::core::mem::ManuallyDrop<Self>; } pub const KAGPROPVAL_CONCUR_LOCK: u32 = 4u32; pub const KAGPROPVAL_CONCUR_READ_ONLY: u32 = 8u32; pub const KAGPROPVAL_CONCUR_ROWVER: u32 = 1u32; pub const KAGPROPVAL_CONCUR_VALUES: u32 = 2u32; pub const KAGPROP_ACCESSIBLEPROCEDURES: u32 = 2u32; pub const KAGPROP_ACCESSIBLETABLES: u32 = 3u32; pub const KAGPROP_ACTIVESTATEMENTS: u32 = 24u32; pub const KAGPROP_AUTH_SERVERINTEGRATED: u32 = 3u32; pub const KAGPROP_AUTH_TRUSTEDCONNECTION: u32 = 2u32; pub const KAGPROP_BLOBSONFOCURSOR: u32 = 8u32; pub const KAGPROP_CONCURRENCY: u32 = 7u32; pub const KAGPROP_CURSOR: u32 = 6u32; pub const KAGPROP_DRIVERNAME: u32 = 7u32; pub const KAGPROP_DRIVERODBCVER: u32 = 9u32; pub const KAGPROP_DRIVERVER: u32 = 8u32; pub const KAGPROP_FILEUSAGE: u32 = 23u32; pub const KAGPROP_FORCENOPARAMETERREBIND: u32 = 11u32; pub const KAGPROP_FORCENOPREPARE: u32 = 12u32; pub const KAGPROP_FORCENOREEXECUTE: u32 = 13u32; pub const KAGPROP_FORCESSFIREHOSEMODE: u32 = 10u32; pub const KAGPROP_INCLUDENONEXACT: u32 = 9u32; pub const KAGPROP_IRowsetChangeExtInfo: u32 = 5u32; pub const KAGPROP_LIKEESCAPECLAUSE: u32 = 10u32; pub const KAGPROP_MARSHALLABLE: u32 = 3u32; pub const KAGPROP_MAXCOLUMNSINGROUPBY: u32 = 12u32; pub const KAGPROP_MAXCOLUMNSININDEX: u32 = 13u32; pub const KAGPROP_MAXCOLUMNSINORDERBY: u32 = 14u32; pub const KAGPROP_MAXCOLUMNSINSELECT: u32 = 15u32; pub const KAGPROP_MAXCOLUMNSINTABLE: u32 = 16u32; pub const KAGPROP_NUMERICFUNCTIONS: u32 = 17u32; pub const KAGPROP_ODBCSQLCONFORMANCE: u32 = 18u32; pub const KAGPROP_ODBCSQLOPTIEF: u32 = 4u32; pub const KAGPROP_OJCAPABILITY: u32 = 5u32; pub const KAGPROP_OUTERJOINS: u32 = 19u32; pub const KAGPROP_POSITIONONNEWROW: u32 = 4u32; pub const KAGPROP_PROCEDURES: u32 = 6u32; pub const KAGPROP_QUERYBASEDUPDATES: u32 = 2u32; pub const KAGPROP_SPECIALCHARACTERS: u32 = 11u32; pub const KAGPROP_STRINGFUNCTIONS: u32 = 20u32; pub const KAGPROP_SYSTEMFUNCTIONS: u32 = 21u32; pub const KAGPROP_TIMEDATEFUNCTIONS: u32 = 22u32; #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] pub struct KAGREQDIAG { pub ulDiagFlags: u32, pub vt: u16, pub sDiagField: i16, } impl KAGREQDIAG {} impl ::core::default::Default for KAGREQDIAG { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } impl ::core::fmt::Debug for KAGREQDIAG { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("KAGREQDIAG").field("ulDiagFlags", &self.ulDiagFlags).field("vt", &self.vt).field("sDiagField", &self.sDiagField).finish() } } impl ::core::cmp::PartialEq for KAGREQDIAG { fn eq(&self, other: &Self) -> bool { self.ulDiagFlags == other.ulDiagFlags && self.vt == other.vt && self.sDiagField == other.sDiagField } } impl ::core::cmp::Eq for KAGREQDIAG {} unsafe impl ::windows::core::Abi for KAGREQDIAG { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct KAGREQDIAGFLAGSENUM(pub i32); pub const KAGREQDIAGFLAGS_HEADER: KAGREQDIAGFLAGSENUM = KAGREQDIAGFLAGSENUM(1i32); pub const KAGREQDIAGFLAGS_RECORD: KAGREQDIAGFLAGSENUM = KAGREQDIAGFLAGSENUM(2i32); impl ::core::convert::From<i32> for KAGREQDIAGFLAGSENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for KAGREQDIAGFLAGSENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct LOCKMODEENUM(pub i32); pub const LOCKMODE_INVALID: LOCKMODEENUM = LOCKMODEENUM(0i32); pub const LOCKMODE_EXCLUSIVE: LOCKMODEENUM = LOCKMODEENUM(1i32); pub const LOCKMODE_SHARED: LOCKMODEENUM = LOCKMODEENUM(2i32); impl ::core::convert::From<i32> for LOCKMODEENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for LOCKMODEENUM { type Abi = Self; } pub const LeafCondition: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x52f15c89_5a17_48e1_bbcd_46a3f89c7cc2); pub const MAXNAME: u32 = 129u32; pub const MAXNUMERICLEN: u32 = 16u32; pub const MAXUSEVERITY: u32 = 18u32; pub const MAX_QUERY_RANK: u32 = 1000u32; #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(feature = "Win32_Foundation")] pub struct MDAXISINFO { pub cbSize: usize, pub iAxis: usize, pub cDimensions: usize, pub cCoordinates: usize, pub rgcColumns: *mut usize, pub rgpwszDimensionNames: *mut super::super::Foundation::PWSTR, } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(feature = "Win32_Foundation")] impl MDAXISINFO {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(feature = "Win32_Foundation")] impl ::core::default::Default for MDAXISINFO { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(feature = "Win32_Foundation")] impl ::core::fmt::Debug for MDAXISINFO { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("MDAXISINFO").field("cbSize", &self.cbSize).field("iAxis", &self.iAxis).field("cDimensions", &self.cDimensions).field("cCoordinates", &self.cCoordinates).field("rgcColumns", &self.rgcColumns).field("rgpwszDimensionNames", &self.rgpwszDimensionNames).finish() } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(feature = "Win32_Foundation")] impl ::core::cmp::PartialEq for MDAXISINFO { fn eq(&self, other: &Self) -> bool { self.cbSize == other.cbSize && self.iAxis == other.iAxis && self.cDimensions == other.cDimensions && self.cCoordinates == other.cCoordinates && self.rgcColumns == other.rgcColumns && self.rgpwszDimensionNames == other.rgpwszDimensionNames } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(feature = "Win32_Foundation")] impl ::core::cmp::Eq for MDAXISINFO {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(feature = "Win32_Foundation")] unsafe impl ::windows::core::Abi for MDAXISINFO { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C, packed(2))] #[cfg(any(target_arch = "x86",))] #[cfg(feature = "Win32_Foundation")] pub struct MDAXISINFO { pub cbSize: usize, pub iAxis: usize, pub cDimensions: usize, pub cCoordinates: usize, pub rgcColumns: *mut usize, pub rgpwszDimensionNames: *mut super::super::Foundation::PWSTR, } #[cfg(any(target_arch = "x86",))] #[cfg(feature = "Win32_Foundation")] impl MDAXISINFO {} #[cfg(any(target_arch = "x86",))] #[cfg(feature = "Win32_Foundation")] impl ::core::default::Default for MDAXISINFO { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86",))] #[cfg(feature = "Win32_Foundation")] impl ::core::cmp::PartialEq for MDAXISINFO { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(any(target_arch = "x86",))] #[cfg(feature = "Win32_Foundation")] impl ::core::cmp::Eq for MDAXISINFO {} #[cfg(any(target_arch = "x86",))] #[cfg(feature = "Win32_Foundation")] unsafe impl ::windows::core::Abi for MDAXISINFO { type Abi = Self; } pub const MDAXIS_CHAPTERS: u32 = 4u32; pub const MDAXIS_COLUMNS: u32 = 0u32; pub const MDAXIS_PAGES: u32 = 2u32; pub const MDAXIS_ROWS: u32 = 1u32; pub const MDAXIS_SECTIONS: u32 = 3u32; pub const MDAXIS_SLICERS: u32 = 4294967295u32; pub const MDDISPINFO_DRILLED_DOWN: u32 = 65536u32; pub const MDDISPINFO_PARENT_SAME_AS_PREV: u32 = 131072u32; pub const MDFF_BOLD: u32 = 1u32; pub const MDFF_ITALIC: u32 = 2u32; pub const MDFF_STRIKEOUT: u32 = 8u32; pub const MDFF_UNDERLINE: u32 = 4u32; pub const MDLEVEL_TYPE_ALL: u32 = 1u32; pub const MDLEVEL_TYPE_CALCULATED: u32 = 2u32; pub const MDLEVEL_TYPE_REGULAR: u32 = 0u32; pub const MDLEVEL_TYPE_RESERVED1: u32 = 8u32; pub const MDLEVEL_TYPE_TIME: u32 = 4u32; pub const MDLEVEL_TYPE_TIME_DAYS: u32 = 516u32; pub const MDLEVEL_TYPE_TIME_HALF_YEAR: u32 = 36u32; pub const MDLEVEL_TYPE_TIME_HOURS: u32 = 772u32; pub const MDLEVEL_TYPE_TIME_MINUTES: u32 = 1028u32; pub const MDLEVEL_TYPE_TIME_MONTHS: u32 = 132u32; pub const MDLEVEL_TYPE_TIME_QUARTERS: u32 = 68u32; pub const MDLEVEL_TYPE_TIME_SECONDS: u32 = 2052u32; pub const MDLEVEL_TYPE_TIME_UNDEFINED: u32 = 4100u32; pub const MDLEVEL_TYPE_TIME_WEEKS: u32 = 260u32; pub const MDLEVEL_TYPE_TIME_YEARS: u32 = 20u32; pub const MDLEVEL_TYPE_UNKNOWN: u32 = 0u32; pub const MDMEASURE_AGGR_AVG: u32 = 5u32; pub const MDMEASURE_AGGR_CALCULATED: u32 = 127u32; pub const MDMEASURE_AGGR_COUNT: u32 = 2u32; pub const MDMEASURE_AGGR_MAX: u32 = 4u32; pub const MDMEASURE_AGGR_MIN: u32 = 3u32; pub const MDMEASURE_AGGR_STD: u32 = 7u32; pub const MDMEASURE_AGGR_SUM: u32 = 1u32; pub const MDMEASURE_AGGR_UNKNOWN: u32 = 0u32; pub const MDMEASURE_AGGR_VAR: u32 = 6u32; pub const MDMEMBER_TYPE_ALL: u32 = 2u32; pub const MDMEMBER_TYPE_FORMULA: u32 = 4u32; pub const MDMEMBER_TYPE_MEASURE: u32 = 3u32; pub const MDMEMBER_TYPE_REGULAR: u32 = 1u32; pub const MDMEMBER_TYPE_RESERVE1: u32 = 5u32; pub const MDMEMBER_TYPE_RESERVE2: u32 = 6u32; pub const MDMEMBER_TYPE_RESERVE3: u32 = 7u32; pub const MDMEMBER_TYPE_RESERVE4: u32 = 8u32; pub const MDMEMBER_TYPE_UNKNOWN: u32 = 0u32; pub const MDPROPVAL_AU_UNCHANGED: i32 = 1i32; pub const MDPROPVAL_AU_UNKNOWN: i32 = 2i32; pub const MDPROPVAL_AU_UNSUPPORTED: i32 = 0i32; pub const MDPROPVAL_FS_FULL_SUPPORT: i32 = 1i32; pub const MDPROPVAL_FS_GENERATED_COLUMN: i32 = 2i32; pub const MDPROPVAL_FS_GENERATED_DIMENSION: i32 = 3i32; pub const MDPROPVAL_FS_NO_SUPPORT: i32 = 4i32; pub const MDPROPVAL_MC_SEARCHEDCASE: i32 = 2i32; pub const MDPROPVAL_MC_SINGLECASE: i32 = 1i32; pub const MDPROPVAL_MD_AFTER: i32 = 4i32; pub const MDPROPVAL_MD_BEFORE: i32 = 2i32; pub const MDPROPVAL_MD_SELF: i32 = 1i32; pub const MDPROPVAL_MF_CREATE_CALCMEMBERS: i32 = 4i32; pub const MDPROPVAL_MF_CREATE_NAMEDSETS: i32 = 8i32; pub const MDPROPVAL_MF_SCOPE_GLOBAL: i32 = 32i32; pub const MDPROPVAL_MF_SCOPE_SESSION: i32 = 16i32; pub const MDPROPVAL_MF_WITH_CALCMEMBERS: i32 = 1i32; pub const MDPROPVAL_MF_WITH_NAMEDSETS: i32 = 2i32; pub const MDPROPVAL_MJC_IMPLICITCUBE: i32 = 4i32; pub const MDPROPVAL_MJC_MULTICUBES: i32 = 2i32; pub const MDPROPVAL_MJC_SINGLECUBE: i32 = 1i32; pub const MDPROPVAL_MMF_CLOSINGPERIOD: i32 = 8i32; pub const MDPROPVAL_MMF_COUSIN: i32 = 1i32; pub const MDPROPVAL_MMF_OPENINGPERIOD: i32 = 4i32; pub const MDPROPVAL_MMF_PARALLELPERIOD: i32 = 2i32; pub const MDPROPVAL_MNF_AGGREGATE: i32 = 16i32; pub const MDPROPVAL_MNF_CORRELATION: i32 = 64i32; pub const MDPROPVAL_MNF_COVARIANCE: i32 = 32i32; pub const MDPROPVAL_MNF_DRILLDOWNLEVEL: i32 = 2048i32; pub const MDPROPVAL_MNF_DRILLDOWNLEVELBOTTOM: i32 = 32768i32; pub const MDPROPVAL_MNF_DRILLDOWNLEVELTOP: i32 = 16384i32; pub const MDPROPVAL_MNF_DRILLDOWNMEMBERBOTTOM: i32 = 8192i32; pub const MDPROPVAL_MNF_DRILLDOWNMEMBERTOP: i32 = 4096i32; pub const MDPROPVAL_MNF_DRILLUPLEVEL: i32 = 131072i32; pub const MDPROPVAL_MNF_DRILLUPMEMBER: i32 = 65536i32; pub const MDPROPVAL_MNF_LINREG2: i32 = 512i32; pub const MDPROPVAL_MNF_LINREGPOINT: i32 = 1024i32; pub const MDPROPVAL_MNF_LINREGSLOPE: i32 = 128i32; pub const MDPROPVAL_MNF_LINREGVARIANCE: i32 = 256i32; pub const MDPROPVAL_MNF_MEDIAN: i32 = 1i32; pub const MDPROPVAL_MNF_RANK: i32 = 8i32; pub const MDPROPVAL_MNF_STDDEV: i32 = 4i32; pub const MDPROPVAL_MNF_VAR: i32 = 2i32; pub const MDPROPVAL_MOQ_CATALOG_CUBE: i32 = 2i32; pub const MDPROPVAL_MOQ_CUBE_DIM: i32 = 8i32; pub const MDPROPVAL_MOQ_DATASOURCE_CUBE: i32 = 1i32; pub const MDPROPVAL_MOQ_DIMHIER_LEVEL: i32 = 32i32; pub const MDPROPVAL_MOQ_DIMHIER_MEMBER: i32 = 256i32; pub const MDPROPVAL_MOQ_DIM_HIER: i32 = 16i32; pub const MDPROPVAL_MOQ_LEVEL_MEMBER: i32 = 64i32; pub const MDPROPVAL_MOQ_MEMBER_MEMBER: i32 = 128i32; pub const MDPROPVAL_MOQ_OUTERREFERENCE: i32 = 1i32; pub const MDPROPVAL_MOQ_SCHEMA_CUBE: i32 = 4i32; pub const MDPROPVAL_MSC_GREATERTHAN: i32 = 2i32; pub const MDPROPVAL_MSC_GREATERTHANEQUAL: i32 = 8i32; pub const MDPROPVAL_MSC_LESSTHAN: i32 = 1i32; pub const MDPROPVAL_MSC_LESSTHANEQUAL: i32 = 4i32; pub const MDPROPVAL_MSF_BOTTOMPERCENT: i32 = 2i32; pub const MDPROPVAL_MSF_BOTTOMSUM: i32 = 8i32; pub const MDPROPVAL_MSF_DRILLDOWNLEVEL: i32 = 2048i32; pub const MDPROPVAL_MSF_DRILLDOWNLEVELBOTTOM: i32 = 32768i32; pub const MDPROPVAL_MSF_DRILLDOWNLEVELTOP: i32 = 16384i32; pub const MDPROPVAL_MSF_DRILLDOWNMEMBBER: i32 = 1024i32; pub const MDPROPVAL_MSF_DRILLDOWNMEMBERBOTTOM: i32 = 8192i32; pub const MDPROPVAL_MSF_DRILLDOWNMEMBERTOP: i32 = 4096i32; pub const MDPROPVAL_MSF_DRILLUPLEVEL: i32 = 131072i32; pub const MDPROPVAL_MSF_DRILLUPMEMBER: i32 = 65536i32; pub const MDPROPVAL_MSF_LASTPERIODS: i32 = 32i32; pub const MDPROPVAL_MSF_MTD: i32 = 256i32; pub const MDPROPVAL_MSF_PERIODSTODATE: i32 = 16i32; pub const MDPROPVAL_MSF_QTD: i32 = 128i32; pub const MDPROPVAL_MSF_TOGGLEDRILLSTATE: i32 = 262144i32; pub const MDPROPVAL_MSF_TOPPERCENT: i32 = 1i32; pub const MDPROPVAL_MSF_TOPSUM: i32 = 4i32; pub const MDPROPVAL_MSF_WTD: i32 = 512i32; pub const MDPROPVAL_MSF_YTD: i32 = 64i32; pub const MDPROPVAL_MS_MULTIPLETUPLES: i32 = 1i32; pub const MDPROPVAL_MS_SINGLETUPLE: i32 = 2i32; pub const MDPROPVAL_NL_NAMEDLEVELS: i32 = 1i32; pub const MDPROPVAL_NL_NUMBEREDLEVELS: i32 = 2i32; pub const MDPROPVAL_NL_SCHEMAONLY: i32 = 4i32; pub const MDPROPVAL_NME_ALLDIMENSIONS: i32 = 0i32; pub const MDPROPVAL_NME_MEASURESONLY: i32 = 1i32; pub const MDPROPVAL_RR_NORANGEROWSET: i32 = 1i32; pub const MDPROPVAL_RR_READONLY: i32 = 2i32; pub const MDPROPVAL_RR_UPDATE: i32 = 4i32; pub const MDPROPVAL_VISUAL_MODE_DEFAULT: i32 = 0i32; pub const MDPROPVAL_VISUAL_MODE_VISUAL: i32 = 1i32; pub const MDPROPVAL_VISUAL_MODE_VISUAL_OFF: i32 = 2i32; pub const MDPROP_CELL: u32 = 2u32; pub const MDPROP_MEMBER: u32 = 1u32; pub const MDTREEOP_ANCESTORS: u32 = 32u32; pub const MDTREEOP_CHILDREN: u32 = 1u32; pub const MDTREEOP_DESCENDANTS: u32 = 16u32; pub const MDTREEOP_PARENT: u32 = 4u32; pub const MDTREEOP_SELF: u32 = 8u32; pub const MDTREEOP_SIBLINGS: u32 = 2u32; pub const MD_DIMTYPE_MEASURE: u32 = 2u32; pub const MD_DIMTYPE_OTHER: u32 = 3u32; pub const MD_DIMTYPE_TIME: u32 = 1u32; pub const MD_DIMTYPE_UNKNOWN: u32 = 0u32; pub const MD_E_BADCOORDINATE: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217822i32 as _); pub const MD_E_BADTUPLE: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217823i32 as _); pub const MD_E_INVALIDAXIS: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217821i32 as _); pub const MD_E_INVALIDCELLRANGE: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217820i32 as _); pub const MINFATALERR: u32 = 20u32; pub const MIN_USER_DATATYPE: u32 = 256u32; pub const MSDAINITIALIZE: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x2206cdb0_19c1_11d1_89e0_00c04fd7a829); pub const MSDAORA: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xe8cc4cbe_fdff_11d0_b865_00a0c9081c1d); pub const MSDAORA8: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x7f06a373_dd6a_43db_b4e0_1fc121e5e62b); pub const MSDAORA8_ERROR: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x7f06a374_dd6a_43db_b4e0_1fc121e5e62b); pub const MSDAORA_ERROR: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xe8cc4cbf_fdff_11d0_b865_00a0c9081c1d); #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct MSDSDBINITPROPENUM(pub i32); pub const DBPROP_MSDS_DBINIT_DATAPROVIDER: MSDSDBINITPROPENUM = MSDSDBINITPROPENUM(2i32); impl ::core::convert::From<i32> for MSDSDBINITPROPENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for MSDSDBINITPROPENUM { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct MSDSSESSIONPROPENUM(pub i32); pub const DBPROP_MSDS_SESS_UNIQUENAMES: MSDSSESSIONPROPENUM = MSDSSESSIONPROPENUM(2i32); impl ::core::convert::From<i32> for MSDSSESSIONPROPENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for MSDSSESSIONPROPENUM { type Abi = Self; } pub const MSG_CI_CORRUPT_INDEX_COMPONENT: ::windows::core::HRESULT = ::windows::core::HRESULT(1073745962i32 as _); pub const MSG_CI_CREATE_SEVER_ITEM_FAILED: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147479480i32 as _); pub const MSG_CI_MASTER_MERGE_ABORTED: ::windows::core::HRESULT = ::windows::core::HRESULT(1073745928i32 as _); pub const MSG_CI_MASTER_MERGE_ABORTED_LOW_DISK: ::windows::core::HRESULT = ::windows::core::HRESULT(1073745987i32 as _); pub const MSG_CI_MASTER_MERGE_CANT_RESTART: ::windows::core::HRESULT = ::windows::core::HRESULT(-1073737718i32 as _); pub const MSG_CI_MASTER_MERGE_CANT_START: ::windows::core::HRESULT = ::windows::core::HRESULT(-1073737719i32 as _); pub const MSG_CI_MASTER_MERGE_COMPLETED: ::windows::core::HRESULT = ::windows::core::HRESULT(1073745927i32 as _); pub const MSG_CI_MASTER_MERGE_REASON_EXPECTED_DOCS: ::windows::core::HRESULT = ::windows::core::HRESULT(1073745990i32 as _); pub const MSG_CI_MASTER_MERGE_REASON_EXTERNAL: ::windows::core::HRESULT = ::windows::core::HRESULT(1073745988i32 as _); pub const MSG_CI_MASTER_MERGE_REASON_INDEX_LIMIT: ::windows::core::HRESULT = ::windows::core::HRESULT(1073745989i32 as _); pub const MSG_CI_MASTER_MERGE_REASON_NUMBER: ::windows::core::HRESULT = ::windows::core::HRESULT(1073745991i32 as _); pub const MSG_CI_MASTER_MERGE_RESTARTED: ::windows::core::HRESULT = ::windows::core::HRESULT(1073745945i32 as _); pub const MSG_CI_MASTER_MERGE_STARTED: ::windows::core::HRESULT = ::windows::core::HRESULT(1073745926i32 as _); pub const MSG_TEST_MESSAGE: i32 = 1074008064i32; pub const MSS_E_APPALREADYEXISTS: i32 = -2147213054i32; pub const MSS_E_APPNOTFOUND: i32 = -2147213055i32; pub const MSS_E_CATALOGALREADYEXISTS: i32 = -2147213050i32; pub const MSS_E_CATALOGNOTFOUND: i32 = -2147213053i32; pub const MSS_E_CATALOGSTOPPING: i32 = -2147213052i32; pub const MSS_E_INVALIDAPPNAME: i32 = -2147213056i32; pub const MSS_E_UNICODEFILEHEADERMISSING: i32 = -2147213051i32; #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct NAMED_ENTITY_CERTAINTY(pub i32); pub const NEC_LOW: NAMED_ENTITY_CERTAINTY = NAMED_ENTITY_CERTAINTY(0i32); pub const NEC_MEDIUM: NAMED_ENTITY_CERTAINTY = NAMED_ENTITY_CERTAINTY(1i32); pub const NEC_HIGH: NAMED_ENTITY_CERTAINTY = NAMED_ENTITY_CERTAINTY(2i32); impl ::core::convert::From<i32> for NAMED_ENTITY_CERTAINTY { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for NAMED_ENTITY_CERTAINTY { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage"))] pub struct NATLANGUAGERESTRICTION { pub prop: super::super::Storage::IndexServer::FULLPROPSPEC, pub pwcsPhrase: super::super::Foundation::PWSTR, pub lcid: u32, } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage"))] impl NATLANGUAGERESTRICTION {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::default::Default for NATLANGUAGERESTRICTION { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::cmp::PartialEq for NATLANGUAGERESTRICTION { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::cmp::Eq for NATLANGUAGERESTRICTION {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage"))] unsafe impl ::windows::core::Abi for NATLANGUAGERESTRICTION { type Abi = Self; } pub const NET_E_DISCONNECTED: i32 = -2147220733i32; pub const NET_E_GENERAL: i32 = -2147220736i32; pub const NET_E_INVALIDPARAMS: i32 = -2147220728i32; pub const NET_E_OPERATIONINPROGRESS: i32 = -2147220727i32; pub const NLADMIN_E_BUILD_CATALOG_NOT_INITIALIZED: i32 = -2147215100i32; pub const NLADMIN_E_DUPLICATE_CATALOG: i32 = -2147215103i32; pub const NLADMIN_E_FAILED_TO_GIVE_ACCOUNT_PRIVILEGE: i32 = -2147215101i32; pub const NLADMIN_S_NOT_ALL_BUILD_CATALOGS_INITIALIZED: i32 = 268546i32; #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub struct NODERESTRICTION { pub cRes: u32, pub paRes: *mut *mut RESTRICTION, pub reserved: u32, } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl NODERESTRICTION {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::default::Default for NODERESTRICTION { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::fmt::Debug for NODERESTRICTION { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("NODERESTRICTION").field("cRes", &self.cRes).field("paRes", &self.paRes).field("reserved", &self.reserved).finish() } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::cmp::PartialEq for NODERESTRICTION { fn eq(&self, other: &Self) -> bool { self.cRes == other.cRes && self.paRes == other.paRes && self.reserved == other.reserved } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::cmp::Eq for NODERESTRICTION {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] unsafe impl ::windows::core::Abi for NODERESTRICTION { type Abi = Self; } pub const NOTESPH_E_ATTACHMENTS: i32 = -2147211770i32; pub const NOTESPH_E_DB_ACCESS_DENIED: i32 = -2147211768i32; pub const NOTESPH_E_FAIL: i32 = -2147211759i32; pub const NOTESPH_E_ITEM_NOT_FOUND: i32 = -2147211772i32; pub const NOTESPH_E_NOTESSETUP_ID_MAPPING_ERROR: i32 = -2147211767i32; pub const NOTESPH_E_NO_NTID: i32 = -2147211769i32; pub const NOTESPH_E_SERVER_CONFIG: i32 = -2147211771i32; pub const NOTESPH_E_UNEXPECTED_STATE: i32 = -2147211775i32; pub const NOTESPH_E_UNSUPPORTED_CONTENT_FIELD_TYPE: i32 = -2147211773i32; pub const NOTESPH_S_IGNORE_ID: i32 = 271874i32; pub const NOTESPH_S_LISTKNOWNFIELDS: i32 = 271888i32; #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub struct NOTRESTRICTION { pub pRes: *mut RESTRICTION, } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl NOTRESTRICTION {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::default::Default for NOTRESTRICTION { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::fmt::Debug for NOTRESTRICTION { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("NOTRESTRICTION").field("pRes", &self.pRes).finish() } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::cmp::PartialEq for NOTRESTRICTION { fn eq(&self, other: &Self) -> bool { self.pRes == other.pRes } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::cmp::Eq for NOTRESTRICTION {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] unsafe impl ::windows::core::Abi for NOTRESTRICTION { type Abi = Self; } pub const NOT_N_PARSE_ERROR: ::windows::core::HRESULT = ::windows::core::HRESULT(526638i32 as _); pub const NegationCondition: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x8de9c74c_605a_4acd_bee3_2b222aa2d23d); pub const OCC_INVALID: u32 = 4294967295u32; #[inline] pub unsafe fn ODBCGetTryWaitValue() -> u32 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn ODBCGetTryWaitValue() -> u32; } ::core::mem::transmute(ODBCGetTryWaitValue()) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(feature = "Win32_Foundation")] #[inline] pub unsafe fn ODBCSetTryWaitValue(dwvalue: u32) -> super::super::Foundation::BOOL { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn ODBCSetTryWaitValue(dwvalue: u32) -> super::super::Foundation::BOOL; } ::core::mem::transmute(ODBCSetTryWaitValue(::core::mem::transmute(dwvalue))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } pub const ODBCVER: u32 = 896u32; pub const ODBC_ADD_DSN: u32 = 1u32; pub const ODBC_ADD_SYS_DSN: u32 = 4u32; pub const ODBC_BOTH_DSN: u32 = 0u32; pub const ODBC_CONFIG_DRIVER: u32 = 3u32; pub const ODBC_CONFIG_DRIVER_MAX: u32 = 100u32; pub const ODBC_CONFIG_DSN: u32 = 2u32; pub const ODBC_CONFIG_SYS_DSN: u32 = 5u32; pub const ODBC_ERROR_COMPONENT_NOT_FOUND: u32 = 6u32; pub const ODBC_ERROR_CREATE_DSN_FAILED: u32 = 18u32; pub const ODBC_ERROR_GENERAL_ERR: u32 = 1u32; pub const ODBC_ERROR_INVALID_BUFF_LEN: u32 = 2u32; pub const ODBC_ERROR_INVALID_DSN: u32 = 9u32; pub const ODBC_ERROR_INVALID_HWND: u32 = 3u32; pub const ODBC_ERROR_INVALID_INF: u32 = 10u32; pub const ODBC_ERROR_INVALID_KEYWORD_VALUE: u32 = 8u32; pub const ODBC_ERROR_INVALID_LOG_FILE: u32 = 15u32; pub const ODBC_ERROR_INVALID_NAME: u32 = 7u32; pub const ODBC_ERROR_INVALID_PARAM_SEQUENCE: u32 = 14u32; pub const ODBC_ERROR_INVALID_PATH: u32 = 12u32; pub const ODBC_ERROR_INVALID_REQUEST_TYPE: u32 = 5u32; pub const ODBC_ERROR_INVALID_STR: u32 = 4u32; pub const ODBC_ERROR_LOAD_LIB_FAILED: u32 = 13u32; pub const ODBC_ERROR_MAX: u32 = 23u32; pub const ODBC_ERROR_NOTRANINFO: u32 = 23u32; pub const ODBC_ERROR_OUTPUT_STRING_TRUNCATED: u32 = 22u32; pub const ODBC_ERROR_OUT_OF_MEM: u32 = 21u32; pub const ODBC_ERROR_REMOVE_DSN_FAILED: u32 = 20u32; pub const ODBC_ERROR_REQUEST_FAILED: u32 = 11u32; pub const ODBC_ERROR_USAGE_UPDATE_FAILED: u32 = 17u32; pub const ODBC_ERROR_USER_CANCELED: u32 = 16u32; pub const ODBC_ERROR_WRITING_SYSINFO_FAILED: u32 = 19u32; pub const ODBC_INSTALL_COMPLETE: u32 = 2u32; pub const ODBC_INSTALL_DRIVER: u32 = 1u32; pub const ODBC_INSTALL_INQUIRY: u32 = 1u32; pub const ODBC_REMOVE_DEFAULT_DSN: u32 = 7u32; pub const ODBC_REMOVE_DRIVER: u32 = 2u32; pub const ODBC_REMOVE_DSN: u32 = 3u32; pub const ODBC_REMOVE_SYS_DSN: u32 = 6u32; pub const ODBC_SYSTEM_DSN: u32 = 2u32; pub const ODBC_USER_DSN: u32 = 1u32; #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(feature = "Win32_Foundation")] pub struct ODBC_VS_ARGS { pub pguidEvent: *mut ::windows::core::GUID, pub dwFlags: u32, pub Anonymous1: ODBC_VS_ARGS_0, pub Anonymous2: ODBC_VS_ARGS_1, pub RetCode: i16, } #[cfg(feature = "Win32_Foundation")] impl ODBC_VS_ARGS {} #[cfg(feature = "Win32_Foundation")] impl ::core::default::Default for ODBC_VS_ARGS { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(feature = "Win32_Foundation")] impl ::core::cmp::PartialEq for ODBC_VS_ARGS { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(feature = "Win32_Foundation")] impl ::core::cmp::Eq for ODBC_VS_ARGS {} #[cfg(feature = "Win32_Foundation")] unsafe impl ::windows::core::Abi for ODBC_VS_ARGS { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(feature = "Win32_Foundation")] pub union ODBC_VS_ARGS_0 { pub wszArg: super::super::Foundation::PWSTR, pub szArg: super::super::Foundation::PSTR, } #[cfg(feature = "Win32_Foundation")] impl ODBC_VS_ARGS_0 {} #[cfg(feature = "Win32_Foundation")] impl ::core::default::Default for ODBC_VS_ARGS_0 { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(feature = "Win32_Foundation")] impl ::core::cmp::PartialEq for ODBC_VS_ARGS_0 { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(feature = "Win32_Foundation")] impl ::core::cmp::Eq for ODBC_VS_ARGS_0 {} #[cfg(feature = "Win32_Foundation")] unsafe impl ::windows::core::Abi for ODBC_VS_ARGS_0 { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(feature = "Win32_Foundation")] pub union ODBC_VS_ARGS_1 { pub wszCorrelation: super::super::Foundation::PWSTR, pub szCorrelation: super::super::Foundation::PSTR, } #[cfg(feature = "Win32_Foundation")] impl ODBC_VS_ARGS_1 {} #[cfg(feature = "Win32_Foundation")] impl ::core::default::Default for ODBC_VS_ARGS_1 { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(feature = "Win32_Foundation")] impl ::core::cmp::PartialEq for ODBC_VS_ARGS_1 { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(feature = "Win32_Foundation")] impl ::core::cmp::Eq for ODBC_VS_ARGS_1 {} #[cfg(feature = "Win32_Foundation")] unsafe impl ::windows::core::Abi for ODBC_VS_ARGS_1 { type Abi = Self; } pub const ODBC_VS_FLAG_RETCODE: i32 = 4i32; pub const ODBC_VS_FLAG_STOP: i32 = 8i32; pub const ODBC_VS_FLAG_UNICODE_ARG: i32 = 1i32; pub const ODBC_VS_FLAG_UNICODE_COR: i32 = 2i32; #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct OLEDBSimpleProvider(pub ::windows::core::IUnknown); impl OLEDBSimpleProvider { pub unsafe fn getRowCount(&self) -> ::windows::core::Result<isize> { let mut result__: <isize as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), &mut result__).from_abi::<isize>(result__) } pub unsafe fn getColumnCount(&self) -> ::windows::core::Result<isize> { let mut result__: <isize as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), &mut result__).from_abi::<isize>(result__) } pub unsafe fn getRWStatus(&self, irow: isize, icolumn: isize) -> ::windows::core::Result<OSPRW> { let mut result__: <OSPRW as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(irow), ::core::mem::transmute(icolumn), &mut result__).from_abi::<OSPRW>(result__) } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn getVariant(&self, irow: isize, icolumn: isize, format: OSPFORMAT) -> ::windows::core::Result<super::Com::VARIANT> { let mut result__: <super::Com::VARIANT as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), ::core::mem::transmute(irow), ::core::mem::transmute(icolumn), ::core::mem::transmute(format), &mut result__).from_abi::<super::Com::VARIANT>(result__) } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn setVariant<'a, Param3: ::windows::core::IntoParam<'a, super::Com::VARIANT>>(&self, irow: isize, icolumn: isize, format: OSPFORMAT, var: Param3) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), ::core::mem::transmute(irow), ::core::mem::transmute(icolumn), ::core::mem::transmute(format), var.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn getLocale(&self) -> ::windows::core::Result<super::super::Foundation::BSTR> { let mut result__: <super::super::Foundation::BSTR as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).8)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::BSTR>(result__) } pub unsafe fn deleteRows(&self, irow: isize, crows: isize) -> ::windows::core::Result<isize> { let mut result__: <isize as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).9)(::core::mem::transmute_copy(self), ::core::mem::transmute(irow), ::core::mem::transmute(crows), &mut result__).from_abi::<isize>(result__) } pub unsafe fn insertRows(&self, irow: isize, crows: isize) -> ::windows::core::Result<isize> { let mut result__: <isize as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).10)(::core::mem::transmute_copy(self), ::core::mem::transmute(irow), ::core::mem::transmute(crows), &mut result__).from_abi::<isize>(result__) } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe fn find<'a, Param2: ::windows::core::IntoParam<'a, super::Com::VARIANT>>(&self, irowstart: isize, icolumn: isize, val: Param2, findflags: OSPFIND, comptype: OSPCOMP) -> ::windows::core::Result<isize> { let mut result__: <isize as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).11)(::core::mem::transmute_copy(self), ::core::mem::transmute(irowstart), ::core::mem::transmute(icolumn), val.into_param().abi(), ::core::mem::transmute(findflags), ::core::mem::transmute(comptype), &mut result__).from_abi::<isize>(result__) } pub unsafe fn addOLEDBSimpleProviderListener<'a, Param0: ::windows::core::IntoParam<'a, OLEDBSimpleProviderListener>>(&self, pospilistener: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).12)(::core::mem::transmute_copy(self), pospilistener.into_param().abi()).ok() } pub unsafe fn removeOLEDBSimpleProviderListener<'a, Param0: ::windows::core::IntoParam<'a, OLEDBSimpleProviderListener>>(&self, pospilistener: Param0) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).13)(::core::mem::transmute_copy(self), pospilistener.into_param().abi()).ok() } #[cfg(feature = "Win32_Foundation")] pub unsafe fn isAsync(&self) -> ::windows::core::Result<super::super::Foundation::BOOL> { let mut result__: <super::super::Foundation::BOOL as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).14)(::core::mem::transmute_copy(self), &mut result__).from_abi::<super::super::Foundation::BOOL>(result__) } pub unsafe fn getEstimatedRows(&self) -> ::windows::core::Result<isize> { let mut result__: <isize as ::windows::core::Abi>::Abi = ::core::mem::zeroed(); (::windows::core::Interface::vtable(self).15)(::core::mem::transmute_copy(self), &mut result__).from_abi::<isize>(result__) } pub unsafe fn stopTransfer(&self) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).16)(::core::mem::transmute_copy(self)).ok() } } unsafe impl ::windows::core::Interface for OLEDBSimpleProvider { type Vtable = OLEDBSimpleProvider_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xe0e270c0_c0be_11d0_8fe4_00a0c90a6341); } impl ::core::convert::From<OLEDBSimpleProvider> for ::windows::core::IUnknown { fn from(value: OLEDBSimpleProvider) -> Self { value.0 } } impl ::core::convert::From<&OLEDBSimpleProvider> for ::windows::core::IUnknown { fn from(value: &OLEDBSimpleProvider) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for OLEDBSimpleProvider { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a OLEDBSimpleProvider { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct OLEDBSimpleProvider_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pcrows: *mut isize) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pccolumns: *mut isize) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, irow: isize, icolumn: isize, prwstatus: *mut OSPRW) -> ::windows::core::HRESULT, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, irow: isize, icolumn: isize, format: OSPFORMAT, pvar: *mut ::core::mem::ManuallyDrop<super::Com::VARIANT>) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, irow: isize, icolumn: isize, format: OSPFORMAT, var: ::core::mem::ManuallyDrop<super::Com::VARIANT>) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pbstrlocale: *mut ::core::mem::ManuallyDrop<super::super::Foundation::BSTR>) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, irow: isize, crows: isize, pcrowsdeleted: *mut isize) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, irow: isize, crows: isize, pcrowsinserted: *mut isize) -> ::windows::core::HRESULT, #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole"))] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, irowstart: isize, icolumn: isize, val: ::core::mem::ManuallyDrop<super::Com::VARIANT>, findflags: OSPFIND, comptype: OSPCOMP, pirowfound: *mut isize) -> ::windows::core::HRESULT, #[cfg(not(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Ole")))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pospilistener: ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pospilistener: ::windows::core::RawPtr) -> ::windows::core::HRESULT, #[cfg(feature = "Win32_Foundation")] pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pbasynch: *mut super::super::Foundation::BOOL) -> ::windows::core::HRESULT, #[cfg(not(feature = "Win32_Foundation"))] usize, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, pirows: *mut isize) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> ::windows::core::HRESULT, ); #[repr(transparent)] #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: clone :: Clone, :: core :: fmt :: Debug)] pub struct OLEDBSimpleProviderListener(pub ::windows::core::IUnknown); impl OLEDBSimpleProviderListener { pub unsafe fn aboutToChangeCell(&self, irow: isize, icolumn: isize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).3)(::core::mem::transmute_copy(self), ::core::mem::transmute(irow), ::core::mem::transmute(icolumn)).ok() } pub unsafe fn cellChanged(&self, irow: isize, icolumn: isize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).4)(::core::mem::transmute_copy(self), ::core::mem::transmute(irow), ::core::mem::transmute(icolumn)).ok() } pub unsafe fn aboutToDeleteRows(&self, irow: isize, crows: isize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).5)(::core::mem::transmute_copy(self), ::core::mem::transmute(irow), ::core::mem::transmute(crows)).ok() } pub unsafe fn deletedRows(&self, irow: isize, crows: isize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).6)(::core::mem::transmute_copy(self), ::core::mem::transmute(irow), ::core::mem::transmute(crows)).ok() } pub unsafe fn aboutToInsertRows(&self, irow: isize, crows: isize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).7)(::core::mem::transmute_copy(self), ::core::mem::transmute(irow), ::core::mem::transmute(crows)).ok() } pub unsafe fn insertedRows(&self, irow: isize, crows: isize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).8)(::core::mem::transmute_copy(self), ::core::mem::transmute(irow), ::core::mem::transmute(crows)).ok() } pub unsafe fn rowsAvailable(&self, irow: isize, crows: isize) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).9)(::core::mem::transmute_copy(self), ::core::mem::transmute(irow), ::core::mem::transmute(crows)).ok() } pub unsafe fn transferComplete(&self, xfer: OSPXFER) -> ::windows::core::Result<()> { (::windows::core::Interface::vtable(self).10)(::core::mem::transmute_copy(self), ::core::mem::transmute(xfer)).ok() } } unsafe impl ::windows::core::Interface for OLEDBSimpleProviderListener { type Vtable = OLEDBSimpleProviderListener_abi; const IID: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xe0e270c1_c0be_11d0_8fe4_00a0c90a6341); } impl ::core::convert::From<OLEDBSimpleProviderListener> for ::windows::core::IUnknown { fn from(value: OLEDBSimpleProviderListener) -> Self { value.0 } } impl ::core::convert::From<&OLEDBSimpleProviderListener> for ::windows::core::IUnknown { fn from(value: &OLEDBSimpleProviderListener) -> Self { value.0.clone() } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for OLEDBSimpleProviderListener { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Owned(self.0) } } impl<'a> ::windows::core::IntoParam<'a, ::windows::core::IUnknown> for &'a OLEDBSimpleProviderListener { fn into_param(self) -> ::windows::core::Param<'a, ::windows::core::IUnknown> { ::windows::core::Param::Borrowed(&self.0) } } #[repr(C)] #[doc(hidden)] pub struct OLEDBSimpleProviderListener_abi( pub unsafe extern "system" fn(this: ::windows::core::RawPtr, iid: &::windows::core::GUID, interface: *mut ::windows::core::RawPtr) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr) -> u32, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, irow: isize, icolumn: isize) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, irow: isize, icolumn: isize) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, irow: isize, crows: isize) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, irow: isize, crows: isize) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, irow: isize, crows: isize) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, irow: isize, crows: isize) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, irow: isize, crows: isize) -> ::windows::core::HRESULT, pub unsafe extern "system" fn(this: ::windows::core::RawPtr, xfer: OSPXFER) -> ::windows::core::HRESULT, ); pub const OLEDBVER: u32 = 624u32; pub const OLEDB_BINDER_CUSTOM_ERROR: i32 = -2147212032i32; #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct OSPCOMP(pub i32); pub const OSPCOMP_EQ: OSPCOMP = OSPCOMP(1i32); pub const OSPCOMP_DEFAULT: OSPCOMP = OSPCOMP(1i32); pub const OSPCOMP_LT: OSPCOMP = OSPCOMP(2i32); pub const OSPCOMP_LE: OSPCOMP = OSPCOMP(3i32); pub const OSPCOMP_GE: OSPCOMP = OSPCOMP(4i32); pub const OSPCOMP_GT: OSPCOMP = OSPCOMP(5i32); pub const OSPCOMP_NE: OSPCOMP = OSPCOMP(6i32); impl ::core::convert::From<i32> for OSPCOMP { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for OSPCOMP { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct OSPFIND(pub i32); pub const OSPFIND_DEFAULT: OSPFIND = OSPFIND(0i32); pub const OSPFIND_UP: OSPFIND = OSPFIND(1i32); pub const OSPFIND_CASESENSITIVE: OSPFIND = OSPFIND(2i32); pub const OSPFIND_UPCASESENSITIVE: OSPFIND = OSPFIND(3i32); impl ::core::convert::From<i32> for OSPFIND { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for OSPFIND { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct OSPFORMAT(pub i32); pub const OSPFORMAT_RAW: OSPFORMAT = OSPFORMAT(0i32); pub const OSPFORMAT_DEFAULT: OSPFORMAT = OSPFORMAT(0i32); pub const OSPFORMAT_FORMATTED: OSPFORMAT = OSPFORMAT(1i32); pub const OSPFORMAT_HTML: OSPFORMAT = OSPFORMAT(2i32); impl ::core::convert::From<i32> for OSPFORMAT { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for OSPFORMAT { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct OSPRW(pub i32); pub const OSPRW_DEFAULT: OSPRW = OSPRW(1i32); pub const OSPRW_READONLY: OSPRW = OSPRW(0i32); pub const OSPRW_READWRITE: OSPRW = OSPRW(1i32); pub const OSPRW_MIXED: OSPRW = OSPRW(2i32); impl ::core::convert::From<i32> for OSPRW { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for OSPRW { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct OSPXFER(pub i32); pub const OSPXFER_COMPLETE: OSPXFER = OSPXFER(0i32); pub const OSPXFER_ABORT: OSPXFER = OSPXFER(1i32); pub const OSPXFER_ERROR: OSPXFER = OSPXFER(2i32); impl ::core::convert::From<i32> for OSPXFER { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for OSPXFER { type Abi = Self; } pub const OSP_IndexLabel: u32 = 0u32; pub const PDPO: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xccb4ec60_b9dc_11d1_ac80_00a0c9034873); pub const PEOPLE_IMPORT_E_CANONICALURL_TOOLONG: i32 = -2147205110i32; pub const PEOPLE_IMPORT_E_DATATYPENOTSUPPORTED: i32 = -2147205115i32; pub const PEOPLE_IMPORT_E_DBCONNFAIL: i32 = -2147205120i32; pub const PEOPLE_IMPORT_E_DC_NOT_AVAILABLE: i32 = -2147205108i32; pub const PEOPLE_IMPORT_E_DIRSYNC_NOTREFRESHED: i32 = -2147205103i32; pub const PEOPLE_IMPORT_E_DIRSYNC_ZERO_COOKIE: i32 = -2147205112i32; pub const PEOPLE_IMPORT_E_DOMAIN_DISCOVER_FAILED: i32 = -2147205107i32; pub const PEOPLE_IMPORT_E_DOMAIN_REMOVED: i32 = -2147205105i32; pub const PEOPLE_IMPORT_E_ENUM_ACCESSDENIED: i32 = -2147205104i32; pub const PEOPLE_IMPORT_E_FAILTOGETDSDEF: i32 = -2147205118i32; pub const PEOPLE_IMPORT_E_FAILTOGETDSMAPPING: i32 = -2147205116i32; pub const PEOPLE_IMPORT_E_FAILTOGETLCID: i32 = -2147205106i32; pub const PEOPLE_IMPORT_E_LDAPPATH_TOOLONG: i32 = -2147205111i32; pub const PEOPLE_IMPORT_E_NOCASTINGSUPPORTED: i32 = -2147205114i32; pub const PEOPLE_IMPORT_E_UPDATE_DIRSYNC_COOKIE: i32 = -2147205113i32; pub const PEOPLE_IMPORT_E_USERNAME_NOTRESOLVED: i32 = -2147205109i32; pub const PEOPLE_IMPORT_NODSDEFINED: i32 = -2147205119i32; pub const PEOPLE_IMPORT_NOMAPPINGDEFINED: i32 = -2147205117i32; #[cfg(feature = "Win32_Foundation")] pub type PFNFILLTEXTBUFFER = unsafe extern "system" fn(ptextsource: *mut ::core::mem::ManuallyDrop<TEXT_SOURCE>) -> ::windows::core::HRESULT; pub const PRAll: u32 = 256u32; pub const PRAllBits: u32 = 7u32; pub const PRAny: u32 = 512u32; #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct PRIORITIZE_FLAGS(pub i32); pub const PRIORITIZE_FLAG_RETRYFAILEDITEMS: PRIORITIZE_FLAGS = PRIORITIZE_FLAGS(1i32); pub const PRIORITIZE_FLAG_IGNOREFAILURECOUNT: PRIORITIZE_FLAGS = PRIORITIZE_FLAGS(2i32); impl ::core::convert::From<i32> for PRIORITIZE_FLAGS { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for PRIORITIZE_FLAGS { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct PRIORITY_LEVEL(pub i32); pub const PRIORITY_LEVEL_FOREGROUND: PRIORITY_LEVEL = PRIORITY_LEVEL(0i32); pub const PRIORITY_LEVEL_HIGH: PRIORITY_LEVEL = PRIORITY_LEVEL(1i32); pub const PRIORITY_LEVEL_LOW: PRIORITY_LEVEL = PRIORITY_LEVEL(2i32); pub const PRIORITY_LEVEL_DEFAULT: PRIORITY_LEVEL = PRIORITY_LEVEL(3i32); impl ::core::convert::From<i32> for PRIORITY_LEVEL { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for PRIORITY_LEVEL { type Abi = Self; } pub const PROGID_MSPersist_Version_W: &'static str = "MSPersist.1"; pub const PROGID_MSPersist_W: &'static str = "MSPersist"; #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::clone::Clone for PROPERTYRESTRICTION { fn clone(&self) -> Self { unimplemented!() } } #[repr(C)] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub struct PROPERTYRESTRICTION { pub rel: u32, pub prop: super::super::Storage::IndexServer::FULLPROPSPEC, pub prval: super::Com::StructuredStorage::PROPVARIANT, } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl PROPERTYRESTRICTION {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::default::Default for PROPERTYRESTRICTION { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::cmp::PartialEq for PROPERTYRESTRICTION { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::cmp::Eq for PROPERTYRESTRICTION {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] unsafe impl ::windows::core::Abi for PROPERTYRESTRICTION { type Abi = ::core::mem::ManuallyDrop<Self>; } pub const PROPID_DBBMK_BOOKMARK: u32 = 2u32; pub const PROPID_DBBMK_CHAPTER: u32 = 3u32; pub const PROPID_DBSELF_SELF: u32 = 2u32; #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct PROXY_ACCESS(pub i32); pub const PROXY_ACCESS_PRECONFIG: PROXY_ACCESS = PROXY_ACCESS(0i32); pub const PROXY_ACCESS_DIRECT: PROXY_ACCESS = PROXY_ACCESS(1i32); pub const PROXY_ACCESS_PROXY: PROXY_ACCESS = PROXY_ACCESS(2i32); impl ::core::convert::From<i32> for PROXY_ACCESS { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for PROXY_ACCESS { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(feature = "Win32_Foundation")] pub struct PROXY_INFO { pub dwSize: u32, pub pcwszUserAgent: super::super::Foundation::PWSTR, pub paUseProxy: PROXY_ACCESS, pub fLocalBypass: super::super::Foundation::BOOL, pub dwPortNumber: u32, pub pcwszProxyName: super::super::Foundation::PWSTR, pub pcwszBypassList: super::super::Foundation::PWSTR, } #[cfg(feature = "Win32_Foundation")] impl PROXY_INFO {} #[cfg(feature = "Win32_Foundation")] impl ::core::default::Default for PROXY_INFO { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(feature = "Win32_Foundation")] impl ::core::fmt::Debug for PROXY_INFO { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("PROXY_INFO") .field("dwSize", &self.dwSize) .field("pcwszUserAgent", &self.pcwszUserAgent) .field("paUseProxy", &self.paUseProxy) .field("fLocalBypass", &self.fLocalBypass) .field("dwPortNumber", &self.dwPortNumber) .field("pcwszProxyName", &self.pcwszProxyName) .field("pcwszBypassList", &self.pcwszBypassList) .finish() } } #[cfg(feature = "Win32_Foundation")] impl ::core::cmp::PartialEq for PROXY_INFO { fn eq(&self, other: &Self) -> bool { self.dwSize == other.dwSize && self.pcwszUserAgent == other.pcwszUserAgent && self.paUseProxy == other.paUseProxy && self.fLocalBypass == other.fLocalBypass && self.dwPortNumber == other.dwPortNumber && self.pcwszProxyName == other.pcwszProxyName && self.pcwszBypassList == other.pcwszBypassList } } #[cfg(feature = "Win32_Foundation")] impl ::core::cmp::Eq for PROXY_INFO {} #[cfg(feature = "Win32_Foundation")] unsafe impl ::windows::core::Abi for PROXY_INFO { type Abi = Self; } pub const PRRE: u32 = 6u32; pub const PRSomeBits: u32 = 8u32; pub const PRTH_E_CANT_TRANSFORM_DENIED_ACE: i32 = -2147216881i32; pub const PRTH_E_CANT_TRANSFORM_EXTERNAL_ACL: i32 = -2147216882i32; pub const PRTH_E_DATABASE_OPEN_ERROR: i32 = -2147216875i32; pub const PRTH_E_HTTPS_CERTIFICATE_ERROR: i32 = -2147216861i32; pub const PRTH_E_HTTPS_REQUIRE_CERTIFICATE: i32 = -2147216860i32; pub const PRTH_E_INIT_FAILED: i32 = -2147216872i32; pub const PRTH_E_INTERNAL_ERROR: i32 = -2147216892i32; pub const PRTH_E_LOAD_FAILED: i32 = -2147216873i32; pub const PRTH_E_MIME_EXCLUDED: i32 = -2147216883i32; pub const PRTH_E_NO_PROPERTY: i32 = -2147216877i32; pub const PRTH_E_OPLOCK_BROKEN: i32 = -2147216874i32; pub const PRTH_E_RETRY: i32 = -2147216885i32; pub const PRTH_E_TRUNCATED: i32 = -2147216870i32; pub const PRTH_E_VOLUME_MOUNT_POINT: i32 = -2147216871i32; pub const PRTH_E_WININET: i32 = -2147216886i32; pub const PRTH_S_MAX_DOWNLOAD: i32 = 266764i32; pub const PRTH_S_MAX_GROWTH: i32 = 266761i32; pub const PRTH_S_TRY_IMPERSONATING: i32 = 266789i32; pub const PRTH_S_USE_ROSEBUD: i32 = 266772i32; pub const PWPROP_OSPVALUE: u32 = 2u32; pub const QRY_E_COLUMNNOTSEARCHABLE: i32 = -2147219700i32; pub const QRY_E_COLUMNNOTSORTABLE: i32 = -2147219701i32; pub const QRY_E_ENGINEFAILED: i32 = -2147219693i32; pub const QRY_E_INFIXWILDCARD: i32 = -2147219696i32; pub const QRY_E_INVALIDCATALOG: i32 = -2147219687i32; pub const QRY_E_INVALIDCOLUMN: i32 = -2147219699i32; pub const QRY_E_INVALIDINTERVAL: i32 = -2147219682i32; pub const QRY_E_INVALIDPATH: i32 = -2147219684i32; pub const QRY_E_INVALIDSCOPES: i32 = -2147219688i32; pub const QRY_E_LMNOTINITIALIZED: i32 = -2147219683i32; pub const QRY_E_NOCOLUMNS: i32 = -2147219689i32; pub const QRY_E_NODATASOURCES: i32 = -2147219703i32; pub const QRY_E_NOLOGMANAGER: i32 = -2147219681i32; pub const QRY_E_NULLQUERY: i32 = -2147219691i32; pub const QRY_E_PREFIXWILDCARD: i32 = -2147219697i32; pub const QRY_E_QUERYCORRUPT: i32 = -2147219698i32; pub const QRY_E_QUERYSYNTAX: i32 = -2147219711i32; pub const QRY_E_SCOPECARDINALIDY: i32 = -2147219686i32; pub const QRY_E_SEARCHTOOBIG: i32 = -2147219692i32; pub const QRY_E_STARTHITTOBIG: i32 = -2147219705i32; pub const QRY_E_TIMEOUT: i32 = -2147219702i32; pub const QRY_E_TOOMANYCOLUMNS: i32 = -2147219707i32; pub const QRY_E_TOOMANYDATABASES: i32 = -2147219706i32; pub const QRY_E_TOOMANYQUERYTERMS: i32 = -2147219704i32; pub const QRY_E_TYPEMISMATCH: i32 = -2147219710i32; pub const QRY_E_UNEXPECTED: i32 = -2147219685i32; pub const QRY_E_UNHANDLEDTYPE: i32 = -2147219709i32; pub const QRY_E_WILDCARDPREFIXLENGTH: i32 = -2147219695i32; pub const QRY_S_INEXACTRESULTS: i32 = 263958i32; pub const QRY_S_NOROWSFOUND: i32 = 263940i32; pub const QRY_S_TERMIGNORED: i32 = 263954i32; pub const QUERY_E_AGGREGATE_NOT_SUPPORTED: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147215847i32 as _); pub const QUERY_E_ALLNOISE_AND_NO_RELDOC: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147215859i32 as _); pub const QUERY_E_ALLNOISE_AND_NO_RELPROP: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147215857i32 as _); pub const QUERY_E_DUPLICATE_RANGE_NAME: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147215845i32 as _); pub const QUERY_E_INCORRECT_VERSION: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147215852i32 as _); pub const QUERY_E_INVALIDCOALESCE: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147215849i32 as _); pub const QUERY_E_INVALIDSCOPE_COALESCE: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147215851i32 as _); pub const QUERY_E_INVALIDSORT_COALESCE: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147215850i32 as _); pub const QUERY_E_INVALID_DOCUMENT_IDENTIFIER: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147215853i32 as _); pub const QUERY_E_NO_RELDOC: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147215858i32 as _); pub const QUERY_E_NO_RELPROP: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147215856i32 as _); pub const QUERY_E_RELDOC_SYNTAX_NOT_SUPPORTED: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147215854i32 as _); pub const QUERY_E_REPEATED_RELDOC: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147215855i32 as _); pub const QUERY_E_TOP_LEVEL_IN_GROUP: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147215846i32 as _); pub const QUERY_E_UPGRADEINPROGRESS: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147215848i32 as _); #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct QUERY_PARSER_MANAGER_OPTION(pub i32); pub const QPMO_SCHEMA_BINARY_NAME: QUERY_PARSER_MANAGER_OPTION = QUERY_PARSER_MANAGER_OPTION(0i32); pub const QPMO_PRELOCALIZED_SCHEMA_BINARY_PATH: QUERY_PARSER_MANAGER_OPTION = QUERY_PARSER_MANAGER_OPTION(1i32); pub const QPMO_UNLOCALIZED_SCHEMA_BINARY_PATH: QUERY_PARSER_MANAGER_OPTION = QUERY_PARSER_MANAGER_OPTION(2i32); pub const QPMO_LOCALIZED_SCHEMA_BINARY_PATH: QUERY_PARSER_MANAGER_OPTION = QUERY_PARSER_MANAGER_OPTION(3i32); pub const QPMO_APPEND_LCID_TO_LOCALIZED_PATH: QUERY_PARSER_MANAGER_OPTION = QUERY_PARSER_MANAGER_OPTION(4i32); pub const QPMO_LOCALIZER_SUPPORT: QUERY_PARSER_MANAGER_OPTION = QUERY_PARSER_MANAGER_OPTION(5i32); impl ::core::convert::From<i32> for QUERY_PARSER_MANAGER_OPTION { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for QUERY_PARSER_MANAGER_OPTION { type Abi = Self; } pub const QUERY_SORTDEFAULT: u32 = 4u32; pub const QUERY_SORTXASCEND: u32 = 2u32; pub const QUERY_SORTXDESCEND: u32 = 3u32; pub const QUERY_VALIDBITS: u32 = 3u32; pub const QueryParser: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xb72f8fd8_0fab_4dd9_bdbf_245a6ce1485b); pub const QueryParserManager: ::windows::core::GUID = ::windows::core::GUID::from_u128(0x5088b39a_29b4_4d9d_8245_4ee289222f66); #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub struct RANGECATEGORIZE { pub cRange: u32, pub aRangeBegin: *mut super::Com::StructuredStorage::PROPVARIANT, } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl RANGECATEGORIZE {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::default::Default for RANGECATEGORIZE { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::fmt::Debug for RANGECATEGORIZE { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("RANGECATEGORIZE").field("cRange", &self.cRange).field("aRangeBegin", &self.aRangeBegin).finish() } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::cmp::PartialEq for RANGECATEGORIZE { fn eq(&self, other: &Self) -> bool { self.cRange == other.cRange && self.aRangeBegin == other.aRangeBegin } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::cmp::Eq for RANGECATEGORIZE {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] unsafe impl ::windows::core::Abi for RANGECATEGORIZE { type Abi = Self; } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::clone::Clone for RESTRICTION { fn clone(&self) -> Self { unimplemented!() } } #[repr(C)] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub struct RESTRICTION { pub rt: u32, pub weight: u32, pub res: RESTRICTION_0, } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl RESTRICTION {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::default::Default for RESTRICTION { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::cmp::PartialEq for RESTRICTION { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::cmp::Eq for RESTRICTION {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] unsafe impl ::windows::core::Abi for RESTRICTION { type Abi = ::core::mem::ManuallyDrop<Self>; } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::clone::Clone for RESTRICTION_0 { fn clone(&self) -> Self { unimplemented!() } } #[repr(C)] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub union RESTRICTION_0 { pub ar: NODERESTRICTION, pub orRestriction: NODERESTRICTION, pub pxr: NODERESTRICTION, pub vr: VECTORRESTRICTION, pub nr: NOTRESTRICTION, pub cr: CONTENTRESTRICTION, pub nlr: NATLANGUAGERESTRICTION, pub pr: ::core::mem::ManuallyDrop<PROPERTYRESTRICTION>, } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl RESTRICTION_0 {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::default::Default for RESTRICTION_0 { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::cmp::PartialEq for RESTRICTION_0 { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::cmp::Eq for RESTRICTION_0 {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] unsafe impl ::windows::core::Abi for RESTRICTION_0 { type Abi = ::core::mem::ManuallyDrop<Self>; } pub const REXSPH_E_DUPLICATE_PROPERTY: i32 = -2147207927i32; pub const REXSPH_E_INVALID_CALL: i32 = -2147207936i32; pub const REXSPH_E_MULTIPLE_REDIRECT: i32 = -2147207933i32; pub const REXSPH_E_NO_PROPERTY_ON_ROW: i32 = -2147207932i32; pub const REXSPH_E_REDIRECT_ON_SECURITY_UPDATE: i32 = -2147207934i32; pub const REXSPH_E_TYPE_MISMATCH_ON_READ: i32 = -2147207931i32; pub const REXSPH_E_UNEXPECTED_DATA_STATUS: i32 = -2147207930i32; pub const REXSPH_E_UNEXPECTED_FILTER_STATE: i32 = -2147207928i32; pub const REXSPH_E_UNKNOWN_DATA_TYPE: i32 = -2147207929i32; pub const REXSPH_S_REDIRECTED: i32 = 275713i32; #[derive(:: core :: clone :: Clone)] #[repr(C)] #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_System_Ole"))] pub struct RMTPACK { pub pISeqStream: ::core::option::Option<super::Com::ISequentialStream>, pub cbData: u32, pub cBSTR: u32, pub rgBSTR: *mut super::super::Foundation::BSTR, pub cVARIANT: u32, pub rgVARIANT: *mut super::Com::VARIANT, pub cIDISPATCH: u32, pub rgIDISPATCH: *mut ::core::option::Option<super::Com::IDispatch>, pub cIUNKNOWN: u32, pub rgIUNKNOWN: *mut ::core::option::Option<::windows::core::IUnknown>, pub cPROPVARIANT: u32, pub rgPROPVARIANT: *mut super::Com::StructuredStorage::PROPVARIANT, pub cArray: u32, pub rgArray: *mut super::Com::VARIANT, } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_System_Ole"))] impl RMTPACK {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_System_Ole"))] impl ::core::default::Default for RMTPACK { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_System_Ole"))] impl ::core::fmt::Debug for RMTPACK { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("RMTPACK") .field("pISeqStream", &self.pISeqStream) .field("cbData", &self.cbData) .field("cBSTR", &self.cBSTR) .field("rgBSTR", &self.rgBSTR) .field("cVARIANT", &self.cVARIANT) .field("rgVARIANT", &self.rgVARIANT) .field("cIDISPATCH", &self.cIDISPATCH) .field("rgIDISPATCH", &self.rgIDISPATCH) .field("cIUNKNOWN", &self.cIUNKNOWN) .field("rgIUNKNOWN", &self.rgIUNKNOWN) .field("cPROPVARIANT", &self.cPROPVARIANT) .field("rgPROPVARIANT", &self.rgPROPVARIANT) .field("cArray", &self.cArray) .field("rgArray", &self.rgArray) .finish() } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_System_Ole"))] impl ::core::cmp::PartialEq for RMTPACK { fn eq(&self, other: &Self) -> bool { self.pISeqStream == other.pISeqStream && self.cbData == other.cbData && self.cBSTR == other.cBSTR && self.rgBSTR == other.rgBSTR && self.cVARIANT == other.cVARIANT && self.rgVARIANT == other.rgVARIANT && self.cIDISPATCH == other.cIDISPATCH && self.rgIDISPATCH == other.rgIDISPATCH && self.cIUNKNOWN == other.cIUNKNOWN && self.rgIUNKNOWN == other.rgIUNKNOWN && self.cPROPVARIANT == other.cPROPVARIANT && self.rgPROPVARIANT == other.rgPROPVARIANT && self.cArray == other.cArray && self.rgArray == other.rgArray } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_System_Ole"))] impl ::core::cmp::Eq for RMTPACK {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_System_Ole"))] unsafe impl ::windows::core::Abi for RMTPACK { type Abi = ::core::mem::ManuallyDrop<Self>; } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_System_Ole"))] impl ::core::clone::Clone for RMTPACK { fn clone(&self) -> Self { unimplemented!() } } #[repr(C, packed(2))] #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_System_Ole"))] pub struct RMTPACK { pub pISeqStream: ::core::option::Option<super::Com::ISequentialStream>, pub cbData: u32, pub cBSTR: u32, pub rgBSTR: *mut super::super::Foundation::BSTR, pub cVARIANT: u32, pub rgVARIANT: *mut super::Com::VARIANT, pub cIDISPATCH: u32, pub rgIDISPATCH: *mut ::core::option::Option<super::Com::IDispatch>, pub cIUNKNOWN: u32, pub rgIUNKNOWN: *mut ::core::option::Option<::windows::core::IUnknown>, pub cPROPVARIANT: u32, pub rgPROPVARIANT: *mut super::Com::StructuredStorage::PROPVARIANT, pub cArray: u32, pub rgArray: *mut super::Com::VARIANT, } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_System_Ole"))] impl RMTPACK {} #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_System_Ole"))] impl ::core::default::Default for RMTPACK { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_System_Ole"))] impl ::core::cmp::PartialEq for RMTPACK { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_System_Ole"))] impl ::core::cmp::Eq for RMTPACK {} #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage", feature = "Win32_System_Ole"))] unsafe impl ::windows::core::Abi for RMTPACK { type Abi = ::core::mem::ManuallyDrop<Self>; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct ROWSETEVENT_ITEMSTATE(pub i32); pub const ROWSETEVENT_ITEMSTATE_NOTINROWSET: ROWSETEVENT_ITEMSTATE = ROWSETEVENT_ITEMSTATE(0i32); pub const ROWSETEVENT_ITEMSTATE_INROWSET: ROWSETEVENT_ITEMSTATE = ROWSETEVENT_ITEMSTATE(1i32); pub const ROWSETEVENT_ITEMSTATE_UNKNOWN: ROWSETEVENT_ITEMSTATE = ROWSETEVENT_ITEMSTATE(2i32); impl ::core::convert::From<i32> for ROWSETEVENT_ITEMSTATE { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for ROWSETEVENT_ITEMSTATE { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct ROWSETEVENT_TYPE(pub i32); pub const ROWSETEVENT_TYPE_DATAEXPIRED: ROWSETEVENT_TYPE = ROWSETEVENT_TYPE(0i32); pub const ROWSETEVENT_TYPE_FOREGROUNDLOST: ROWSETEVENT_TYPE = ROWSETEVENT_TYPE(1i32); pub const ROWSETEVENT_TYPE_SCOPESTATISTICS: ROWSETEVENT_TYPE = ROWSETEVENT_TYPE(2i32); impl ::core::convert::From<i32> for ROWSETEVENT_TYPE { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for ROWSETEVENT_TYPE { type Abi = Self; } pub const RS_COMPLETED: u32 = 2147483648u32; pub const RS_MAYBOTHERUSER: u32 = 131072u32; pub const RS_READY: u32 = 1u32; pub const RS_SUSPENDED: u32 = 2u32; pub const RS_SUSPENDONIDLE: u32 = 65536u32; pub const RS_UPDATING: u32 = 4u32; pub const RTAnd: u32 = 1u32; pub const RTContent: u32 = 4u32; pub const RTNatLanguage: u32 = 8u32; pub const RTNone: u32 = 0u32; pub const RTNot: u32 = 3u32; pub const RTOr: u32 = 2u32; pub const RTProperty: u32 = 5u32; pub const RTProximity: u32 = 6u32; pub const RTVector: u32 = 7u32; pub const RootBinder: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xff151822_b0bf_11d1_a80d_000000000000); pub const SCHEMA_E_ADDSTOPWORDS: i32 = -2147218420i32; pub const SCHEMA_E_BADATTRIBUTE: i32 = -2147218412i32; pub const SCHEMA_E_BADCOLUMNNAME: i32 = -2147218414i32; pub const SCHEMA_E_BADFILENAME: i32 = -2147218411i32; pub const SCHEMA_E_BADPROPPID: i32 = -2147218413i32; pub const SCHEMA_E_BADPROPSPEC: i32 = -2147218417i32; pub const SCHEMA_E_CANNOTCREATEFILE: i32 = -2147218426i32; pub const SCHEMA_E_CANNOTCREATENOISEWORDFILE: i32 = -2147218421i32; pub const SCHEMA_E_CANNOTWRITEFILE: i32 = -2147218425i32; pub const SCHEMA_E_DUPLICATENOISE: i32 = -2147218409i32; pub const SCHEMA_E_EMPTYFILE: i32 = -2147218424i32; pub const SCHEMA_E_FILECHANGED: i32 = -2147218415i32; pub const SCHEMA_E_FILENOTFOUND: i32 = -2147218430i32; pub const SCHEMA_E_INVALIDDATATYPE: i32 = -2147218422i32; pub const SCHEMA_E_INVALIDFILETYPE: i32 = -2147218423i32; pub const SCHEMA_E_INVALIDVALUE: i32 = -2147218418i32; pub const SCHEMA_E_LOAD_SPECIAL: i32 = -2147218431i32; pub const SCHEMA_E_NAMEEXISTS: i32 = -2147218419i32; pub const SCHEMA_E_NESTEDTAG: i32 = -2147218429i32; pub const SCHEMA_E_NOMORECOLUMNS: i32 = -2147218416i32; pub const SCHEMA_E_PROPEXISTS: i32 = -2147218410i32; pub const SCHEMA_E_UNEXPECTEDTAG: i32 = -2147218428i32; pub const SCHEMA_E_VERSIONMISMATCH: i32 = -2147218427i32; pub const SCRIPTPI_E_ALREADY_COMPLETED: i32 = -2147213307i32; pub const SCRIPTPI_E_CANNOT_ALTER_CHUNK: i32 = -2147213308i32; pub const SCRIPTPI_E_CHUNK_NOT_TEXT: i32 = -2147213312i32; pub const SCRIPTPI_E_CHUNK_NOT_VALUE: i32 = -2147213309i32; pub const SCRIPTPI_E_PID_NOT_NAME: i32 = -2147213311i32; pub const SCRIPTPI_E_PID_NOT_NUMERIC: i32 = -2147213310i32; #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::clone::Clone for SEARCH_COLUMN_PROPERTIES { fn clone(&self) -> Self { unimplemented!() } } #[repr(C)] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub struct SEARCH_COLUMN_PROPERTIES { pub Value: super::Com::StructuredStorage::PROPVARIANT, pub lcid: u32, } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl SEARCH_COLUMN_PROPERTIES {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::default::Default for SEARCH_COLUMN_PROPERTIES { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::cmp::PartialEq for SEARCH_COLUMN_PROPERTIES { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::cmp::Eq for SEARCH_COLUMN_PROPERTIES {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] unsafe impl ::windows::core::Abi for SEARCH_COLUMN_PROPERTIES { type Abi = ::core::mem::ManuallyDrop<Self>; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct SEARCH_INDEXING_PHASE(pub i32); pub const SEARCH_INDEXING_PHASE_GATHERER: SEARCH_INDEXING_PHASE = SEARCH_INDEXING_PHASE(0i32); pub const SEARCH_INDEXING_PHASE_QUERYABLE: SEARCH_INDEXING_PHASE = SEARCH_INDEXING_PHASE(1i32); pub const SEARCH_INDEXING_PHASE_PERSISTED: SEARCH_INDEXING_PHASE = SEARCH_INDEXING_PHASE(2i32); impl ::core::convert::From<i32> for SEARCH_INDEXING_PHASE { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for SEARCH_INDEXING_PHASE { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub struct SEARCH_ITEM_CHANGE { pub Change: SEARCH_KIND_OF_CHANGE, pub Priority: SEARCH_NOTIFICATION_PRIORITY, pub pUserData: *mut super::Com::BLOB, pub lpwszURL: super::super::Foundation::PWSTR, pub lpwszOldURL: super::super::Foundation::PWSTR, } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl SEARCH_ITEM_CHANGE {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::default::Default for SEARCH_ITEM_CHANGE { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::fmt::Debug for SEARCH_ITEM_CHANGE { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("SEARCH_ITEM_CHANGE").field("Change", &self.Change).field("Priority", &self.Priority).field("pUserData", &self.pUserData).field("lpwszURL", &self.lpwszURL).field("lpwszOldURL", &self.lpwszOldURL).finish() } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::cmp::PartialEq for SEARCH_ITEM_CHANGE { fn eq(&self, other: &Self) -> bool { self.Change == other.Change && self.Priority == other.Priority && self.pUserData == other.pUserData && self.lpwszURL == other.lpwszURL && self.lpwszOldURL == other.lpwszOldURL } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::cmp::Eq for SEARCH_ITEM_CHANGE {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] unsafe impl ::windows::core::Abi for SEARCH_ITEM_CHANGE { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] pub struct SEARCH_ITEM_INDEXING_STATUS { pub dwDocID: u32, pub hrIndexingStatus: ::windows::core::HRESULT, } impl SEARCH_ITEM_INDEXING_STATUS {} impl ::core::default::Default for SEARCH_ITEM_INDEXING_STATUS { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } impl ::core::fmt::Debug for SEARCH_ITEM_INDEXING_STATUS { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("SEARCH_ITEM_INDEXING_STATUS").field("dwDocID", &self.dwDocID).field("hrIndexingStatus", &self.hrIndexingStatus).finish() } } impl ::core::cmp::PartialEq for SEARCH_ITEM_INDEXING_STATUS { fn eq(&self, other: &Self) -> bool { self.dwDocID == other.dwDocID && self.hrIndexingStatus == other.hrIndexingStatus } } impl ::core::cmp::Eq for SEARCH_ITEM_INDEXING_STATUS {} unsafe impl ::windows::core::Abi for SEARCH_ITEM_INDEXING_STATUS { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(feature = "Win32_Foundation")] pub struct SEARCH_ITEM_PERSISTENT_CHANGE { pub Change: SEARCH_KIND_OF_CHANGE, pub URL: super::super::Foundation::PWSTR, pub OldURL: super::super::Foundation::PWSTR, pub Priority: SEARCH_NOTIFICATION_PRIORITY, } #[cfg(feature = "Win32_Foundation")] impl SEARCH_ITEM_PERSISTENT_CHANGE {} #[cfg(feature = "Win32_Foundation")] impl ::core::default::Default for SEARCH_ITEM_PERSISTENT_CHANGE { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(feature = "Win32_Foundation")] impl ::core::fmt::Debug for SEARCH_ITEM_PERSISTENT_CHANGE { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("SEARCH_ITEM_PERSISTENT_CHANGE").field("Change", &self.Change).field("URL", &self.URL).field("OldURL", &self.OldURL).field("Priority", &self.Priority).finish() } } #[cfg(feature = "Win32_Foundation")] impl ::core::cmp::PartialEq for SEARCH_ITEM_PERSISTENT_CHANGE { fn eq(&self, other: &Self) -> bool { self.Change == other.Change && self.URL == other.URL && self.OldURL == other.OldURL && self.Priority == other.Priority } } #[cfg(feature = "Win32_Foundation")] impl ::core::cmp::Eq for SEARCH_ITEM_PERSISTENT_CHANGE {} #[cfg(feature = "Win32_Foundation")] unsafe impl ::windows::core::Abi for SEARCH_ITEM_PERSISTENT_CHANGE { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct SEARCH_KIND_OF_CHANGE(pub i32); pub const SEARCH_CHANGE_ADD: SEARCH_KIND_OF_CHANGE = SEARCH_KIND_OF_CHANGE(0i32); pub const SEARCH_CHANGE_DELETE: SEARCH_KIND_OF_CHANGE = SEARCH_KIND_OF_CHANGE(1i32); pub const SEARCH_CHANGE_MODIFY: SEARCH_KIND_OF_CHANGE = SEARCH_KIND_OF_CHANGE(2i32); pub const SEARCH_CHANGE_MOVE_RENAME: SEARCH_KIND_OF_CHANGE = SEARCH_KIND_OF_CHANGE(3i32); pub const SEARCH_CHANGE_SEMANTICS_DIRECTORY: SEARCH_KIND_OF_CHANGE = SEARCH_KIND_OF_CHANGE(262144i32); pub const SEARCH_CHANGE_SEMANTICS_SHALLOW: SEARCH_KIND_OF_CHANGE = SEARCH_KIND_OF_CHANGE(524288i32); pub const SEARCH_CHANGE_SEMANTICS_UPDATE_SECURITY: SEARCH_KIND_OF_CHANGE = SEARCH_KIND_OF_CHANGE(4194304i32); impl ::core::convert::From<i32> for SEARCH_KIND_OF_CHANGE { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for SEARCH_KIND_OF_CHANGE { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct SEARCH_NOTIFICATION_PRIORITY(pub i32); pub const SEARCH_NORMAL_PRIORITY: SEARCH_NOTIFICATION_PRIORITY = SEARCH_NOTIFICATION_PRIORITY(0i32); pub const SEARCH_HIGH_PRIORITY: SEARCH_NOTIFICATION_PRIORITY = SEARCH_NOTIFICATION_PRIORITY(1i32); impl ::core::convert::From<i32> for SEARCH_NOTIFICATION_PRIORITY { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for SEARCH_NOTIFICATION_PRIORITY { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct SEARCH_QUERY_SYNTAX(pub i32); pub const SEARCH_NO_QUERY_SYNTAX: SEARCH_QUERY_SYNTAX = SEARCH_QUERY_SYNTAX(0i32); pub const SEARCH_ADVANCED_QUERY_SYNTAX: SEARCH_QUERY_SYNTAX = SEARCH_QUERY_SYNTAX(1i32); pub const SEARCH_NATURAL_QUERY_SYNTAX: SEARCH_QUERY_SYNTAX = SEARCH_QUERY_SYNTAX(2i32); impl ::core::convert::From<i32> for SEARCH_QUERY_SYNTAX { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for SEARCH_QUERY_SYNTAX { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct SEARCH_TERM_EXPANSION(pub i32); pub const SEARCH_TERM_NO_EXPANSION: SEARCH_TERM_EXPANSION = SEARCH_TERM_EXPANSION(0i32); pub const SEARCH_TERM_PREFIX_ALL: SEARCH_TERM_EXPANSION = SEARCH_TERM_EXPANSION(1i32); pub const SEARCH_TERM_STEM_ALL: SEARCH_TERM_EXPANSION = SEARCH_TERM_EXPANSION(2i32); impl ::core::convert::From<i32> for SEARCH_TERM_EXPANSION { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for SEARCH_TERM_EXPANSION { type Abi = Self; } pub const SEC_E_ACCESSDENIED: i32 = -2147216129i32; pub const SEC_E_BADTRUSTEEID: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217814i32 as _); pub const SEC_E_INITFAILED: i32 = -2147216383i32; pub const SEC_E_INVALIDACCESSENTRY: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217807i32 as _); pub const SEC_E_INVALIDACCESSENTRYLIST: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217809i32 as _); pub const SEC_E_INVALIDCONTEXT: i32 = -2147216381i32; pub const SEC_E_INVALIDOBJECT: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217811i32 as _); pub const SEC_E_INVALIDOWNER: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217808i32 as _); pub const SEC_E_NOMEMBERSHIPSUPPORT: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217812i32 as _); pub const SEC_E_NOOWNER: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217810i32 as _); pub const SEC_E_NOTINITIALIZED: i32 = -2147216382i32; pub const SEC_E_NOTRUSTEEID: ::windows::core::HRESULT = ::windows::core::HRESULT(-2147217813i32 as _); pub const SEC_E_PERMISSIONDENIED: i32 = -2147217911i32; #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub struct SEC_OBJECT { pub cObjects: u32, pub prgObjects: *mut SEC_OBJECT_ELEMENT, } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] impl SEC_OBJECT {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] impl ::core::default::Default for SEC_OBJECT { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] impl ::core::fmt::Debug for SEC_OBJECT { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("SEC_OBJECT").field("cObjects", &self.cObjects).field("prgObjects", &self.prgObjects).finish() } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] impl ::core::cmp::PartialEq for SEC_OBJECT { fn eq(&self, other: &Self) -> bool { self.cObjects == other.cObjects && self.prgObjects == other.prgObjects } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] impl ::core::cmp::Eq for SEC_OBJECT {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] unsafe impl ::windows::core::Abi for SEC_OBJECT { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C, packed(2))] #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub struct SEC_OBJECT { pub cObjects: u32, pub prgObjects: *mut SEC_OBJECT_ELEMENT, } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] impl SEC_OBJECT {} #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] impl ::core::default::Default for SEC_OBJECT { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] impl ::core::cmp::PartialEq for SEC_OBJECT { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] impl ::core::cmp::Eq for SEC_OBJECT {} #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] unsafe impl ::windows::core::Abi for SEC_OBJECT { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub struct SEC_OBJECT_ELEMENT { pub guidObjectType: ::windows::core::GUID, pub ObjectID: super::super::Storage::IndexServer::DBID, } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] impl SEC_OBJECT_ELEMENT {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] impl ::core::default::Default for SEC_OBJECT_ELEMENT { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] impl ::core::cmp::PartialEq for SEC_OBJECT_ELEMENT { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] impl ::core::cmp::Eq for SEC_OBJECT_ELEMENT {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] unsafe impl ::windows::core::Abi for SEC_OBJECT_ELEMENT { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C, packed(2))] #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] pub struct SEC_OBJECT_ELEMENT { pub guidObjectType: ::windows::core::GUID, pub ObjectID: super::super::Storage::IndexServer::DBID, } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] impl SEC_OBJECT_ELEMENT {} #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] impl ::core::default::Default for SEC_OBJECT_ELEMENT { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] impl ::core::cmp::PartialEq for SEC_OBJECT_ELEMENT { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] impl ::core::cmp::Eq for SEC_OBJECT_ELEMENT {} #[cfg(any(target_arch = "x86",))] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer"))] unsafe impl ::windows::core::Abi for SEC_OBJECT_ELEMENT { type Abi = Self; } pub const SI_TEMPORARY: u32 = 2147483648u32; #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage"))] pub struct SORTKEY { pub propColumn: super::super::Storage::IndexServer::FULLPROPSPEC, pub dwOrder: u32, pub locale: u32, } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage"))] impl SORTKEY {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::default::Default for SORTKEY { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::cmp::PartialEq for SORTKEY { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::cmp::Eq for SORTKEY {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage"))] unsafe impl ::windows::core::Abi for SORTKEY { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage"))] pub struct SORTSET { pub cCol: u32, pub aCol: *mut SORTKEY, } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage"))] impl SORTSET {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::default::Default for SORTSET { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::fmt::Debug for SORTSET { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("SORTSET").field("cCol", &self.cCol).field("aCol", &self.aCol).finish() } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::cmp::PartialEq for SORTSET { fn eq(&self, other: &Self) -> bool { self.cCol == other.cCol && self.aCol == other.aCol } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::cmp::Eq for SORTSET {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com_StructuredStorage"))] unsafe impl ::windows::core::Abi for SORTSET { type Abi = Self; } pub const SPS_WS_ERROR: i32 = -2147211753i32; pub const SQLAOPANY: u32 = 83u32; pub const SQLAOPAVG: u32 = 79u32; pub const SQLAOPCNT: u32 = 75u32; pub const SQLAOPMAX: u32 = 82u32; pub const SQLAOPMIN: u32 = 81u32; pub const SQLAOPNOOP: u32 = 86u32; pub const SQLAOPSTDEV: u32 = 48u32; pub const SQLAOPSTDEVP: u32 = 49u32; pub const SQLAOPSUM: u32 = 77u32; pub const SQLAOPVAR: u32 = 50u32; pub const SQLAOPVARP: u32 = 51u32; #[inline] pub unsafe fn SQLAllocConnect(environmenthandle: *mut ::core::ffi::c_void, connectionhandle: *mut *mut ::core::ffi::c_void) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLAllocConnect(environmenthandle: *mut ::core::ffi::c_void, connectionhandle: *mut *mut ::core::ffi::c_void) -> i16; } ::core::mem::transmute(SQLAllocConnect(::core::mem::transmute(environmenthandle), ::core::mem::transmute(connectionhandle))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLAllocEnv(environmenthandle: *mut *mut ::core::ffi::c_void) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLAllocEnv(environmenthandle: *mut *mut ::core::ffi::c_void) -> i16; } ::core::mem::transmute(SQLAllocEnv(::core::mem::transmute(environmenthandle))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLAllocHandle(handletype: i16, inputhandle: *mut ::core::ffi::c_void, outputhandle: *mut *mut ::core::ffi::c_void) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLAllocHandle(handletype: i16, inputhandle: *mut ::core::ffi::c_void, outputhandle: *mut *mut ::core::ffi::c_void) -> i16; } ::core::mem::transmute(SQLAllocHandle(::core::mem::transmute(handletype), ::core::mem::transmute(inputhandle), ::core::mem::transmute(outputhandle))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLAllocHandleStd(fhandletype: i16, hinput: *mut ::core::ffi::c_void, phoutput: *mut *mut ::core::ffi::c_void) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLAllocHandleStd(fhandletype: i16, hinput: *mut ::core::ffi::c_void, phoutput: *mut *mut ::core::ffi::c_void) -> i16; } ::core::mem::transmute(SQLAllocHandleStd(::core::mem::transmute(fhandletype), ::core::mem::transmute(hinput), ::core::mem::transmute(phoutput))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLAllocStmt(connectionhandle: *mut ::core::ffi::c_void, statementhandle: *mut *mut ::core::ffi::c_void) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLAllocStmt(connectionhandle: *mut ::core::ffi::c_void, statementhandle: *mut *mut ::core::ffi::c_void) -> i16; } ::core::mem::transmute(SQLAllocStmt(::core::mem::transmute(connectionhandle), ::core::mem::transmute(statementhandle))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } pub const SQLBIGBINARY: u32 = 173u32; pub const SQLBIGCHAR: u32 = 175u32; pub const SQLBIGVARBINARY: u32 = 165u32; pub const SQLBIGVARCHAR: u32 = 167u32; pub const SQLBINARY: u32 = 45u32; pub const SQLBIT: u32 = 50u32; pub const SQLBITN: u32 = 104u32; #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[inline] pub unsafe fn SQLBindCol(statementhandle: *mut ::core::ffi::c_void, columnnumber: u16, targettype: i16, targetvalue: *mut ::core::ffi::c_void, bufferlength: i64, strlen_or_ind: *mut i64) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLBindCol(statementhandle: *mut ::core::ffi::c_void, columnnumber: u16, targettype: i16, targetvalue: *mut ::core::ffi::c_void, bufferlength: i64, strlen_or_ind: *mut i64) -> i16; } ::core::mem::transmute(SQLBindCol(::core::mem::transmute(statementhandle), ::core::mem::transmute(columnnumber), ::core::mem::transmute(targettype), ::core::mem::transmute(targetvalue), ::core::mem::transmute(bufferlength), ::core::mem::transmute(strlen_or_ind))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86",))] #[inline] pub unsafe fn SQLBindCol(statementhandle: *mut ::core::ffi::c_void, columnnumber: u16, targettype: i16, targetvalue: *mut ::core::ffi::c_void, bufferlength: i32, strlen_or_ind: *mut i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLBindCol(statementhandle: *mut ::core::ffi::c_void, columnnumber: u16, targettype: i16, targetvalue: *mut ::core::ffi::c_void, bufferlength: i32, strlen_or_ind: *mut i32) -> i16; } ::core::mem::transmute(SQLBindCol(::core::mem::transmute(statementhandle), ::core::mem::transmute(columnnumber), ::core::mem::transmute(targettype), ::core::mem::transmute(targetvalue), ::core::mem::transmute(bufferlength), ::core::mem::transmute(strlen_or_ind))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[inline] pub unsafe fn SQLBindParam(statementhandle: *mut ::core::ffi::c_void, parameternumber: u16, valuetype: i16, parametertype: i16, lengthprecision: u64, parameterscale: i16, parametervalue: *mut ::core::ffi::c_void, strlen_or_ind: *mut i64) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLBindParam(statementhandle: *mut ::core::ffi::c_void, parameternumber: u16, valuetype: i16, parametertype: i16, lengthprecision: u64, parameterscale: i16, parametervalue: *mut ::core::ffi::c_void, strlen_or_ind: *mut i64) -> i16; } ::core::mem::transmute(SQLBindParam( ::core::mem::transmute(statementhandle), ::core::mem::transmute(parameternumber), ::core::mem::transmute(valuetype), ::core::mem::transmute(parametertype), ::core::mem::transmute(lengthprecision), ::core::mem::transmute(parameterscale), ::core::mem::transmute(parametervalue), ::core::mem::transmute(strlen_or_ind), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86",))] #[inline] pub unsafe fn SQLBindParam(statementhandle: *mut ::core::ffi::c_void, parameternumber: u16, valuetype: i16, parametertype: i16, lengthprecision: u32, parameterscale: i16, parametervalue: *mut ::core::ffi::c_void, strlen_or_ind: *mut i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLBindParam(statementhandle: *mut ::core::ffi::c_void, parameternumber: u16, valuetype: i16, parametertype: i16, lengthprecision: u32, parameterscale: i16, parametervalue: *mut ::core::ffi::c_void, strlen_or_ind: *mut i32) -> i16; } ::core::mem::transmute(SQLBindParam( ::core::mem::transmute(statementhandle), ::core::mem::transmute(parameternumber), ::core::mem::transmute(valuetype), ::core::mem::transmute(parametertype), ::core::mem::transmute(lengthprecision), ::core::mem::transmute(parameterscale), ::core::mem::transmute(parametervalue), ::core::mem::transmute(strlen_or_ind), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[inline] pub unsafe fn SQLBindParameter(hstmt: *mut ::core::ffi::c_void, ipar: u16, fparamtype: i16, fctype: i16, fsqltype: i16, cbcoldef: u64, ibscale: i16, rgbvalue: *mut ::core::ffi::c_void, cbvaluemax: i64, pcbvalue: *mut i64) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLBindParameter(hstmt: *mut ::core::ffi::c_void, ipar: u16, fparamtype: i16, fctype: i16, fsqltype: i16, cbcoldef: u64, ibscale: i16, rgbvalue: *mut ::core::ffi::c_void, cbvaluemax: i64, pcbvalue: *mut i64) -> i16; } ::core::mem::transmute(SQLBindParameter( ::core::mem::transmute(hstmt), ::core::mem::transmute(ipar), ::core::mem::transmute(fparamtype), ::core::mem::transmute(fctype), ::core::mem::transmute(fsqltype), ::core::mem::transmute(cbcoldef), ::core::mem::transmute(ibscale), ::core::mem::transmute(rgbvalue), ::core::mem::transmute(cbvaluemax), ::core::mem::transmute(pcbvalue), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86",))] #[inline] pub unsafe fn SQLBindParameter(hstmt: *mut ::core::ffi::c_void, ipar: u16, fparamtype: i16, fctype: i16, fsqltype: i16, cbcoldef: u32, ibscale: i16, rgbvalue: *mut ::core::ffi::c_void, cbvaluemax: i32, pcbvalue: *mut i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLBindParameter(hstmt: *mut ::core::ffi::c_void, ipar: u16, fparamtype: i16, fctype: i16, fsqltype: i16, cbcoldef: u32, ibscale: i16, rgbvalue: *mut ::core::ffi::c_void, cbvaluemax: i32, pcbvalue: *mut i32) -> i16; } ::core::mem::transmute(SQLBindParameter( ::core::mem::transmute(hstmt), ::core::mem::transmute(ipar), ::core::mem::transmute(fparamtype), ::core::mem::transmute(fctype), ::core::mem::transmute(fsqltype), ::core::mem::transmute(cbcoldef), ::core::mem::transmute(ibscale), ::core::mem::transmute(rgbvalue), ::core::mem::transmute(cbvaluemax), ::core::mem::transmute(pcbvalue), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLBrowseConnect(hdbc: *mut ::core::ffi::c_void, szconnstrin: *const u8, cchconnstrin: i16, szconnstrout: *mut u8, cchconnstroutmax: i16, pcchconnstrout: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLBrowseConnect(hdbc: *mut ::core::ffi::c_void, szconnstrin: *const u8, cchconnstrin: i16, szconnstrout: *mut u8, cchconnstroutmax: i16, pcchconnstrout: *mut i16) -> i16; } ::core::mem::transmute(SQLBrowseConnect(::core::mem::transmute(hdbc), ::core::mem::transmute(szconnstrin), ::core::mem::transmute(cchconnstrin), ::core::mem::transmute(szconnstrout), ::core::mem::transmute(cchconnstroutmax), ::core::mem::transmute(pcchconnstrout))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLBrowseConnectA(hdbc: *mut ::core::ffi::c_void, szconnstrin: *const u8, cbconnstrin: i16, szconnstrout: *mut u8, cbconnstroutmax: i16, pcbconnstrout: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLBrowseConnectA(hdbc: *mut ::core::ffi::c_void, szconnstrin: *const u8, cbconnstrin: i16, szconnstrout: *mut u8, cbconnstroutmax: i16, pcbconnstrout: *mut i16) -> i16; } ::core::mem::transmute(SQLBrowseConnectA(::core::mem::transmute(hdbc), ::core::mem::transmute(szconnstrin), ::core::mem::transmute(cbconnstrin), ::core::mem::transmute(szconnstrout), ::core::mem::transmute(cbconnstroutmax), ::core::mem::transmute(pcbconnstrout))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLBrowseConnectW(hdbc: *mut ::core::ffi::c_void, szconnstrin: *const u16, cchconnstrin: i16, szconnstrout: *mut u16, cchconnstroutmax: i16, pcchconnstrout: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLBrowseConnectW(hdbc: *mut ::core::ffi::c_void, szconnstrin: *const u16, cchconnstrin: i16, szconnstrout: *mut u16, cchconnstroutmax: i16, pcchconnstrout: *mut i16) -> i16; } ::core::mem::transmute(SQLBrowseConnectW(::core::mem::transmute(hdbc), ::core::mem::transmute(szconnstrin), ::core::mem::transmute(cchconnstrin), ::core::mem::transmute(szconnstrout), ::core::mem::transmute(cchconnstroutmax), ::core::mem::transmute(pcchconnstrout))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLBulkOperations(statementhandle: *mut ::core::ffi::c_void, operation: i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLBulkOperations(statementhandle: *mut ::core::ffi::c_void, operation: i16) -> i16; } ::core::mem::transmute(SQLBulkOperations(::core::mem::transmute(statementhandle), ::core::mem::transmute(operation))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } pub const SQLCHARACTER: u32 = 47u32; #[inline] pub unsafe fn SQLCancel(statementhandle: *mut ::core::ffi::c_void) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLCancel(statementhandle: *mut ::core::ffi::c_void) -> i16; } ::core::mem::transmute(SQLCancel(::core::mem::transmute(statementhandle))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLCancelHandle(handletype: i16, inputhandle: *mut ::core::ffi::c_void) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLCancelHandle(handletype: i16, inputhandle: *mut ::core::ffi::c_void) -> i16; } ::core::mem::transmute(SQLCancelHandle(::core::mem::transmute(handletype), ::core::mem::transmute(inputhandle))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLCloseCursor(statementhandle: *mut ::core::ffi::c_void) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLCloseCursor(statementhandle: *mut ::core::ffi::c_void) -> i16; } ::core::mem::transmute(SQLCloseCursor(::core::mem::transmute(statementhandle))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(feature = "Win32_Foundation")] #[inline] pub unsafe fn SQLCloseEnumServers<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::HANDLE>>(henumhandle: Param0) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLCloseEnumServers(henumhandle: super::super::Foundation::HANDLE) -> i16; } ::core::mem::transmute(SQLCloseEnumServers(henumhandle.into_param().abi())) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[inline] pub unsafe fn SQLColAttribute(statementhandle: *mut ::core::ffi::c_void, columnnumber: u16, fieldidentifier: u16, characterattribute: *mut ::core::ffi::c_void, bufferlength: i16, stringlength: *mut i16, numericattribute: *mut i64) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLColAttribute(statementhandle: *mut ::core::ffi::c_void, columnnumber: u16, fieldidentifier: u16, characterattribute: *mut ::core::ffi::c_void, bufferlength: i16, stringlength: *mut i16, numericattribute: *mut i64) -> i16; } ::core::mem::transmute(SQLColAttribute(::core::mem::transmute(statementhandle), ::core::mem::transmute(columnnumber), ::core::mem::transmute(fieldidentifier), ::core::mem::transmute(characterattribute), ::core::mem::transmute(bufferlength), ::core::mem::transmute(stringlength), ::core::mem::transmute(numericattribute))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86",))] #[inline] pub unsafe fn SQLColAttribute(statementhandle: *mut ::core::ffi::c_void, columnnumber: u16, fieldidentifier: u16, characterattribute: *mut ::core::ffi::c_void, bufferlength: i16, stringlength: *mut i16, numericattribute: *mut ::core::ffi::c_void) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLColAttribute(statementhandle: *mut ::core::ffi::c_void, columnnumber: u16, fieldidentifier: u16, characterattribute: *mut ::core::ffi::c_void, bufferlength: i16, stringlength: *mut i16, numericattribute: *mut ::core::ffi::c_void) -> i16; } ::core::mem::transmute(SQLColAttribute(::core::mem::transmute(statementhandle), ::core::mem::transmute(columnnumber), ::core::mem::transmute(fieldidentifier), ::core::mem::transmute(characterattribute), ::core::mem::transmute(bufferlength), ::core::mem::transmute(stringlength), ::core::mem::transmute(numericattribute))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[inline] pub unsafe fn SQLColAttributeA(hstmt: *mut ::core::ffi::c_void, icol: i16, ifield: i16, pcharattr: *mut ::core::ffi::c_void, cbcharattrmax: i16, pcbcharattr: *mut i16, pnumattr: *mut i64) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLColAttributeA(hstmt: *mut ::core::ffi::c_void, icol: i16, ifield: i16, pcharattr: *mut ::core::ffi::c_void, cbcharattrmax: i16, pcbcharattr: *mut i16, pnumattr: *mut i64) -> i16; } ::core::mem::transmute(SQLColAttributeA(::core::mem::transmute(hstmt), ::core::mem::transmute(icol), ::core::mem::transmute(ifield), ::core::mem::transmute(pcharattr), ::core::mem::transmute(cbcharattrmax), ::core::mem::transmute(pcbcharattr), ::core::mem::transmute(pnumattr))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86",))] #[inline] pub unsafe fn SQLColAttributeA(hstmt: *mut ::core::ffi::c_void, icol: i16, ifield: i16, pcharattr: *mut ::core::ffi::c_void, cbcharattrmax: i16, pcbcharattr: *mut i16, pnumattr: *mut ::core::ffi::c_void) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLColAttributeA(hstmt: *mut ::core::ffi::c_void, icol: i16, ifield: i16, pcharattr: *mut ::core::ffi::c_void, cbcharattrmax: i16, pcbcharattr: *mut i16, pnumattr: *mut ::core::ffi::c_void) -> i16; } ::core::mem::transmute(SQLColAttributeA(::core::mem::transmute(hstmt), ::core::mem::transmute(icol), ::core::mem::transmute(ifield), ::core::mem::transmute(pcharattr), ::core::mem::transmute(cbcharattrmax), ::core::mem::transmute(pcbcharattr), ::core::mem::transmute(pnumattr))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[inline] pub unsafe fn SQLColAttributeW(hstmt: *mut ::core::ffi::c_void, icol: u16, ifield: u16, pcharattr: *mut ::core::ffi::c_void, cbdescmax: i16, pcbcharattr: *mut i16, pnumattr: *mut i64) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLColAttributeW(hstmt: *mut ::core::ffi::c_void, icol: u16, ifield: u16, pcharattr: *mut ::core::ffi::c_void, cbdescmax: i16, pcbcharattr: *mut i16, pnumattr: *mut i64) -> i16; } ::core::mem::transmute(SQLColAttributeW(::core::mem::transmute(hstmt), ::core::mem::transmute(icol), ::core::mem::transmute(ifield), ::core::mem::transmute(pcharattr), ::core::mem::transmute(cbdescmax), ::core::mem::transmute(pcbcharattr), ::core::mem::transmute(pnumattr))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86",))] #[inline] pub unsafe fn SQLColAttributeW(hstmt: *mut ::core::ffi::c_void, icol: u16, ifield: u16, pcharattr: *mut ::core::ffi::c_void, cbdescmax: i16, pcbcharattr: *mut i16, pnumattr: *mut ::core::ffi::c_void) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLColAttributeW(hstmt: *mut ::core::ffi::c_void, icol: u16, ifield: u16, pcharattr: *mut ::core::ffi::c_void, cbdescmax: i16, pcbcharattr: *mut i16, pnumattr: *mut ::core::ffi::c_void) -> i16; } ::core::mem::transmute(SQLColAttributeW(::core::mem::transmute(hstmt), ::core::mem::transmute(icol), ::core::mem::transmute(ifield), ::core::mem::transmute(pcharattr), ::core::mem::transmute(cbdescmax), ::core::mem::transmute(pcbcharattr), ::core::mem::transmute(pnumattr))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[inline] pub unsafe fn SQLColAttributes(hstmt: *mut ::core::ffi::c_void, icol: u16, fdesctype: u16, rgbdesc: *mut ::core::ffi::c_void, cbdescmax: i16, pcbdesc: *mut i16, pfdesc: *mut i64) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLColAttributes(hstmt: *mut ::core::ffi::c_void, icol: u16, fdesctype: u16, rgbdesc: *mut ::core::ffi::c_void, cbdescmax: i16, pcbdesc: *mut i16, pfdesc: *mut i64) -> i16; } ::core::mem::transmute(SQLColAttributes(::core::mem::transmute(hstmt), ::core::mem::transmute(icol), ::core::mem::transmute(fdesctype), ::core::mem::transmute(rgbdesc), ::core::mem::transmute(cbdescmax), ::core::mem::transmute(pcbdesc), ::core::mem::transmute(pfdesc))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86",))] #[inline] pub unsafe fn SQLColAttributes(hstmt: *mut ::core::ffi::c_void, icol: u16, fdesctype: u16, rgbdesc: *mut ::core::ffi::c_void, cbdescmax: i16, pcbdesc: *mut i16, pfdesc: *mut i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLColAttributes(hstmt: *mut ::core::ffi::c_void, icol: u16, fdesctype: u16, rgbdesc: *mut ::core::ffi::c_void, cbdescmax: i16, pcbdesc: *mut i16, pfdesc: *mut i32) -> i16; } ::core::mem::transmute(SQLColAttributes(::core::mem::transmute(hstmt), ::core::mem::transmute(icol), ::core::mem::transmute(fdesctype), ::core::mem::transmute(rgbdesc), ::core::mem::transmute(cbdescmax), ::core::mem::transmute(pcbdesc), ::core::mem::transmute(pfdesc))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[inline] pub unsafe fn SQLColAttributesA(hstmt: *mut ::core::ffi::c_void, icol: u16, fdesctype: u16, rgbdesc: *mut ::core::ffi::c_void, cbdescmax: i16, pcbdesc: *mut i16, pfdesc: *mut i64) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLColAttributesA(hstmt: *mut ::core::ffi::c_void, icol: u16, fdesctype: u16, rgbdesc: *mut ::core::ffi::c_void, cbdescmax: i16, pcbdesc: *mut i16, pfdesc: *mut i64) -> i16; } ::core::mem::transmute(SQLColAttributesA(::core::mem::transmute(hstmt), ::core::mem::transmute(icol), ::core::mem::transmute(fdesctype), ::core::mem::transmute(rgbdesc), ::core::mem::transmute(cbdescmax), ::core::mem::transmute(pcbdesc), ::core::mem::transmute(pfdesc))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86",))] #[inline] pub unsafe fn SQLColAttributesA(hstmt: *mut ::core::ffi::c_void, icol: u16, fdesctype: u16, rgbdesc: *mut ::core::ffi::c_void, cbdescmax: i16, pcbdesc: *mut i16, pfdesc: *mut i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLColAttributesA(hstmt: *mut ::core::ffi::c_void, icol: u16, fdesctype: u16, rgbdesc: *mut ::core::ffi::c_void, cbdescmax: i16, pcbdesc: *mut i16, pfdesc: *mut i32) -> i16; } ::core::mem::transmute(SQLColAttributesA(::core::mem::transmute(hstmt), ::core::mem::transmute(icol), ::core::mem::transmute(fdesctype), ::core::mem::transmute(rgbdesc), ::core::mem::transmute(cbdescmax), ::core::mem::transmute(pcbdesc), ::core::mem::transmute(pfdesc))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[inline] pub unsafe fn SQLColAttributesW(hstmt: *mut ::core::ffi::c_void, icol: u16, fdesctype: u16, rgbdesc: *mut ::core::ffi::c_void, cbdescmax: i16, pcbdesc: *mut i16, pfdesc: *mut i64) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLColAttributesW(hstmt: *mut ::core::ffi::c_void, icol: u16, fdesctype: u16, rgbdesc: *mut ::core::ffi::c_void, cbdescmax: i16, pcbdesc: *mut i16, pfdesc: *mut i64) -> i16; } ::core::mem::transmute(SQLColAttributesW(::core::mem::transmute(hstmt), ::core::mem::transmute(icol), ::core::mem::transmute(fdesctype), ::core::mem::transmute(rgbdesc), ::core::mem::transmute(cbdescmax), ::core::mem::transmute(pcbdesc), ::core::mem::transmute(pfdesc))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86",))] #[inline] pub unsafe fn SQLColAttributesW(hstmt: *mut ::core::ffi::c_void, icol: u16, fdesctype: u16, rgbdesc: *mut ::core::ffi::c_void, cbdescmax: i16, pcbdesc: *mut i16, pfdesc: *mut i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLColAttributesW(hstmt: *mut ::core::ffi::c_void, icol: u16, fdesctype: u16, rgbdesc: *mut ::core::ffi::c_void, cbdescmax: i16, pcbdesc: *mut i16, pfdesc: *mut i32) -> i16; } ::core::mem::transmute(SQLColAttributesW(::core::mem::transmute(hstmt), ::core::mem::transmute(icol), ::core::mem::transmute(fdesctype), ::core::mem::transmute(rgbdesc), ::core::mem::transmute(cbdescmax), ::core::mem::transmute(pcbdesc), ::core::mem::transmute(pfdesc))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLColumnPrivileges(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u8, cchcatalogname: i16, szschemaname: *const u8, cchschemaname: i16, sztablename: *const u8, cchtablename: i16, szcolumnname: *const u8, cchcolumnname: i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLColumnPrivileges(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u8, cchcatalogname: i16, szschemaname: *const u8, cchschemaname: i16, sztablename: *const u8, cchtablename: i16, szcolumnname: *const u8, cchcolumnname: i16) -> i16; } ::core::mem::transmute(SQLColumnPrivileges( ::core::mem::transmute(hstmt), ::core::mem::transmute(szcatalogname), ::core::mem::transmute(cchcatalogname), ::core::mem::transmute(szschemaname), ::core::mem::transmute(cchschemaname), ::core::mem::transmute(sztablename), ::core::mem::transmute(cchtablename), ::core::mem::transmute(szcolumnname), ::core::mem::transmute(cchcolumnname), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLColumnPrivilegesA(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u8, cbcatalogname: i16, szschemaname: *const u8, cbschemaname: i16, sztablename: *const u8, cbtablename: i16, szcolumnname: *const u8, cbcolumnname: i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLColumnPrivilegesA(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u8, cbcatalogname: i16, szschemaname: *const u8, cbschemaname: i16, sztablename: *const u8, cbtablename: i16, szcolumnname: *const u8, cbcolumnname: i16) -> i16; } ::core::mem::transmute(SQLColumnPrivilegesA( ::core::mem::transmute(hstmt), ::core::mem::transmute(szcatalogname), ::core::mem::transmute(cbcatalogname), ::core::mem::transmute(szschemaname), ::core::mem::transmute(cbschemaname), ::core::mem::transmute(sztablename), ::core::mem::transmute(cbtablename), ::core::mem::transmute(szcolumnname), ::core::mem::transmute(cbcolumnname), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLColumnPrivilegesW(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u16, cchcatalogname: i16, szschemaname: *const u16, cchschemaname: i16, sztablename: *const u16, cchtablename: i16, szcolumnname: *const u16, cchcolumnname: i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLColumnPrivilegesW(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u16, cchcatalogname: i16, szschemaname: *const u16, cchschemaname: i16, sztablename: *const u16, cchtablename: i16, szcolumnname: *const u16, cchcolumnname: i16) -> i16; } ::core::mem::transmute(SQLColumnPrivilegesW( ::core::mem::transmute(hstmt), ::core::mem::transmute(szcatalogname), ::core::mem::transmute(cchcatalogname), ::core::mem::transmute(szschemaname), ::core::mem::transmute(cchschemaname), ::core::mem::transmute(sztablename), ::core::mem::transmute(cchtablename), ::core::mem::transmute(szcolumnname), ::core::mem::transmute(cchcolumnname), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLColumns(statementhandle: *mut ::core::ffi::c_void, catalogname: *const u8, namelength1: i16, schemaname: *const u8, namelength2: i16, tablename: *const u8, namelength3: i16, columnname: *const u8, namelength4: i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLColumns(statementhandle: *mut ::core::ffi::c_void, catalogname: *const u8, namelength1: i16, schemaname: *const u8, namelength2: i16, tablename: *const u8, namelength3: i16, columnname: *const u8, namelength4: i16) -> i16; } ::core::mem::transmute(SQLColumns( ::core::mem::transmute(statementhandle), ::core::mem::transmute(catalogname), ::core::mem::transmute(namelength1), ::core::mem::transmute(schemaname), ::core::mem::transmute(namelength2), ::core::mem::transmute(tablename), ::core::mem::transmute(namelength3), ::core::mem::transmute(columnname), ::core::mem::transmute(namelength4), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLColumnsA(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u8, cbcatalogname: i16, szschemaname: *const u8, cbschemaname: i16, sztablename: *const u8, cbtablename: i16, szcolumnname: *const u8, cbcolumnname: i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLColumnsA(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u8, cbcatalogname: i16, szschemaname: *const u8, cbschemaname: i16, sztablename: *const u8, cbtablename: i16, szcolumnname: *const u8, cbcolumnname: i16) -> i16; } ::core::mem::transmute(SQLColumnsA( ::core::mem::transmute(hstmt), ::core::mem::transmute(szcatalogname), ::core::mem::transmute(cbcatalogname), ::core::mem::transmute(szschemaname), ::core::mem::transmute(cbschemaname), ::core::mem::transmute(sztablename), ::core::mem::transmute(cbtablename), ::core::mem::transmute(szcolumnname), ::core::mem::transmute(cbcolumnname), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLColumnsW(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u16, cchcatalogname: i16, szschemaname: *const u16, cchschemaname: i16, sztablename: *const u16, cchtablename: i16, szcolumnname: *const u16, cchcolumnname: i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLColumnsW(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u16, cchcatalogname: i16, szschemaname: *const u16, cchschemaname: i16, sztablename: *const u16, cchtablename: i16, szcolumnname: *const u16, cchcolumnname: i16) -> i16; } ::core::mem::transmute(SQLColumnsW( ::core::mem::transmute(hstmt), ::core::mem::transmute(szcatalogname), ::core::mem::transmute(cchcatalogname), ::core::mem::transmute(szschemaname), ::core::mem::transmute(cchschemaname), ::core::mem::transmute(sztablename), ::core::mem::transmute(cchtablename), ::core::mem::transmute(szcolumnname), ::core::mem::transmute(cchcolumnname), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLCompleteAsync(handletype: i16, handle: *mut ::core::ffi::c_void, asyncretcodeptr: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLCompleteAsync(handletype: i16, handle: *mut ::core::ffi::c_void, asyncretcodeptr: *mut i16) -> i16; } ::core::mem::transmute(SQLCompleteAsync(::core::mem::transmute(handletype), ::core::mem::transmute(handle), ::core::mem::transmute(asyncretcodeptr))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLConnect(connectionhandle: *mut ::core::ffi::c_void, servername: *const u8, namelength1: i16, username: *const u8, namelength2: i16, authentication: *const u8, namelength3: i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLConnect(connectionhandle: *mut ::core::ffi::c_void, servername: *const u8, namelength1: i16, username: *const u8, namelength2: i16, authentication: *const u8, namelength3: i16) -> i16; } ::core::mem::transmute(SQLConnect(::core::mem::transmute(connectionhandle), ::core::mem::transmute(servername), ::core::mem::transmute(namelength1), ::core::mem::transmute(username), ::core::mem::transmute(namelength2), ::core::mem::transmute(authentication), ::core::mem::transmute(namelength3))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLConnectA(hdbc: *mut ::core::ffi::c_void, szdsn: *const u8, cbdsn: i16, szuid: *const u8, cbuid: i16, szauthstr: *const u8, cbauthstr: i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLConnectA(hdbc: *mut ::core::ffi::c_void, szdsn: *const u8, cbdsn: i16, szuid: *const u8, cbuid: i16, szauthstr: *const u8, cbauthstr: i16) -> i16; } ::core::mem::transmute(SQLConnectA(::core::mem::transmute(hdbc), ::core::mem::transmute(szdsn), ::core::mem::transmute(cbdsn), ::core::mem::transmute(szuid), ::core::mem::transmute(cbuid), ::core::mem::transmute(szauthstr), ::core::mem::transmute(cbauthstr))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLConnectW(hdbc: *mut ::core::ffi::c_void, szdsn: *const u16, cchdsn: i16, szuid: *const u16, cchuid: i16, szauthstr: *const u16, cchauthstr: i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLConnectW(hdbc: *mut ::core::ffi::c_void, szdsn: *const u16, cchdsn: i16, szuid: *const u16, cchuid: i16, szauthstr: *const u16, cchauthstr: i16) -> i16; } ::core::mem::transmute(SQLConnectW(::core::mem::transmute(hdbc), ::core::mem::transmute(szdsn), ::core::mem::transmute(cchdsn), ::core::mem::transmute(szuid), ::core::mem::transmute(cchuid), ::core::mem::transmute(szauthstr), ::core::mem::transmute(cchauthstr))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLCopyDesc(sourcedeschandle: *mut ::core::ffi::c_void, targetdeschandle: *mut ::core::ffi::c_void) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLCopyDesc(sourcedeschandle: *mut ::core::ffi::c_void, targetdeschandle: *mut ::core::ffi::c_void) -> i16; } ::core::mem::transmute(SQLCopyDesc(::core::mem::transmute(sourcedeschandle), ::core::mem::transmute(targetdeschandle))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } pub const SQLDATETIM4: u32 = 58u32; pub const SQLDATETIME: u32 = 61u32; pub const SQLDATETIMN: u32 = 111u32; pub const SQLDECIMAL: u32 = 106u32; pub const SQLDECIMALN: u32 = 106u32; #[inline] pub unsafe fn SQLDataSources(environmenthandle: *mut ::core::ffi::c_void, direction: u16, servername: *mut u8, bufferlength1: i16, namelength1ptr: *mut i16, description: *mut u8, bufferlength2: i16, namelength2ptr: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLDataSources(environmenthandle: *mut ::core::ffi::c_void, direction: u16, servername: *mut u8, bufferlength1: i16, namelength1ptr: *mut i16, description: *mut u8, bufferlength2: i16, namelength2ptr: *mut i16) -> i16; } ::core::mem::transmute(SQLDataSources( ::core::mem::transmute(environmenthandle), ::core::mem::transmute(direction), ::core::mem::transmute(servername), ::core::mem::transmute(bufferlength1), ::core::mem::transmute(namelength1ptr), ::core::mem::transmute(description), ::core::mem::transmute(bufferlength2), ::core::mem::transmute(namelength2ptr), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLDataSourcesA(henv: *mut ::core::ffi::c_void, fdirection: u16, szdsn: *mut u8, cbdsnmax: i16, pcbdsn: *mut i16, szdescription: *mut u8, cbdescriptionmax: i16, pcbdescription: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLDataSourcesA(henv: *mut ::core::ffi::c_void, fdirection: u16, szdsn: *mut u8, cbdsnmax: i16, pcbdsn: *mut i16, szdescription: *mut u8, cbdescriptionmax: i16, pcbdescription: *mut i16) -> i16; } ::core::mem::transmute(SQLDataSourcesA(::core::mem::transmute(henv), ::core::mem::transmute(fdirection), ::core::mem::transmute(szdsn), ::core::mem::transmute(cbdsnmax), ::core::mem::transmute(pcbdsn), ::core::mem::transmute(szdescription), ::core::mem::transmute(cbdescriptionmax), ::core::mem::transmute(pcbdescription))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLDataSourcesW(henv: *mut ::core::ffi::c_void, fdirection: u16, szdsn: *mut u16, cchdsnmax: i16, pcchdsn: *mut i16, wszdescription: *mut u16, cchdescriptionmax: i16, pcchdescription: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLDataSourcesW(henv: *mut ::core::ffi::c_void, fdirection: u16, szdsn: *mut u16, cchdsnmax: i16, pcchdsn: *mut i16, wszdescription: *mut u16, cchdescriptionmax: i16, pcchdescription: *mut i16) -> i16; } ::core::mem::transmute(SQLDataSourcesW( ::core::mem::transmute(henv), ::core::mem::transmute(fdirection), ::core::mem::transmute(szdsn), ::core::mem::transmute(cchdsnmax), ::core::mem::transmute(pcchdsn), ::core::mem::transmute(wszdescription), ::core::mem::transmute(cchdescriptionmax), ::core::mem::transmute(pcchdescription), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[inline] pub unsafe fn SQLDescribeCol(statementhandle: *mut ::core::ffi::c_void, columnnumber: u16, columnname: *mut u8, bufferlength: i16, namelength: *mut i16, datatype: *mut i16, columnsize: *mut u64, decimaldigits: *mut i16, nullable: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLDescribeCol(statementhandle: *mut ::core::ffi::c_void, columnnumber: u16, columnname: *mut u8, bufferlength: i16, namelength: *mut i16, datatype: *mut i16, columnsize: *mut u64, decimaldigits: *mut i16, nullable: *mut i16) -> i16; } ::core::mem::transmute(SQLDescribeCol( ::core::mem::transmute(statementhandle), ::core::mem::transmute(columnnumber), ::core::mem::transmute(columnname), ::core::mem::transmute(bufferlength), ::core::mem::transmute(namelength), ::core::mem::transmute(datatype), ::core::mem::transmute(columnsize), ::core::mem::transmute(decimaldigits), ::core::mem::transmute(nullable), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86",))] #[inline] pub unsafe fn SQLDescribeCol(statementhandle: *mut ::core::ffi::c_void, columnnumber: u16, columnname: *mut u8, bufferlength: i16, namelength: *mut i16, datatype: *mut i16, columnsize: *mut u32, decimaldigits: *mut i16, nullable: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLDescribeCol(statementhandle: *mut ::core::ffi::c_void, columnnumber: u16, columnname: *mut u8, bufferlength: i16, namelength: *mut i16, datatype: *mut i16, columnsize: *mut u32, decimaldigits: *mut i16, nullable: *mut i16) -> i16; } ::core::mem::transmute(SQLDescribeCol( ::core::mem::transmute(statementhandle), ::core::mem::transmute(columnnumber), ::core::mem::transmute(columnname), ::core::mem::transmute(bufferlength), ::core::mem::transmute(namelength), ::core::mem::transmute(datatype), ::core::mem::transmute(columnsize), ::core::mem::transmute(decimaldigits), ::core::mem::transmute(nullable), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[inline] pub unsafe fn SQLDescribeColA(hstmt: *mut ::core::ffi::c_void, icol: u16, szcolname: *mut u8, cbcolnamemax: i16, pcbcolname: *mut i16, pfsqltype: *mut i16, pcbcoldef: *mut u64, pibscale: *mut i16, pfnullable: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLDescribeColA(hstmt: *mut ::core::ffi::c_void, icol: u16, szcolname: *mut u8, cbcolnamemax: i16, pcbcolname: *mut i16, pfsqltype: *mut i16, pcbcoldef: *mut u64, pibscale: *mut i16, pfnullable: *mut i16) -> i16; } ::core::mem::transmute(SQLDescribeColA( ::core::mem::transmute(hstmt), ::core::mem::transmute(icol), ::core::mem::transmute(szcolname), ::core::mem::transmute(cbcolnamemax), ::core::mem::transmute(pcbcolname), ::core::mem::transmute(pfsqltype), ::core::mem::transmute(pcbcoldef), ::core::mem::transmute(pibscale), ::core::mem::transmute(pfnullable), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86",))] #[inline] pub unsafe fn SQLDescribeColA(hstmt: *mut ::core::ffi::c_void, icol: u16, szcolname: *mut u8, cbcolnamemax: i16, pcbcolname: *mut i16, pfsqltype: *mut i16, pcbcoldef: *mut u32, pibscale: *mut i16, pfnullable: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLDescribeColA(hstmt: *mut ::core::ffi::c_void, icol: u16, szcolname: *mut u8, cbcolnamemax: i16, pcbcolname: *mut i16, pfsqltype: *mut i16, pcbcoldef: *mut u32, pibscale: *mut i16, pfnullable: *mut i16) -> i16; } ::core::mem::transmute(SQLDescribeColA( ::core::mem::transmute(hstmt), ::core::mem::transmute(icol), ::core::mem::transmute(szcolname), ::core::mem::transmute(cbcolnamemax), ::core::mem::transmute(pcbcolname), ::core::mem::transmute(pfsqltype), ::core::mem::transmute(pcbcoldef), ::core::mem::transmute(pibscale), ::core::mem::transmute(pfnullable), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[inline] pub unsafe fn SQLDescribeColW(hstmt: *mut ::core::ffi::c_void, icol: u16, szcolname: *mut u16, cchcolnamemax: i16, pcchcolname: *mut i16, pfsqltype: *mut i16, pcbcoldef: *mut u64, pibscale: *mut i16, pfnullable: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLDescribeColW(hstmt: *mut ::core::ffi::c_void, icol: u16, szcolname: *mut u16, cchcolnamemax: i16, pcchcolname: *mut i16, pfsqltype: *mut i16, pcbcoldef: *mut u64, pibscale: *mut i16, pfnullable: *mut i16) -> i16; } ::core::mem::transmute(SQLDescribeColW( ::core::mem::transmute(hstmt), ::core::mem::transmute(icol), ::core::mem::transmute(szcolname), ::core::mem::transmute(cchcolnamemax), ::core::mem::transmute(pcchcolname), ::core::mem::transmute(pfsqltype), ::core::mem::transmute(pcbcoldef), ::core::mem::transmute(pibscale), ::core::mem::transmute(pfnullable), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86",))] #[inline] pub unsafe fn SQLDescribeColW(hstmt: *mut ::core::ffi::c_void, icol: u16, szcolname: *mut u16, cchcolnamemax: i16, pcchcolname: *mut i16, pfsqltype: *mut i16, pcbcoldef: *mut u32, pibscale: *mut i16, pfnullable: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLDescribeColW(hstmt: *mut ::core::ffi::c_void, icol: u16, szcolname: *mut u16, cchcolnamemax: i16, pcchcolname: *mut i16, pfsqltype: *mut i16, pcbcoldef: *mut u32, pibscale: *mut i16, pfnullable: *mut i16) -> i16; } ::core::mem::transmute(SQLDescribeColW( ::core::mem::transmute(hstmt), ::core::mem::transmute(icol), ::core::mem::transmute(szcolname), ::core::mem::transmute(cchcolnamemax), ::core::mem::transmute(pcchcolname), ::core::mem::transmute(pfsqltype), ::core::mem::transmute(pcbcoldef), ::core::mem::transmute(pibscale), ::core::mem::transmute(pfnullable), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[inline] pub unsafe fn SQLDescribeParam(hstmt: *mut ::core::ffi::c_void, ipar: u16, pfsqltype: *mut i16, pcbparamdef: *mut u64, pibscale: *mut i16, pfnullable: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLDescribeParam(hstmt: *mut ::core::ffi::c_void, ipar: u16, pfsqltype: *mut i16, pcbparamdef: *mut u64, pibscale: *mut i16, pfnullable: *mut i16) -> i16; } ::core::mem::transmute(SQLDescribeParam(::core::mem::transmute(hstmt), ::core::mem::transmute(ipar), ::core::mem::transmute(pfsqltype), ::core::mem::transmute(pcbparamdef), ::core::mem::transmute(pibscale), ::core::mem::transmute(pfnullable))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86",))] #[inline] pub unsafe fn SQLDescribeParam(hstmt: *mut ::core::ffi::c_void, ipar: u16, pfsqltype: *mut i16, pcbparamdef: *mut u32, pibscale: *mut i16, pfnullable: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLDescribeParam(hstmt: *mut ::core::ffi::c_void, ipar: u16, pfsqltype: *mut i16, pcbparamdef: *mut u32, pibscale: *mut i16, pfnullable: *mut i16) -> i16; } ::core::mem::transmute(SQLDescribeParam(::core::mem::transmute(hstmt), ::core::mem::transmute(ipar), ::core::mem::transmute(pfsqltype), ::core::mem::transmute(pcbparamdef), ::core::mem::transmute(pibscale), ::core::mem::transmute(pfnullable))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLDisconnect(connectionhandle: *mut ::core::ffi::c_void) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLDisconnect(connectionhandle: *mut ::core::ffi::c_void) -> i16; } ::core::mem::transmute(SQLDisconnect(::core::mem::transmute(connectionhandle))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLDriverConnect(hdbc: *mut ::core::ffi::c_void, hwnd: isize, szconnstrin: *const u8, cchconnstrin: i16, szconnstrout: *mut u8, cchconnstroutmax: i16, pcchconnstrout: *mut i16, fdrivercompletion: u16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLDriverConnect(hdbc: *mut ::core::ffi::c_void, hwnd: isize, szconnstrin: *const u8, cchconnstrin: i16, szconnstrout: *mut u8, cchconnstroutmax: i16, pcchconnstrout: *mut i16, fdrivercompletion: u16) -> i16; } ::core::mem::transmute(SQLDriverConnect( ::core::mem::transmute(hdbc), ::core::mem::transmute(hwnd), ::core::mem::transmute(szconnstrin), ::core::mem::transmute(cchconnstrin), ::core::mem::transmute(szconnstrout), ::core::mem::transmute(cchconnstroutmax), ::core::mem::transmute(pcchconnstrout), ::core::mem::transmute(fdrivercompletion), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLDriverConnectA(hdbc: *mut ::core::ffi::c_void, hwnd: isize, szconnstrin: *const u8, cbconnstrin: i16, szconnstrout: *mut u8, cbconnstroutmax: i16, pcbconnstrout: *mut i16, fdrivercompletion: u16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLDriverConnectA(hdbc: *mut ::core::ffi::c_void, hwnd: isize, szconnstrin: *const u8, cbconnstrin: i16, szconnstrout: *mut u8, cbconnstroutmax: i16, pcbconnstrout: *mut i16, fdrivercompletion: u16) -> i16; } ::core::mem::transmute(SQLDriverConnectA( ::core::mem::transmute(hdbc), ::core::mem::transmute(hwnd), ::core::mem::transmute(szconnstrin), ::core::mem::transmute(cbconnstrin), ::core::mem::transmute(szconnstrout), ::core::mem::transmute(cbconnstroutmax), ::core::mem::transmute(pcbconnstrout), ::core::mem::transmute(fdrivercompletion), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLDriverConnectW(hdbc: *mut ::core::ffi::c_void, hwnd: isize, szconnstrin: *const u16, cchconnstrin: i16, szconnstrout: *mut u16, cchconnstroutmax: i16, pcchconnstrout: *mut i16, fdrivercompletion: u16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLDriverConnectW(hdbc: *mut ::core::ffi::c_void, hwnd: isize, szconnstrin: *const u16, cchconnstrin: i16, szconnstrout: *mut u16, cchconnstroutmax: i16, pcchconnstrout: *mut i16, fdrivercompletion: u16) -> i16; } ::core::mem::transmute(SQLDriverConnectW( ::core::mem::transmute(hdbc), ::core::mem::transmute(hwnd), ::core::mem::transmute(szconnstrin), ::core::mem::transmute(cchconnstrin), ::core::mem::transmute(szconnstrout), ::core::mem::transmute(cchconnstroutmax), ::core::mem::transmute(pcchconnstrout), ::core::mem::transmute(fdrivercompletion), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLDrivers(henv: *mut ::core::ffi::c_void, fdirection: u16, szdriverdesc: *mut u8, cchdriverdescmax: i16, pcchdriverdesc: *mut i16, szdriverattributes: *mut u8, cchdrvrattrmax: i16, pcchdrvrattr: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLDrivers(henv: *mut ::core::ffi::c_void, fdirection: u16, szdriverdesc: *mut u8, cchdriverdescmax: i16, pcchdriverdesc: *mut i16, szdriverattributes: *mut u8, cchdrvrattrmax: i16, pcchdrvrattr: *mut i16) -> i16; } ::core::mem::transmute(SQLDrivers( ::core::mem::transmute(henv), ::core::mem::transmute(fdirection), ::core::mem::transmute(szdriverdesc), ::core::mem::transmute(cchdriverdescmax), ::core::mem::transmute(pcchdriverdesc), ::core::mem::transmute(szdriverattributes), ::core::mem::transmute(cchdrvrattrmax), ::core::mem::transmute(pcchdrvrattr), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLDriversA(henv: *mut ::core::ffi::c_void, fdirection: u16, szdriverdesc: *mut u8, cbdriverdescmax: i16, pcbdriverdesc: *mut i16, szdriverattributes: *mut u8, cbdrvrattrmax: i16, pcbdrvrattr: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLDriversA(henv: *mut ::core::ffi::c_void, fdirection: u16, szdriverdesc: *mut u8, cbdriverdescmax: i16, pcbdriverdesc: *mut i16, szdriverattributes: *mut u8, cbdrvrattrmax: i16, pcbdrvrattr: *mut i16) -> i16; } ::core::mem::transmute(SQLDriversA( ::core::mem::transmute(henv), ::core::mem::transmute(fdirection), ::core::mem::transmute(szdriverdesc), ::core::mem::transmute(cbdriverdescmax), ::core::mem::transmute(pcbdriverdesc), ::core::mem::transmute(szdriverattributes), ::core::mem::transmute(cbdrvrattrmax), ::core::mem::transmute(pcbdrvrattr), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLDriversW(henv: *mut ::core::ffi::c_void, fdirection: u16, szdriverdesc: *mut u16, cchdriverdescmax: i16, pcchdriverdesc: *mut i16, szdriverattributes: *mut u16, cchdrvrattrmax: i16, pcchdrvrattr: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLDriversW(henv: *mut ::core::ffi::c_void, fdirection: u16, szdriverdesc: *mut u16, cchdriverdescmax: i16, pcchdriverdesc: *mut i16, szdriverattributes: *mut u16, cchdrvrattrmax: i16, pcchdrvrattr: *mut i16) -> i16; } ::core::mem::transmute(SQLDriversW( ::core::mem::transmute(henv), ::core::mem::transmute(fdirection), ::core::mem::transmute(szdriverdesc), ::core::mem::transmute(cchdriverdescmax), ::core::mem::transmute(pcchdriverdesc), ::core::mem::transmute(szdriverattributes), ::core::mem::transmute(cchdrvrattrmax), ::core::mem::transmute(pcchdrvrattr), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLEndTran(handletype: i16, handle: *mut ::core::ffi::c_void, completiontype: i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLEndTran(handletype: i16, handle: *mut ::core::ffi::c_void, completiontype: i16) -> i16; } ::core::mem::transmute(SQLEndTran(::core::mem::transmute(handletype), ::core::mem::transmute(handle), ::core::mem::transmute(completiontype))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLError(environmenthandle: *mut ::core::ffi::c_void, connectionhandle: *mut ::core::ffi::c_void, statementhandle: *mut ::core::ffi::c_void, sqlstate: *mut u8, nativeerror: *mut i32, messagetext: *mut u8, bufferlength: i16, textlength: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLError(environmenthandle: *mut ::core::ffi::c_void, connectionhandle: *mut ::core::ffi::c_void, statementhandle: *mut ::core::ffi::c_void, sqlstate: *mut u8, nativeerror: *mut i32, messagetext: *mut u8, bufferlength: i16, textlength: *mut i16) -> i16; } ::core::mem::transmute(SQLError( ::core::mem::transmute(environmenthandle), ::core::mem::transmute(connectionhandle), ::core::mem::transmute(statementhandle), ::core::mem::transmute(sqlstate), ::core::mem::transmute(nativeerror), ::core::mem::transmute(messagetext), ::core::mem::transmute(bufferlength), ::core::mem::transmute(textlength), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLErrorA(henv: *mut ::core::ffi::c_void, hdbc: *mut ::core::ffi::c_void, hstmt: *mut ::core::ffi::c_void, szsqlstate: *mut u8, pfnativeerror: *mut i32, szerrormsg: *mut u8, cberrormsgmax: i16, pcberrormsg: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLErrorA(henv: *mut ::core::ffi::c_void, hdbc: *mut ::core::ffi::c_void, hstmt: *mut ::core::ffi::c_void, szsqlstate: *mut u8, pfnativeerror: *mut i32, szerrormsg: *mut u8, cberrormsgmax: i16, pcberrormsg: *mut i16) -> i16; } ::core::mem::transmute(SQLErrorA(::core::mem::transmute(henv), ::core::mem::transmute(hdbc), ::core::mem::transmute(hstmt), ::core::mem::transmute(szsqlstate), ::core::mem::transmute(pfnativeerror), ::core::mem::transmute(szerrormsg), ::core::mem::transmute(cberrormsgmax), ::core::mem::transmute(pcberrormsg))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLErrorW(henv: *mut ::core::ffi::c_void, hdbc: *mut ::core::ffi::c_void, hstmt: *mut ::core::ffi::c_void, wszsqlstate: *mut u16, pfnativeerror: *mut i32, wszerrormsg: *mut u16, ccherrormsgmax: i16, pccherrormsg: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLErrorW(henv: *mut ::core::ffi::c_void, hdbc: *mut ::core::ffi::c_void, hstmt: *mut ::core::ffi::c_void, wszsqlstate: *mut u16, pfnativeerror: *mut i32, wszerrormsg: *mut u16, ccherrormsgmax: i16, pccherrormsg: *mut i16) -> i16; } ::core::mem::transmute(SQLErrorW(::core::mem::transmute(henv), ::core::mem::transmute(hdbc), ::core::mem::transmute(hstmt), ::core::mem::transmute(wszsqlstate), ::core::mem::transmute(pfnativeerror), ::core::mem::transmute(wszerrormsg), ::core::mem::transmute(ccherrormsgmax), ::core::mem::transmute(pccherrormsg))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLExecDirect(statementhandle: *mut ::core::ffi::c_void, statementtext: *const u8, textlength: i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLExecDirect(statementhandle: *mut ::core::ffi::c_void, statementtext: *const u8, textlength: i32) -> i16; } ::core::mem::transmute(SQLExecDirect(::core::mem::transmute(statementhandle), ::core::mem::transmute(statementtext), ::core::mem::transmute(textlength))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLExecDirectA(hstmt: *mut ::core::ffi::c_void, szsqlstr: *const u8, cbsqlstr: i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLExecDirectA(hstmt: *mut ::core::ffi::c_void, szsqlstr: *const u8, cbsqlstr: i32) -> i16; } ::core::mem::transmute(SQLExecDirectA(::core::mem::transmute(hstmt), ::core::mem::transmute(szsqlstr), ::core::mem::transmute(cbsqlstr))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLExecDirectW(hstmt: *mut ::core::ffi::c_void, szsqlstr: *const u16, textlength: i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLExecDirectW(hstmt: *mut ::core::ffi::c_void, szsqlstr: *const u16, textlength: i32) -> i16; } ::core::mem::transmute(SQLExecDirectW(::core::mem::transmute(hstmt), ::core::mem::transmute(szsqlstr), ::core::mem::transmute(textlength))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLExecute(statementhandle: *mut ::core::ffi::c_void) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLExecute(statementhandle: *mut ::core::ffi::c_void) -> i16; } ::core::mem::transmute(SQLExecute(::core::mem::transmute(statementhandle))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[inline] pub unsafe fn SQLExtendedFetch(hstmt: *mut ::core::ffi::c_void, ffetchtype: u16, irow: i64, pcrow: *mut u64, rgfrowstatus: *mut u16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLExtendedFetch(hstmt: *mut ::core::ffi::c_void, ffetchtype: u16, irow: i64, pcrow: *mut u64, rgfrowstatus: *mut u16) -> i16; } ::core::mem::transmute(SQLExtendedFetch(::core::mem::transmute(hstmt), ::core::mem::transmute(ffetchtype), ::core::mem::transmute(irow), ::core::mem::transmute(pcrow), ::core::mem::transmute(rgfrowstatus))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86",))] #[inline] pub unsafe fn SQLExtendedFetch(hstmt: *mut ::core::ffi::c_void, ffetchtype: u16, irow: i32, pcrow: *mut u32, rgfrowstatus: *mut u16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLExtendedFetch(hstmt: *mut ::core::ffi::c_void, ffetchtype: u16, irow: i32, pcrow: *mut u32, rgfrowstatus: *mut u16) -> i16; } ::core::mem::transmute(SQLExtendedFetch(::core::mem::transmute(hstmt), ::core::mem::transmute(ffetchtype), ::core::mem::transmute(irow), ::core::mem::transmute(pcrow), ::core::mem::transmute(rgfrowstatus))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } pub const SQLFLT4: u32 = 59u32; pub const SQLFLT8: u32 = 62u32; pub const SQLFLTN: u32 = 109u32; #[inline] pub unsafe fn SQLFetch(statementhandle: *mut ::core::ffi::c_void) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLFetch(statementhandle: *mut ::core::ffi::c_void) -> i16; } ::core::mem::transmute(SQLFetch(::core::mem::transmute(statementhandle))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[inline] pub unsafe fn SQLFetchScroll(statementhandle: *mut ::core::ffi::c_void, fetchorientation: i16, fetchoffset: i64) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLFetchScroll(statementhandle: *mut ::core::ffi::c_void, fetchorientation: i16, fetchoffset: i64) -> i16; } ::core::mem::transmute(SQLFetchScroll(::core::mem::transmute(statementhandle), ::core::mem::transmute(fetchorientation), ::core::mem::transmute(fetchoffset))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86",))] #[inline] pub unsafe fn SQLFetchScroll(statementhandle: *mut ::core::ffi::c_void, fetchorientation: i16, fetchoffset: i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLFetchScroll(statementhandle: *mut ::core::ffi::c_void, fetchorientation: i16, fetchoffset: i32) -> i16; } ::core::mem::transmute(SQLFetchScroll(::core::mem::transmute(statementhandle), ::core::mem::transmute(fetchorientation), ::core::mem::transmute(fetchoffset))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLForeignKeys(hstmt: *mut ::core::ffi::c_void, szpkcatalogname: *const u8, cchpkcatalogname: i16, szpkschemaname: *const u8, cchpkschemaname: i16, szpktablename: *const u8, cchpktablename: i16, szfkcatalogname: *const u8, cchfkcatalogname: i16, szfkschemaname: *const u8, cchfkschemaname: i16, szfktablename: *const u8, cchfktablename: i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLForeignKeys(hstmt: *mut ::core::ffi::c_void, szpkcatalogname: *const u8, cchpkcatalogname: i16, szpkschemaname: *const u8, cchpkschemaname: i16, szpktablename: *const u8, cchpktablename: i16, szfkcatalogname: *const u8, cchfkcatalogname: i16, szfkschemaname: *const u8, cchfkschemaname: i16, szfktablename: *const u8, cchfktablename: i16) -> i16; } ::core::mem::transmute(SQLForeignKeys( ::core::mem::transmute(hstmt), ::core::mem::transmute(szpkcatalogname), ::core::mem::transmute(cchpkcatalogname), ::core::mem::transmute(szpkschemaname), ::core::mem::transmute(cchpkschemaname), ::core::mem::transmute(szpktablename), ::core::mem::transmute(cchpktablename), ::core::mem::transmute(szfkcatalogname), ::core::mem::transmute(cchfkcatalogname), ::core::mem::transmute(szfkschemaname), ::core::mem::transmute(cchfkschemaname), ::core::mem::transmute(szfktablename), ::core::mem::transmute(cchfktablename), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLForeignKeysA(hstmt: *mut ::core::ffi::c_void, szpkcatalogname: *const u8, cbpkcatalogname: i16, szpkschemaname: *const u8, cbpkschemaname: i16, szpktablename: *const u8, cbpktablename: i16, szfkcatalogname: *const u8, cbfkcatalogname: i16, szfkschemaname: *const u8, cbfkschemaname: i16, szfktablename: *const u8, cbfktablename: i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLForeignKeysA(hstmt: *mut ::core::ffi::c_void, szpkcatalogname: *const u8, cbpkcatalogname: i16, szpkschemaname: *const u8, cbpkschemaname: i16, szpktablename: *const u8, cbpktablename: i16, szfkcatalogname: *const u8, cbfkcatalogname: i16, szfkschemaname: *const u8, cbfkschemaname: i16, szfktablename: *const u8, cbfktablename: i16) -> i16; } ::core::mem::transmute(SQLForeignKeysA( ::core::mem::transmute(hstmt), ::core::mem::transmute(szpkcatalogname), ::core::mem::transmute(cbpkcatalogname), ::core::mem::transmute(szpkschemaname), ::core::mem::transmute(cbpkschemaname), ::core::mem::transmute(szpktablename), ::core::mem::transmute(cbpktablename), ::core::mem::transmute(szfkcatalogname), ::core::mem::transmute(cbfkcatalogname), ::core::mem::transmute(szfkschemaname), ::core::mem::transmute(cbfkschemaname), ::core::mem::transmute(szfktablename), ::core::mem::transmute(cbfktablename), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLForeignKeysW(hstmt: *mut ::core::ffi::c_void, szpkcatalogname: *const u16, cchpkcatalogname: i16, szpkschemaname: *const u16, cchpkschemaname: i16, szpktablename: *const u16, cchpktablename: i16, szfkcatalogname: *const u16, cchfkcatalogname: i16, szfkschemaname: *const u16, cchfkschemaname: i16, szfktablename: *const u16, cchfktablename: i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLForeignKeysW(hstmt: *mut ::core::ffi::c_void, szpkcatalogname: *const u16, cchpkcatalogname: i16, szpkschemaname: *const u16, cchpkschemaname: i16, szpktablename: *const u16, cchpktablename: i16, szfkcatalogname: *const u16, cchfkcatalogname: i16, szfkschemaname: *const u16, cchfkschemaname: i16, szfktablename: *const u16, cchfktablename: i16) -> i16; } ::core::mem::transmute(SQLForeignKeysW( ::core::mem::transmute(hstmt), ::core::mem::transmute(szpkcatalogname), ::core::mem::transmute(cchpkcatalogname), ::core::mem::transmute(szpkschemaname), ::core::mem::transmute(cchpkschemaname), ::core::mem::transmute(szpktablename), ::core::mem::transmute(cchpktablename), ::core::mem::transmute(szfkcatalogname), ::core::mem::transmute(cchfkcatalogname), ::core::mem::transmute(szfkschemaname), ::core::mem::transmute(cchfkschemaname), ::core::mem::transmute(szfktablename), ::core::mem::transmute(cchfktablename), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLFreeConnect(connectionhandle: *mut ::core::ffi::c_void) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLFreeConnect(connectionhandle: *mut ::core::ffi::c_void) -> i16; } ::core::mem::transmute(SQLFreeConnect(::core::mem::transmute(connectionhandle))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLFreeEnv(environmenthandle: *mut ::core::ffi::c_void) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLFreeEnv(environmenthandle: *mut ::core::ffi::c_void) -> i16; } ::core::mem::transmute(SQLFreeEnv(::core::mem::transmute(environmenthandle))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLFreeHandle(handletype: i16, handle: *mut ::core::ffi::c_void) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLFreeHandle(handletype: i16, handle: *mut ::core::ffi::c_void) -> i16; } ::core::mem::transmute(SQLFreeHandle(::core::mem::transmute(handletype), ::core::mem::transmute(handle))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLFreeStmt(statementhandle: *mut ::core::ffi::c_void, option: u16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLFreeStmt(statementhandle: *mut ::core::ffi::c_void, option: u16) -> i16; } ::core::mem::transmute(SQLFreeStmt(::core::mem::transmute(statementhandle), ::core::mem::transmute(option))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLGetConnectAttr(connectionhandle: *mut ::core::ffi::c_void, attribute: i32, value: *mut ::core::ffi::c_void, bufferlength: i32, stringlengthptr: *mut i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetConnectAttr(connectionhandle: *mut ::core::ffi::c_void, attribute: i32, value: *mut ::core::ffi::c_void, bufferlength: i32, stringlengthptr: *mut i32) -> i16; } ::core::mem::transmute(SQLGetConnectAttr(::core::mem::transmute(connectionhandle), ::core::mem::transmute(attribute), ::core::mem::transmute(value), ::core::mem::transmute(bufferlength), ::core::mem::transmute(stringlengthptr))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLGetConnectAttrA(hdbc: *mut ::core::ffi::c_void, fattribute: i32, rgbvalue: *mut ::core::ffi::c_void, cbvaluemax: i32, pcbvalue: *mut i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetConnectAttrA(hdbc: *mut ::core::ffi::c_void, fattribute: i32, rgbvalue: *mut ::core::ffi::c_void, cbvaluemax: i32, pcbvalue: *mut i32) -> i16; } ::core::mem::transmute(SQLGetConnectAttrA(::core::mem::transmute(hdbc), ::core::mem::transmute(fattribute), ::core::mem::transmute(rgbvalue), ::core::mem::transmute(cbvaluemax), ::core::mem::transmute(pcbvalue))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLGetConnectAttrW(hdbc: *mut ::core::ffi::c_void, fattribute: i32, rgbvalue: *mut ::core::ffi::c_void, cbvaluemax: i32, pcbvalue: *mut i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetConnectAttrW(hdbc: *mut ::core::ffi::c_void, fattribute: i32, rgbvalue: *mut ::core::ffi::c_void, cbvaluemax: i32, pcbvalue: *mut i32) -> i16; } ::core::mem::transmute(SQLGetConnectAttrW(::core::mem::transmute(hdbc), ::core::mem::transmute(fattribute), ::core::mem::transmute(rgbvalue), ::core::mem::transmute(cbvaluemax), ::core::mem::transmute(pcbvalue))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLGetConnectOption(connectionhandle: *mut ::core::ffi::c_void, option: u16, value: *mut ::core::ffi::c_void) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetConnectOption(connectionhandle: *mut ::core::ffi::c_void, option: u16, value: *mut ::core::ffi::c_void) -> i16; } ::core::mem::transmute(SQLGetConnectOption(::core::mem::transmute(connectionhandle), ::core::mem::transmute(option), ::core::mem::transmute(value))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLGetConnectOptionA(hdbc: *mut ::core::ffi::c_void, foption: u16, pvparam: *mut ::core::ffi::c_void) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetConnectOptionA(hdbc: *mut ::core::ffi::c_void, foption: u16, pvparam: *mut ::core::ffi::c_void) -> i16; } ::core::mem::transmute(SQLGetConnectOptionA(::core::mem::transmute(hdbc), ::core::mem::transmute(foption), ::core::mem::transmute(pvparam))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLGetConnectOptionW(hdbc: *mut ::core::ffi::c_void, foption: u16, pvparam: *mut ::core::ffi::c_void) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetConnectOptionW(hdbc: *mut ::core::ffi::c_void, foption: u16, pvparam: *mut ::core::ffi::c_void) -> i16; } ::core::mem::transmute(SQLGetConnectOptionW(::core::mem::transmute(hdbc), ::core::mem::transmute(foption), ::core::mem::transmute(pvparam))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLGetCursorName(statementhandle: *mut ::core::ffi::c_void, cursorname: *mut u8, bufferlength: i16, namelengthptr: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetCursorName(statementhandle: *mut ::core::ffi::c_void, cursorname: *mut u8, bufferlength: i16, namelengthptr: *mut i16) -> i16; } ::core::mem::transmute(SQLGetCursorName(::core::mem::transmute(statementhandle), ::core::mem::transmute(cursorname), ::core::mem::transmute(bufferlength), ::core::mem::transmute(namelengthptr))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLGetCursorNameA(hstmt: *mut ::core::ffi::c_void, szcursor: *mut u8, cbcursormax: i16, pcbcursor: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetCursorNameA(hstmt: *mut ::core::ffi::c_void, szcursor: *mut u8, cbcursormax: i16, pcbcursor: *mut i16) -> i16; } ::core::mem::transmute(SQLGetCursorNameA(::core::mem::transmute(hstmt), ::core::mem::transmute(szcursor), ::core::mem::transmute(cbcursormax), ::core::mem::transmute(pcbcursor))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLGetCursorNameW(hstmt: *mut ::core::ffi::c_void, szcursor: *mut u16, cchcursormax: i16, pcchcursor: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetCursorNameW(hstmt: *mut ::core::ffi::c_void, szcursor: *mut u16, cchcursormax: i16, pcchcursor: *mut i16) -> i16; } ::core::mem::transmute(SQLGetCursorNameW(::core::mem::transmute(hstmt), ::core::mem::transmute(szcursor), ::core::mem::transmute(cchcursormax), ::core::mem::transmute(pcchcursor))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[inline] pub unsafe fn SQLGetData(statementhandle: *mut ::core::ffi::c_void, columnnumber: u16, targettype: i16, targetvalue: *mut ::core::ffi::c_void, bufferlength: i64, strlen_or_indptr: *mut i64) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetData(statementhandle: *mut ::core::ffi::c_void, columnnumber: u16, targettype: i16, targetvalue: *mut ::core::ffi::c_void, bufferlength: i64, strlen_or_indptr: *mut i64) -> i16; } ::core::mem::transmute(SQLGetData(::core::mem::transmute(statementhandle), ::core::mem::transmute(columnnumber), ::core::mem::transmute(targettype), ::core::mem::transmute(targetvalue), ::core::mem::transmute(bufferlength), ::core::mem::transmute(strlen_or_indptr))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86",))] #[inline] pub unsafe fn SQLGetData(statementhandle: *mut ::core::ffi::c_void, columnnumber: u16, targettype: i16, targetvalue: *mut ::core::ffi::c_void, bufferlength: i32, strlen_or_indptr: *mut i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetData(statementhandle: *mut ::core::ffi::c_void, columnnumber: u16, targettype: i16, targetvalue: *mut ::core::ffi::c_void, bufferlength: i32, strlen_or_indptr: *mut i32) -> i16; } ::core::mem::transmute(SQLGetData(::core::mem::transmute(statementhandle), ::core::mem::transmute(columnnumber), ::core::mem::transmute(targettype), ::core::mem::transmute(targetvalue), ::core::mem::transmute(bufferlength), ::core::mem::transmute(strlen_or_indptr))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLGetDescField(descriptorhandle: *mut ::core::ffi::c_void, recnumber: i16, fieldidentifier: i16, value: *mut ::core::ffi::c_void, bufferlength: i32, stringlength: *mut i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetDescField(descriptorhandle: *mut ::core::ffi::c_void, recnumber: i16, fieldidentifier: i16, value: *mut ::core::ffi::c_void, bufferlength: i32, stringlength: *mut i32) -> i16; } ::core::mem::transmute(SQLGetDescField(::core::mem::transmute(descriptorhandle), ::core::mem::transmute(recnumber), ::core::mem::transmute(fieldidentifier), ::core::mem::transmute(value), ::core::mem::transmute(bufferlength), ::core::mem::transmute(stringlength))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLGetDescFieldA(hdesc: *mut ::core::ffi::c_void, irecord: i16, ifield: i16, rgbvalue: *mut ::core::ffi::c_void, cbbufferlength: i32, stringlength: *mut i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetDescFieldA(hdesc: *mut ::core::ffi::c_void, irecord: i16, ifield: i16, rgbvalue: *mut ::core::ffi::c_void, cbbufferlength: i32, stringlength: *mut i32) -> i16; } ::core::mem::transmute(SQLGetDescFieldA(::core::mem::transmute(hdesc), ::core::mem::transmute(irecord), ::core::mem::transmute(ifield), ::core::mem::transmute(rgbvalue), ::core::mem::transmute(cbbufferlength), ::core::mem::transmute(stringlength))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLGetDescFieldW(hdesc: *mut ::core::ffi::c_void, irecord: i16, ifield: i16, rgbvalue: *mut ::core::ffi::c_void, cbbufferlength: i32, stringlength: *mut i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetDescFieldW(hdesc: *mut ::core::ffi::c_void, irecord: i16, ifield: i16, rgbvalue: *mut ::core::ffi::c_void, cbbufferlength: i32, stringlength: *mut i32) -> i16; } ::core::mem::transmute(SQLGetDescFieldW(::core::mem::transmute(hdesc), ::core::mem::transmute(irecord), ::core::mem::transmute(ifield), ::core::mem::transmute(rgbvalue), ::core::mem::transmute(cbbufferlength), ::core::mem::transmute(stringlength))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[inline] pub unsafe fn SQLGetDescRec(descriptorhandle: *mut ::core::ffi::c_void, recnumber: i16, name: *mut u8, bufferlength: i16, stringlengthptr: *mut i16, typeptr: *mut i16, subtypeptr: *mut i16, lengthptr: *mut i64, precisionptr: *mut i16, scaleptr: *mut i16, nullableptr: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetDescRec(descriptorhandle: *mut ::core::ffi::c_void, recnumber: i16, name: *mut u8, bufferlength: i16, stringlengthptr: *mut i16, typeptr: *mut i16, subtypeptr: *mut i16, lengthptr: *mut i64, precisionptr: *mut i16, scaleptr: *mut i16, nullableptr: *mut i16) -> i16; } ::core::mem::transmute(SQLGetDescRec( ::core::mem::transmute(descriptorhandle), ::core::mem::transmute(recnumber), ::core::mem::transmute(name), ::core::mem::transmute(bufferlength), ::core::mem::transmute(stringlengthptr), ::core::mem::transmute(typeptr), ::core::mem::transmute(subtypeptr), ::core::mem::transmute(lengthptr), ::core::mem::transmute(precisionptr), ::core::mem::transmute(scaleptr), ::core::mem::transmute(nullableptr), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86",))] #[inline] pub unsafe fn SQLGetDescRec(descriptorhandle: *mut ::core::ffi::c_void, recnumber: i16, name: *mut u8, bufferlength: i16, stringlengthptr: *mut i16, typeptr: *mut i16, subtypeptr: *mut i16, lengthptr: *mut i32, precisionptr: *mut i16, scaleptr: *mut i16, nullableptr: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetDescRec(descriptorhandle: *mut ::core::ffi::c_void, recnumber: i16, name: *mut u8, bufferlength: i16, stringlengthptr: *mut i16, typeptr: *mut i16, subtypeptr: *mut i16, lengthptr: *mut i32, precisionptr: *mut i16, scaleptr: *mut i16, nullableptr: *mut i16) -> i16; } ::core::mem::transmute(SQLGetDescRec( ::core::mem::transmute(descriptorhandle), ::core::mem::transmute(recnumber), ::core::mem::transmute(name), ::core::mem::transmute(bufferlength), ::core::mem::transmute(stringlengthptr), ::core::mem::transmute(typeptr), ::core::mem::transmute(subtypeptr), ::core::mem::transmute(lengthptr), ::core::mem::transmute(precisionptr), ::core::mem::transmute(scaleptr), ::core::mem::transmute(nullableptr), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[inline] pub unsafe fn SQLGetDescRecA(hdesc: *mut ::core::ffi::c_void, irecord: i16, szname: *mut u8, cbnamemax: i16, pcbname: *mut i16, pftype: *mut i16, pfsubtype: *mut i16, plength: *mut i64, pprecision: *mut i16, pscale: *mut i16, pnullable: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetDescRecA(hdesc: *mut ::core::ffi::c_void, irecord: i16, szname: *mut u8, cbnamemax: i16, pcbname: *mut i16, pftype: *mut i16, pfsubtype: *mut i16, plength: *mut i64, pprecision: *mut i16, pscale: *mut i16, pnullable: *mut i16) -> i16; } ::core::mem::transmute(SQLGetDescRecA( ::core::mem::transmute(hdesc), ::core::mem::transmute(irecord), ::core::mem::transmute(szname), ::core::mem::transmute(cbnamemax), ::core::mem::transmute(pcbname), ::core::mem::transmute(pftype), ::core::mem::transmute(pfsubtype), ::core::mem::transmute(plength), ::core::mem::transmute(pprecision), ::core::mem::transmute(pscale), ::core::mem::transmute(pnullable), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86",))] #[inline] pub unsafe fn SQLGetDescRecA(hdesc: *mut ::core::ffi::c_void, irecord: i16, szname: *mut u8, cbnamemax: i16, pcbname: *mut i16, pftype: *mut i16, pfsubtype: *mut i16, plength: *mut i32, pprecision: *mut i16, pscale: *mut i16, pnullable: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetDescRecA(hdesc: *mut ::core::ffi::c_void, irecord: i16, szname: *mut u8, cbnamemax: i16, pcbname: *mut i16, pftype: *mut i16, pfsubtype: *mut i16, plength: *mut i32, pprecision: *mut i16, pscale: *mut i16, pnullable: *mut i16) -> i16; } ::core::mem::transmute(SQLGetDescRecA( ::core::mem::transmute(hdesc), ::core::mem::transmute(irecord), ::core::mem::transmute(szname), ::core::mem::transmute(cbnamemax), ::core::mem::transmute(pcbname), ::core::mem::transmute(pftype), ::core::mem::transmute(pfsubtype), ::core::mem::transmute(plength), ::core::mem::transmute(pprecision), ::core::mem::transmute(pscale), ::core::mem::transmute(pnullable), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[inline] pub unsafe fn SQLGetDescRecW(hdesc: *mut ::core::ffi::c_void, irecord: i16, szname: *mut u16, cchnamemax: i16, pcchname: *mut i16, pftype: *mut i16, pfsubtype: *mut i16, plength: *mut i64, pprecision: *mut i16, pscale: *mut i16, pnullable: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetDescRecW(hdesc: *mut ::core::ffi::c_void, irecord: i16, szname: *mut u16, cchnamemax: i16, pcchname: *mut i16, pftype: *mut i16, pfsubtype: *mut i16, plength: *mut i64, pprecision: *mut i16, pscale: *mut i16, pnullable: *mut i16) -> i16; } ::core::mem::transmute(SQLGetDescRecW( ::core::mem::transmute(hdesc), ::core::mem::transmute(irecord), ::core::mem::transmute(szname), ::core::mem::transmute(cchnamemax), ::core::mem::transmute(pcchname), ::core::mem::transmute(pftype), ::core::mem::transmute(pfsubtype), ::core::mem::transmute(plength), ::core::mem::transmute(pprecision), ::core::mem::transmute(pscale), ::core::mem::transmute(pnullable), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86",))] #[inline] pub unsafe fn SQLGetDescRecW(hdesc: *mut ::core::ffi::c_void, irecord: i16, szname: *mut u16, cchnamemax: i16, pcchname: *mut i16, pftype: *mut i16, pfsubtype: *mut i16, plength: *mut i32, pprecision: *mut i16, pscale: *mut i16, pnullable: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetDescRecW(hdesc: *mut ::core::ffi::c_void, irecord: i16, szname: *mut u16, cchnamemax: i16, pcchname: *mut i16, pftype: *mut i16, pfsubtype: *mut i16, plength: *mut i32, pprecision: *mut i16, pscale: *mut i16, pnullable: *mut i16) -> i16; } ::core::mem::transmute(SQLGetDescRecW( ::core::mem::transmute(hdesc), ::core::mem::transmute(irecord), ::core::mem::transmute(szname), ::core::mem::transmute(cchnamemax), ::core::mem::transmute(pcchname), ::core::mem::transmute(pftype), ::core::mem::transmute(pfsubtype), ::core::mem::transmute(plength), ::core::mem::transmute(pprecision), ::core::mem::transmute(pscale), ::core::mem::transmute(pnullable), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLGetDiagField(handletype: i16, handle: *mut ::core::ffi::c_void, recnumber: i16, diagidentifier: i16, diaginfo: *mut ::core::ffi::c_void, bufferlength: i16, stringlength: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetDiagField(handletype: i16, handle: *mut ::core::ffi::c_void, recnumber: i16, diagidentifier: i16, diaginfo: *mut ::core::ffi::c_void, bufferlength: i16, stringlength: *mut i16) -> i16; } ::core::mem::transmute(SQLGetDiagField(::core::mem::transmute(handletype), ::core::mem::transmute(handle), ::core::mem::transmute(recnumber), ::core::mem::transmute(diagidentifier), ::core::mem::transmute(diaginfo), ::core::mem::transmute(bufferlength), ::core::mem::transmute(stringlength))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLGetDiagFieldA(fhandletype: i16, handle: *mut ::core::ffi::c_void, irecord: i16, fdiagfield: i16, rgbdiaginfo: *mut ::core::ffi::c_void, cbdiaginfomax: i16, pcbdiaginfo: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetDiagFieldA(fhandletype: i16, handle: *mut ::core::ffi::c_void, irecord: i16, fdiagfield: i16, rgbdiaginfo: *mut ::core::ffi::c_void, cbdiaginfomax: i16, pcbdiaginfo: *mut i16) -> i16; } ::core::mem::transmute(SQLGetDiagFieldA(::core::mem::transmute(fhandletype), ::core::mem::transmute(handle), ::core::mem::transmute(irecord), ::core::mem::transmute(fdiagfield), ::core::mem::transmute(rgbdiaginfo), ::core::mem::transmute(cbdiaginfomax), ::core::mem::transmute(pcbdiaginfo))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLGetDiagFieldW(fhandletype: i16, handle: *mut ::core::ffi::c_void, irecord: i16, fdiagfield: i16, rgbdiaginfo: *mut ::core::ffi::c_void, cbbufferlength: i16, pcbstringlength: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetDiagFieldW(fhandletype: i16, handle: *mut ::core::ffi::c_void, irecord: i16, fdiagfield: i16, rgbdiaginfo: *mut ::core::ffi::c_void, cbbufferlength: i16, pcbstringlength: *mut i16) -> i16; } ::core::mem::transmute(SQLGetDiagFieldW(::core::mem::transmute(fhandletype), ::core::mem::transmute(handle), ::core::mem::transmute(irecord), ::core::mem::transmute(fdiagfield), ::core::mem::transmute(rgbdiaginfo), ::core::mem::transmute(cbbufferlength), ::core::mem::transmute(pcbstringlength))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLGetDiagRec(handletype: i16, handle: *mut ::core::ffi::c_void, recnumber: i16, sqlstate: *mut u8, nativeerror: *mut i32, messagetext: *mut u8, bufferlength: i16, textlength: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetDiagRec(handletype: i16, handle: *mut ::core::ffi::c_void, recnumber: i16, sqlstate: *mut u8, nativeerror: *mut i32, messagetext: *mut u8, bufferlength: i16, textlength: *mut i16) -> i16; } ::core::mem::transmute(SQLGetDiagRec(::core::mem::transmute(handletype), ::core::mem::transmute(handle), ::core::mem::transmute(recnumber), ::core::mem::transmute(sqlstate), ::core::mem::transmute(nativeerror), ::core::mem::transmute(messagetext), ::core::mem::transmute(bufferlength), ::core::mem::transmute(textlength))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLGetDiagRecA(fhandletype: i16, handle: *mut ::core::ffi::c_void, irecord: i16, szsqlstate: *mut u8, pfnativeerror: *mut i32, szerrormsg: *mut u8, cberrormsgmax: i16, pcberrormsg: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetDiagRecA(fhandletype: i16, handle: *mut ::core::ffi::c_void, irecord: i16, szsqlstate: *mut u8, pfnativeerror: *mut i32, szerrormsg: *mut u8, cberrormsgmax: i16, pcberrormsg: *mut i16) -> i16; } ::core::mem::transmute(SQLGetDiagRecA( ::core::mem::transmute(fhandletype), ::core::mem::transmute(handle), ::core::mem::transmute(irecord), ::core::mem::transmute(szsqlstate), ::core::mem::transmute(pfnativeerror), ::core::mem::transmute(szerrormsg), ::core::mem::transmute(cberrormsgmax), ::core::mem::transmute(pcberrormsg), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLGetDiagRecW(fhandletype: i16, handle: *mut ::core::ffi::c_void, irecord: i16, szsqlstate: *mut u16, pfnativeerror: *mut i32, szerrormsg: *mut u16, ccherrormsgmax: i16, pccherrormsg: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetDiagRecW(fhandletype: i16, handle: *mut ::core::ffi::c_void, irecord: i16, szsqlstate: *mut u16, pfnativeerror: *mut i32, szerrormsg: *mut u16, ccherrormsgmax: i16, pccherrormsg: *mut i16) -> i16; } ::core::mem::transmute(SQLGetDiagRecW( ::core::mem::transmute(fhandletype), ::core::mem::transmute(handle), ::core::mem::transmute(irecord), ::core::mem::transmute(szsqlstate), ::core::mem::transmute(pfnativeerror), ::core::mem::transmute(szerrormsg), ::core::mem::transmute(ccherrormsgmax), ::core::mem::transmute(pccherrormsg), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLGetEnvAttr(environmenthandle: *mut ::core::ffi::c_void, attribute: i32, value: *mut ::core::ffi::c_void, bufferlength: i32, stringlength: *mut i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetEnvAttr(environmenthandle: *mut ::core::ffi::c_void, attribute: i32, value: *mut ::core::ffi::c_void, bufferlength: i32, stringlength: *mut i32) -> i16; } ::core::mem::transmute(SQLGetEnvAttr(::core::mem::transmute(environmenthandle), ::core::mem::transmute(attribute), ::core::mem::transmute(value), ::core::mem::transmute(bufferlength), ::core::mem::transmute(stringlength))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLGetFunctions(connectionhandle: *mut ::core::ffi::c_void, functionid: u16, supported: *mut u16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetFunctions(connectionhandle: *mut ::core::ffi::c_void, functionid: u16, supported: *mut u16) -> i16; } ::core::mem::transmute(SQLGetFunctions(::core::mem::transmute(connectionhandle), ::core::mem::transmute(functionid), ::core::mem::transmute(supported))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLGetInfo(connectionhandle: *mut ::core::ffi::c_void, infotype: u16, infovalue: *mut ::core::ffi::c_void, bufferlength: i16, stringlengthptr: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetInfo(connectionhandle: *mut ::core::ffi::c_void, infotype: u16, infovalue: *mut ::core::ffi::c_void, bufferlength: i16, stringlengthptr: *mut i16) -> i16; } ::core::mem::transmute(SQLGetInfo(::core::mem::transmute(connectionhandle), ::core::mem::transmute(infotype), ::core::mem::transmute(infovalue), ::core::mem::transmute(bufferlength), ::core::mem::transmute(stringlengthptr))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLGetInfoA(hdbc: *mut ::core::ffi::c_void, finfotype: u16, rgbinfovalue: *mut ::core::ffi::c_void, cbinfovaluemax: i16, pcbinfovalue: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetInfoA(hdbc: *mut ::core::ffi::c_void, finfotype: u16, rgbinfovalue: *mut ::core::ffi::c_void, cbinfovaluemax: i16, pcbinfovalue: *mut i16) -> i16; } ::core::mem::transmute(SQLGetInfoA(::core::mem::transmute(hdbc), ::core::mem::transmute(finfotype), ::core::mem::transmute(rgbinfovalue), ::core::mem::transmute(cbinfovaluemax), ::core::mem::transmute(pcbinfovalue))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLGetInfoW(hdbc: *mut ::core::ffi::c_void, finfotype: u16, rgbinfovalue: *mut ::core::ffi::c_void, cbinfovaluemax: i16, pcbinfovalue: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetInfoW(hdbc: *mut ::core::ffi::c_void, finfotype: u16, rgbinfovalue: *mut ::core::ffi::c_void, cbinfovaluemax: i16, pcbinfovalue: *mut i16) -> i16; } ::core::mem::transmute(SQLGetInfoW(::core::mem::transmute(hdbc), ::core::mem::transmute(finfotype), ::core::mem::transmute(rgbinfovalue), ::core::mem::transmute(cbinfovaluemax), ::core::mem::transmute(pcbinfovalue))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(feature = "Win32_Foundation")] #[inline] pub unsafe fn SQLGetNextEnumeration<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::HANDLE>>(henumhandle: Param0, prgenumdata: *mut u8, pienumlength: *mut i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetNextEnumeration(henumhandle: super::super::Foundation::HANDLE, prgenumdata: *mut u8, pienumlength: *mut i32) -> i16; } ::core::mem::transmute(SQLGetNextEnumeration(henumhandle.into_param().abi(), ::core::mem::transmute(prgenumdata), ::core::mem::transmute(pienumlength))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLGetStmtAttr(statementhandle: *mut ::core::ffi::c_void, attribute: i32, value: *mut ::core::ffi::c_void, bufferlength: i32, stringlength: *mut i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetStmtAttr(statementhandle: *mut ::core::ffi::c_void, attribute: i32, value: *mut ::core::ffi::c_void, bufferlength: i32, stringlength: *mut i32) -> i16; } ::core::mem::transmute(SQLGetStmtAttr(::core::mem::transmute(statementhandle), ::core::mem::transmute(attribute), ::core::mem::transmute(value), ::core::mem::transmute(bufferlength), ::core::mem::transmute(stringlength))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLGetStmtAttrA(hstmt: *mut ::core::ffi::c_void, fattribute: i32, rgbvalue: *mut ::core::ffi::c_void, cbvaluemax: i32, pcbvalue: *mut i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetStmtAttrA(hstmt: *mut ::core::ffi::c_void, fattribute: i32, rgbvalue: *mut ::core::ffi::c_void, cbvaluemax: i32, pcbvalue: *mut i32) -> i16; } ::core::mem::transmute(SQLGetStmtAttrA(::core::mem::transmute(hstmt), ::core::mem::transmute(fattribute), ::core::mem::transmute(rgbvalue), ::core::mem::transmute(cbvaluemax), ::core::mem::transmute(pcbvalue))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLGetStmtAttrW(hstmt: *mut ::core::ffi::c_void, fattribute: i32, rgbvalue: *mut ::core::ffi::c_void, cbvaluemax: i32, pcbvalue: *mut i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetStmtAttrW(hstmt: *mut ::core::ffi::c_void, fattribute: i32, rgbvalue: *mut ::core::ffi::c_void, cbvaluemax: i32, pcbvalue: *mut i32) -> i16; } ::core::mem::transmute(SQLGetStmtAttrW(::core::mem::transmute(hstmt), ::core::mem::transmute(fattribute), ::core::mem::transmute(rgbvalue), ::core::mem::transmute(cbvaluemax), ::core::mem::transmute(pcbvalue))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLGetStmtOption(statementhandle: *mut ::core::ffi::c_void, option: u16, value: *mut ::core::ffi::c_void) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetStmtOption(statementhandle: *mut ::core::ffi::c_void, option: u16, value: *mut ::core::ffi::c_void) -> i16; } ::core::mem::transmute(SQLGetStmtOption(::core::mem::transmute(statementhandle), ::core::mem::transmute(option), ::core::mem::transmute(value))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLGetTypeInfo(statementhandle: *mut ::core::ffi::c_void, datatype: i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetTypeInfo(statementhandle: *mut ::core::ffi::c_void, datatype: i16) -> i16; } ::core::mem::transmute(SQLGetTypeInfo(::core::mem::transmute(statementhandle), ::core::mem::transmute(datatype))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLGetTypeInfoA(statementhandle: *mut ::core::ffi::c_void, datatype: i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetTypeInfoA(statementhandle: *mut ::core::ffi::c_void, datatype: i16) -> i16; } ::core::mem::transmute(SQLGetTypeInfoA(::core::mem::transmute(statementhandle), ::core::mem::transmute(datatype))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLGetTypeInfoW(statementhandle: *mut ::core::ffi::c_void, datatype: i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLGetTypeInfoW(statementhandle: *mut ::core::ffi::c_void, datatype: i16) -> i16; } ::core::mem::transmute(SQLGetTypeInfoW(::core::mem::transmute(statementhandle), ::core::mem::transmute(datatype))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } pub const SQLIMAGE: u32 = 34u32; pub const SQLINT1: u32 = 48u32; pub const SQLINT2: u32 = 52u32; pub const SQLINT4: u32 = 56u32; pub const SQLINT8: u32 = 127u32; #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct SQLINTERVAL(pub i32); pub const SQL_IS_YEAR: SQLINTERVAL = SQLINTERVAL(1i32); pub const SQL_IS_MONTH: SQLINTERVAL = SQLINTERVAL(2i32); pub const SQL_IS_DAY: SQLINTERVAL = SQLINTERVAL(3i32); pub const SQL_IS_HOUR: SQLINTERVAL = SQLINTERVAL(4i32); pub const SQL_IS_MINUTE: SQLINTERVAL = SQLINTERVAL(5i32); pub const SQL_IS_SECOND: SQLINTERVAL = SQLINTERVAL(6i32); pub const SQL_IS_YEAR_TO_MONTH: SQLINTERVAL = SQLINTERVAL(7i32); pub const SQL_IS_DAY_TO_HOUR: SQLINTERVAL = SQLINTERVAL(8i32); pub const SQL_IS_DAY_TO_MINUTE: SQLINTERVAL = SQLINTERVAL(9i32); pub const SQL_IS_DAY_TO_SECOND: SQLINTERVAL = SQLINTERVAL(10i32); pub const SQL_IS_HOUR_TO_MINUTE: SQLINTERVAL = SQLINTERVAL(11i32); pub const SQL_IS_HOUR_TO_SECOND: SQLINTERVAL = SQLINTERVAL(12i32); pub const SQL_IS_MINUTE_TO_SECOND: SQLINTERVAL = SQLINTERVAL(13i32); impl ::core::convert::From<i32> for SQLINTERVAL { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for SQLINTERVAL { type Abi = Self; } pub const SQLINTN: u32 = 38u32; #[cfg(feature = "Win32_Foundation")] #[inline] pub unsafe fn SQLInitEnumServers<'a, Param0: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(pwchservername: Param0, pwchinstancename: Param1) -> super::super::Foundation::HANDLE { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLInitEnumServers(pwchservername: super::super::Foundation::PWSTR, pwchinstancename: super::super::Foundation::PWSTR) -> super::super::Foundation::HANDLE; } ::core::mem::transmute(SQLInitEnumServers(pwchservername.into_param().abi(), pwchinstancename.into_param().abi())) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(feature = "Win32_Foundation")] #[inline] pub unsafe fn SQLLinkedCatalogsA<'a, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::PSTR>>(param0: *mut ::core::ffi::c_void, param1: Param1, param2: i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLLinkedCatalogsA(param0: *mut ::core::ffi::c_void, param1: super::super::Foundation::PSTR, param2: i16) -> i16; } ::core::mem::transmute(SQLLinkedCatalogsA(::core::mem::transmute(param0), param1.into_param().abi(), ::core::mem::transmute(param2))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(feature = "Win32_Foundation")] #[inline] pub unsafe fn SQLLinkedCatalogsW<'a, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(param0: *mut ::core::ffi::c_void, param1: Param1, param2: i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLLinkedCatalogsW(param0: *mut ::core::ffi::c_void, param1: super::super::Foundation::PWSTR, param2: i16) -> i16; } ::core::mem::transmute(SQLLinkedCatalogsW(::core::mem::transmute(param0), param1.into_param().abi(), ::core::mem::transmute(param2))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLLinkedServers(param0: *mut ::core::ffi::c_void) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLLinkedServers(param0: *mut ::core::ffi::c_void) -> i16; } ::core::mem::transmute(SQLLinkedServers(::core::mem::transmute(param0))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } pub const SQLMONEY: u32 = 60u32; pub const SQLMONEY4: u32 = 122u32; pub const SQLMONEYN: u32 = 110u32; #[inline] pub unsafe fn SQLMoreResults(hstmt: *mut ::core::ffi::c_void) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLMoreResults(hstmt: *mut ::core::ffi::c_void) -> i16; } ::core::mem::transmute(SQLMoreResults(::core::mem::transmute(hstmt))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } pub const SQLNCHAR: u32 = 239u32; pub const SQLNTEXT: u32 = 99u32; pub const SQLNUMERIC: u32 = 108u32; pub const SQLNUMERICN: u32 = 108u32; pub const SQLNVARCHAR: u32 = 231u32; #[inline] pub unsafe fn SQLNativeSql(hdbc: *mut ::core::ffi::c_void, szsqlstrin: *const u8, cchsqlstrin: i32, szsqlstr: *mut u8, cchsqlstrmax: i32, pcbsqlstr: *mut i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLNativeSql(hdbc: *mut ::core::ffi::c_void, szsqlstrin: *const u8, cchsqlstrin: i32, szsqlstr: *mut u8, cchsqlstrmax: i32, pcbsqlstr: *mut i32) -> i16; } ::core::mem::transmute(SQLNativeSql(::core::mem::transmute(hdbc), ::core::mem::transmute(szsqlstrin), ::core::mem::transmute(cchsqlstrin), ::core::mem::transmute(szsqlstr), ::core::mem::transmute(cchsqlstrmax), ::core::mem::transmute(pcbsqlstr))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLNativeSqlA(hdbc: *mut ::core::ffi::c_void, szsqlstrin: *const u8, cbsqlstrin: i32, szsqlstr: *mut u8, cbsqlstrmax: i32, pcbsqlstr: *mut i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLNativeSqlA(hdbc: *mut ::core::ffi::c_void, szsqlstrin: *const u8, cbsqlstrin: i32, szsqlstr: *mut u8, cbsqlstrmax: i32, pcbsqlstr: *mut i32) -> i16; } ::core::mem::transmute(SQLNativeSqlA(::core::mem::transmute(hdbc), ::core::mem::transmute(szsqlstrin), ::core::mem::transmute(cbsqlstrin), ::core::mem::transmute(szsqlstr), ::core::mem::transmute(cbsqlstrmax), ::core::mem::transmute(pcbsqlstr))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLNativeSqlW(hdbc: *mut ::core::ffi::c_void, szsqlstrin: *const u16, cchsqlstrin: i32, szsqlstr: *mut u16, cchsqlstrmax: i32, pcchsqlstr: *mut i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLNativeSqlW(hdbc: *mut ::core::ffi::c_void, szsqlstrin: *const u16, cchsqlstrin: i32, szsqlstr: *mut u16, cchsqlstrmax: i32, pcchsqlstr: *mut i32) -> i16; } ::core::mem::transmute(SQLNativeSqlW(::core::mem::transmute(hdbc), ::core::mem::transmute(szsqlstrin), ::core::mem::transmute(cchsqlstrin), ::core::mem::transmute(szsqlstr), ::core::mem::transmute(cchsqlstrmax), ::core::mem::transmute(pcchsqlstr))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLNumParams(hstmt: *mut ::core::ffi::c_void, pcpar: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLNumParams(hstmt: *mut ::core::ffi::c_void, pcpar: *mut i16) -> i16; } ::core::mem::transmute(SQLNumParams(::core::mem::transmute(hstmt), ::core::mem::transmute(pcpar))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLNumResultCols(statementhandle: *mut ::core::ffi::c_void, columncount: *mut i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLNumResultCols(statementhandle: *mut ::core::ffi::c_void, columncount: *mut i16) -> i16; } ::core::mem::transmute(SQLNumResultCols(::core::mem::transmute(statementhandle), ::core::mem::transmute(columncount))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLParamData(statementhandle: *mut ::core::ffi::c_void, value: *mut *mut ::core::ffi::c_void) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLParamData(statementhandle: *mut ::core::ffi::c_void, value: *mut *mut ::core::ffi::c_void) -> i16; } ::core::mem::transmute(SQLParamData(::core::mem::transmute(statementhandle), ::core::mem::transmute(value))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[inline] pub unsafe fn SQLParamOptions(hstmt: *mut ::core::ffi::c_void, crow: u64, pirow: *mut u64) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLParamOptions(hstmt: *mut ::core::ffi::c_void, crow: u64, pirow: *mut u64) -> i16; } ::core::mem::transmute(SQLParamOptions(::core::mem::transmute(hstmt), ::core::mem::transmute(crow), ::core::mem::transmute(pirow))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86",))] #[inline] pub unsafe fn SQLParamOptions(hstmt: *mut ::core::ffi::c_void, crow: u32, pirow: *mut u32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLParamOptions(hstmt: *mut ::core::ffi::c_void, crow: u32, pirow: *mut u32) -> i16; } ::core::mem::transmute(SQLParamOptions(::core::mem::transmute(hstmt), ::core::mem::transmute(crow), ::core::mem::transmute(pirow))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLPrepare(statementhandle: *mut ::core::ffi::c_void, statementtext: *const u8, textlength: i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLPrepare(statementhandle: *mut ::core::ffi::c_void, statementtext: *const u8, textlength: i32) -> i16; } ::core::mem::transmute(SQLPrepare(::core::mem::transmute(statementhandle), ::core::mem::transmute(statementtext), ::core::mem::transmute(textlength))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLPrepareA(hstmt: *mut ::core::ffi::c_void, szsqlstr: *const u8, cbsqlstr: i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLPrepareA(hstmt: *mut ::core::ffi::c_void, szsqlstr: *const u8, cbsqlstr: i32) -> i16; } ::core::mem::transmute(SQLPrepareA(::core::mem::transmute(hstmt), ::core::mem::transmute(szsqlstr), ::core::mem::transmute(cbsqlstr))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLPrepareW(hstmt: *mut ::core::ffi::c_void, szsqlstr: *const u16, cchsqlstr: i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLPrepareW(hstmt: *mut ::core::ffi::c_void, szsqlstr: *const u16, cchsqlstr: i32) -> i16; } ::core::mem::transmute(SQLPrepareW(::core::mem::transmute(hstmt), ::core::mem::transmute(szsqlstr), ::core::mem::transmute(cchsqlstr))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLPrimaryKeys(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u8, cchcatalogname: i16, szschemaname: *const u8, cchschemaname: i16, sztablename: *const u8, cchtablename: i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLPrimaryKeys(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u8, cchcatalogname: i16, szschemaname: *const u8, cchschemaname: i16, sztablename: *const u8, cchtablename: i16) -> i16; } ::core::mem::transmute(SQLPrimaryKeys(::core::mem::transmute(hstmt), ::core::mem::transmute(szcatalogname), ::core::mem::transmute(cchcatalogname), ::core::mem::transmute(szschemaname), ::core::mem::transmute(cchschemaname), ::core::mem::transmute(sztablename), ::core::mem::transmute(cchtablename))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLPrimaryKeysA(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u8, cbcatalogname: i16, szschemaname: *const u8, cbschemaname: i16, sztablename: *const u8, cbtablename: i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLPrimaryKeysA(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u8, cbcatalogname: i16, szschemaname: *const u8, cbschemaname: i16, sztablename: *const u8, cbtablename: i16) -> i16; } ::core::mem::transmute(SQLPrimaryKeysA(::core::mem::transmute(hstmt), ::core::mem::transmute(szcatalogname), ::core::mem::transmute(cbcatalogname), ::core::mem::transmute(szschemaname), ::core::mem::transmute(cbschemaname), ::core::mem::transmute(sztablename), ::core::mem::transmute(cbtablename))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLPrimaryKeysW(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u16, cchcatalogname: i16, szschemaname: *const u16, cchschemaname: i16, sztablename: *const u16, cchtablename: i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLPrimaryKeysW(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u16, cchcatalogname: i16, szschemaname: *const u16, cchschemaname: i16, sztablename: *const u16, cchtablename: i16) -> i16; } ::core::mem::transmute(SQLPrimaryKeysW(::core::mem::transmute(hstmt), ::core::mem::transmute(szcatalogname), ::core::mem::transmute(cchcatalogname), ::core::mem::transmute(szschemaname), ::core::mem::transmute(cchschemaname), ::core::mem::transmute(sztablename), ::core::mem::transmute(cchtablename))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLProcedureColumns(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u8, cchcatalogname: i16, szschemaname: *const u8, cchschemaname: i16, szprocname: *const u8, cchprocname: i16, szcolumnname: *const u8, cchcolumnname: i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLProcedureColumns(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u8, cchcatalogname: i16, szschemaname: *const u8, cchschemaname: i16, szprocname: *const u8, cchprocname: i16, szcolumnname: *const u8, cchcolumnname: i16) -> i16; } ::core::mem::transmute(SQLProcedureColumns( ::core::mem::transmute(hstmt), ::core::mem::transmute(szcatalogname), ::core::mem::transmute(cchcatalogname), ::core::mem::transmute(szschemaname), ::core::mem::transmute(cchschemaname), ::core::mem::transmute(szprocname), ::core::mem::transmute(cchprocname), ::core::mem::transmute(szcolumnname), ::core::mem::transmute(cchcolumnname), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLProcedureColumnsA(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u8, cbcatalogname: i16, szschemaname: *const u8, cbschemaname: i16, szprocname: *const u8, cbprocname: i16, szcolumnname: *const u8, cbcolumnname: i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLProcedureColumnsA(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u8, cbcatalogname: i16, szschemaname: *const u8, cbschemaname: i16, szprocname: *const u8, cbprocname: i16, szcolumnname: *const u8, cbcolumnname: i16) -> i16; } ::core::mem::transmute(SQLProcedureColumnsA( ::core::mem::transmute(hstmt), ::core::mem::transmute(szcatalogname), ::core::mem::transmute(cbcatalogname), ::core::mem::transmute(szschemaname), ::core::mem::transmute(cbschemaname), ::core::mem::transmute(szprocname), ::core::mem::transmute(cbprocname), ::core::mem::transmute(szcolumnname), ::core::mem::transmute(cbcolumnname), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLProcedureColumnsW(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u16, cchcatalogname: i16, szschemaname: *const u16, cchschemaname: i16, szprocname: *const u16, cchprocname: i16, szcolumnname: *const u16, cchcolumnname: i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLProcedureColumnsW(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u16, cchcatalogname: i16, szschemaname: *const u16, cchschemaname: i16, szprocname: *const u16, cchprocname: i16, szcolumnname: *const u16, cchcolumnname: i16) -> i16; } ::core::mem::transmute(SQLProcedureColumnsW( ::core::mem::transmute(hstmt), ::core::mem::transmute(szcatalogname), ::core::mem::transmute(cchcatalogname), ::core::mem::transmute(szschemaname), ::core::mem::transmute(cchschemaname), ::core::mem::transmute(szprocname), ::core::mem::transmute(cchprocname), ::core::mem::transmute(szcolumnname), ::core::mem::transmute(cchcolumnname), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLProcedures(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u8, cchcatalogname: i16, szschemaname: *const u8, cchschemaname: i16, szprocname: *const u8, cchprocname: i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLProcedures(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u8, cchcatalogname: i16, szschemaname: *const u8, cchschemaname: i16, szprocname: *const u8, cchprocname: i16) -> i16; } ::core::mem::transmute(SQLProcedures(::core::mem::transmute(hstmt), ::core::mem::transmute(szcatalogname), ::core::mem::transmute(cchcatalogname), ::core::mem::transmute(szschemaname), ::core::mem::transmute(cchschemaname), ::core::mem::transmute(szprocname), ::core::mem::transmute(cchprocname))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLProceduresA(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u8, cbcatalogname: i16, szschemaname: *const u8, cbschemaname: i16, szprocname: *const u8, cbprocname: i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLProceduresA(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u8, cbcatalogname: i16, szschemaname: *const u8, cbschemaname: i16, szprocname: *const u8, cbprocname: i16) -> i16; } ::core::mem::transmute(SQLProceduresA(::core::mem::transmute(hstmt), ::core::mem::transmute(szcatalogname), ::core::mem::transmute(cbcatalogname), ::core::mem::transmute(szschemaname), ::core::mem::transmute(cbschemaname), ::core::mem::transmute(szprocname), ::core::mem::transmute(cbprocname))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLProceduresW(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u16, cchcatalogname: i16, szschemaname: *const u16, cchschemaname: i16, szprocname: *const u16, cchprocname: i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLProceduresW(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u16, cchcatalogname: i16, szschemaname: *const u16, cchschemaname: i16, szprocname: *const u16, cchprocname: i16) -> i16; } ::core::mem::transmute(SQLProceduresW(::core::mem::transmute(hstmt), ::core::mem::transmute(szcatalogname), ::core::mem::transmute(cchcatalogname), ::core::mem::transmute(szschemaname), ::core::mem::transmute(cchschemaname), ::core::mem::transmute(szprocname), ::core::mem::transmute(cchprocname))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[inline] pub unsafe fn SQLPutData(statementhandle: *mut ::core::ffi::c_void, data: *const ::core::ffi::c_void, strlen_or_ind: i64) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLPutData(statementhandle: *mut ::core::ffi::c_void, data: *const ::core::ffi::c_void, strlen_or_ind: i64) -> i16; } ::core::mem::transmute(SQLPutData(::core::mem::transmute(statementhandle), ::core::mem::transmute(data), ::core::mem::transmute(strlen_or_ind))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86",))] #[inline] pub unsafe fn SQLPutData(statementhandle: *mut ::core::ffi::c_void, data: *const ::core::ffi::c_void, strlen_or_ind: i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLPutData(statementhandle: *mut ::core::ffi::c_void, data: *const ::core::ffi::c_void, strlen_or_ind: i32) -> i16; } ::core::mem::transmute(SQLPutData(::core::mem::transmute(statementhandle), ::core::mem::transmute(data), ::core::mem::transmute(strlen_or_ind))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[inline] pub unsafe fn SQLRowCount(statementhandle: *const ::core::ffi::c_void, rowcount: *mut i64) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLRowCount(statementhandle: *const ::core::ffi::c_void, rowcount: *mut i64) -> i16; } ::core::mem::transmute(SQLRowCount(::core::mem::transmute(statementhandle), ::core::mem::transmute(rowcount))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86",))] #[inline] pub unsafe fn SQLRowCount(statementhandle: *const ::core::ffi::c_void, rowcount: *mut i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLRowCount(statementhandle: *const ::core::ffi::c_void, rowcount: *mut i32) -> i16; } ::core::mem::transmute(SQLRowCount(::core::mem::transmute(statementhandle), ::core::mem::transmute(rowcount))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLSetConnectAttr(connectionhandle: *mut ::core::ffi::c_void, attribute: i32, value: *const ::core::ffi::c_void, stringlength: i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLSetConnectAttr(connectionhandle: *mut ::core::ffi::c_void, attribute: i32, value: *const ::core::ffi::c_void, stringlength: i32) -> i16; } ::core::mem::transmute(SQLSetConnectAttr(::core::mem::transmute(connectionhandle), ::core::mem::transmute(attribute), ::core::mem::transmute(value), ::core::mem::transmute(stringlength))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLSetConnectAttrA(hdbc: *mut ::core::ffi::c_void, fattribute: i32, rgbvalue: *const ::core::ffi::c_void, cbvalue: i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLSetConnectAttrA(hdbc: *mut ::core::ffi::c_void, fattribute: i32, rgbvalue: *const ::core::ffi::c_void, cbvalue: i32) -> i16; } ::core::mem::transmute(SQLSetConnectAttrA(::core::mem::transmute(hdbc), ::core::mem::transmute(fattribute), ::core::mem::transmute(rgbvalue), ::core::mem::transmute(cbvalue))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLSetConnectAttrW(hdbc: *mut ::core::ffi::c_void, fattribute: i32, rgbvalue: *const ::core::ffi::c_void, cbvalue: i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLSetConnectAttrW(hdbc: *mut ::core::ffi::c_void, fattribute: i32, rgbvalue: *const ::core::ffi::c_void, cbvalue: i32) -> i16; } ::core::mem::transmute(SQLSetConnectAttrW(::core::mem::transmute(hdbc), ::core::mem::transmute(fattribute), ::core::mem::transmute(rgbvalue), ::core::mem::transmute(cbvalue))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[inline] pub unsafe fn SQLSetConnectOption(connectionhandle: *mut ::core::ffi::c_void, option: u16, value: u64) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLSetConnectOption(connectionhandle: *mut ::core::ffi::c_void, option: u16, value: u64) -> i16; } ::core::mem::transmute(SQLSetConnectOption(::core::mem::transmute(connectionhandle), ::core::mem::transmute(option), ::core::mem::transmute(value))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86",))] #[inline] pub unsafe fn SQLSetConnectOption(connectionhandle: *mut ::core::ffi::c_void, option: u16, value: u32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLSetConnectOption(connectionhandle: *mut ::core::ffi::c_void, option: u16, value: u32) -> i16; } ::core::mem::transmute(SQLSetConnectOption(::core::mem::transmute(connectionhandle), ::core::mem::transmute(option), ::core::mem::transmute(value))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[inline] pub unsafe fn SQLSetConnectOptionA(hdbc: *mut ::core::ffi::c_void, foption: u16, vparam: u64) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLSetConnectOptionA(hdbc: *mut ::core::ffi::c_void, foption: u16, vparam: u64) -> i16; } ::core::mem::transmute(SQLSetConnectOptionA(::core::mem::transmute(hdbc), ::core::mem::transmute(foption), ::core::mem::transmute(vparam))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86",))] #[inline] pub unsafe fn SQLSetConnectOptionA(hdbc: *mut ::core::ffi::c_void, foption: u16, vparam: u32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLSetConnectOptionA(hdbc: *mut ::core::ffi::c_void, foption: u16, vparam: u32) -> i16; } ::core::mem::transmute(SQLSetConnectOptionA(::core::mem::transmute(hdbc), ::core::mem::transmute(foption), ::core::mem::transmute(vparam))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[inline] pub unsafe fn SQLSetConnectOptionW(hdbc: *mut ::core::ffi::c_void, foption: u16, vparam: u64) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLSetConnectOptionW(hdbc: *mut ::core::ffi::c_void, foption: u16, vparam: u64) -> i16; } ::core::mem::transmute(SQLSetConnectOptionW(::core::mem::transmute(hdbc), ::core::mem::transmute(foption), ::core::mem::transmute(vparam))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86",))] #[inline] pub unsafe fn SQLSetConnectOptionW(hdbc: *mut ::core::ffi::c_void, foption: u16, vparam: u32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLSetConnectOptionW(hdbc: *mut ::core::ffi::c_void, foption: u16, vparam: u32) -> i16; } ::core::mem::transmute(SQLSetConnectOptionW(::core::mem::transmute(hdbc), ::core::mem::transmute(foption), ::core::mem::transmute(vparam))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLSetCursorName(statementhandle: *mut ::core::ffi::c_void, cursorname: *const u8, namelength: i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLSetCursorName(statementhandle: *mut ::core::ffi::c_void, cursorname: *const u8, namelength: i16) -> i16; } ::core::mem::transmute(SQLSetCursorName(::core::mem::transmute(statementhandle), ::core::mem::transmute(cursorname), ::core::mem::transmute(namelength))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLSetCursorNameA(hstmt: *mut ::core::ffi::c_void, szcursor: *const u8, cbcursor: i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLSetCursorNameA(hstmt: *mut ::core::ffi::c_void, szcursor: *const u8, cbcursor: i16) -> i16; } ::core::mem::transmute(SQLSetCursorNameA(::core::mem::transmute(hstmt), ::core::mem::transmute(szcursor), ::core::mem::transmute(cbcursor))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLSetCursorNameW(hstmt: *mut ::core::ffi::c_void, szcursor: *const u16, cchcursor: i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLSetCursorNameW(hstmt: *mut ::core::ffi::c_void, szcursor: *const u16, cchcursor: i16) -> i16; } ::core::mem::transmute(SQLSetCursorNameW(::core::mem::transmute(hstmt), ::core::mem::transmute(szcursor), ::core::mem::transmute(cchcursor))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLSetDescField(descriptorhandle: *mut ::core::ffi::c_void, recnumber: i16, fieldidentifier: i16, value: *const ::core::ffi::c_void, bufferlength: i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLSetDescField(descriptorhandle: *mut ::core::ffi::c_void, recnumber: i16, fieldidentifier: i16, value: *const ::core::ffi::c_void, bufferlength: i32) -> i16; } ::core::mem::transmute(SQLSetDescField(::core::mem::transmute(descriptorhandle), ::core::mem::transmute(recnumber), ::core::mem::transmute(fieldidentifier), ::core::mem::transmute(value), ::core::mem::transmute(bufferlength))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLSetDescFieldW(descriptorhandle: *mut ::core::ffi::c_void, recnumber: i16, fieldidentifier: i16, value: *mut ::core::ffi::c_void, bufferlength: i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLSetDescFieldW(descriptorhandle: *mut ::core::ffi::c_void, recnumber: i16, fieldidentifier: i16, value: *mut ::core::ffi::c_void, bufferlength: i32) -> i16; } ::core::mem::transmute(SQLSetDescFieldW(::core::mem::transmute(descriptorhandle), ::core::mem::transmute(recnumber), ::core::mem::transmute(fieldidentifier), ::core::mem::transmute(value), ::core::mem::transmute(bufferlength))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[inline] pub unsafe fn SQLSetDescRec(descriptorhandle: *mut ::core::ffi::c_void, recnumber: i16, r#type: i16, subtype: i16, length: i64, precision: i16, scale: i16, data: *mut ::core::ffi::c_void, stringlength: *mut i64, indicator: *mut i64) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLSetDescRec(descriptorhandle: *mut ::core::ffi::c_void, recnumber: i16, r#type: i16, subtype: i16, length: i64, precision: i16, scale: i16, data: *mut ::core::ffi::c_void, stringlength: *mut i64, indicator: *mut i64) -> i16; } ::core::mem::transmute(SQLSetDescRec( ::core::mem::transmute(descriptorhandle), ::core::mem::transmute(recnumber), ::core::mem::transmute(r#type), ::core::mem::transmute(subtype), ::core::mem::transmute(length), ::core::mem::transmute(precision), ::core::mem::transmute(scale), ::core::mem::transmute(data), ::core::mem::transmute(stringlength), ::core::mem::transmute(indicator), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86",))] #[inline] pub unsafe fn SQLSetDescRec(descriptorhandle: *mut ::core::ffi::c_void, recnumber: i16, r#type: i16, subtype: i16, length: i32, precision: i16, scale: i16, data: *mut ::core::ffi::c_void, stringlength: *mut i32, indicator: *mut i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLSetDescRec(descriptorhandle: *mut ::core::ffi::c_void, recnumber: i16, r#type: i16, subtype: i16, length: i32, precision: i16, scale: i16, data: *mut ::core::ffi::c_void, stringlength: *mut i32, indicator: *mut i32) -> i16; } ::core::mem::transmute(SQLSetDescRec( ::core::mem::transmute(descriptorhandle), ::core::mem::transmute(recnumber), ::core::mem::transmute(r#type), ::core::mem::transmute(subtype), ::core::mem::transmute(length), ::core::mem::transmute(precision), ::core::mem::transmute(scale), ::core::mem::transmute(data), ::core::mem::transmute(stringlength), ::core::mem::transmute(indicator), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLSetEnvAttr(environmenthandle: *mut ::core::ffi::c_void, attribute: i32, value: *const ::core::ffi::c_void, stringlength: i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLSetEnvAttr(environmenthandle: *mut ::core::ffi::c_void, attribute: i32, value: *const ::core::ffi::c_void, stringlength: i32) -> i16; } ::core::mem::transmute(SQLSetEnvAttr(::core::mem::transmute(environmenthandle), ::core::mem::transmute(attribute), ::core::mem::transmute(value), ::core::mem::transmute(stringlength))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[inline] pub unsafe fn SQLSetParam(statementhandle: *mut ::core::ffi::c_void, parameternumber: u16, valuetype: i16, parametertype: i16, lengthprecision: u64, parameterscale: i16, parametervalue: *const ::core::ffi::c_void, strlen_or_ind: *mut i64) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLSetParam(statementhandle: *mut ::core::ffi::c_void, parameternumber: u16, valuetype: i16, parametertype: i16, lengthprecision: u64, parameterscale: i16, parametervalue: *const ::core::ffi::c_void, strlen_or_ind: *mut i64) -> i16; } ::core::mem::transmute(SQLSetParam( ::core::mem::transmute(statementhandle), ::core::mem::transmute(parameternumber), ::core::mem::transmute(valuetype), ::core::mem::transmute(parametertype), ::core::mem::transmute(lengthprecision), ::core::mem::transmute(parameterscale), ::core::mem::transmute(parametervalue), ::core::mem::transmute(strlen_or_ind), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86",))] #[inline] pub unsafe fn SQLSetParam(statementhandle: *mut ::core::ffi::c_void, parameternumber: u16, valuetype: i16, parametertype: i16, lengthprecision: u32, parameterscale: i16, parametervalue: *const ::core::ffi::c_void, strlen_or_ind: *mut i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLSetParam(statementhandle: *mut ::core::ffi::c_void, parameternumber: u16, valuetype: i16, parametertype: i16, lengthprecision: u32, parameterscale: i16, parametervalue: *const ::core::ffi::c_void, strlen_or_ind: *mut i32) -> i16; } ::core::mem::transmute(SQLSetParam( ::core::mem::transmute(statementhandle), ::core::mem::transmute(parameternumber), ::core::mem::transmute(valuetype), ::core::mem::transmute(parametertype), ::core::mem::transmute(lengthprecision), ::core::mem::transmute(parameterscale), ::core::mem::transmute(parametervalue), ::core::mem::transmute(strlen_or_ind), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[inline] pub unsafe fn SQLSetPos(hstmt: *mut ::core::ffi::c_void, irow: u64, foption: u16, flock: u16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLSetPos(hstmt: *mut ::core::ffi::c_void, irow: u64, foption: u16, flock: u16) -> i16; } ::core::mem::transmute(SQLSetPos(::core::mem::transmute(hstmt), ::core::mem::transmute(irow), ::core::mem::transmute(foption), ::core::mem::transmute(flock))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86",))] #[inline] pub unsafe fn SQLSetPos(hstmt: *mut ::core::ffi::c_void, irow: u16, foption: u16, flock: u16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLSetPos(hstmt: *mut ::core::ffi::c_void, irow: u16, foption: u16, flock: u16) -> i16; } ::core::mem::transmute(SQLSetPos(::core::mem::transmute(hstmt), ::core::mem::transmute(irow), ::core::mem::transmute(foption), ::core::mem::transmute(flock))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[inline] pub unsafe fn SQLSetScrollOptions(hstmt: *mut ::core::ffi::c_void, fconcurrency: u16, crowkeyset: i64, crowrowset: u16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLSetScrollOptions(hstmt: *mut ::core::ffi::c_void, fconcurrency: u16, crowkeyset: i64, crowrowset: u16) -> i16; } ::core::mem::transmute(SQLSetScrollOptions(::core::mem::transmute(hstmt), ::core::mem::transmute(fconcurrency), ::core::mem::transmute(crowkeyset), ::core::mem::transmute(crowrowset))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86",))] #[inline] pub unsafe fn SQLSetScrollOptions(hstmt: *mut ::core::ffi::c_void, fconcurrency: u16, crowkeyset: i32, crowrowset: u16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLSetScrollOptions(hstmt: *mut ::core::ffi::c_void, fconcurrency: u16, crowkeyset: i32, crowrowset: u16) -> i16; } ::core::mem::transmute(SQLSetScrollOptions(::core::mem::transmute(hstmt), ::core::mem::transmute(fconcurrency), ::core::mem::transmute(crowkeyset), ::core::mem::transmute(crowrowset))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLSetStmtAttr(statementhandle: *mut ::core::ffi::c_void, attribute: i32, value: *const ::core::ffi::c_void, stringlength: i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLSetStmtAttr(statementhandle: *mut ::core::ffi::c_void, attribute: i32, value: *const ::core::ffi::c_void, stringlength: i32) -> i16; } ::core::mem::transmute(SQLSetStmtAttr(::core::mem::transmute(statementhandle), ::core::mem::transmute(attribute), ::core::mem::transmute(value), ::core::mem::transmute(stringlength))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLSetStmtAttrW(hstmt: *mut ::core::ffi::c_void, fattribute: i32, rgbvalue: *mut ::core::ffi::c_void, cbvaluemax: i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLSetStmtAttrW(hstmt: *mut ::core::ffi::c_void, fattribute: i32, rgbvalue: *mut ::core::ffi::c_void, cbvaluemax: i32) -> i16; } ::core::mem::transmute(SQLSetStmtAttrW(::core::mem::transmute(hstmt), ::core::mem::transmute(fattribute), ::core::mem::transmute(rgbvalue), ::core::mem::transmute(cbvaluemax))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] #[inline] pub unsafe fn SQLSetStmtOption(statementhandle: *mut ::core::ffi::c_void, option: u16, value: u64) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLSetStmtOption(statementhandle: *mut ::core::ffi::c_void, option: u16, value: u64) -> i16; } ::core::mem::transmute(SQLSetStmtOption(::core::mem::transmute(statementhandle), ::core::mem::transmute(option), ::core::mem::transmute(value))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(any(target_arch = "x86",))] #[inline] pub unsafe fn SQLSetStmtOption(statementhandle: *mut ::core::ffi::c_void, option: u16, value: u32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLSetStmtOption(statementhandle: *mut ::core::ffi::c_void, option: u16, value: u32) -> i16; } ::core::mem::transmute(SQLSetStmtOption(::core::mem::transmute(statementhandle), ::core::mem::transmute(option), ::core::mem::transmute(value))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLSpecialColumns(statementhandle: *mut ::core::ffi::c_void, identifiertype: u16, catalogname: *const u8, namelength1: i16, schemaname: *const u8, namelength2: i16, tablename: *const u8, namelength3: i16, scope: u16, nullable: u16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLSpecialColumns(statementhandle: *mut ::core::ffi::c_void, identifiertype: u16, catalogname: *const u8, namelength1: i16, schemaname: *const u8, namelength2: i16, tablename: *const u8, namelength3: i16, scope: u16, nullable: u16) -> i16; } ::core::mem::transmute(SQLSpecialColumns( ::core::mem::transmute(statementhandle), ::core::mem::transmute(identifiertype), ::core::mem::transmute(catalogname), ::core::mem::transmute(namelength1), ::core::mem::transmute(schemaname), ::core::mem::transmute(namelength2), ::core::mem::transmute(tablename), ::core::mem::transmute(namelength3), ::core::mem::transmute(scope), ::core::mem::transmute(nullable), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLSpecialColumnsA(hstmt: *mut ::core::ffi::c_void, fcoltype: u16, szcatalogname: *const u8, cbcatalogname: i16, szschemaname: *const u8, cbschemaname: i16, sztablename: *const u8, cbtablename: i16, fscope: u16, fnullable: u16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLSpecialColumnsA(hstmt: *mut ::core::ffi::c_void, fcoltype: u16, szcatalogname: *const u8, cbcatalogname: i16, szschemaname: *const u8, cbschemaname: i16, sztablename: *const u8, cbtablename: i16, fscope: u16, fnullable: u16) -> i16; } ::core::mem::transmute(SQLSpecialColumnsA( ::core::mem::transmute(hstmt), ::core::mem::transmute(fcoltype), ::core::mem::transmute(szcatalogname), ::core::mem::transmute(cbcatalogname), ::core::mem::transmute(szschemaname), ::core::mem::transmute(cbschemaname), ::core::mem::transmute(sztablename), ::core::mem::transmute(cbtablename), ::core::mem::transmute(fscope), ::core::mem::transmute(fnullable), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLSpecialColumnsW(hstmt: *mut ::core::ffi::c_void, fcoltype: u16, szcatalogname: *const u16, cchcatalogname: i16, szschemaname: *const u16, cchschemaname: i16, sztablename: *const u16, cchtablename: i16, fscope: u16, fnullable: u16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLSpecialColumnsW(hstmt: *mut ::core::ffi::c_void, fcoltype: u16, szcatalogname: *const u16, cchcatalogname: i16, szschemaname: *const u16, cchschemaname: i16, sztablename: *const u16, cchtablename: i16, fscope: u16, fnullable: u16) -> i16; } ::core::mem::transmute(SQLSpecialColumnsW( ::core::mem::transmute(hstmt), ::core::mem::transmute(fcoltype), ::core::mem::transmute(szcatalogname), ::core::mem::transmute(cchcatalogname), ::core::mem::transmute(szschemaname), ::core::mem::transmute(cchschemaname), ::core::mem::transmute(sztablename), ::core::mem::transmute(cchtablename), ::core::mem::transmute(fscope), ::core::mem::transmute(fnullable), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLStatistics(statementhandle: *mut ::core::ffi::c_void, catalogname: *const u8, namelength1: i16, schemaname: *const u8, namelength2: i16, tablename: *const u8, namelength3: i16, unique: u16, reserved: u16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLStatistics(statementhandle: *mut ::core::ffi::c_void, catalogname: *const u8, namelength1: i16, schemaname: *const u8, namelength2: i16, tablename: *const u8, namelength3: i16, unique: u16, reserved: u16) -> i16; } ::core::mem::transmute(SQLStatistics( ::core::mem::transmute(statementhandle), ::core::mem::transmute(catalogname), ::core::mem::transmute(namelength1), ::core::mem::transmute(schemaname), ::core::mem::transmute(namelength2), ::core::mem::transmute(tablename), ::core::mem::transmute(namelength3), ::core::mem::transmute(unique), ::core::mem::transmute(reserved), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLStatisticsA(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u8, cbcatalogname: i16, szschemaname: *const u8, cbschemaname: i16, sztablename: *const u8, cbtablename: i16, funique: u16, faccuracy: u16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLStatisticsA(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u8, cbcatalogname: i16, szschemaname: *const u8, cbschemaname: i16, sztablename: *const u8, cbtablename: i16, funique: u16, faccuracy: u16) -> i16; } ::core::mem::transmute(SQLStatisticsA( ::core::mem::transmute(hstmt), ::core::mem::transmute(szcatalogname), ::core::mem::transmute(cbcatalogname), ::core::mem::transmute(szschemaname), ::core::mem::transmute(cbschemaname), ::core::mem::transmute(sztablename), ::core::mem::transmute(cbtablename), ::core::mem::transmute(funique), ::core::mem::transmute(faccuracy), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLStatisticsW(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u16, cchcatalogname: i16, szschemaname: *const u16, cchschemaname: i16, sztablename: *const u16, cchtablename: i16, funique: u16, faccuracy: u16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLStatisticsW(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u16, cchcatalogname: i16, szschemaname: *const u16, cchschemaname: i16, sztablename: *const u16, cchtablename: i16, funique: u16, faccuracy: u16) -> i16; } ::core::mem::transmute(SQLStatisticsW( ::core::mem::transmute(hstmt), ::core::mem::transmute(szcatalogname), ::core::mem::transmute(cchcatalogname), ::core::mem::transmute(szschemaname), ::core::mem::transmute(cchschemaname), ::core::mem::transmute(sztablename), ::core::mem::transmute(cchtablename), ::core::mem::transmute(funique), ::core::mem::transmute(faccuracy), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } pub const SQLTEXT: u32 = 35u32; #[inline] pub unsafe fn SQLTablePrivileges(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u8, cchcatalogname: i16, szschemaname: *const u8, cchschemaname: i16, sztablename: *const u8, cchtablename: i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLTablePrivileges(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u8, cchcatalogname: i16, szschemaname: *const u8, cchschemaname: i16, sztablename: *const u8, cchtablename: i16) -> i16; } ::core::mem::transmute(SQLTablePrivileges(::core::mem::transmute(hstmt), ::core::mem::transmute(szcatalogname), ::core::mem::transmute(cchcatalogname), ::core::mem::transmute(szschemaname), ::core::mem::transmute(cchschemaname), ::core::mem::transmute(sztablename), ::core::mem::transmute(cchtablename))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLTablePrivilegesA(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u8, cbcatalogname: i16, szschemaname: *const u8, cbschemaname: i16, sztablename: *const u8, cbtablename: i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLTablePrivilegesA(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u8, cbcatalogname: i16, szschemaname: *const u8, cbschemaname: i16, sztablename: *const u8, cbtablename: i16) -> i16; } ::core::mem::transmute(SQLTablePrivilegesA(::core::mem::transmute(hstmt), ::core::mem::transmute(szcatalogname), ::core::mem::transmute(cbcatalogname), ::core::mem::transmute(szschemaname), ::core::mem::transmute(cbschemaname), ::core::mem::transmute(sztablename), ::core::mem::transmute(cbtablename))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLTablePrivilegesW(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u16, cchcatalogname: i16, szschemaname: *const u16, cchschemaname: i16, sztablename: *const u16, cchtablename: i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLTablePrivilegesW(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u16, cchcatalogname: i16, szschemaname: *const u16, cchschemaname: i16, sztablename: *const u16, cchtablename: i16) -> i16; } ::core::mem::transmute(SQLTablePrivilegesW(::core::mem::transmute(hstmt), ::core::mem::transmute(szcatalogname), ::core::mem::transmute(cchcatalogname), ::core::mem::transmute(szschemaname), ::core::mem::transmute(cchschemaname), ::core::mem::transmute(sztablename), ::core::mem::transmute(cchtablename))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLTables(statementhandle: *mut ::core::ffi::c_void, catalogname: *const u8, namelength1: i16, schemaname: *const u8, namelength2: i16, tablename: *const u8, namelength3: i16, tabletype: *const u8, namelength4: i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLTables(statementhandle: *mut ::core::ffi::c_void, catalogname: *const u8, namelength1: i16, schemaname: *const u8, namelength2: i16, tablename: *const u8, namelength3: i16, tabletype: *const u8, namelength4: i16) -> i16; } ::core::mem::transmute(SQLTables( ::core::mem::transmute(statementhandle), ::core::mem::transmute(catalogname), ::core::mem::transmute(namelength1), ::core::mem::transmute(schemaname), ::core::mem::transmute(namelength2), ::core::mem::transmute(tablename), ::core::mem::transmute(namelength3), ::core::mem::transmute(tabletype), ::core::mem::transmute(namelength4), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLTablesA(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u8, cbcatalogname: i16, szschemaname: *const u8, cbschemaname: i16, sztablename: *const u8, cbtablename: i16, sztabletype: *const u8, cbtabletype: i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLTablesA(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u8, cbcatalogname: i16, szschemaname: *const u8, cbschemaname: i16, sztablename: *const u8, cbtablename: i16, sztabletype: *const u8, cbtabletype: i16) -> i16; } ::core::mem::transmute(SQLTablesA( ::core::mem::transmute(hstmt), ::core::mem::transmute(szcatalogname), ::core::mem::transmute(cbcatalogname), ::core::mem::transmute(szschemaname), ::core::mem::transmute(cbschemaname), ::core::mem::transmute(sztablename), ::core::mem::transmute(cbtablename), ::core::mem::transmute(sztabletype), ::core::mem::transmute(cbtabletype), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLTablesW(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u16, cchcatalogname: i16, szschemaname: *const u16, cchschemaname: i16, sztablename: *const u16, cchtablename: i16, sztabletype: *const u16, cchtabletype: i16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLTablesW(hstmt: *mut ::core::ffi::c_void, szcatalogname: *const u16, cchcatalogname: i16, szschemaname: *const u16, cchschemaname: i16, sztablename: *const u16, cchtablename: i16, sztabletype: *const u16, cchtabletype: i16) -> i16; } ::core::mem::transmute(SQLTablesW( ::core::mem::transmute(hstmt), ::core::mem::transmute(szcatalogname), ::core::mem::transmute(cchcatalogname), ::core::mem::transmute(szschemaname), ::core::mem::transmute(cchschemaname), ::core::mem::transmute(sztablename), ::core::mem::transmute(cchtablename), ::core::mem::transmute(sztabletype), ::core::mem::transmute(cchtabletype), )) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn SQLTransact(environmenthandle: *mut ::core::ffi::c_void, connectionhandle: *mut ::core::ffi::c_void, completiontype: u16) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn SQLTransact(environmenthandle: *mut ::core::ffi::c_void, connectionhandle: *mut ::core::ffi::c_void, completiontype: u16) -> i16; } ::core::mem::transmute(SQLTransact(::core::mem::transmute(environmenthandle), ::core::mem::transmute(connectionhandle), ::core::mem::transmute(completiontype))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } pub const SQLUNIQUEID: u32 = 36u32; pub const SQLVARBINARY: u32 = 37u32; pub const SQLVARCHAR: u32 = 39u32; #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct SQLVARENUM(pub i32); pub const VT_SS_EMPTY: SQLVARENUM = SQLVARENUM(0i32); pub const VT_SS_NULL: SQLVARENUM = SQLVARENUM(1i32); pub const VT_SS_UI1: SQLVARENUM = SQLVARENUM(17i32); pub const VT_SS_I2: SQLVARENUM = SQLVARENUM(2i32); pub const VT_SS_I4: SQLVARENUM = SQLVARENUM(3i32); pub const VT_SS_I8: SQLVARENUM = SQLVARENUM(20i32); pub const VT_SS_R4: SQLVARENUM = SQLVARENUM(4i32); pub const VT_SS_R8: SQLVARENUM = SQLVARENUM(5i32); pub const VT_SS_MONEY: SQLVARENUM = SQLVARENUM(6i32); pub const VT_SS_SMALLMONEY: SQLVARENUM = SQLVARENUM(200i32); pub const VT_SS_WSTRING: SQLVARENUM = SQLVARENUM(201i32); pub const VT_SS_WVARSTRING: SQLVARENUM = SQLVARENUM(202i32); pub const VT_SS_STRING: SQLVARENUM = SQLVARENUM(203i32); pub const VT_SS_VARSTRING: SQLVARENUM = SQLVARENUM(204i32); pub const VT_SS_BIT: SQLVARENUM = SQLVARENUM(11i32); pub const VT_SS_GUID: SQLVARENUM = SQLVARENUM(72i32); pub const VT_SS_NUMERIC: SQLVARENUM = SQLVARENUM(131i32); pub const VT_SS_DECIMAL: SQLVARENUM = SQLVARENUM(205i32); pub const VT_SS_DATETIME: SQLVARENUM = SQLVARENUM(135i32); pub const VT_SS_SMALLDATETIME: SQLVARENUM = SQLVARENUM(206i32); pub const VT_SS_BINARY: SQLVARENUM = SQLVARENUM(207i32); pub const VT_SS_VARBINARY: SQLVARENUM = SQLVARENUM(208i32); pub const VT_SS_UNKNOWN: SQLVARENUM = SQLVARENUM(209i32); impl ::core::convert::From<i32> for SQLVARENUM { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for SQLVARENUM { type Abi = Self; } pub const SQLVARIANT: u32 = 98u32; pub const SQL_AA_FALSE: i32 = 0i32; pub const SQL_AA_TRUE: i32 = 1i32; pub const SQL_ACCESSIBLE_PROCEDURES: u32 = 20u32; pub const SQL_ACCESSIBLE_TABLES: u32 = 19u32; pub const SQL_ACCESS_MODE: u32 = 101u32; pub const SQL_ACTIVE_CONNECTIONS: u32 = 0u32; pub const SQL_ACTIVE_ENVIRONMENTS: u32 = 116u32; pub const SQL_ACTIVE_STATEMENTS: u32 = 1u32; pub const SQL_ADD: u32 = 4u32; pub const SQL_AD_ADD_CONSTRAINT_DEFERRABLE: i32 = 128i32; pub const SQL_AD_ADD_CONSTRAINT_INITIALLY_DEFERRED: i32 = 32i32; pub const SQL_AD_ADD_CONSTRAINT_INITIALLY_IMMEDIATE: i32 = 64i32; pub const SQL_AD_ADD_CONSTRAINT_NON_DEFERRABLE: i32 = 256i32; pub const SQL_AD_ADD_DOMAIN_CONSTRAINT: i32 = 2i32; pub const SQL_AD_ADD_DOMAIN_DEFAULT: i32 = 8i32; pub const SQL_AD_CONSTRAINT_NAME_DEFINITION: i32 = 1i32; pub const SQL_AD_DEFAULT: i32 = 1i32; pub const SQL_AD_DROP_DOMAIN_CONSTRAINT: i32 = 4i32; pub const SQL_AD_DROP_DOMAIN_DEFAULT: i32 = 16i32; pub const SQL_AD_OFF: i32 = 0i32; pub const SQL_AD_ON: i32 = 1i32; pub const SQL_AF_ALL: i32 = 64i32; pub const SQL_AF_AVG: i32 = 1i32; pub const SQL_AF_COUNT: i32 = 2i32; pub const SQL_AF_DISTINCT: i32 = 32i32; pub const SQL_AF_MAX: i32 = 4i32; pub const SQL_AF_MIN: i32 = 8i32; pub const SQL_AF_SUM: i32 = 16i32; pub const SQL_AGGREGATE_FUNCTIONS: u32 = 169u32; pub const SQL_ALL_EXCEPT_LIKE: u32 = 2u32; pub const SQL_ALL_TYPES: u32 = 0u32; pub const SQL_ALTER_DOMAIN: u32 = 117u32; pub const SQL_ALTER_TABLE: u32 = 86u32; pub const SQL_AM_CONNECTION: u32 = 1u32; pub const SQL_AM_NONE: u32 = 0u32; pub const SQL_AM_STATEMENT: u32 = 2u32; pub const SQL_AO_DEFAULT: i32 = 0i32; pub const SQL_AO_OFF: i32 = 0i32; pub const SQL_AO_ON: i32 = 1i32; pub const SQL_APD_TYPE: i32 = -100i32; pub const SQL_API_ALL_FUNCTIONS: u32 = 0u32; pub const SQL_API_LOADBYORDINAL: u32 = 199u32; pub const SQL_API_ODBC3_ALL_FUNCTIONS: u32 = 999u32; pub const SQL_API_ODBC3_ALL_FUNCTIONS_SIZE: u32 = 250u32; pub const SQL_API_SQLALLOCCONNECT: u32 = 1u32; pub const SQL_API_SQLALLOCENV: u32 = 2u32; pub const SQL_API_SQLALLOCHANDLE: u32 = 1001u32; pub const SQL_API_SQLALLOCHANDLESTD: u32 = 73u32; pub const SQL_API_SQLALLOCSTMT: u32 = 3u32; pub const SQL_API_SQLBINDCOL: u32 = 4u32; pub const SQL_API_SQLBINDPARAM: u32 = 1002u32; pub const SQL_API_SQLBINDPARAMETER: u32 = 72u32; pub const SQL_API_SQLBROWSECONNECT: u32 = 55u32; pub const SQL_API_SQLBULKOPERATIONS: u32 = 24u32; pub const SQL_API_SQLCANCEL: u32 = 5u32; pub const SQL_API_SQLCANCELHANDLE: u32 = 1550u32; pub const SQL_API_SQLCLOSECURSOR: u32 = 1003u32; pub const SQL_API_SQLCOLATTRIBUTE: u32 = 6u32; pub const SQL_API_SQLCOLATTRIBUTES: u32 = 6u32; pub const SQL_API_SQLCOLUMNPRIVILEGES: u32 = 56u32; pub const SQL_API_SQLCOLUMNS: u32 = 40u32; pub const SQL_API_SQLCOMPLETEASYNC: u32 = 1551u32; pub const SQL_API_SQLCONNECT: u32 = 7u32; pub const SQL_API_SQLCOPYDESC: u32 = 1004u32; pub const SQL_API_SQLDATASOURCES: u32 = 57u32; pub const SQL_API_SQLDESCRIBECOL: u32 = 8u32; pub const SQL_API_SQLDESCRIBEPARAM: u32 = 58u32; pub const SQL_API_SQLDISCONNECT: u32 = 9u32; pub const SQL_API_SQLDRIVERCONNECT: u32 = 41u32; pub const SQL_API_SQLDRIVERS: u32 = 71u32; pub const SQL_API_SQLENDTRAN: u32 = 1005u32; pub const SQL_API_SQLERROR: u32 = 10u32; pub const SQL_API_SQLEXECDIRECT: u32 = 11u32; pub const SQL_API_SQLEXECUTE: u32 = 12u32; pub const SQL_API_SQLEXTENDEDFETCH: u32 = 59u32; pub const SQL_API_SQLFETCH: u32 = 13u32; pub const SQL_API_SQLFETCHSCROLL: u32 = 1021u32; pub const SQL_API_SQLFOREIGNKEYS: u32 = 60u32; pub const SQL_API_SQLFREECONNECT: u32 = 14u32; pub const SQL_API_SQLFREEENV: u32 = 15u32; pub const SQL_API_SQLFREEHANDLE: u32 = 1006u32; pub const SQL_API_SQLFREESTMT: u32 = 16u32; pub const SQL_API_SQLGETCONNECTATTR: u32 = 1007u32; pub const SQL_API_SQLGETCONNECTOPTION: u32 = 42u32; pub const SQL_API_SQLGETCURSORNAME: u32 = 17u32; pub const SQL_API_SQLGETDATA: u32 = 43u32; pub const SQL_API_SQLGETDESCFIELD: u32 = 1008u32; pub const SQL_API_SQLGETDESCREC: u32 = 1009u32; pub const SQL_API_SQLGETDIAGFIELD: u32 = 1010u32; pub const SQL_API_SQLGETDIAGREC: u32 = 1011u32; pub const SQL_API_SQLGETENVATTR: u32 = 1012u32; pub const SQL_API_SQLGETFUNCTIONS: u32 = 44u32; pub const SQL_API_SQLGETINFO: u32 = 45u32; pub const SQL_API_SQLGETSTMTATTR: u32 = 1014u32; pub const SQL_API_SQLGETSTMTOPTION: u32 = 46u32; pub const SQL_API_SQLGETTYPEINFO: u32 = 47u32; pub const SQL_API_SQLMORERESULTS: u32 = 61u32; pub const SQL_API_SQLNATIVESQL: u32 = 62u32; pub const SQL_API_SQLNUMPARAMS: u32 = 63u32; pub const SQL_API_SQLNUMRESULTCOLS: u32 = 18u32; pub const SQL_API_SQLPARAMDATA: u32 = 48u32; pub const SQL_API_SQLPARAMOPTIONS: u32 = 64u32; pub const SQL_API_SQLPREPARE: u32 = 19u32; pub const SQL_API_SQLPRIMARYKEYS: u32 = 65u32; pub const SQL_API_SQLPRIVATEDRIVERS: u32 = 79u32; pub const SQL_API_SQLPROCEDURECOLUMNS: u32 = 66u32; pub const SQL_API_SQLPROCEDURES: u32 = 67u32; pub const SQL_API_SQLPUTDATA: u32 = 49u32; pub const SQL_API_SQLROWCOUNT: u32 = 20u32; pub const SQL_API_SQLSETCONNECTATTR: u32 = 1016u32; pub const SQL_API_SQLSETCONNECTOPTION: u32 = 50u32; pub const SQL_API_SQLSETCURSORNAME: u32 = 21u32; pub const SQL_API_SQLSETDESCFIELD: u32 = 1017u32; pub const SQL_API_SQLSETDESCREC: u32 = 1018u32; pub const SQL_API_SQLSETENVATTR: u32 = 1019u32; pub const SQL_API_SQLSETPARAM: u32 = 22u32; pub const SQL_API_SQLSETPOS: u32 = 68u32; pub const SQL_API_SQLSETSCROLLOPTIONS: u32 = 69u32; pub const SQL_API_SQLSETSTMTATTR: u32 = 1020u32; pub const SQL_API_SQLSETSTMTOPTION: u32 = 51u32; pub const SQL_API_SQLSPECIALCOLUMNS: u32 = 52u32; pub const SQL_API_SQLSTATISTICS: u32 = 53u32; pub const SQL_API_SQLTABLEPRIVILEGES: u32 = 70u32; pub const SQL_API_SQLTABLES: u32 = 54u32; pub const SQL_API_SQLTRANSACT: u32 = 23u32; pub const SQL_ARD_TYPE: i32 = -99i32; pub const SQL_ASYNC_DBC_CAPABLE: i32 = 1i32; pub const SQL_ASYNC_DBC_ENABLE_DEFAULT: u32 = 0u32; pub const SQL_ASYNC_DBC_ENABLE_OFF: u32 = 0u32; pub const SQL_ASYNC_DBC_ENABLE_ON: u32 = 1u32; pub const SQL_ASYNC_DBC_FUNCTIONS: u32 = 10023u32; pub const SQL_ASYNC_DBC_NOT_CAPABLE: i32 = 0i32; pub const SQL_ASYNC_ENABLE: u32 = 4u32; pub const SQL_ASYNC_ENABLE_DEFAULT: u32 = 0u32; pub const SQL_ASYNC_ENABLE_OFF: u32 = 0u32; pub const SQL_ASYNC_ENABLE_ON: u32 = 1u32; pub const SQL_ASYNC_MODE: u32 = 10021u32; pub const SQL_ASYNC_NOTIFICATION: u32 = 10025u32; #[cfg(feature = "Win32_Foundation")] pub type SQL_ASYNC_NOTIFICATION_CALLBACK = unsafe extern "system" fn(pcontext: *const ::core::ffi::c_void, flast: super::super::Foundation::BOOL) -> i16; pub const SQL_ASYNC_NOTIFICATION_CAPABLE: i32 = 1i32; pub const SQL_ASYNC_NOTIFICATION_NOT_CAPABLE: i32 = 0i32; pub const SQL_ATTR_ACCESS_MODE: u32 = 101u32; pub const SQL_ATTR_ANSI_APP: u32 = 115u32; pub const SQL_ATTR_APPLICATION_KEY: u32 = 203u32; pub const SQL_ATTR_APP_PARAM_DESC: u32 = 10011u32; pub const SQL_ATTR_APP_ROW_DESC: u32 = 10010u32; pub const SQL_ATTR_ASYNC_DBC_EVENT: u32 = 119u32; pub const SQL_ATTR_ASYNC_DBC_FUNCTIONS_ENABLE: u32 = 117u32; pub const SQL_ATTR_ASYNC_DBC_NOTIFICATION_CALLBACK: u32 = 120u32; pub const SQL_ATTR_ASYNC_DBC_NOTIFICATION_CONTEXT: u32 = 121u32; pub const SQL_ATTR_ASYNC_ENABLE: u32 = 4u32; pub const SQL_ATTR_ASYNC_STMT_EVENT: u32 = 29u32; pub const SQL_ATTR_ASYNC_STMT_NOTIFICATION_CALLBACK: u32 = 30u32; pub const SQL_ATTR_ASYNC_STMT_NOTIFICATION_CONTEXT: u32 = 31u32; pub const SQL_ATTR_AUTOCOMMIT: u32 = 102u32; pub const SQL_ATTR_AUTO_IPD: u32 = 10001u32; pub const SQL_ATTR_CONCURRENCY: u32 = 7u32; pub const SQL_ATTR_CONNECTION_DEAD: u32 = 1209u32; pub const SQL_ATTR_CONNECTION_POOLING: u32 = 201u32; pub const SQL_ATTR_CONNECTION_TIMEOUT: u32 = 113u32; pub const SQL_ATTR_CP_MATCH: u32 = 202u32; pub const SQL_ATTR_CURRENT_CATALOG: u32 = 109u32; pub const SQL_ATTR_CURSOR_SCROLLABLE: i32 = -1i32; pub const SQL_ATTR_CURSOR_SENSITIVITY: i32 = -2i32; pub const SQL_ATTR_CURSOR_TYPE: u32 = 6u32; pub const SQL_ATTR_DBC_INFO_TOKEN: u32 = 118u32; pub const SQL_ATTR_DISCONNECT_BEHAVIOR: u32 = 114u32; pub const SQL_ATTR_ENABLE_AUTO_IPD: u32 = 15u32; pub const SQL_ATTR_ENLIST_IN_DTC: u32 = 1207u32; pub const SQL_ATTR_ENLIST_IN_XA: u32 = 1208u32; pub const SQL_ATTR_FETCH_BOOKMARK_PTR: u32 = 16u32; pub const SQL_ATTR_IMP_PARAM_DESC: u32 = 10013u32; pub const SQL_ATTR_IMP_ROW_DESC: u32 = 10012u32; pub const SQL_ATTR_KEYSET_SIZE: u32 = 8u32; pub const SQL_ATTR_LOGIN_TIMEOUT: u32 = 103u32; pub const SQL_ATTR_MAX_LENGTH: u32 = 3u32; pub const SQL_ATTR_MAX_ROWS: u32 = 1u32; pub const SQL_ATTR_METADATA_ID: u32 = 10014u32; pub const SQL_ATTR_NOSCAN: u32 = 2u32; pub const SQL_ATTR_ODBC_CURSORS: u32 = 110u32; pub const SQL_ATTR_ODBC_VERSION: u32 = 200u32; pub const SQL_ATTR_OUTPUT_NTS: u32 = 10001u32; pub const SQL_ATTR_PACKET_SIZE: u32 = 112u32; pub const SQL_ATTR_PARAMSET_SIZE: u32 = 22u32; pub const SQL_ATTR_PARAMS_PROCESSED_PTR: u32 = 21u32; pub const SQL_ATTR_PARAM_BIND_OFFSET_PTR: u32 = 17u32; pub const SQL_ATTR_PARAM_BIND_TYPE: u32 = 18u32; pub const SQL_ATTR_PARAM_OPERATION_PTR: u32 = 19u32; pub const SQL_ATTR_PARAM_STATUS_PTR: u32 = 20u32; pub const SQL_ATTR_QUERY_TIMEOUT: u32 = 0u32; pub const SQL_ATTR_QUIET_MODE: u32 = 111u32; pub const SQL_ATTR_READONLY: u32 = 0u32; pub const SQL_ATTR_READWRITE_UNKNOWN: u32 = 2u32; pub const SQL_ATTR_RESET_CONNECTION: u32 = 116u32; pub const SQL_ATTR_RETRIEVE_DATA: u32 = 11u32; pub const SQL_ATTR_ROWS_FETCHED_PTR: u32 = 26u32; pub const SQL_ATTR_ROW_ARRAY_SIZE: u32 = 27u32; pub const SQL_ATTR_ROW_BIND_OFFSET_PTR: u32 = 23u32; pub const SQL_ATTR_ROW_BIND_TYPE: u32 = 5u32; pub const SQL_ATTR_ROW_NUMBER: u32 = 14u32; pub const SQL_ATTR_ROW_OPERATION_PTR: u32 = 24u32; pub const SQL_ATTR_ROW_STATUS_PTR: u32 = 25u32; pub const SQL_ATTR_SIMULATE_CURSOR: u32 = 10u32; pub const SQL_ATTR_TRACE: u32 = 104u32; pub const SQL_ATTR_TRACEFILE: u32 = 105u32; pub const SQL_ATTR_TRANSLATE_LIB: u32 = 106u32; pub const SQL_ATTR_TRANSLATE_OPTION: u32 = 107u32; pub const SQL_ATTR_TXN_ISOLATION: u32 = 108u32; pub const SQL_ATTR_USE_BOOKMARKS: u32 = 12u32; pub const SQL_ATTR_WRITE: u32 = 1u32; pub const SQL_AT_ADD_COLUMN: i32 = 1i32; pub const SQL_AT_ADD_COLUMN_COLLATION: i32 = 128i32; pub const SQL_AT_ADD_COLUMN_DEFAULT: i32 = 64i32; pub const SQL_AT_ADD_COLUMN_SINGLE: i32 = 32i32; pub const SQL_AT_ADD_CONSTRAINT: i32 = 8i32; pub const SQL_AT_ADD_TABLE_CONSTRAINT: i32 = 4096i32; pub const SQL_AT_CONSTRAINT_DEFERRABLE: i32 = 262144i32; pub const SQL_AT_CONSTRAINT_INITIALLY_DEFERRED: i32 = 65536i32; pub const SQL_AT_CONSTRAINT_INITIALLY_IMMEDIATE: i32 = 131072i32; pub const SQL_AT_CONSTRAINT_NAME_DEFINITION: i32 = 32768i32; pub const SQL_AT_CONSTRAINT_NON_DEFERRABLE: i32 = 524288i32; pub const SQL_AT_DROP_COLUMN: i32 = 2i32; pub const SQL_AT_DROP_COLUMN_CASCADE: i32 = 1024i32; pub const SQL_AT_DROP_COLUMN_DEFAULT: i32 = 512i32; pub const SQL_AT_DROP_COLUMN_RESTRICT: i32 = 2048i32; pub const SQL_AT_DROP_TABLE_CONSTRAINT_CASCADE: i32 = 8192i32; pub const SQL_AT_DROP_TABLE_CONSTRAINT_RESTRICT: i32 = 16384i32; pub const SQL_AT_SET_COLUMN_DEFAULT: i32 = 256i32; pub const SQL_AUTOCOMMIT: u32 = 102u32; pub const SQL_AUTOCOMMIT_DEFAULT: u32 = 1u32; pub const SQL_AUTOCOMMIT_OFF: u32 = 0u32; pub const SQL_AUTOCOMMIT_ON: u32 = 1u32; pub const SQL_BATCH_ROW_COUNT: u32 = 120u32; pub const SQL_BATCH_SUPPORT: u32 = 121u32; pub const SQL_BCP_DEFAULT: i32 = 0i32; pub const SQL_BCP_OFF: i32 = 0i32; pub const SQL_BCP_ON: i32 = 1i32; pub const SQL_BEST_ROWID: u32 = 1u32; pub const SQL_BIGINT: i32 = -5i32; pub const SQL_BINARY: i32 = -2i32; pub const SQL_BIND_BY_COLUMN: u32 = 0u32; pub const SQL_BIND_TYPE: u32 = 5u32; pub const SQL_BIND_TYPE_DEFAULT: u32 = 0u32; pub const SQL_BIT: i32 = -7i32; pub const SQL_BOOKMARK_PERSISTENCE: u32 = 82u32; pub const SQL_BP_CLOSE: i32 = 1i32; pub const SQL_BP_DELETE: i32 = 2i32; pub const SQL_BP_DROP: i32 = 4i32; pub const SQL_BP_OTHER_HSTMT: i32 = 32i32; pub const SQL_BP_SCROLL: i32 = 64i32; pub const SQL_BP_TRANSACTION: i32 = 8i32; pub const SQL_BP_UPDATE: i32 = 16i32; pub const SQL_BRC_EXPLICIT: u32 = 2u32; pub const SQL_BRC_PROCEDURES: u32 = 1u32; pub const SQL_BRC_ROLLED_UP: u32 = 4u32; pub const SQL_BS_ROW_COUNT_EXPLICIT: i32 = 2i32; pub const SQL_BS_ROW_COUNT_PROC: i32 = 8i32; pub const SQL_BS_SELECT_EXPLICIT: i32 = 1i32; pub const SQL_BS_SELECT_PROC: i32 = 4i32; pub const SQL_CA1_ABSOLUTE: i32 = 2i32; pub const SQL_CA1_BOOKMARK: i32 = 8i32; pub const SQL_CA1_BULK_ADD: i32 = 65536i32; pub const SQL_CA1_BULK_DELETE_BY_BOOKMARK: i32 = 262144i32; pub const SQL_CA1_BULK_FETCH_BY_BOOKMARK: i32 = 524288i32; pub const SQL_CA1_BULK_UPDATE_BY_BOOKMARK: i32 = 131072i32; pub const SQL_CA1_LOCK_EXCLUSIVE: i32 = 128i32; pub const SQL_CA1_LOCK_NO_CHANGE: i32 = 64i32; pub const SQL_CA1_LOCK_UNLOCK: i32 = 256i32; pub const SQL_CA1_NEXT: i32 = 1i32; pub const SQL_CA1_POSITIONED_DELETE: i32 = 16384i32; pub const SQL_CA1_POSITIONED_UPDATE: i32 = 8192i32; pub const SQL_CA1_POS_DELETE: i32 = 2048i32; pub const SQL_CA1_POS_POSITION: i32 = 512i32; pub const SQL_CA1_POS_REFRESH: i32 = 4096i32; pub const SQL_CA1_POS_UPDATE: i32 = 1024i32; pub const SQL_CA1_RELATIVE: i32 = 4i32; pub const SQL_CA1_SELECT_FOR_UPDATE: i32 = 32768i32; pub const SQL_CA2_CRC_APPROXIMATE: i32 = 8192i32; pub const SQL_CA2_CRC_EXACT: i32 = 4096i32; pub const SQL_CA2_LOCK_CONCURRENCY: i32 = 2i32; pub const SQL_CA2_MAX_ROWS_CATALOG: i32 = 2048i32; pub const SQL_CA2_MAX_ROWS_DELETE: i32 = 512i32; pub const SQL_CA2_MAX_ROWS_INSERT: i32 = 256i32; pub const SQL_CA2_MAX_ROWS_SELECT: i32 = 128i32; pub const SQL_CA2_MAX_ROWS_UPDATE: i32 = 1024i32; pub const SQL_CA2_OPT_ROWVER_CONCURRENCY: i32 = 4i32; pub const SQL_CA2_OPT_VALUES_CONCURRENCY: i32 = 8i32; pub const SQL_CA2_READ_ONLY_CONCURRENCY: i32 = 1i32; pub const SQL_CA2_SENSITIVITY_ADDITIONS: i32 = 16i32; pub const SQL_CA2_SENSITIVITY_DELETIONS: i32 = 32i32; pub const SQL_CA2_SENSITIVITY_UPDATES: i32 = 64i32; pub const SQL_CA2_SIMULATE_NON_UNIQUE: i32 = 16384i32; pub const SQL_CA2_SIMULATE_TRY_UNIQUE: i32 = 32768i32; pub const SQL_CA2_SIMULATE_UNIQUE: i32 = 65536i32; pub const SQL_CACHE_DATA_NO: i32 = 0i32; pub const SQL_CACHE_DATA_YES: i32 = 1i32; pub const SQL_CASCADE: u32 = 0u32; pub const SQL_CATALOG_LOCATION: u32 = 114u32; pub const SQL_CATALOG_NAME: u32 = 10003u32; pub const SQL_CATALOG_NAME_SEPARATOR: u32 = 41u32; pub const SQL_CATALOG_TERM: u32 = 42u32; pub const SQL_CATALOG_USAGE: u32 = 92u32; pub const SQL_CA_CONSTRAINT_DEFERRABLE: i32 = 64i32; pub const SQL_CA_CONSTRAINT_INITIALLY_DEFERRED: i32 = 16i32; pub const SQL_CA_CONSTRAINT_INITIALLY_IMMEDIATE: i32 = 32i32; pub const SQL_CA_CONSTRAINT_NON_DEFERRABLE: i32 = 128i32; pub const SQL_CA_CREATE_ASSERTION: i32 = 1i32; pub const SQL_CA_SS_BASE: u32 = 1200u32; pub const SQL_CA_SS_COLUMN_COLLATION: u32 = 1214u32; pub const SQL_CA_SS_COLUMN_HIDDEN: u32 = 1211u32; pub const SQL_CA_SS_COLUMN_ID: u32 = 1208u32; pub const SQL_CA_SS_COLUMN_KEY: u32 = 1212u32; pub const SQL_CA_SS_COLUMN_OP: u32 = 1209u32; pub const SQL_CA_SS_COLUMN_ORDER: u32 = 1203u32; pub const SQL_CA_SS_COLUMN_SIZE: u32 = 1210u32; pub const SQL_CA_SS_COLUMN_SSTYPE: u32 = 1200u32; pub const SQL_CA_SS_COLUMN_UTYPE: u32 = 1201u32; pub const SQL_CA_SS_COLUMN_VARYLEN: u32 = 1204u32; pub const SQL_CA_SS_COMPUTE_BYLIST: u32 = 1207u32; pub const SQL_CA_SS_COMPUTE_ID: u32 = 1206u32; pub const SQL_CA_SS_MAX_USED: u32 = 1218u32; pub const SQL_CA_SS_NUM_COMPUTES: u32 = 1205u32; pub const SQL_CA_SS_NUM_ORDERS: u32 = 1202u32; pub const SQL_CA_SS_VARIANT_SERVER_TYPE: u32 = 1217u32; pub const SQL_CA_SS_VARIANT_SQL_TYPE: u32 = 1216u32; pub const SQL_CA_SS_VARIANT_TYPE: u32 = 1215u32; pub const SQL_CB_CLOSE: u32 = 1u32; pub const SQL_CB_DELETE: u32 = 0u32; pub const SQL_CB_NON_NULL: u32 = 1u32; pub const SQL_CB_NULL: u32 = 0u32; pub const SQL_CB_PRESERVE: u32 = 2u32; pub const SQL_CCOL_CREATE_COLLATION: i32 = 1i32; pub const SQL_CCS_COLLATE_CLAUSE: i32 = 2i32; pub const SQL_CCS_CREATE_CHARACTER_SET: i32 = 1i32; pub const SQL_CCS_LIMITED_COLLATION: i32 = 4i32; pub const SQL_CC_CLOSE: u32 = 1u32; pub const SQL_CC_DELETE: u32 = 0u32; pub const SQL_CC_PRESERVE: u32 = 2u32; pub const SQL_CDO_COLLATION: i32 = 8i32; pub const SQL_CDO_CONSTRAINT: i32 = 4i32; pub const SQL_CDO_CONSTRAINT_DEFERRABLE: i32 = 128i32; pub const SQL_CDO_CONSTRAINT_INITIALLY_DEFERRED: i32 = 32i32; pub const SQL_CDO_CONSTRAINT_INITIALLY_IMMEDIATE: i32 = 64i32; pub const SQL_CDO_CONSTRAINT_NAME_DEFINITION: i32 = 16i32; pub const SQL_CDO_CONSTRAINT_NON_DEFERRABLE: i32 = 256i32; pub const SQL_CDO_CREATE_DOMAIN: i32 = 1i32; pub const SQL_CDO_DEFAULT: i32 = 2i32; pub const SQL_CD_FALSE: i32 = 0i32; pub const SQL_CD_TRUE: i32 = 1i32; pub const SQL_CHAR: u32 = 1u32; pub const SQL_CLOSE: u32 = 0u32; pub const SQL_CL_END: u32 = 2u32; pub const SQL_CL_START: u32 = 1u32; pub const SQL_CN_ANY: u32 = 2u32; pub const SQL_CN_DEFAULT: i32 = 1i32; pub const SQL_CN_DIFFERENT: u32 = 1u32; pub const SQL_CN_NONE: u32 = 0u32; pub const SQL_CN_OFF: i32 = 0i32; pub const SQL_CN_ON: i32 = 1i32; pub const SQL_CODE_DATE: u32 = 1u32; pub const SQL_CODE_DAY: u32 = 3u32; pub const SQL_CODE_DAY_TO_HOUR: u32 = 8u32; pub const SQL_CODE_DAY_TO_MINUTE: u32 = 9u32; pub const SQL_CODE_DAY_TO_SECOND: u32 = 10u32; pub const SQL_CODE_HOUR: u32 = 4u32; pub const SQL_CODE_HOUR_TO_MINUTE: u32 = 11u32; pub const SQL_CODE_HOUR_TO_SECOND: u32 = 12u32; pub const SQL_CODE_MINUTE: u32 = 5u32; pub const SQL_CODE_MINUTE_TO_SECOND: u32 = 13u32; pub const SQL_CODE_MONTH: u32 = 2u32; pub const SQL_CODE_SECOND: u32 = 6u32; pub const SQL_CODE_TIME: u32 = 2u32; pub const SQL_CODE_TIMESTAMP: u32 = 3u32; pub const SQL_CODE_YEAR: u32 = 1u32; pub const SQL_CODE_YEAR_TO_MONTH: u32 = 7u32; pub const SQL_COLATT_OPT_MAX: u32 = 18u32; pub const SQL_COLATT_OPT_MIN: u32 = 0u32; pub const SQL_COLLATION_SEQ: u32 = 10004u32; pub const SQL_COLUMN_ALIAS: u32 = 87u32; pub const SQL_COLUMN_AUTO_INCREMENT: u32 = 11u32; pub const SQL_COLUMN_CASE_SENSITIVE: u32 = 12u32; pub const SQL_COLUMN_COUNT: u32 = 0u32; pub const SQL_COLUMN_DISPLAY_SIZE: u32 = 6u32; pub const SQL_COLUMN_DRIVER_START: u32 = 1000u32; pub const SQL_COLUMN_IGNORE: i32 = -6i32; pub const SQL_COLUMN_LABEL: u32 = 18u32; pub const SQL_COLUMN_LENGTH: u32 = 3u32; pub const SQL_COLUMN_MONEY: u32 = 9u32; pub const SQL_COLUMN_NAME: u32 = 1u32; pub const SQL_COLUMN_NULLABLE: u32 = 7u32; pub const SQL_COLUMN_NUMBER_UNKNOWN: i32 = -2i32; pub const SQL_COLUMN_OWNER_NAME: u32 = 16u32; pub const SQL_COLUMN_PRECISION: u32 = 4u32; pub const SQL_COLUMN_QUALIFIER_NAME: u32 = 17u32; pub const SQL_COLUMN_SCALE: u32 = 5u32; pub const SQL_COLUMN_SEARCHABLE: u32 = 13u32; pub const SQL_COLUMN_TABLE_NAME: u32 = 15u32; pub const SQL_COLUMN_TYPE: u32 = 2u32; pub const SQL_COLUMN_TYPE_NAME: u32 = 14u32; pub const SQL_COLUMN_UNSIGNED: u32 = 8u32; pub const SQL_COLUMN_UPDATABLE: u32 = 10u32; pub const SQL_COMMIT: u32 = 0u32; pub const SQL_CONCAT_NULL_BEHAVIOR: u32 = 22u32; pub const SQL_CONCURRENCY: u32 = 7u32; pub const SQL_CONCUR_DEFAULT: u32 = 1u32; pub const SQL_CONCUR_LOCK: u32 = 2u32; pub const SQL_CONCUR_READ_ONLY: u32 = 1u32; pub const SQL_CONCUR_ROWVER: u32 = 3u32; pub const SQL_CONCUR_TIMESTAMP: u32 = 3u32; pub const SQL_CONCUR_VALUES: u32 = 4u32; pub const SQL_CONNECT_OPT_DRVR_START: u32 = 1000u32; pub const SQL_CONN_OPT_MAX: u32 = 112u32; pub const SQL_CONN_OPT_MIN: u32 = 101u32; pub const SQL_CONN_POOL_RATING_BEST: u32 = 100u32; pub const SQL_CONN_POOL_RATING_GOOD_ENOUGH: u32 = 99u32; pub const SQL_CONN_POOL_RATING_USELESS: u32 = 0u32; pub const SQL_CONVERT_BIGINT: u32 = 53u32; pub const SQL_CONVERT_BINARY: u32 = 54u32; pub const SQL_CONVERT_BIT: u32 = 55u32; pub const SQL_CONVERT_CHAR: u32 = 56u32; pub const SQL_CONVERT_DATE: u32 = 57u32; pub const SQL_CONVERT_DECIMAL: u32 = 58u32; pub const SQL_CONVERT_DOUBLE: u32 = 59u32; pub const SQL_CONVERT_FLOAT: u32 = 60u32; pub const SQL_CONVERT_FUNCTIONS: u32 = 48u32; pub const SQL_CONVERT_GUID: u32 = 173u32; pub const SQL_CONVERT_INTEGER: u32 = 61u32; pub const SQL_CONVERT_INTERVAL_DAY_TIME: u32 = 123u32; pub const SQL_CONVERT_INTERVAL_YEAR_MONTH: u32 = 124u32; pub const SQL_CONVERT_LONGVARBINARY: u32 = 71u32; pub const SQL_CONVERT_LONGVARCHAR: u32 = 62u32; pub const SQL_CONVERT_NUMERIC: u32 = 63u32; pub const SQL_CONVERT_REAL: u32 = 64u32; pub const SQL_CONVERT_SMALLINT: u32 = 65u32; pub const SQL_CONVERT_TIME: u32 = 66u32; pub const SQL_CONVERT_TIMESTAMP: u32 = 67u32; pub const SQL_CONVERT_TINYINT: u32 = 68u32; pub const SQL_CONVERT_VARBINARY: u32 = 69u32; pub const SQL_CONVERT_VARCHAR: u32 = 70u32; pub const SQL_CONVERT_WCHAR: u32 = 122u32; pub const SQL_CONVERT_WLONGVARCHAR: u32 = 125u32; pub const SQL_CONVERT_WVARCHAR: u32 = 126u32; pub const SQL_COPT_SS_ANSI_NPW: u32 = 1218u32; pub const SQL_COPT_SS_ANSI_OEM: u32 = 1206u32; pub const SQL_COPT_SS_ATTACHDBFILENAME: u32 = 1221u32; pub const SQL_COPT_SS_BASE: u32 = 1200u32; pub const SQL_COPT_SS_BASE_EX: u32 = 1240u32; pub const SQL_COPT_SS_BCP: u32 = 1219u32; pub const SQL_COPT_SS_BROWSE_CACHE_DATA: u32 = 1245u32; pub const SQL_COPT_SS_BROWSE_CONNECT: u32 = 1241u32; pub const SQL_COPT_SS_BROWSE_SERVER: u32 = 1242u32; pub const SQL_COPT_SS_CONCAT_NULL: u32 = 1222u32; pub const SQL_COPT_SS_CONNECTION_DEAD: u32 = 1244u32; pub const SQL_COPT_SS_ENCRYPT: u32 = 1223u32; pub const SQL_COPT_SS_EX_MAX_USED: u32 = 1246u32; pub const SQL_COPT_SS_FALLBACK_CONNECT: u32 = 1210u32; pub const SQL_COPT_SS_INTEGRATED_SECURITY: u32 = 1203u32; pub const SQL_COPT_SS_MAX_USED: u32 = 1223u32; pub const SQL_COPT_SS_PERF_DATA: u32 = 1211u32; pub const SQL_COPT_SS_PERF_DATA_LOG: u32 = 1212u32; pub const SQL_COPT_SS_PERF_DATA_LOG_NOW: u32 = 1216u32; pub const SQL_COPT_SS_PERF_QUERY: u32 = 1215u32; pub const SQL_COPT_SS_PERF_QUERY_INTERVAL: u32 = 1213u32; pub const SQL_COPT_SS_PERF_QUERY_LOG: u32 = 1214u32; pub const SQL_COPT_SS_PRESERVE_CURSORS: u32 = 1204u32; pub const SQL_COPT_SS_QUOTED_IDENT: u32 = 1217u32; pub const SQL_COPT_SS_REMOTE_PWD: u32 = 1201u32; pub const SQL_COPT_SS_RESET_CONNECTION: u32 = 1246u32; pub const SQL_COPT_SS_TRANSLATE: u32 = 1220u32; pub const SQL_COPT_SS_USER_DATA: u32 = 1205u32; pub const SQL_COPT_SS_USE_PROC_FOR_PREP: u32 = 1202u32; pub const SQL_COPT_SS_WARN_ON_CP_ERROR: u32 = 1243u32; pub const SQL_CORRELATION_NAME: u32 = 74u32; pub const SQL_CO_AF: i32 = 2i32; pub const SQL_CO_DEFAULT: i32 = 0i32; pub const SQL_CO_FFO: i32 = 1i32; pub const SQL_CO_FIREHOSE_AF: i32 = 4i32; pub const SQL_CO_OFF: i32 = 0i32; pub const SQL_CP_DEFAULT: u32 = 0u32; pub const SQL_CP_DRIVER_AWARE: u32 = 3u32; pub const SQL_CP_MATCH_DEFAULT: u32 = 0u32; pub const SQL_CP_OFF: u32 = 0u32; pub const SQL_CP_ONE_PER_DRIVER: u32 = 1u32; pub const SQL_CP_ONE_PER_HENV: u32 = 2u32; pub const SQL_CP_RELAXED_MATCH: u32 = 1u32; pub const SQL_CP_STRICT_MATCH: u32 = 0u32; pub const SQL_CREATE_ASSERTION: u32 = 127u32; pub const SQL_CREATE_CHARACTER_SET: u32 = 128u32; pub const SQL_CREATE_COLLATION: u32 = 129u32; pub const SQL_CREATE_DOMAIN: u32 = 130u32; pub const SQL_CREATE_SCHEMA: u32 = 131u32; pub const SQL_CREATE_TABLE: u32 = 132u32; pub const SQL_CREATE_TRANSLATION: u32 = 133u32; pub const SQL_CREATE_VIEW: u32 = 134u32; pub const SQL_CR_CLOSE: u32 = 1u32; pub const SQL_CR_DELETE: u32 = 0u32; pub const SQL_CR_PRESERVE: u32 = 2u32; pub const SQL_CS_AUTHORIZATION: i32 = 2i32; pub const SQL_CS_CREATE_SCHEMA: i32 = 1i32; pub const SQL_CS_DEFAULT_CHARACTER_SET: i32 = 4i32; pub const SQL_CTR_CREATE_TRANSLATION: i32 = 1i32; pub const SQL_CT_COLUMN_COLLATION: i32 = 2048i32; pub const SQL_CT_COLUMN_CONSTRAINT: i32 = 512i32; pub const SQL_CT_COLUMN_DEFAULT: i32 = 1024i32; pub const SQL_CT_COMMIT_DELETE: i32 = 4i32; pub const SQL_CT_COMMIT_PRESERVE: i32 = 2i32; pub const SQL_CT_CONSTRAINT_DEFERRABLE: i32 = 128i32; pub const SQL_CT_CONSTRAINT_INITIALLY_DEFERRED: i32 = 32i32; pub const SQL_CT_CONSTRAINT_INITIALLY_IMMEDIATE: i32 = 64i32; pub const SQL_CT_CONSTRAINT_NAME_DEFINITION: i32 = 8192i32; pub const SQL_CT_CONSTRAINT_NON_DEFERRABLE: i32 = 256i32; pub const SQL_CT_CREATE_TABLE: i32 = 1i32; pub const SQL_CT_GLOBAL_TEMPORARY: i32 = 8i32; pub const SQL_CT_LOCAL_TEMPORARY: i32 = 16i32; pub const SQL_CT_TABLE_CONSTRAINT: i32 = 4096i32; pub const SQL_CURRENT_QUALIFIER: u32 = 109u32; pub const SQL_CURSOR_COMMIT_BEHAVIOR: u32 = 23u32; pub const SQL_CURSOR_DYNAMIC: u32 = 2u32; pub const SQL_CURSOR_FAST_FORWARD_ONLY: u32 = 8u32; pub const SQL_CURSOR_FORWARD_ONLY: u32 = 0u32; pub const SQL_CURSOR_KEYSET_DRIVEN: u32 = 1u32; pub const SQL_CURSOR_ROLLBACK_BEHAVIOR: u32 = 24u32; pub const SQL_CURSOR_SENSITIVITY: u32 = 10001u32; pub const SQL_CURSOR_STATIC: u32 = 3u32; pub const SQL_CURSOR_TYPE: u32 = 6u32; pub const SQL_CURSOR_TYPE_DEFAULT: u32 = 0u32; pub const SQL_CUR_DEFAULT: u32 = 2u32; pub const SQL_CUR_USE_DRIVER: u32 = 2u32; pub const SQL_CUR_USE_IF_NEEDED: u32 = 0u32; pub const SQL_CUR_USE_ODBC: u32 = 1u32; pub const SQL_CU_DML_STATEMENTS: i32 = 1i32; pub const SQL_CU_INDEX_DEFINITION: i32 = 8i32; pub const SQL_CU_PRIVILEGE_DEFINITION: i32 = 16i32; pub const SQL_CU_PROCEDURE_INVOCATION: i32 = 2i32; pub const SQL_CU_TABLE_DEFINITION: i32 = 4i32; pub const SQL_CVT_BIGINT: i32 = 16384i32; pub const SQL_CVT_BINARY: i32 = 1024i32; pub const SQL_CVT_BIT: i32 = 4096i32; pub const SQL_CVT_CHAR: i32 = 1i32; pub const SQL_CVT_DATE: i32 = 32768i32; pub const SQL_CVT_DECIMAL: i32 = 4i32; pub const SQL_CVT_DOUBLE: i32 = 128i32; pub const SQL_CVT_FLOAT: i32 = 32i32; pub const SQL_CVT_GUID: i32 = 16777216i32; pub const SQL_CVT_INTEGER: i32 = 8i32; pub const SQL_CVT_INTERVAL_DAY_TIME: i32 = 1048576i32; pub const SQL_CVT_INTERVAL_YEAR_MONTH: i32 = 524288i32; pub const SQL_CVT_LONGVARBINARY: i32 = 262144i32; pub const SQL_CVT_LONGVARCHAR: i32 = 512i32; pub const SQL_CVT_NUMERIC: i32 = 2i32; pub const SQL_CVT_REAL: i32 = 64i32; pub const SQL_CVT_SMALLINT: i32 = 16i32; pub const SQL_CVT_TIME: i32 = 65536i32; pub const SQL_CVT_TIMESTAMP: i32 = 131072i32; pub const SQL_CVT_TINYINT: i32 = 8192i32; pub const SQL_CVT_VARBINARY: i32 = 2048i32; pub const SQL_CVT_VARCHAR: i32 = 256i32; pub const SQL_CVT_WCHAR: i32 = 2097152i32; pub const SQL_CVT_WLONGVARCHAR: i32 = 4194304i32; pub const SQL_CVT_WVARCHAR: i32 = 8388608i32; pub const SQL_CV_CASCADED: i32 = 4i32; pub const SQL_CV_CHECK_OPTION: i32 = 2i32; pub const SQL_CV_CREATE_VIEW: i32 = 1i32; pub const SQL_CV_LOCAL: i32 = 8i32; pub const SQL_C_BINARY: i32 = -2i32; pub const SQL_C_BIT: i32 = -7i32; pub const SQL_C_CHAR: u32 = 1u32; pub const SQL_C_DATE: u32 = 9u32; pub const SQL_C_DEFAULT: u32 = 99u32; pub const SQL_C_DOUBLE: u32 = 8u32; pub const SQL_C_FLOAT: u32 = 7u32; pub const SQL_C_GUID: i32 = -11i32; pub const SQL_C_INTERVAL_DAY: i32 = -83i32; pub const SQL_C_INTERVAL_DAY_TO_HOUR: i32 = -87i32; pub const SQL_C_INTERVAL_DAY_TO_MINUTE: i32 = -88i32; pub const SQL_C_INTERVAL_DAY_TO_SECOND: i32 = -89i32; pub const SQL_C_INTERVAL_HOUR: i32 = -84i32; pub const SQL_C_INTERVAL_HOUR_TO_MINUTE: i32 = -90i32; pub const SQL_C_INTERVAL_HOUR_TO_SECOND: i32 = -91i32; pub const SQL_C_INTERVAL_MINUTE: i32 = -85i32; pub const SQL_C_INTERVAL_MINUTE_TO_SECOND: i32 = -92i32; pub const SQL_C_INTERVAL_MONTH: i32 = -81i32; pub const SQL_C_INTERVAL_SECOND: i32 = -86i32; pub const SQL_C_INTERVAL_YEAR: i32 = -80i32; pub const SQL_C_INTERVAL_YEAR_TO_MONTH: i32 = -82i32; pub const SQL_C_LONG: u32 = 4u32; pub const SQL_C_NUMERIC: u32 = 2u32; pub const SQL_C_SHORT: u32 = 5u32; pub const SQL_C_TCHAR: i32 = -8i32; pub const SQL_C_TIME: u32 = 10u32; pub const SQL_C_TIMESTAMP: u32 = 11u32; pub const SQL_C_TINYINT: i32 = -6i32; pub const SQL_C_TYPE_DATE: u32 = 91u32; pub const SQL_C_TYPE_TIME: u32 = 92u32; pub const SQL_C_TYPE_TIMESTAMP: u32 = 93u32; pub const SQL_C_VARBOOKMARK: i32 = -2i32; pub const SQL_C_WCHAR: i32 = -8i32; pub const SQL_DATABASE_NAME: u32 = 16u32; pub const SQL_DATA_AT_EXEC: i32 = -2i32; pub const SQL_DATA_SOURCE_NAME: u32 = 2u32; pub const SQL_DATA_SOURCE_READ_ONLY: u32 = 25u32; pub const SQL_DATE: u32 = 9u32; pub const SQL_DATETIME: u32 = 9u32; pub const SQL_DATETIME_LITERALS: u32 = 119u32; pub const SQL_DATE_LEN: u32 = 10u32; pub const SQL_DAY: u32 = 3u32; pub const SQL_DAY_TO_HOUR: u32 = 8u32; pub const SQL_DAY_TO_MINUTE: u32 = 9u32; pub const SQL_DAY_TO_SECOND: u32 = 10u32; pub const SQL_DA_DROP_ASSERTION: i32 = 1i32; pub const SQL_DBMS_NAME: u32 = 17u32; pub const SQL_DBMS_VER: u32 = 18u32; pub const SQL_DB_DEFAULT: u32 = 0u32; pub const SQL_DB_DISCONNECT: u32 = 1u32; pub const SQL_DB_RETURN_TO_POOL: u32 = 0u32; pub const SQL_DCS_DROP_CHARACTER_SET: i32 = 1i32; pub const SQL_DC_DROP_COLLATION: i32 = 1i32; pub const SQL_DDL_INDEX: u32 = 170u32; pub const SQL_DD_CASCADE: i32 = 4i32; pub const SQL_DD_DROP_DOMAIN: i32 = 1i32; pub const SQL_DD_RESTRICT: i32 = 2i32; pub const SQL_DECIMAL: u32 = 3u32; pub const SQL_DEFAULT: u32 = 99u32; pub const SQL_DEFAULT_PARAM: i32 = -5i32; pub const SQL_DEFAULT_TXN_ISOLATION: u32 = 26u32; pub const SQL_DELETE: u32 = 3u32; pub const SQL_DELETE_BY_BOOKMARK: u32 = 6u32; pub const SQL_DESCRIBE_PARAMETER: u32 = 10002u32; pub const SQL_DESC_ALLOC_AUTO: u32 = 1u32; pub const SQL_DESC_ALLOC_TYPE: u32 = 1099u32; pub const SQL_DESC_ALLOC_USER: u32 = 2u32; pub const SQL_DESC_ARRAY_SIZE: u32 = 20u32; pub const SQL_DESC_ARRAY_STATUS_PTR: u32 = 21u32; pub const SQL_DESC_BASE_COLUMN_NAME: u32 = 22u32; pub const SQL_DESC_BASE_TABLE_NAME: u32 = 23u32; pub const SQL_DESC_BIND_OFFSET_PTR: u32 = 24u32; pub const SQL_DESC_BIND_TYPE: u32 = 25u32; pub const SQL_DESC_COUNT: u32 = 1001u32; pub const SQL_DESC_DATA_PTR: u32 = 1010u32; pub const SQL_DESC_DATETIME_INTERVAL_CODE: u32 = 1007u32; pub const SQL_DESC_DATETIME_INTERVAL_PRECISION: u32 = 26u32; pub const SQL_DESC_INDICATOR_PTR: u32 = 1009u32; pub const SQL_DESC_LENGTH: u32 = 1003u32; pub const SQL_DESC_LITERAL_PREFIX: u32 = 27u32; pub const SQL_DESC_LITERAL_SUFFIX: u32 = 28u32; pub const SQL_DESC_LOCAL_TYPE_NAME: u32 = 29u32; pub const SQL_DESC_MAXIMUM_SCALE: u32 = 30u32; pub const SQL_DESC_MINIMUM_SCALE: u32 = 31u32; pub const SQL_DESC_NAME: u32 = 1011u32; pub const SQL_DESC_NULLABLE: u32 = 1008u32; pub const SQL_DESC_NUM_PREC_RADIX: u32 = 32u32; pub const SQL_DESC_OCTET_LENGTH: u32 = 1013u32; pub const SQL_DESC_OCTET_LENGTH_PTR: u32 = 1004u32; pub const SQL_DESC_PARAMETER_TYPE: u32 = 33u32; pub const SQL_DESC_PRECISION: u32 = 1005u32; pub const SQL_DESC_ROWS_PROCESSED_PTR: u32 = 34u32; pub const SQL_DESC_ROWVER: u32 = 35u32; pub const SQL_DESC_SCALE: u32 = 1006u32; pub const SQL_DESC_TYPE: u32 = 1002u32; pub const SQL_DESC_UNNAMED: u32 = 1012u32; pub const SQL_DIAG_ALTER_DOMAIN: u32 = 3u32; pub const SQL_DIAG_ALTER_TABLE: u32 = 4u32; pub const SQL_DIAG_CALL: u32 = 7u32; pub const SQL_DIAG_CLASS_ORIGIN: u32 = 8u32; pub const SQL_DIAG_COLUMN_NUMBER: i32 = -1247i32; pub const SQL_DIAG_CONNECTION_NAME: u32 = 10u32; pub const SQL_DIAG_CREATE_ASSERTION: u32 = 6u32; pub const SQL_DIAG_CREATE_CHARACTER_SET: u32 = 8u32; pub const SQL_DIAG_CREATE_COLLATION: u32 = 10u32; pub const SQL_DIAG_CREATE_DOMAIN: u32 = 23u32; pub const SQL_DIAG_CREATE_INDEX: i32 = -1i32; pub const SQL_DIAG_CREATE_SCHEMA: u32 = 64u32; pub const SQL_DIAG_CREATE_TABLE: u32 = 77u32; pub const SQL_DIAG_CREATE_TRANSLATION: u32 = 79u32; pub const SQL_DIAG_CREATE_VIEW: u32 = 84u32; pub const SQL_DIAG_CURSOR_ROW_COUNT: i32 = -1249i32; pub const SQL_DIAG_DELETE_WHERE: u32 = 19u32; pub const SQL_DIAG_DFC_SS_BASE: i32 = -200i32; pub const SQL_DIAG_DROP_ASSERTION: u32 = 24u32; pub const SQL_DIAG_DROP_CHARACTER_SET: u32 = 25u32; pub const SQL_DIAG_DROP_COLLATION: u32 = 26u32; pub const SQL_DIAG_DROP_DOMAIN: u32 = 27u32; pub const SQL_DIAG_DROP_INDEX: i32 = -2i32; pub const SQL_DIAG_DROP_SCHEMA: u32 = 31u32; pub const SQL_DIAG_DROP_TABLE: u32 = 32u32; pub const SQL_DIAG_DROP_TRANSLATION: u32 = 33u32; pub const SQL_DIAG_DROP_VIEW: u32 = 36u32; pub const SQL_DIAG_DYNAMIC_DELETE_CURSOR: u32 = 38u32; pub const SQL_DIAG_DYNAMIC_FUNCTION: u32 = 7u32; pub const SQL_DIAG_DYNAMIC_FUNCTION_CODE: u32 = 12u32; pub const SQL_DIAG_DYNAMIC_UPDATE_CURSOR: u32 = 81u32; pub const SQL_DIAG_GRANT: u32 = 48u32; pub const SQL_DIAG_INSERT: u32 = 50u32; pub const SQL_DIAG_MESSAGE_TEXT: u32 = 6u32; pub const SQL_DIAG_NATIVE: u32 = 5u32; pub const SQL_DIAG_NUMBER: u32 = 2u32; pub const SQL_DIAG_RETURNCODE: u32 = 1u32; pub const SQL_DIAG_REVOKE: u32 = 59u32; pub const SQL_DIAG_ROW_COUNT: u32 = 3u32; pub const SQL_DIAG_ROW_NUMBER: i32 = -1248i32; pub const SQL_DIAG_SELECT_CURSOR: u32 = 85u32; pub const SQL_DIAG_SERVER_NAME: u32 = 11u32; pub const SQL_DIAG_SQLSTATE: u32 = 4u32; pub const SQL_DIAG_SS_BASE: i32 = -1150i32; pub const SQL_DIAG_SS_MSGSTATE: i32 = -1150i32; pub const SQL_DIAG_SUBCLASS_ORIGIN: u32 = 9u32; pub const SQL_DIAG_UNKNOWN_STATEMENT: u32 = 0u32; pub const SQL_DIAG_UPDATE_WHERE: u32 = 82u32; pub const SQL_DI_CREATE_INDEX: i32 = 1i32; pub const SQL_DI_DROP_INDEX: i32 = 2i32; pub const SQL_DL_SQL92_DATE: i32 = 1i32; pub const SQL_DL_SQL92_INTERVAL_DAY: i32 = 32i32; pub const SQL_DL_SQL92_INTERVAL_DAY_TO_HOUR: i32 = 1024i32; pub const SQL_DL_SQL92_INTERVAL_DAY_TO_MINUTE: i32 = 2048i32; pub const SQL_DL_SQL92_INTERVAL_DAY_TO_SECOND: i32 = 4096i32; pub const SQL_DL_SQL92_INTERVAL_HOUR: i32 = 64i32; pub const SQL_DL_SQL92_INTERVAL_HOUR_TO_MINUTE: i32 = 8192i32; pub const SQL_DL_SQL92_INTERVAL_HOUR_TO_SECOND: i32 = 16384i32; pub const SQL_DL_SQL92_INTERVAL_MINUTE: i32 = 128i32; pub const SQL_DL_SQL92_INTERVAL_MINUTE_TO_SECOND: i32 = 32768i32; pub const SQL_DL_SQL92_INTERVAL_MONTH: i32 = 16i32; pub const SQL_DL_SQL92_INTERVAL_SECOND: i32 = 256i32; pub const SQL_DL_SQL92_INTERVAL_YEAR: i32 = 8i32; pub const SQL_DL_SQL92_INTERVAL_YEAR_TO_MONTH: i32 = 512i32; pub const SQL_DL_SQL92_TIME: i32 = 2i32; pub const SQL_DL_SQL92_TIMESTAMP: i32 = 4i32; pub const SQL_DM_VER: u32 = 171u32; pub const SQL_DOUBLE: u32 = 8u32; pub const SQL_DP_OFF: i32 = 0i32; pub const SQL_DP_ON: i32 = 1i32; pub const SQL_DRIVER_AWARE_POOLING_CAPABLE: i32 = 1i32; pub const SQL_DRIVER_AWARE_POOLING_NOT_CAPABLE: i32 = 0i32; pub const SQL_DRIVER_AWARE_POOLING_SUPPORTED: u32 = 10024u32; pub const SQL_DRIVER_COMPLETE: u32 = 1u32; pub const SQL_DRIVER_COMPLETE_REQUIRED: u32 = 3u32; pub const SQL_DRIVER_CONN_ATTR_BASE: u32 = 16384u32; pub const SQL_DRIVER_C_TYPE_BASE: u32 = 16384u32; pub const SQL_DRIVER_DESC_FIELD_BASE: u32 = 16384u32; pub const SQL_DRIVER_DIAG_FIELD_BASE: u32 = 16384u32; pub const SQL_DRIVER_HDBC: u32 = 3u32; pub const SQL_DRIVER_HDESC: u32 = 135u32; pub const SQL_DRIVER_HENV: u32 = 4u32; pub const SQL_DRIVER_HLIB: u32 = 76u32; pub const SQL_DRIVER_HSTMT: u32 = 5u32; pub const SQL_DRIVER_INFO_TYPE_BASE: u32 = 16384u32; pub const SQL_DRIVER_NAME: u32 = 6u32; pub const SQL_DRIVER_NOPROMPT: u32 = 0u32; pub const SQL_DRIVER_ODBC_VER: u32 = 77u32; pub const SQL_DRIVER_PROMPT: u32 = 2u32; pub const SQL_DRIVER_SQL_TYPE_BASE: u32 = 16384u32; pub const SQL_DRIVER_STMT_ATTR_BASE: u32 = 16384u32; pub const SQL_DRIVER_VER: u32 = 7u32; pub const SQL_DROP: u32 = 1u32; pub const SQL_DROP_ASSERTION: u32 = 136u32; pub const SQL_DROP_CHARACTER_SET: u32 = 137u32; pub const SQL_DROP_COLLATION: u32 = 138u32; pub const SQL_DROP_DOMAIN: u32 = 139u32; pub const SQL_DROP_SCHEMA: u32 = 140u32; pub const SQL_DROP_TABLE: u32 = 141u32; pub const SQL_DROP_TRANSLATION: u32 = 142u32; pub const SQL_DROP_VIEW: u32 = 143u32; pub const SQL_DS_CASCADE: i32 = 4i32; pub const SQL_DS_DROP_SCHEMA: i32 = 1i32; pub const SQL_DS_RESTRICT: i32 = 2i32; pub const SQL_DTC_DONE: i32 = 0i32; pub const SQL_DTC_ENLIST_EXPENSIVE: i32 = 1i32; pub const SQL_DTC_TRANSITION_COST: u32 = 1750u32; pub const SQL_DTC_UNENLIST_EXPENSIVE: i32 = 2i32; pub const SQL_DTR_DROP_TRANSLATION: i32 = 1i32; pub const SQL_DT_CASCADE: i32 = 4i32; pub const SQL_DT_DROP_TABLE: i32 = 1i32; pub const SQL_DT_RESTRICT: i32 = 2i32; pub const SQL_DV_CASCADE: i32 = 4i32; pub const SQL_DV_DROP_VIEW: i32 = 1i32; pub const SQL_DV_RESTRICT: i32 = 2i32; pub const SQL_DYNAMIC_CURSOR_ATTRIBUTES1: u32 = 144u32; pub const SQL_DYNAMIC_CURSOR_ATTRIBUTES2: u32 = 145u32; pub const SQL_ENSURE: u32 = 1u32; pub const SQL_ENTIRE_ROWSET: u32 = 0u32; pub const SQL_EN_OFF: i32 = 0i32; pub const SQL_EN_ON: i32 = 1i32; pub const SQL_ERROR: i32 = -1i32; pub const SQL_EXPRESSIONS_IN_ORDERBY: u32 = 27u32; pub const SQL_EXT_API_LAST: u32 = 72u32; pub const SQL_EXT_API_START: u32 = 40u32; pub const SQL_FALSE: u32 = 0u32; pub const SQL_FAST_CONNECT: u32 = 1200u32; pub const SQL_FB_DEFAULT: i32 = 0i32; pub const SQL_FB_OFF: i32 = 0i32; pub const SQL_FB_ON: i32 = 1i32; pub const SQL_FC_DEFAULT: i32 = 0i32; pub const SQL_FC_OFF: i32 = 0i32; pub const SQL_FC_ON: i32 = 1i32; pub const SQL_FD_FETCH_ABSOLUTE: i32 = 16i32; pub const SQL_FD_FETCH_BOOKMARK: i32 = 128i32; pub const SQL_FD_FETCH_FIRST: i32 = 2i32; pub const SQL_FD_FETCH_LAST: i32 = 4i32; pub const SQL_FD_FETCH_NEXT: i32 = 1i32; pub const SQL_FD_FETCH_PREV: i32 = 8i32; pub const SQL_FD_FETCH_PRIOR: i32 = 8i32; pub const SQL_FD_FETCH_RELATIVE: i32 = 32i32; pub const SQL_FD_FETCH_RESUME: i32 = 64i32; pub const SQL_FETCH_ABSOLUTE: u32 = 5u32; pub const SQL_FETCH_BOOKMARK: u32 = 8u32; pub const SQL_FETCH_BY_BOOKMARK: u32 = 7u32; pub const SQL_FETCH_DIRECTION: u32 = 8u32; pub const SQL_FETCH_FIRST: u32 = 2u32; pub const SQL_FETCH_FIRST_SYSTEM: u32 = 32u32; pub const SQL_FETCH_FIRST_USER: u32 = 31u32; pub const SQL_FETCH_LAST: u32 = 3u32; pub const SQL_FETCH_NEXT: u32 = 1u32; pub const SQL_FETCH_PREV: u32 = 4u32; pub const SQL_FETCH_PRIOR: u32 = 4u32; pub const SQL_FETCH_RELATIVE: u32 = 6u32; pub const SQL_FETCH_RESUME: u32 = 7u32; pub const SQL_FILE_CATALOG: u32 = 2u32; pub const SQL_FILE_NOT_SUPPORTED: u32 = 0u32; pub const SQL_FILE_QUALIFIER: u32 = 2u32; pub const SQL_FILE_TABLE: u32 = 1u32; pub const SQL_FILE_USAGE: u32 = 84u32; pub const SQL_FLOAT: u32 = 6u32; pub const SQL_FN_CVT_CAST: i32 = 2i32; pub const SQL_FN_CVT_CONVERT: i32 = 1i32; pub const SQL_FN_NUM_ABS: i32 = 1i32; pub const SQL_FN_NUM_ACOS: i32 = 2i32; pub const SQL_FN_NUM_ASIN: i32 = 4i32; pub const SQL_FN_NUM_ATAN: i32 = 8i32; pub const SQL_FN_NUM_ATAN2: i32 = 16i32; pub const SQL_FN_NUM_CEILING: i32 = 32i32; pub const SQL_FN_NUM_COS: i32 = 64i32; pub const SQL_FN_NUM_COT: i32 = 128i32; pub const SQL_FN_NUM_DEGREES: i32 = 262144i32; pub const SQL_FN_NUM_EXP: i32 = 256i32; pub const SQL_FN_NUM_FLOOR: i32 = 512i32; pub const SQL_FN_NUM_LOG: i32 = 1024i32; pub const SQL_FN_NUM_LOG10: i32 = 524288i32; pub const SQL_FN_NUM_MOD: i32 = 2048i32; pub const SQL_FN_NUM_PI: i32 = 65536i32; pub const SQL_FN_NUM_POWER: i32 = 1048576i32; pub const SQL_FN_NUM_RADIANS: i32 = 2097152i32; pub const SQL_FN_NUM_RAND: i32 = 131072i32; pub const SQL_FN_NUM_ROUND: i32 = 4194304i32; pub const SQL_FN_NUM_SIGN: i32 = 4096i32; pub const SQL_FN_NUM_SIN: i32 = 8192i32; pub const SQL_FN_NUM_SQRT: i32 = 16384i32; pub const SQL_FN_NUM_TAN: i32 = 32768i32; pub const SQL_FN_NUM_TRUNCATE: i32 = 8388608i32; pub const SQL_FN_STR_ASCII: i32 = 8192i32; pub const SQL_FN_STR_BIT_LENGTH: i32 = 524288i32; pub const SQL_FN_STR_CHAR: i32 = 16384i32; pub const SQL_FN_STR_CHARACTER_LENGTH: i32 = 2097152i32; pub const SQL_FN_STR_CHAR_LENGTH: i32 = 1048576i32; pub const SQL_FN_STR_CONCAT: i32 = 1i32; pub const SQL_FN_STR_DIFFERENCE: i32 = 32768i32; pub const SQL_FN_STR_INSERT: i32 = 2i32; pub const SQL_FN_STR_LCASE: i32 = 64i32; pub const SQL_FN_STR_LEFT: i32 = 4i32; pub const SQL_FN_STR_LENGTH: i32 = 16i32; pub const SQL_FN_STR_LOCATE: i32 = 32i32; pub const SQL_FN_STR_LOCATE_2: i32 = 65536i32; pub const SQL_FN_STR_LTRIM: i32 = 8i32; pub const SQL_FN_STR_OCTET_LENGTH: i32 = 4194304i32; pub const SQL_FN_STR_POSITION: i32 = 8388608i32; pub const SQL_FN_STR_REPEAT: i32 = 128i32; pub const SQL_FN_STR_REPLACE: i32 = 256i32; pub const SQL_FN_STR_RIGHT: i32 = 512i32; pub const SQL_FN_STR_RTRIM: i32 = 1024i32; pub const SQL_FN_STR_SOUNDEX: i32 = 131072i32; pub const SQL_FN_STR_SPACE: i32 = 262144i32; pub const SQL_FN_STR_SUBSTRING: i32 = 2048i32; pub const SQL_FN_STR_UCASE: i32 = 4096i32; pub const SQL_FN_SYS_DBNAME: i32 = 2i32; pub const SQL_FN_SYS_IFNULL: i32 = 4i32; pub const SQL_FN_SYS_USERNAME: i32 = 1i32; pub const SQL_FN_TD_CURDATE: i32 = 2i32; pub const SQL_FN_TD_CURRENT_DATE: i32 = 131072i32; pub const SQL_FN_TD_CURRENT_TIME: i32 = 262144i32; pub const SQL_FN_TD_CURRENT_TIMESTAMP: i32 = 524288i32; pub const SQL_FN_TD_CURTIME: i32 = 512i32; pub const SQL_FN_TD_DAYNAME: i32 = 32768i32; pub const SQL_FN_TD_DAYOFMONTH: i32 = 4i32; pub const SQL_FN_TD_DAYOFWEEK: i32 = 8i32; pub const SQL_FN_TD_DAYOFYEAR: i32 = 16i32; pub const SQL_FN_TD_EXTRACT: i32 = 1048576i32; pub const SQL_FN_TD_HOUR: i32 = 1024i32; pub const SQL_FN_TD_MINUTE: i32 = 2048i32; pub const SQL_FN_TD_MONTH: i32 = 32i32; pub const SQL_FN_TD_MONTHNAME: i32 = 65536i32; pub const SQL_FN_TD_NOW: i32 = 1i32; pub const SQL_FN_TD_QUARTER: i32 = 64i32; pub const SQL_FN_TD_SECOND: i32 = 4096i32; pub const SQL_FN_TD_TIMESTAMPADD: i32 = 8192i32; pub const SQL_FN_TD_TIMESTAMPDIFF: i32 = 16384i32; pub const SQL_FN_TD_WEEK: i32 = 128i32; pub const SQL_FN_TD_YEAR: i32 = 256i32; pub const SQL_FN_TSI_DAY: i32 = 16i32; pub const SQL_FN_TSI_FRAC_SECOND: i32 = 1i32; pub const SQL_FN_TSI_HOUR: i32 = 8i32; pub const SQL_FN_TSI_MINUTE: i32 = 4i32; pub const SQL_FN_TSI_MONTH: i32 = 64i32; pub const SQL_FN_TSI_QUARTER: i32 = 128i32; pub const SQL_FN_TSI_SECOND: i32 = 2i32; pub const SQL_FN_TSI_WEEK: i32 = 32i32; pub const SQL_FN_TSI_YEAR: i32 = 256i32; pub const SQL_FORWARD_ONLY_CURSOR_ATTRIBUTES1: u32 = 146u32; pub const SQL_FORWARD_ONLY_CURSOR_ATTRIBUTES2: u32 = 147u32; pub const SQL_GB_COLLATE: u32 = 4u32; pub const SQL_GB_GROUP_BY_CONTAINS_SELECT: u32 = 2u32; pub const SQL_GB_GROUP_BY_EQUALS_SELECT: u32 = 1u32; pub const SQL_GB_NOT_SUPPORTED: u32 = 0u32; pub const SQL_GB_NO_RELATION: u32 = 3u32; pub const SQL_GD_ANY_COLUMN: i32 = 1i32; pub const SQL_GD_ANY_ORDER: i32 = 2i32; pub const SQL_GD_BLOCK: i32 = 4i32; pub const SQL_GD_BOUND: i32 = 8i32; pub const SQL_GD_OUTPUT_PARAMS: i32 = 16i32; pub const SQL_GETDATA_EXTENSIONS: u32 = 81u32; pub const SQL_GET_BOOKMARK: u32 = 13u32; pub const SQL_GROUP_BY: u32 = 88u32; pub const SQL_GUID: i32 = -11i32; pub const SQL_HANDLE_DBC: u32 = 2u32; pub const SQL_HANDLE_DBC_INFO_TOKEN: u32 = 6u32; pub const SQL_HANDLE_DESC: u32 = 4u32; pub const SQL_HANDLE_ENV: u32 = 1u32; pub const SQL_HANDLE_SENV: u32 = 5u32; pub const SQL_HANDLE_STMT: u32 = 3u32; pub const SQL_HC_DEFAULT: i32 = 0i32; pub const SQL_HC_OFF: i32 = 0i32; pub const SQL_HC_ON: i32 = 1i32; pub const SQL_HOUR: u32 = 4u32; pub const SQL_HOUR_TO_MINUTE: u32 = 11u32; pub const SQL_HOUR_TO_SECOND: u32 = 12u32; pub const SQL_IC_LOWER: u32 = 2u32; pub const SQL_IC_MIXED: u32 = 4u32; pub const SQL_IC_SENSITIVE: u32 = 3u32; pub const SQL_IC_UPPER: u32 = 1u32; pub const SQL_IDENTIFIER_CASE: u32 = 28u32; pub const SQL_IDENTIFIER_QUOTE_CHAR: u32 = 29u32; pub const SQL_IGNORE: i32 = -6i32; pub const SQL_IK_ASC: i32 = 1i32; pub const SQL_IK_DESC: i32 = 2i32; pub const SQL_IK_NONE: i32 = 0i32; pub const SQL_INDEX_ALL: u32 = 1u32; pub const SQL_INDEX_CLUSTERED: u32 = 1u32; pub const SQL_INDEX_HASHED: u32 = 2u32; pub const SQL_INDEX_KEYWORDS: u32 = 148u32; pub const SQL_INDEX_OTHER: u32 = 3u32; pub const SQL_INDEX_UNIQUE: u32 = 0u32; pub const SQL_INFO_DRIVER_START: u32 = 1000u32; pub const SQL_INFO_FIRST: u32 = 0u32; pub const SQL_INFO_LAST: u32 = 114u32; pub const SQL_INFO_SCHEMA_VIEWS: u32 = 149u32; pub const SQL_INFO_SS_FIRST: u32 = 1199u32; pub const SQL_INFO_SS_MAX_USED: u32 = 1200u32; pub const SQL_INFO_SS_NETLIB_NAME: u32 = 1199u32; pub const SQL_INFO_SS_NETLIB_NAMEA: u32 = 1200u32; pub const SQL_INFO_SS_NETLIB_NAMEW: u32 = 1199u32; pub const SQL_INITIALLY_DEFERRED: u32 = 5u32; pub const SQL_INITIALLY_IMMEDIATE: u32 = 6u32; pub const SQL_INSENSITIVE: u32 = 1u32; pub const SQL_INSERT_STATEMENT: u32 = 172u32; pub const SQL_INTEGER: u32 = 4u32; pub const SQL_INTEGRATED_SECURITY: u32 = 1203u32; pub const SQL_INTEGRITY: u32 = 73u32; pub const SQL_INTERVAL: u32 = 10u32; pub const SQL_INTERVAL_DAY: i32 = -83i32; pub const SQL_INTERVAL_DAY_TO_HOUR: i32 = -87i32; pub const SQL_INTERVAL_DAY_TO_MINUTE: i32 = -88i32; pub const SQL_INTERVAL_DAY_TO_SECOND: i32 = -89i32; pub const SQL_INTERVAL_HOUR: i32 = -84i32; pub const SQL_INTERVAL_HOUR_TO_MINUTE: i32 = -90i32; pub const SQL_INTERVAL_HOUR_TO_SECOND: i32 = -91i32; pub const SQL_INTERVAL_MINUTE: i32 = -85i32; pub const SQL_INTERVAL_MINUTE_TO_SECOND: i32 = -92i32; pub const SQL_INTERVAL_MONTH: i32 = -81i32; pub const SQL_INTERVAL_SECOND: i32 = -86i32; #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] pub struct SQL_INTERVAL_STRUCT { pub interval_type: SQLINTERVAL, pub interval_sign: i16, pub intval: SQL_INTERVAL_STRUCT_0, } impl SQL_INTERVAL_STRUCT {} impl ::core::default::Default for SQL_INTERVAL_STRUCT { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } impl ::core::cmp::PartialEq for SQL_INTERVAL_STRUCT { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } impl ::core::cmp::Eq for SQL_INTERVAL_STRUCT {} unsafe impl ::windows::core::Abi for SQL_INTERVAL_STRUCT { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] pub union SQL_INTERVAL_STRUCT_0 { pub year_month: tagSQL_YEAR_MONTH, pub day_second: tagSQL_DAY_SECOND, } impl SQL_INTERVAL_STRUCT_0 {} impl ::core::default::Default for SQL_INTERVAL_STRUCT_0 { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } impl ::core::cmp::PartialEq for SQL_INTERVAL_STRUCT_0 { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } impl ::core::cmp::Eq for SQL_INTERVAL_STRUCT_0 {} unsafe impl ::windows::core::Abi for SQL_INTERVAL_STRUCT_0 { type Abi = Self; } pub const SQL_INTERVAL_YEAR: i32 = -80i32; pub const SQL_INTERVAL_YEAR_TO_MONTH: i32 = -82i32; pub const SQL_INVALID_HANDLE: i32 = -2i32; pub const SQL_ISV_ASSERTIONS: i32 = 1i32; pub const SQL_ISV_CHARACTER_SETS: i32 = 2i32; pub const SQL_ISV_CHECK_CONSTRAINTS: i32 = 4i32; pub const SQL_ISV_COLLATIONS: i32 = 8i32; pub const SQL_ISV_COLUMNS: i32 = 64i32; pub const SQL_ISV_COLUMN_DOMAIN_USAGE: i32 = 16i32; pub const SQL_ISV_COLUMN_PRIVILEGES: i32 = 32i32; pub const SQL_ISV_CONSTRAINT_COLUMN_USAGE: i32 = 128i32; pub const SQL_ISV_CONSTRAINT_TABLE_USAGE: i32 = 256i32; pub const SQL_ISV_DOMAINS: i32 = 1024i32; pub const SQL_ISV_DOMAIN_CONSTRAINTS: i32 = 512i32; pub const SQL_ISV_KEY_COLUMN_USAGE: i32 = 2048i32; pub const SQL_ISV_REFERENTIAL_CONSTRAINTS: i32 = 4096i32; pub const SQL_ISV_SCHEMATA: i32 = 8192i32; pub const SQL_ISV_SQL_LANGUAGES: i32 = 16384i32; pub const SQL_ISV_TABLES: i32 = 131072i32; pub const SQL_ISV_TABLE_CONSTRAINTS: i32 = 32768i32; pub const SQL_ISV_TABLE_PRIVILEGES: i32 = 65536i32; pub const SQL_ISV_TRANSLATIONS: i32 = 262144i32; pub const SQL_ISV_USAGE_PRIVILEGES: i32 = 524288i32; pub const SQL_ISV_VIEWS: i32 = 4194304i32; pub const SQL_ISV_VIEW_COLUMN_USAGE: i32 = 1048576i32; pub const SQL_ISV_VIEW_TABLE_USAGE: i32 = 2097152i32; pub const SQL_IS_DEFAULT: i32 = 0i32; pub const SQL_IS_INSERT_LITERALS: i32 = 1i32; pub const SQL_IS_INSERT_SEARCHED: i32 = 2i32; pub const SQL_IS_INTEGER: i32 = -6i32; pub const SQL_IS_OFF: i32 = 0i32; pub const SQL_IS_ON: i32 = 1i32; pub const SQL_IS_POINTER: i32 = -4i32; pub const SQL_IS_SELECT_INTO: i32 = 4i32; pub const SQL_IS_SMALLINT: i32 = -8i32; pub const SQL_IS_UINTEGER: i32 = -5i32; pub const SQL_IS_USMALLINT: i32 = -7i32; pub const SQL_KEYSET_CURSOR_ATTRIBUTES1: u32 = 150u32; pub const SQL_KEYSET_CURSOR_ATTRIBUTES2: u32 = 151u32; pub const SQL_KEYSET_SIZE: u32 = 8u32; pub const SQL_KEYSET_SIZE_DEFAULT: u32 = 0u32; pub const SQL_KEYWORDS: u32 = 89u32; pub const SQL_LCK_EXCLUSIVE: i32 = 2i32; pub const SQL_LCK_NO_CHANGE: i32 = 1i32; pub const SQL_LCK_UNLOCK: i32 = 4i32; pub const SQL_LEN_BINARY_ATTR_OFFSET: i32 = -100i32; pub const SQL_LEN_DATA_AT_EXEC_OFFSET: i32 = -100i32; pub const SQL_LIKE_ESCAPE_CLAUSE: u32 = 113u32; pub const SQL_LIKE_ONLY: u32 = 1u32; pub const SQL_LOCK_EXCLUSIVE: u32 = 1u32; pub const SQL_LOCK_NO_CHANGE: u32 = 0u32; pub const SQL_LOCK_TYPES: u32 = 78u32; pub const SQL_LOCK_UNLOCK: u32 = 2u32; pub const SQL_LOGIN_TIMEOUT: u32 = 103u32; pub const SQL_LOGIN_TIMEOUT_DEFAULT: u32 = 15u32; pub const SQL_LONGVARBINARY: i32 = -4i32; pub const SQL_LONGVARCHAR: i32 = -1i32; pub const SQL_MAXIMUM_CATALOG_NAME_LENGTH: u32 = 34u32; pub const SQL_MAXIMUM_COLUMNS_IN_GROUP_BY: u32 = 97u32; pub const SQL_MAXIMUM_COLUMNS_IN_INDEX: u32 = 98u32; pub const SQL_MAXIMUM_COLUMNS_IN_ORDER_BY: u32 = 99u32; pub const SQL_MAXIMUM_COLUMNS_IN_SELECT: u32 = 100u32; pub const SQL_MAXIMUM_COLUMN_NAME_LENGTH: u32 = 30u32; pub const SQL_MAXIMUM_CONCURRENT_ACTIVITIES: u32 = 1u32; pub const SQL_MAXIMUM_CURSOR_NAME_LENGTH: u32 = 31u32; pub const SQL_MAXIMUM_DRIVER_CONNECTIONS: u32 = 0u32; pub const SQL_MAXIMUM_IDENTIFIER_LENGTH: u32 = 10005u32; pub const SQL_MAXIMUM_INDEX_SIZE: u32 = 102u32; pub const SQL_MAXIMUM_ROW_SIZE: u32 = 104u32; pub const SQL_MAXIMUM_SCHEMA_NAME_LENGTH: u32 = 32u32; pub const SQL_MAXIMUM_STATEMENT_LENGTH: u32 = 105u32; pub const SQL_MAXIMUM_TABLES_IN_SELECT: u32 = 106u32; pub const SQL_MAXIMUM_USER_NAME_LENGTH: u32 = 107u32; pub const SQL_MAX_ASYNC_CONCURRENT_STATEMENTS: u32 = 10022u32; pub const SQL_MAX_BINARY_LITERAL_LEN: u32 = 112u32; pub const SQL_MAX_CATALOG_NAME_LEN: u32 = 34u32; pub const SQL_MAX_CHAR_LITERAL_LEN: u32 = 108u32; pub const SQL_MAX_COLUMNS_IN_GROUP_BY: u32 = 97u32; pub const SQL_MAX_COLUMNS_IN_INDEX: u32 = 98u32; pub const SQL_MAX_COLUMNS_IN_ORDER_BY: u32 = 99u32; pub const SQL_MAX_COLUMNS_IN_SELECT: u32 = 100u32; pub const SQL_MAX_COLUMNS_IN_TABLE: u32 = 101u32; pub const SQL_MAX_COLUMN_NAME_LEN: u32 = 30u32; pub const SQL_MAX_CONCURRENT_ACTIVITIES: u32 = 1u32; pub const SQL_MAX_CURSOR_NAME_LEN: u32 = 31u32; pub const SQL_MAX_DRIVER_CONNECTIONS: u32 = 0u32; pub const SQL_MAX_DSN_LENGTH: u32 = 32u32; pub const SQL_MAX_IDENTIFIER_LEN: u32 = 10005u32; pub const SQL_MAX_INDEX_SIZE: u32 = 102u32; pub const SQL_MAX_LENGTH: u32 = 3u32; pub const SQL_MAX_LENGTH_DEFAULT: u32 = 0u32; pub const SQL_MAX_MESSAGE_LENGTH: u32 = 512u32; pub const SQL_MAX_NUMERIC_LEN: u32 = 16u32; pub const SQL_MAX_OPTION_STRING_LENGTH: u32 = 256u32; pub const SQL_MAX_OWNER_NAME_LEN: u32 = 32u32; pub const SQL_MAX_PROCEDURE_NAME_LEN: u32 = 33u32; pub const SQL_MAX_QUALIFIER_NAME_LEN: u32 = 34u32; pub const SQL_MAX_ROWS: u32 = 1u32; pub const SQL_MAX_ROWS_DEFAULT: u32 = 0u32; pub const SQL_MAX_ROW_SIZE: u32 = 104u32; pub const SQL_MAX_ROW_SIZE_INCLUDES_LONG: u32 = 103u32; pub const SQL_MAX_SCHEMA_NAME_LEN: u32 = 32u32; pub const SQL_MAX_SQLSERVERNAME: u32 = 128u32; pub const SQL_MAX_STATEMENT_LEN: u32 = 105u32; pub const SQL_MAX_TABLES_IN_SELECT: u32 = 106u32; pub const SQL_MAX_TABLE_NAME_LEN: u32 = 35u32; pub const SQL_MAX_USER_NAME_LEN: u32 = 107u32; pub const SQL_MINUTE: u32 = 5u32; pub const SQL_MINUTE_TO_SECOND: u32 = 13u32; pub const SQL_MODE_DEFAULT: u32 = 0u32; pub const SQL_MODE_READ_ONLY: u32 = 1u32; pub const SQL_MODE_READ_WRITE: u32 = 0u32; pub const SQL_MONTH: u32 = 2u32; pub const SQL_MORE_INFO_NO: i32 = 0i32; pub const SQL_MORE_INFO_YES: i32 = 1i32; pub const SQL_MULTIPLE_ACTIVE_TXN: u32 = 37u32; pub const SQL_MULT_RESULT_SETS: u32 = 36u32; pub const SQL_NAMED: u32 = 0u32; pub const SQL_NB_DEFAULT: i32 = 0i32; pub const SQL_NB_OFF: i32 = 0i32; pub const SQL_NB_ON: i32 = 1i32; pub const SQL_NC_END: u32 = 4u32; pub const SQL_NC_HIGH: u32 = 0u32; pub const SQL_NC_LOW: u32 = 1u32; pub const SQL_NC_OFF: i32 = 0i32; pub const SQL_NC_ON: i32 = 1i32; pub const SQL_NC_START: u32 = 2u32; pub const SQL_NEED_DATA: u32 = 99u32; pub const SQL_NEED_LONG_DATA_LEN: u32 = 111u32; pub const SQL_NNC_NON_NULL: u32 = 1u32; pub const SQL_NNC_NULL: u32 = 0u32; pub const SQL_NONSCROLLABLE: u32 = 0u32; pub const SQL_NON_NULLABLE_COLUMNS: u32 = 75u32; pub const SQL_NOSCAN: u32 = 2u32; pub const SQL_NOSCAN_DEFAULT: u32 = 0u32; pub const SQL_NOSCAN_OFF: u32 = 0u32; pub const SQL_NOSCAN_ON: u32 = 1u32; pub const SQL_NOT_DEFERRABLE: u32 = 7u32; pub const SQL_NO_ACTION: u32 = 3u32; pub const SQL_NO_COLUMN_NUMBER: i32 = -1i32; pub const SQL_NO_DATA: u32 = 100u32; pub const SQL_NO_DATA_FOUND: u32 = 100u32; pub const SQL_NO_NULLS: u32 = 0u32; pub const SQL_NO_ROW_NUMBER: i32 = -1i32; pub const SQL_NO_TOTAL: i32 = -4i32; pub const SQL_NTS: i32 = -3i32; pub const SQL_NTSL: i32 = -3i32; pub const SQL_NULLABLE: u32 = 1u32; pub const SQL_NULLABLE_UNKNOWN: u32 = 2u32; pub const SQL_NULL_COLLATION: u32 = 85u32; pub const SQL_NULL_DATA: i32 = -1i32; pub const SQL_NULL_HANDLE: i32 = 0i32; pub const SQL_NULL_HDBC: u32 = 0u32; pub const SQL_NULL_HDESC: u32 = 0u32; pub const SQL_NULL_HENV: u32 = 0u32; pub const SQL_NULL_HSTMT: u32 = 0u32; pub const SQL_NUMERIC: u32 = 2u32; pub const SQL_NUMERIC_FUNCTIONS: u32 = 49u32; #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] pub struct SQL_NUMERIC_STRUCT { pub precision: u8, pub scale: i8, pub sign: u8, pub val: [u8; 16], } impl SQL_NUMERIC_STRUCT {} impl ::core::default::Default for SQL_NUMERIC_STRUCT { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } impl ::core::fmt::Debug for SQL_NUMERIC_STRUCT { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("SQL_NUMERIC_STRUCT").field("precision", &self.precision).field("scale", &self.scale).field("sign", &self.sign).field("val", &self.val).finish() } } impl ::core::cmp::PartialEq for SQL_NUMERIC_STRUCT { fn eq(&self, other: &Self) -> bool { self.precision == other.precision && self.scale == other.scale && self.sign == other.sign && self.val == other.val } } impl ::core::cmp::Eq for SQL_NUMERIC_STRUCT {} unsafe impl ::windows::core::Abi for SQL_NUMERIC_STRUCT { type Abi = Self; } pub const SQL_NUM_FUNCTIONS: u32 = 23u32; pub const SQL_OAC_LEVEL1: u32 = 1u32; pub const SQL_OAC_LEVEL2: u32 = 2u32; pub const SQL_OAC_NONE: u32 = 0u32; pub const SQL_ODBC_API_CONFORMANCE: u32 = 9u32; pub const SQL_ODBC_CURSORS: u32 = 110u32; pub const SQL_ODBC_INTERFACE_CONFORMANCE: u32 = 152u32; pub const SQL_ODBC_SAG_CLI_CONFORMANCE: u32 = 12u32; pub const SQL_ODBC_SQL_CONFORMANCE: u32 = 15u32; pub const SQL_ODBC_SQL_OPT_IEF: u32 = 73u32; pub const SQL_ODBC_VER: u32 = 10u32; pub const SQL_OIC_CORE: u32 = 1u32; pub const SQL_OIC_LEVEL1: u32 = 2u32; pub const SQL_OIC_LEVEL2: u32 = 3u32; pub const SQL_OJ_ALL_COMPARISON_OPS: i32 = 64i32; pub const SQL_OJ_CAPABILITIES: u32 = 115u32; pub const SQL_OJ_FULL: i32 = 4i32; pub const SQL_OJ_INNER: i32 = 32i32; pub const SQL_OJ_LEFT: i32 = 1i32; pub const SQL_OJ_NESTED: i32 = 8i32; pub const SQL_OJ_NOT_ORDERED: i32 = 16i32; pub const SQL_OJ_RIGHT: i32 = 2i32; pub const SQL_OPT_TRACE: u32 = 104u32; pub const SQL_OPT_TRACEFILE: u32 = 105u32; pub const SQL_OPT_TRACE_DEFAULT: u32 = 0u32; pub const SQL_OPT_TRACE_OFF: u32 = 0u32; pub const SQL_OPT_TRACE_ON: u32 = 1u32; pub const SQL_ORDER_BY_COLUMNS_IN_SELECT: u32 = 90u32; pub const SQL_OSCC_COMPLIANT: u32 = 1u32; pub const SQL_OSCC_NOT_COMPLIANT: u32 = 0u32; pub const SQL_OSC_CORE: u32 = 1u32; pub const SQL_OSC_EXTENDED: u32 = 2u32; pub const SQL_OSC_MINIMUM: u32 = 0u32; pub const SQL_OUTER_JOINS: u32 = 38u32; pub const SQL_OUTER_JOIN_CAPABILITIES: u32 = 115u32; pub const SQL_OU_DML_STATEMENTS: i32 = 1i32; pub const SQL_OU_INDEX_DEFINITION: i32 = 8i32; pub const SQL_OU_PRIVILEGE_DEFINITION: i32 = 16i32; pub const SQL_OU_PROCEDURE_INVOCATION: i32 = 2i32; pub const SQL_OU_TABLE_DEFINITION: i32 = 4i32; pub const SQL_OV_ODBC2: u32 = 2u32; pub const SQL_OV_ODBC3: u32 = 3u32; pub const SQL_OV_ODBC3_80: u32 = 380u32; pub const SQL_OWNER_TERM: u32 = 39u32; pub const SQL_OWNER_USAGE: u32 = 91u32; pub const SQL_PACKET_SIZE: u32 = 112u32; pub const SQL_PARAM_ARRAY_ROW_COUNTS: u32 = 153u32; pub const SQL_PARAM_ARRAY_SELECTS: u32 = 154u32; pub const SQL_PARAM_BIND_BY_COLUMN: u32 = 0u32; pub const SQL_PARAM_BIND_TYPE_DEFAULT: u32 = 0u32; pub const SQL_PARAM_DATA_AVAILABLE: u32 = 101u32; pub const SQL_PARAM_DIAG_UNAVAILABLE: u32 = 1u32; pub const SQL_PARAM_ERROR: u32 = 5u32; pub const SQL_PARAM_IGNORE: u32 = 1u32; pub const SQL_PARAM_INPUT: u32 = 1u32; pub const SQL_PARAM_INPUT_OUTPUT: u32 = 2u32; pub const SQL_PARAM_INPUT_OUTPUT_STREAM: u32 = 8u32; pub const SQL_PARAM_OUTPUT: u32 = 4u32; pub const SQL_PARAM_OUTPUT_STREAM: u32 = 16u32; pub const SQL_PARAM_PROCEED: u32 = 0u32; pub const SQL_PARAM_SUCCESS: u32 = 0u32; pub const SQL_PARAM_SUCCESS_WITH_INFO: u32 = 6u32; pub const SQL_PARAM_TYPE_UNKNOWN: u32 = 0u32; pub const SQL_PARAM_UNUSED: u32 = 7u32; pub const SQL_PARC_BATCH: u32 = 1u32; pub const SQL_PARC_NO_BATCH: u32 = 2u32; pub const SQL_PAS_BATCH: u32 = 1u32; pub const SQL_PAS_NO_BATCH: u32 = 2u32; pub const SQL_PAS_NO_SELECT: u32 = 3u32; pub const SQL_PC_DEFAULT: i32 = 0i32; pub const SQL_PC_NON_PSEUDO: u32 = 1u32; pub const SQL_PC_NOT_PSEUDO: u32 = 1u32; pub const SQL_PC_OFF: i32 = 0i32; pub const SQL_PC_ON: i32 = 1i32; pub const SQL_PC_PSEUDO: u32 = 2u32; pub const SQL_PC_UNKNOWN: u32 = 0u32; pub const SQL_PERF_START: u32 = 1u32; pub const SQL_PERF_STOP: u32 = 2u32; pub const SQL_POSITION: u32 = 0u32; pub const SQL_POSITIONED_STATEMENTS: u32 = 80u32; pub const SQL_POS_ADD: i32 = 16i32; pub const SQL_POS_DELETE: i32 = 8i32; pub const SQL_POS_OPERATIONS: u32 = 79u32; pub const SQL_POS_POSITION: i32 = 1i32; pub const SQL_POS_REFRESH: i32 = 2i32; pub const SQL_POS_UPDATE: i32 = 4i32; pub const SQL_PRED_BASIC: u32 = 2u32; pub const SQL_PRED_CHAR: u32 = 1u32; pub const SQL_PRED_NONE: u32 = 0u32; pub const SQL_PRED_SEARCHABLE: u32 = 3u32; pub const SQL_PRESERVE_CURSORS: u32 = 1204u32; pub const SQL_PROCEDURES: u32 = 21u32; pub const SQL_PROCEDURE_TERM: u32 = 40u32; pub const SQL_PS_POSITIONED_DELETE: i32 = 1i32; pub const SQL_PS_POSITIONED_UPDATE: i32 = 2i32; pub const SQL_PS_SELECT_FOR_UPDATE: i32 = 4i32; pub const SQL_PT_FUNCTION: u32 = 2u32; pub const SQL_PT_PROCEDURE: u32 = 1u32; pub const SQL_PT_UNKNOWN: u32 = 0u32; pub const SQL_QI_DEFAULT: i32 = 1i32; pub const SQL_QI_OFF: i32 = 0i32; pub const SQL_QI_ON: i32 = 1i32; pub const SQL_QL_END: u32 = 2u32; pub const SQL_QL_START: u32 = 1u32; pub const SQL_QUALIFIER_LOCATION: u32 = 114u32; pub const SQL_QUALIFIER_NAME_SEPARATOR: u32 = 41u32; pub const SQL_QUALIFIER_TERM: u32 = 42u32; pub const SQL_QUALIFIER_USAGE: u32 = 92u32; pub const SQL_QUERY_TIMEOUT: u32 = 0u32; pub const SQL_QUERY_TIMEOUT_DEFAULT: u32 = 0u32; pub const SQL_QUICK: u32 = 0u32; pub const SQL_QUIET_MODE: u32 = 111u32; pub const SQL_QUOTED_IDENTIFIER_CASE: u32 = 93u32; pub const SQL_QU_DML_STATEMENTS: i32 = 1i32; pub const SQL_QU_INDEX_DEFINITION: i32 = 8i32; pub const SQL_QU_PRIVILEGE_DEFINITION: i32 = 16i32; pub const SQL_QU_PROCEDURE_INVOCATION: i32 = 2i32; pub const SQL_QU_TABLE_DEFINITION: i32 = 4i32; pub const SQL_RD_DEFAULT: u32 = 1u32; pub const SQL_RD_OFF: u32 = 0u32; pub const SQL_RD_ON: u32 = 1u32; pub const SQL_REAL: u32 = 7u32; pub const SQL_REFRESH: u32 = 1u32; pub const SQL_REMOTE_PWD: u32 = 1201u32; pub const SQL_RESET_CONNECTION_YES: u32 = 1u32; pub const SQL_RESET_PARAMS: u32 = 3u32; pub const SQL_RESET_YES: i32 = 1i32; pub const SQL_RESTRICT: u32 = 1u32; pub const SQL_RESULT_COL: u32 = 3u32; pub const SQL_RETRIEVE_DATA: u32 = 11u32; pub const SQL_RETURN_VALUE: u32 = 5u32; pub const SQL_RE_DEFAULT: i32 = 0i32; pub const SQL_RE_OFF: i32 = 0i32; pub const SQL_RE_ON: i32 = 1i32; pub const SQL_ROLLBACK: u32 = 1u32; pub const SQL_ROWSET_SIZE: u32 = 9u32; pub const SQL_ROWSET_SIZE_DEFAULT: u32 = 1u32; pub const SQL_ROWVER: u32 = 2u32; pub const SQL_ROW_ADDED: u32 = 4u32; pub const SQL_ROW_DELETED: u32 = 1u32; pub const SQL_ROW_ERROR: u32 = 5u32; pub const SQL_ROW_IDENTIFIER: u32 = 1u32; pub const SQL_ROW_IGNORE: u32 = 1u32; pub const SQL_ROW_NOROW: u32 = 3u32; pub const SQL_ROW_NUMBER: u32 = 14u32; pub const SQL_ROW_NUMBER_UNKNOWN: i32 = -2i32; pub const SQL_ROW_PROCEED: u32 = 0u32; pub const SQL_ROW_SUCCESS: u32 = 0u32; pub const SQL_ROW_SUCCESS_WITH_INFO: u32 = 6u32; pub const SQL_ROW_UPDATED: u32 = 2u32; pub const SQL_ROW_UPDATES: u32 = 11u32; pub const SQL_SCCO_LOCK: i32 = 2i32; pub const SQL_SCCO_OPT_ROWVER: i32 = 4i32; pub const SQL_SCCO_OPT_TIMESTAMP: i32 = 4i32; pub const SQL_SCCO_OPT_VALUES: i32 = 8i32; pub const SQL_SCCO_READ_ONLY: i32 = 1i32; pub const SQL_SCC_ISO92_CLI: i32 = 2i32; pub const SQL_SCC_XOPEN_CLI_VERSION1: i32 = 1i32; pub const SQL_SCHEMA_TERM: u32 = 39u32; pub const SQL_SCHEMA_USAGE: u32 = 91u32; pub const SQL_SCOPE_CURROW: u32 = 0u32; pub const SQL_SCOPE_SESSION: u32 = 2u32; pub const SQL_SCOPE_TRANSACTION: u32 = 1u32; pub const SQL_SCROLLABLE: u32 = 1u32; pub const SQL_SCROLL_CONCURRENCY: u32 = 43u32; pub const SQL_SCROLL_DYNAMIC: i32 = -2i32; pub const SQL_SCROLL_FORWARD_ONLY: i32 = 0i32; pub const SQL_SCROLL_KEYSET_DRIVEN: i32 = -1i32; pub const SQL_SCROLL_OPTIONS: u32 = 44u32; pub const SQL_SCROLL_STATIC: i32 = -3i32; pub const SQL_SC_FIPS127_2_TRANSITIONAL: i32 = 2i32; pub const SQL_SC_NON_UNIQUE: u32 = 0u32; pub const SQL_SC_SQL92_ENTRY: i32 = 1i32; pub const SQL_SC_SQL92_FULL: i32 = 8i32; pub const SQL_SC_SQL92_INTERMEDIATE: i32 = 4i32; pub const SQL_SC_TRY_UNIQUE: u32 = 1u32; pub const SQL_SC_UNIQUE: u32 = 2u32; pub const SQL_SDF_CURRENT_DATE: i32 = 1i32; pub const SQL_SDF_CURRENT_TIME: i32 = 2i32; pub const SQL_SDF_CURRENT_TIMESTAMP: i32 = 4i32; pub const SQL_SEARCHABLE: u32 = 3u32; pub const SQL_SEARCH_PATTERN_ESCAPE: u32 = 14u32; pub const SQL_SECOND: u32 = 6u32; pub const SQL_SENSITIVE: u32 = 2u32; pub const SQL_SERVER_NAME: u32 = 13u32; pub const SQL_SETPARAM_VALUE_MAX: i32 = -1i32; pub const SQL_SETPOS_MAX_LOCK_VALUE: u32 = 2u32; pub const SQL_SETPOS_MAX_OPTION_VALUE: u32 = 4u32; pub const SQL_SET_DEFAULT: u32 = 4u32; pub const SQL_SET_NULL: u32 = 2u32; pub const SQL_SFKD_CASCADE: i32 = 1i32; pub const SQL_SFKD_NO_ACTION: i32 = 2i32; pub const SQL_SFKD_SET_DEFAULT: i32 = 4i32; pub const SQL_SFKD_SET_NULL: i32 = 8i32; pub const SQL_SFKU_CASCADE: i32 = 1i32; pub const SQL_SFKU_NO_ACTION: i32 = 2i32; pub const SQL_SFKU_SET_DEFAULT: i32 = 4i32; pub const SQL_SFKU_SET_NULL: i32 = 8i32; pub const SQL_SG_DELETE_TABLE: i32 = 32i32; pub const SQL_SG_INSERT_COLUMN: i32 = 128i32; pub const SQL_SG_INSERT_TABLE: i32 = 64i32; pub const SQL_SG_REFERENCES_COLUMN: i32 = 512i32; pub const SQL_SG_REFERENCES_TABLE: i32 = 256i32; pub const SQL_SG_SELECT_TABLE: i32 = 1024i32; pub const SQL_SG_UPDATE_COLUMN: i32 = 4096i32; pub const SQL_SG_UPDATE_TABLE: i32 = 2048i32; pub const SQL_SG_USAGE_ON_CHARACTER_SET: i32 = 2i32; pub const SQL_SG_USAGE_ON_COLLATION: i32 = 4i32; pub const SQL_SG_USAGE_ON_DOMAIN: i32 = 1i32; pub const SQL_SG_USAGE_ON_TRANSLATION: i32 = 8i32; pub const SQL_SG_WITH_GRANT_OPTION: i32 = 16i32; pub const SQL_SIGNED_OFFSET: i32 = -20i32; pub const SQL_SIMULATE_CURSOR: u32 = 10u32; pub const SQL_SMALLINT: u32 = 5u32; pub const SQL_SNVF_BIT_LENGTH: i32 = 1i32; pub const SQL_SNVF_CHARACTER_LENGTH: i32 = 4i32; pub const SQL_SNVF_CHAR_LENGTH: i32 = 2i32; pub const SQL_SNVF_EXTRACT: i32 = 8i32; pub const SQL_SNVF_OCTET_LENGTH: i32 = 16i32; pub const SQL_SNVF_POSITION: i32 = 32i32; pub const SQL_SOPT_SS_BASE: u32 = 1225u32; pub const SQL_SOPT_SS_CURRENT_COMMAND: u32 = 1226u32; pub const SQL_SOPT_SS_CURSOR_OPTIONS: u32 = 1230u32; pub const SQL_SOPT_SS_DEFER_PREPARE: u32 = 1232u32; pub const SQL_SOPT_SS_HIDDEN_COLUMNS: u32 = 1227u32; pub const SQL_SOPT_SS_MAX_USED: u32 = 1232u32; pub const SQL_SOPT_SS_NOBROWSETABLE: u32 = 1228u32; pub const SQL_SOPT_SS_NOCOUNT_STATUS: u32 = 1231u32; pub const SQL_SOPT_SS_REGIONALIZE: u32 = 1229u32; pub const SQL_SOPT_SS_TEXTPTR_LOGGING: u32 = 1225u32; pub const SQL_SO_DYNAMIC: i32 = 4i32; pub const SQL_SO_FORWARD_ONLY: i32 = 1i32; pub const SQL_SO_KEYSET_DRIVEN: i32 = 2i32; pub const SQL_SO_MIXED: i32 = 8i32; pub const SQL_SO_STATIC: i32 = 16i32; pub const SQL_SPECIAL_CHARACTERS: u32 = 94u32; pub const SQL_SPEC_MAJOR: u32 = 3u32; pub const SQL_SPEC_MINOR: u32 = 80u32; pub const SQL_SP_BETWEEN: i32 = 2048i32; pub const SQL_SP_COMPARISON: i32 = 4096i32; pub const SQL_SP_EXISTS: i32 = 1i32; pub const SQL_SP_IN: i32 = 1024i32; pub const SQL_SP_ISNOTNULL: i32 = 2i32; pub const SQL_SP_ISNULL: i32 = 4i32; pub const SQL_SP_LIKE: i32 = 512i32; pub const SQL_SP_MATCH_FULL: i32 = 8i32; pub const SQL_SP_MATCH_PARTIAL: i32 = 16i32; pub const SQL_SP_MATCH_UNIQUE_FULL: i32 = 32i32; pub const SQL_SP_MATCH_UNIQUE_PARTIAL: i32 = 64i32; pub const SQL_SP_OVERLAPS: i32 = 128i32; pub const SQL_SP_QUANTIFIED_COMPARISON: i32 = 8192i32; pub const SQL_SP_UNIQUE: i32 = 256i32; pub const SQL_SQL92_DATETIME_FUNCTIONS: u32 = 155u32; pub const SQL_SQL92_FOREIGN_KEY_DELETE_RULE: u32 = 156u32; pub const SQL_SQL92_FOREIGN_KEY_UPDATE_RULE: u32 = 157u32; pub const SQL_SQL92_GRANT: u32 = 158u32; pub const SQL_SQL92_NUMERIC_VALUE_FUNCTIONS: u32 = 159u32; pub const SQL_SQL92_PREDICATES: u32 = 160u32; pub const SQL_SQL92_RELATIONAL_JOIN_OPERATORS: u32 = 161u32; pub const SQL_SQL92_REVOKE: u32 = 162u32; pub const SQL_SQL92_ROW_VALUE_CONSTRUCTOR: u32 = 163u32; pub const SQL_SQL92_STRING_FUNCTIONS: u32 = 164u32; pub const SQL_SQL92_VALUE_EXPRESSIONS: u32 = 165u32; pub const SQL_SQLSTATE_SIZE: u32 = 5u32; pub const SQL_SQLSTATE_SIZEW: u32 = 10u32; pub const SQL_SQL_CONFORMANCE: u32 = 118u32; pub const SQL_SQ_COMPARISON: i32 = 1i32; pub const SQL_SQ_CORRELATED_SUBQUERIES: i32 = 16i32; pub const SQL_SQ_EXISTS: i32 = 2i32; pub const SQL_SQ_IN: i32 = 4i32; pub const SQL_SQ_QUANTIFIED: i32 = 8i32; pub const SQL_SRJO_CORRESPONDING_CLAUSE: i32 = 1i32; pub const SQL_SRJO_CROSS_JOIN: i32 = 2i32; pub const SQL_SRJO_EXCEPT_JOIN: i32 = 4i32; pub const SQL_SRJO_FULL_OUTER_JOIN: i32 = 8i32; pub const SQL_SRJO_INNER_JOIN: i32 = 16i32; pub const SQL_SRJO_INTERSECT_JOIN: i32 = 32i32; pub const SQL_SRJO_LEFT_OUTER_JOIN: i32 = 64i32; pub const SQL_SRJO_NATURAL_JOIN: i32 = 128i32; pub const SQL_SRJO_RIGHT_OUTER_JOIN: i32 = 256i32; pub const SQL_SRJO_UNION_JOIN: i32 = 512i32; pub const SQL_SRVC_DEFAULT: i32 = 4i32; pub const SQL_SRVC_NULL: i32 = 2i32; pub const SQL_SRVC_ROW_SUBQUERY: i32 = 8i32; pub const SQL_SRVC_VALUE_EXPRESSION: i32 = 1i32; pub const SQL_SR_CASCADE: i32 = 32i32; pub const SQL_SR_DELETE_TABLE: i32 = 128i32; pub const SQL_SR_GRANT_OPTION_FOR: i32 = 16i32; pub const SQL_SR_INSERT_COLUMN: i32 = 512i32; pub const SQL_SR_INSERT_TABLE: i32 = 256i32; pub const SQL_SR_REFERENCES_COLUMN: i32 = 2048i32; pub const SQL_SR_REFERENCES_TABLE: i32 = 1024i32; pub const SQL_SR_RESTRICT: i32 = 64i32; pub const SQL_SR_SELECT_TABLE: i32 = 4096i32; pub const SQL_SR_UPDATE_COLUMN: i32 = 16384i32; pub const SQL_SR_UPDATE_TABLE: i32 = 8192i32; pub const SQL_SR_USAGE_ON_CHARACTER_SET: i32 = 2i32; pub const SQL_SR_USAGE_ON_COLLATION: i32 = 4i32; pub const SQL_SR_USAGE_ON_DOMAIN: i32 = 1i32; pub const SQL_SR_USAGE_ON_TRANSLATION: i32 = 8i32; pub const SQL_SSF_CONVERT: i32 = 1i32; pub const SQL_SSF_LOWER: i32 = 2i32; pub const SQL_SSF_SUBSTRING: i32 = 8i32; pub const SQL_SSF_TRANSLATE: i32 = 16i32; pub const SQL_SSF_TRIM_BOTH: i32 = 32i32; pub const SQL_SSF_TRIM_LEADING: i32 = 64i32; pub const SQL_SSF_TRIM_TRAILING: i32 = 128i32; pub const SQL_SSF_UPPER: i32 = 4i32; pub const SQL_SS_ADDITIONS: i32 = 1i32; pub const SQL_SS_DELETIONS: i32 = 2i32; pub const SQL_SS_QI_DEFAULT: u32 = 30000u32; pub const SQL_SS_UPDATES: i32 = 4i32; pub const SQL_SS_VARIANT: i32 = -150i32; pub const SQL_STANDARD_CLI_CONFORMANCE: u32 = 166u32; pub const SQL_STATIC_CURSOR_ATTRIBUTES1: u32 = 167u32; pub const SQL_STATIC_CURSOR_ATTRIBUTES2: u32 = 168u32; pub const SQL_STATIC_SENSITIVITY: u32 = 83u32; pub const SQL_STILL_EXECUTING: u32 = 2u32; pub const SQL_STMT_OPT_MAX: u32 = 14u32; pub const SQL_STMT_OPT_MIN: u32 = 0u32; pub const SQL_STRING_FUNCTIONS: u32 = 50u32; pub const SQL_SUBQUERIES: u32 = 95u32; pub const SQL_SUCCESS: u32 = 0u32; pub const SQL_SUCCESS_WITH_INFO: u32 = 1u32; pub const SQL_SU_DML_STATEMENTS: i32 = 1i32; pub const SQL_SU_INDEX_DEFINITION: i32 = 8i32; pub const SQL_SU_PRIVILEGE_DEFINITION: i32 = 16i32; pub const SQL_SU_PROCEDURE_INVOCATION: i32 = 2i32; pub const SQL_SU_TABLE_DEFINITION: i32 = 4i32; pub const SQL_SVE_CASE: i32 = 1i32; pub const SQL_SVE_CAST: i32 = 2i32; pub const SQL_SVE_COALESCE: i32 = 4i32; pub const SQL_SVE_NULLIF: i32 = 8i32; pub const SQL_SYSTEM_FUNCTIONS: u32 = 51u32; pub const SQL_TABLE_STAT: u32 = 0u32; pub const SQL_TABLE_TERM: u32 = 45u32; pub const SQL_TC_ALL: u32 = 2u32; pub const SQL_TC_DDL_COMMIT: u32 = 3u32; pub const SQL_TC_DDL_IGNORE: u32 = 4u32; pub const SQL_TC_DML: u32 = 1u32; pub const SQL_TC_NONE: u32 = 0u32; pub const SQL_TEXTPTR_LOGGING: u32 = 1225u32; pub const SQL_TIME: u32 = 10u32; pub const SQL_TIMEDATE_ADD_INTERVALS: u32 = 109u32; pub const SQL_TIMEDATE_DIFF_INTERVALS: u32 = 110u32; pub const SQL_TIMEDATE_FUNCTIONS: u32 = 52u32; pub const SQL_TIMESTAMP: u32 = 11u32; pub const SQL_TIMESTAMP_LEN: u32 = 19u32; pub const SQL_TIME_LEN: u32 = 8u32; pub const SQL_TINYINT: i32 = -6i32; pub const SQL_TL_DEFAULT: i32 = 1i32; pub const SQL_TL_OFF: i32 = 0i32; pub const SQL_TL_ON: i32 = 1i32; pub const SQL_TRANSACTION_CAPABLE: u32 = 46u32; pub const SQL_TRANSACTION_ISOLATION_OPTION: u32 = 72u32; pub const SQL_TRANSACTION_READ_COMMITTED: i32 = 2i32; pub const SQL_TRANSACTION_READ_UNCOMMITTED: i32 = 1i32; pub const SQL_TRANSACTION_REPEATABLE_READ: i32 = 4i32; pub const SQL_TRANSACTION_SERIALIZABLE: i32 = 8i32; pub const SQL_TRANSLATE_DLL: u32 = 106u32; pub const SQL_TRANSLATE_OPTION: u32 = 107u32; pub const SQL_TRUE: u32 = 1u32; pub const SQL_TXN_CAPABLE: u32 = 46u32; pub const SQL_TXN_ISOLATION: u32 = 108u32; pub const SQL_TXN_ISOLATION_OPTION: u32 = 72u32; pub const SQL_TXN_READ_COMMITTED: i32 = 2i32; pub const SQL_TXN_READ_UNCOMMITTED: i32 = 1i32; pub const SQL_TXN_REPEATABLE_READ: i32 = 4i32; pub const SQL_TXN_SERIALIZABLE: i32 = 8i32; pub const SQL_TXN_VERSIONING: i32 = 16i32; pub const SQL_TYPE_DATE: u32 = 91u32; pub const SQL_TYPE_DRIVER_END: i32 = -97i32; pub const SQL_TYPE_DRIVER_START: i32 = -80i32; pub const SQL_TYPE_MAX: u32 = 12u32; pub const SQL_TYPE_MIN: i32 = -7i32; pub const SQL_TYPE_NULL: u32 = 0u32; pub const SQL_TYPE_TIME: u32 = 92u32; pub const SQL_TYPE_TIMESTAMP: u32 = 93u32; pub const SQL_UB_DEFAULT: u32 = 0u32; pub const SQL_UB_FIXED: u32 = 1u32; pub const SQL_UB_OFF: u32 = 0u32; pub const SQL_UB_ON: u32 = 1u32; pub const SQL_UB_VARIABLE: u32 = 2u32; pub const SQL_UNBIND: u32 = 2u32; pub const SQL_UNICODE: i32 = -95i32; pub const SQL_UNICODE_CHAR: i32 = -95i32; pub const SQL_UNICODE_LONGVARCHAR: i32 = -97i32; pub const SQL_UNICODE_VARCHAR: i32 = -96i32; pub const SQL_UNION: u32 = 96u32; pub const SQL_UNION_STATEMENT: u32 = 96u32; pub const SQL_UNKNOWN_TYPE: u32 = 0u32; pub const SQL_UNNAMED: u32 = 1u32; pub const SQL_UNSEARCHABLE: u32 = 0u32; pub const SQL_UNSIGNED_OFFSET: i32 = -22i32; pub const SQL_UNSPECIFIED: u32 = 0u32; pub const SQL_UPDATE: u32 = 2u32; pub const SQL_UPDATE_BY_BOOKMARK: u32 = 5u32; pub const SQL_UP_DEFAULT: i32 = 1i32; pub const SQL_UP_OFF: i32 = 0i32; pub const SQL_UP_ON: i32 = 1i32; pub const SQL_UP_ON_DROP: i32 = 2i32; pub const SQL_USER_NAME: u32 = 47u32; pub const SQL_USE_BOOKMARKS: u32 = 12u32; pub const SQL_USE_PROCEDURE_FOR_PREPARE: u32 = 1202u32; pub const SQL_US_UNION: i32 = 1i32; pub const SQL_US_UNION_ALL: i32 = 2i32; pub const SQL_U_UNION: i32 = 1i32; pub const SQL_U_UNION_ALL: i32 = 2i32; pub const SQL_VARBINARY: i32 = -3i32; pub const SQL_VARCHAR: u32 = 12u32; pub const SQL_VARLEN_DATA: i32 = -10i32; pub const SQL_WARN_NO: i32 = 0i32; pub const SQL_WARN_YES: i32 = 1i32; pub const SQL_WCHAR: i32 = -8i32; pub const SQL_WLONGVARCHAR: i32 = -10i32; pub const SQL_WVARCHAR: i32 = -9i32; pub const SQL_XL_DEFAULT: i32 = 1i32; pub const SQL_XL_OFF: i32 = 0i32; pub const SQL_XL_ON: i32 = 1i32; pub const SQL_XOPEN_CLI_YEAR: u32 = 10000u32; pub const SQL_YEAR: u32 = 1u32; pub const SQL_YEAR_TO_MONTH: u32 = 7u32; pub const SQLudtBINARY: u32 = 3u32; pub const SQLudtBIT: u32 = 16u32; pub const SQLudtBITN: u32 = 0u32; pub const SQLudtCHAR: u32 = 1u32; pub const SQLudtDATETIM4: u32 = 22u32; pub const SQLudtDATETIME: u32 = 12u32; pub const SQLudtDATETIMN: u32 = 15u32; pub const SQLudtDECML: u32 = 24u32; pub const SQLudtDECMLN: u32 = 26u32; pub const SQLudtFLT4: u32 = 23u32; pub const SQLudtFLT8: u32 = 8u32; pub const SQLudtFLTN: u32 = 14u32; pub const SQLudtIMAGE: u32 = 20u32; pub const SQLudtINT1: u32 = 5u32; pub const SQLudtINT2: u32 = 6u32; pub const SQLudtINT4: u32 = 7u32; pub const SQLudtINTN: u32 = 13u32; pub const SQLudtMONEY: u32 = 11u32; pub const SQLudtMONEY4: u32 = 21u32; pub const SQLudtMONEYN: u32 = 17u32; pub const SQLudtNUM: u32 = 10u32; pub const SQLudtNUMN: u32 = 25u32; pub const SQLudtSYSNAME: u32 = 18u32; pub const SQLudtTEXT: u32 = 19u32; pub const SQLudtTIMESTAMP: u32 = 80u32; pub const SQLudtUNIQUEIDENTIFIER: u32 = 0u32; pub const SQLudtVARBINARY: u32 = 4u32; pub const SQLudtVARCHAR: u32 = 2u32; pub const SRCH_SCHEMA_CACHE_E_UNEXPECTED: i32 = -2147208447i32; pub const SSPROPVAL_COMMANDTYPE_BULKLOAD: u32 = 22u32; pub const SSPROPVAL_COMMANDTYPE_REGULAR: u32 = 21u32; pub const SSPROPVAL_USEPROCFORPREP_OFF: u32 = 0u32; pub const SSPROPVAL_USEPROCFORPREP_ON: u32 = 1u32; pub const SSPROPVAL_USEPROCFORPREP_ON_DROP: u32 = 2u32; pub const SSPROP_ALLOWNATIVEVARIANT: u32 = 3u32; pub const SSPROP_AUTH_REPL_SERVER_NAME: u32 = 14u32; pub const SSPROP_CHARACTERSET: u32 = 5u32; pub const SSPROP_COLUMNLEVELCOLLATION: u32 = 4u32; pub const SSPROP_COL_COLLATIONNAME: u32 = 14u32; pub const SSPROP_CURRENTCOLLATION: u32 = 7u32; pub const SSPROP_CURSORAUTOFETCH: u32 = 12u32; pub const SSPROP_DEFERPREPARE: u32 = 13u32; pub const SSPROP_ENABLEFASTLOAD: u32 = 2u32; pub const SSPROP_FASTLOADKEEPIDENTITY: u32 = 11u32; pub const SSPROP_FASTLOADKEEPNULLS: u32 = 10u32; pub const SSPROP_FASTLOADOPTIONS: u32 = 9u32; pub const SSPROP_INIT_APPNAME: u32 = 10u32; pub const SSPROP_INIT_AUTOTRANSLATE: u32 = 8u32; pub const SSPROP_INIT_CURRENTLANGUAGE: u32 = 4u32; pub const SSPROP_INIT_ENCRYPT: u32 = 13u32; pub const SSPROP_INIT_FILENAME: u32 = 12u32; pub const SSPROP_INIT_NETWORKADDRESS: u32 = 5u32; pub const SSPROP_INIT_NETWORKLIBRARY: u32 = 6u32; pub const SSPROP_INIT_PACKETSIZE: u32 = 9u32; pub const SSPROP_INIT_TAGCOLUMNCOLLATION: u32 = 15u32; pub const SSPROP_INIT_USEPROCFORPREP: u32 = 7u32; pub const SSPROP_INIT_WSID: u32 = 11u32; pub const SSPROP_IRowsetFastLoad: u32 = 14u32; pub const SSPROP_MAXBLOBLENGTH: u32 = 8u32; pub const SSPROP_QUOTEDCATALOGNAMES: u32 = 2u32; pub const SSPROP_SORTORDER: u32 = 6u32; pub const SSPROP_SQLXMLXPROGID: u32 = 4u32; pub const SSPROP_STREAM_BASEPATH: u32 = 17u32; pub const SSPROP_STREAM_COMMANDTYPE: u32 = 18u32; pub const SSPROP_STREAM_CONTENTTYPE: u32 = 23u32; pub const SSPROP_STREAM_FLAGS: u32 = 20u32; pub const SSPROP_STREAM_MAPPINGSCHEMA: u32 = 15u32; pub const SSPROP_STREAM_XMLROOT: u32 = 19u32; pub const SSPROP_STREAM_XSL: u32 = 16u32; pub const SSPROP_UNICODECOMPARISONSTYLE: u32 = 3u32; pub const SSPROP_UNICODELCID: u32 = 2u32; #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::clone::Clone for SSVARIANT { fn clone(&self) -> Self { unimplemented!() } } #[repr(C)] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub struct SSVARIANT { pub vt: u16, pub dwReserved1: u32, pub dwReserved2: u32, pub Anonymous: SSVARIANT_0, } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl SSVARIANT {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::default::Default for SSVARIANT { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::cmp::PartialEq for SSVARIANT { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::cmp::Eq for SSVARIANT {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] unsafe impl ::windows::core::Abi for SSVARIANT { type Abi = ::core::mem::ManuallyDrop<Self>; } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::clone::Clone for SSVARIANT_0 { fn clone(&self) -> Self { unimplemented!() } } #[repr(C)] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub union SSVARIANT_0 { pub bTinyIntVal: u8, pub sShortIntVal: i16, pub lIntVal: i32, pub llBigIntVal: i64, pub fltRealVal: f32, pub dblFloatVal: f64, pub cyMoneyVal: super::Com::CY, pub NCharVal: SSVARIANT_0_3, pub CharVal: SSVARIANT_0_2, pub fBitVal: i16, pub rgbGuidVal: [u8; 16], pub numNumericVal: DB_NUMERIC, pub BinaryVal: SSVARIANT_0_1, pub tsDateTimeVal: DBTIMESTAMP, pub UnknownType: SSVARIANT_0_4, pub BLOBType: ::core::mem::ManuallyDrop<SSVARIANT_0_0>, } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl SSVARIANT_0 {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::default::Default for SSVARIANT_0 { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::cmp::PartialEq for SSVARIANT_0 { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::cmp::Eq for SSVARIANT_0 {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] unsafe impl ::windows::core::Abi for SSVARIANT_0 { type Abi = ::core::mem::ManuallyDrop<Self>; } #[derive(:: core :: clone :: Clone)] #[repr(C)] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub struct SSVARIANT_0_0 { pub dbobj: DBOBJECT, pub pUnk: ::core::option::Option<::windows::core::IUnknown>, } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl SSVARIANT_0_0 {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::default::Default for SSVARIANT_0_0 { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::fmt::Debug for SSVARIANT_0_0 { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("_BLOBType").field("dbobj", &self.dbobj).field("pUnk", &self.pUnk).finish() } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::cmp::PartialEq for SSVARIANT_0_0 { fn eq(&self, other: &Self) -> bool { self.dbobj == other.dbobj && self.pUnk == other.pUnk } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::cmp::Eq for SSVARIANT_0_0 {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] unsafe impl ::windows::core::Abi for SSVARIANT_0_0 { type Abi = ::core::mem::ManuallyDrop<Self>; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub struct SSVARIANT_0_1 { pub sActualLength: i16, pub sMaxLength: i16, pub prgbBinaryVal: *mut u8, pub dwReserved: u32, } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl SSVARIANT_0_1 {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::default::Default for SSVARIANT_0_1 { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::fmt::Debug for SSVARIANT_0_1 { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("_BinaryVal").field("sActualLength", &self.sActualLength).field("sMaxLength", &self.sMaxLength).field("prgbBinaryVal", &self.prgbBinaryVal).field("dwReserved", &self.dwReserved).finish() } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::cmp::PartialEq for SSVARIANT_0_1 { fn eq(&self, other: &Self) -> bool { self.sActualLength == other.sActualLength && self.sMaxLength == other.sMaxLength && self.prgbBinaryVal == other.prgbBinaryVal && self.dwReserved == other.dwReserved } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::cmp::Eq for SSVARIANT_0_1 {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] unsafe impl ::windows::core::Abi for SSVARIANT_0_1 { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub struct SSVARIANT_0_2 { pub sActualLength: i16, pub sMaxLength: i16, pub pchCharVal: super::super::Foundation::PSTR, pub rgbReserved: [u8; 5], pub dwReserved: u32, pub pwchReserved: super::super::Foundation::PWSTR, } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl SSVARIANT_0_2 {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::default::Default for SSVARIANT_0_2 { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::fmt::Debug for SSVARIANT_0_2 { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("_CharVal").field("sActualLength", &self.sActualLength).field("sMaxLength", &self.sMaxLength).field("pchCharVal", &self.pchCharVal).field("rgbReserved", &self.rgbReserved).field("dwReserved", &self.dwReserved).field("pwchReserved", &self.pwchReserved).finish() } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::cmp::PartialEq for SSVARIANT_0_2 { fn eq(&self, other: &Self) -> bool { self.sActualLength == other.sActualLength && self.sMaxLength == other.sMaxLength && self.pchCharVal == other.pchCharVal && self.rgbReserved == other.rgbReserved && self.dwReserved == other.dwReserved && self.pwchReserved == other.pwchReserved } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::cmp::Eq for SSVARIANT_0_2 {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] unsafe impl ::windows::core::Abi for SSVARIANT_0_2 { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub struct SSVARIANT_0_3 { pub sActualLength: i16, pub sMaxLength: i16, pub pwchNCharVal: super::super::Foundation::PWSTR, pub rgbReserved: [u8; 5], pub dwReserved: u32, pub pwchReserved: super::super::Foundation::PWSTR, } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl SSVARIANT_0_3 {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::default::Default for SSVARIANT_0_3 { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::fmt::Debug for SSVARIANT_0_3 { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("_NCharVal").field("sActualLength", &self.sActualLength).field("sMaxLength", &self.sMaxLength).field("pwchNCharVal", &self.pwchNCharVal).field("rgbReserved", &self.rgbReserved).field("dwReserved", &self.dwReserved).field("pwchReserved", &self.pwchReserved).finish() } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::cmp::PartialEq for SSVARIANT_0_3 { fn eq(&self, other: &Self) -> bool { self.sActualLength == other.sActualLength && self.sMaxLength == other.sMaxLength && self.pwchNCharVal == other.pwchNCharVal && self.rgbReserved == other.rgbReserved && self.dwReserved == other.dwReserved && self.pwchReserved == other.pwchReserved } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::cmp::Eq for SSVARIANT_0_3 {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] unsafe impl ::windows::core::Abi for SSVARIANT_0_3 { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] pub struct SSVARIANT_0_4 { pub dwActualLength: u32, pub rgMetadata: [u8; 16], pub pUnknownData: *mut u8, } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl SSVARIANT_0_4 {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::default::Default for SSVARIANT_0_4 { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::fmt::Debug for SSVARIANT_0_4 { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("_UnknownType").field("dwActualLength", &self.dwActualLength).field("rgMetadata", &self.rgMetadata).field("pUnknownData", &self.pUnknownData).finish() } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::cmp::PartialEq for SSVARIANT_0_4 { fn eq(&self, other: &Self) -> bool { self.dwActualLength == other.dwActualLength && self.rgMetadata == other.rgMetadata && self.pUnknownData == other.pUnknownData } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] impl ::core::cmp::Eq for SSVARIANT_0_4 {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_System_Com"))] unsafe impl ::windows::core::Abi for SSVARIANT_0_4 { type Abi = Self; } pub const STD_BOOKMARKLENGTH: u32 = 1u32; pub const STGM_COLLECTION: i32 = 8192i32; pub const STGM_OPEN: i32 = -2147483648i32; pub const STGM_OUTPUT: i32 = 32768i32; pub const STGM_RECURSIVE: i32 = 16777216i32; pub const STGM_STRICTOPEN: i32 = 1073741824i32; pub const STREAM_FLAGS_DISALLOW_ABSOLUTE_PATH: u32 = 2u32; pub const STREAM_FLAGS_DISALLOW_QUERY: u32 = 4u32; pub const STREAM_FLAGS_DISALLOW_UPDATEGRAMS: u32 = 64u32; pub const STREAM_FLAGS_DISALLOW_URL: u32 = 1u32; pub const STREAM_FLAGS_DONTCACHEMAPPINGSCHEMA: u32 = 8u32; pub const STREAM_FLAGS_DONTCACHETEMPLATE: u32 = 16u32; pub const STREAM_FLAGS_DONTCACHEXSL: u32 = 32u32; pub const STREAM_FLAGS_RESERVED: u32 = 4294901760u32; #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct STRUCTURED_QUERY_MULTIOPTION(pub i32); pub const SQMO_VIRTUAL_PROPERTY: STRUCTURED_QUERY_MULTIOPTION = STRUCTURED_QUERY_MULTIOPTION(0i32); pub const SQMO_DEFAULT_PROPERTY: STRUCTURED_QUERY_MULTIOPTION = STRUCTURED_QUERY_MULTIOPTION(1i32); pub const SQMO_GENERATOR_FOR_TYPE: STRUCTURED_QUERY_MULTIOPTION = STRUCTURED_QUERY_MULTIOPTION(2i32); pub const SQMO_MAP_PROPERTY: STRUCTURED_QUERY_MULTIOPTION = STRUCTURED_QUERY_MULTIOPTION(3i32); impl ::core::convert::From<i32> for STRUCTURED_QUERY_MULTIOPTION { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for STRUCTURED_QUERY_MULTIOPTION { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct STRUCTURED_QUERY_PARSE_ERROR(pub i32); pub const SQPE_NONE: STRUCTURED_QUERY_PARSE_ERROR = STRUCTURED_QUERY_PARSE_ERROR(0i32); pub const SQPE_EXTRA_OPENING_PARENTHESIS: STRUCTURED_QUERY_PARSE_ERROR = STRUCTURED_QUERY_PARSE_ERROR(1i32); pub const SQPE_EXTRA_CLOSING_PARENTHESIS: STRUCTURED_QUERY_PARSE_ERROR = STRUCTURED_QUERY_PARSE_ERROR(2i32); pub const SQPE_IGNORED_MODIFIER: STRUCTURED_QUERY_PARSE_ERROR = STRUCTURED_QUERY_PARSE_ERROR(3i32); pub const SQPE_IGNORED_CONNECTOR: STRUCTURED_QUERY_PARSE_ERROR = STRUCTURED_QUERY_PARSE_ERROR(4i32); pub const SQPE_IGNORED_KEYWORD: STRUCTURED_QUERY_PARSE_ERROR = STRUCTURED_QUERY_PARSE_ERROR(5i32); pub const SQPE_UNHANDLED: STRUCTURED_QUERY_PARSE_ERROR = STRUCTURED_QUERY_PARSE_ERROR(6i32); impl ::core::convert::From<i32> for STRUCTURED_QUERY_PARSE_ERROR { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for STRUCTURED_QUERY_PARSE_ERROR { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct STRUCTURED_QUERY_RESOLVE_OPTION(pub u32); pub const SQRO_DEFAULT: STRUCTURED_QUERY_RESOLVE_OPTION = STRUCTURED_QUERY_RESOLVE_OPTION(0u32); pub const SQRO_DONT_RESOLVE_DATETIME: STRUCTURED_QUERY_RESOLVE_OPTION = STRUCTURED_QUERY_RESOLVE_OPTION(1u32); pub const SQRO_ALWAYS_ONE_INTERVAL: STRUCTURED_QUERY_RESOLVE_OPTION = STRUCTURED_QUERY_RESOLVE_OPTION(2u32); pub const SQRO_DONT_SIMPLIFY_CONDITION_TREES: STRUCTURED_QUERY_RESOLVE_OPTION = STRUCTURED_QUERY_RESOLVE_OPTION(4u32); pub const SQRO_DONT_MAP_RELATIONS: STRUCTURED_QUERY_RESOLVE_OPTION = STRUCTURED_QUERY_RESOLVE_OPTION(8u32); pub const SQRO_DONT_RESOLVE_RANGES: STRUCTURED_QUERY_RESOLVE_OPTION = STRUCTURED_QUERY_RESOLVE_OPTION(16u32); pub const SQRO_DONT_REMOVE_UNRESTRICTED_KEYWORDS: STRUCTURED_QUERY_RESOLVE_OPTION = STRUCTURED_QUERY_RESOLVE_OPTION(32u32); pub const SQRO_DONT_SPLIT_WORDS: STRUCTURED_QUERY_RESOLVE_OPTION = STRUCTURED_QUERY_RESOLVE_OPTION(64u32); pub const SQRO_IGNORE_PHRASE_ORDER: STRUCTURED_QUERY_RESOLVE_OPTION = STRUCTURED_QUERY_RESOLVE_OPTION(128u32); pub const SQRO_ADD_VALUE_TYPE_FOR_PLAIN_VALUES: STRUCTURED_QUERY_RESOLVE_OPTION = STRUCTURED_QUERY_RESOLVE_OPTION(256u32); pub const SQRO_ADD_ROBUST_ITEM_NAME: STRUCTURED_QUERY_RESOLVE_OPTION = STRUCTURED_QUERY_RESOLVE_OPTION(512u32); impl ::core::convert::From<u32> for STRUCTURED_QUERY_RESOLVE_OPTION { fn from(value: u32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for STRUCTURED_QUERY_RESOLVE_OPTION { type Abi = Self; } impl ::core::ops::BitOr for STRUCTURED_QUERY_RESOLVE_OPTION { type Output = Self; fn bitor(self, rhs: Self) -> Self { Self(self.0 | rhs.0) } } impl ::core::ops::BitAnd for STRUCTURED_QUERY_RESOLVE_OPTION { type Output = Self; fn bitand(self, rhs: Self) -> Self { Self(self.0 & rhs.0) } } impl ::core::ops::BitOrAssign for STRUCTURED_QUERY_RESOLVE_OPTION { fn bitor_assign(&mut self, rhs: Self) { self.0.bitor_assign(rhs.0) } } impl ::core::ops::BitAndAssign for STRUCTURED_QUERY_RESOLVE_OPTION { fn bitand_assign(&mut self, rhs: Self) { self.0.bitand_assign(rhs.0) } } impl ::core::ops::Not for STRUCTURED_QUERY_RESOLVE_OPTION { type Output = Self; fn not(self) -> Self { Self(self.0.not()) } } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct STRUCTURED_QUERY_SINGLE_OPTION(pub i32); pub const SQSO_SCHEMA: STRUCTURED_QUERY_SINGLE_OPTION = STRUCTURED_QUERY_SINGLE_OPTION(0i32); pub const SQSO_LOCALE_WORD_BREAKING: STRUCTURED_QUERY_SINGLE_OPTION = STRUCTURED_QUERY_SINGLE_OPTION(1i32); pub const SQSO_WORD_BREAKER: STRUCTURED_QUERY_SINGLE_OPTION = STRUCTURED_QUERY_SINGLE_OPTION(2i32); pub const SQSO_NATURAL_SYNTAX: STRUCTURED_QUERY_SINGLE_OPTION = STRUCTURED_QUERY_SINGLE_OPTION(3i32); pub const SQSO_AUTOMATIC_WILDCARD: STRUCTURED_QUERY_SINGLE_OPTION = STRUCTURED_QUERY_SINGLE_OPTION(4i32); pub const SQSO_TRACE_LEVEL: STRUCTURED_QUERY_SINGLE_OPTION = STRUCTURED_QUERY_SINGLE_OPTION(5i32); pub const SQSO_LANGUAGE_KEYWORDS: STRUCTURED_QUERY_SINGLE_OPTION = STRUCTURED_QUERY_SINGLE_OPTION(6i32); pub const SQSO_SYNTAX: STRUCTURED_QUERY_SINGLE_OPTION = STRUCTURED_QUERY_SINGLE_OPTION(7i32); pub const SQSO_TIME_ZONE: STRUCTURED_QUERY_SINGLE_OPTION = STRUCTURED_QUERY_SINGLE_OPTION(8i32); pub const SQSO_IMPLICIT_CONNECTOR: STRUCTURED_QUERY_SINGLE_OPTION = STRUCTURED_QUERY_SINGLE_OPTION(9i32); pub const SQSO_CONNECTOR_CASE: STRUCTURED_QUERY_SINGLE_OPTION = STRUCTURED_QUERY_SINGLE_OPTION(10i32); impl ::core::convert::From<i32> for STRUCTURED_QUERY_SINGLE_OPTION { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for STRUCTURED_QUERY_SINGLE_OPTION { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct STRUCTURED_QUERY_SYNTAX(pub i32); pub const SQS_NO_SYNTAX: STRUCTURED_QUERY_SYNTAX = STRUCTURED_QUERY_SYNTAX(0i32); pub const SQS_ADVANCED_QUERY_SYNTAX: STRUCTURED_QUERY_SYNTAX = STRUCTURED_QUERY_SYNTAX(1i32); pub const SQS_NATURAL_QUERY_SYNTAX: STRUCTURED_QUERY_SYNTAX = STRUCTURED_QUERY_SYNTAX(2i32); impl ::core::convert::From<i32> for STRUCTURED_QUERY_SYNTAX { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for STRUCTURED_QUERY_SYNTAX { type Abi = Self; } pub const STS_ABORTXMLPARSE: i32 = -2147211756i32; pub const STS_WS_ERROR: i32 = -2147211754i32; #[derive(:: core :: clone :: Clone)] #[repr(C)] #[cfg(feature = "Win32_Foundation")] pub struct SUBSCRIPTIONINFO { pub cbSize: u32, pub fUpdateFlags: u32, pub schedule: SUBSCRIPTIONSCHEDULE, pub customGroupCookie: ::windows::core::GUID, pub pTrigger: *mut ::core::ffi::c_void, pub dwRecurseLevels: u32, pub fWebcrawlerFlags: u32, pub bMailNotification: super::super::Foundation::BOOL, pub bGleam: super::super::Foundation::BOOL, pub bChangesOnly: super::super::Foundation::BOOL, pub bNeedPassword: super::super::Foundation::BOOL, pub fChannelFlags: u32, pub bstrUserName: super::super::Foundation::BSTR, pub bstrPassword: super::super::Foundation::BSTR, pub bstrFriendlyName: super::super::Foundation::BSTR, pub dwMaxSizeKB: u32, pub subType: SUBSCRIPTIONTYPE, pub fTaskFlags: u32, pub dwReserved: u32, } #[cfg(feature = "Win32_Foundation")] impl SUBSCRIPTIONINFO {} #[cfg(feature = "Win32_Foundation")] impl ::core::default::Default for SUBSCRIPTIONINFO { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(feature = "Win32_Foundation")] impl ::core::fmt::Debug for SUBSCRIPTIONINFO { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("SUBSCRIPTIONINFO") .field("cbSize", &self.cbSize) .field("fUpdateFlags", &self.fUpdateFlags) .field("schedule", &self.schedule) .field("customGroupCookie", &self.customGroupCookie) .field("pTrigger", &self.pTrigger) .field("dwRecurseLevels", &self.dwRecurseLevels) .field("fWebcrawlerFlags", &self.fWebcrawlerFlags) .field("bMailNotification", &self.bMailNotification) .field("bGleam", &self.bGleam) .field("bChangesOnly", &self.bChangesOnly) .field("bNeedPassword", &self.bNeedPassword) .field("fChannelFlags", &self.fChannelFlags) .field("bstrUserName", &self.bstrUserName) .field("bstrPassword", &self.bstrPassword) .field("bstrFriendlyName", &self.bstrFriendlyName) .field("dwMaxSizeKB", &self.dwMaxSizeKB) .field("subType", &self.subType) .field("fTaskFlags", &self.fTaskFlags) .field("dwReserved", &self.dwReserved) .finish() } } #[cfg(feature = "Win32_Foundation")] impl ::core::cmp::PartialEq for SUBSCRIPTIONINFO { fn eq(&self, other: &Self) -> bool { self.cbSize == other.cbSize && self.fUpdateFlags == other.fUpdateFlags && self.schedule == other.schedule && self.customGroupCookie == other.customGroupCookie && self.pTrigger == other.pTrigger && self.dwRecurseLevels == other.dwRecurseLevels && self.fWebcrawlerFlags == other.fWebcrawlerFlags && self.bMailNotification == other.bMailNotification && self.bGleam == other.bGleam && self.bChangesOnly == other.bChangesOnly && self.bNeedPassword == other.bNeedPassword && self.fChannelFlags == other.fChannelFlags && self.bstrUserName == other.bstrUserName && self.bstrPassword == other.bstrPassword && self.bstrFriendlyName == other.bstrFriendlyName && self.dwMaxSizeKB == other.dwMaxSizeKB && self.subType == other.subType && self.fTaskFlags == other.fTaskFlags && self.dwReserved == other.dwReserved } } #[cfg(feature = "Win32_Foundation")] impl ::core::cmp::Eq for SUBSCRIPTIONINFO {} #[cfg(feature = "Win32_Foundation")] unsafe impl ::windows::core::Abi for SUBSCRIPTIONINFO { type Abi = ::core::mem::ManuallyDrop<Self>; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct SUBSCRIPTIONINFOFLAGS(pub i32); pub const SUBSINFO_SCHEDULE: SUBSCRIPTIONINFOFLAGS = SUBSCRIPTIONINFOFLAGS(1i32); pub const SUBSINFO_RECURSE: SUBSCRIPTIONINFOFLAGS = SUBSCRIPTIONINFOFLAGS(2i32); pub const SUBSINFO_WEBCRAWL: SUBSCRIPTIONINFOFLAGS = SUBSCRIPTIONINFOFLAGS(4i32); pub const SUBSINFO_MAILNOT: SUBSCRIPTIONINFOFLAGS = SUBSCRIPTIONINFOFLAGS(8i32); pub const SUBSINFO_MAXSIZEKB: SUBSCRIPTIONINFOFLAGS = SUBSCRIPTIONINFOFLAGS(16i32); pub const SUBSINFO_USER: SUBSCRIPTIONINFOFLAGS = SUBSCRIPTIONINFOFLAGS(32i32); pub const SUBSINFO_PASSWORD: SUBSCRIPTIONINFOFLAGS = SUBSCRIPTIONINFOFLAGS(64i32); pub const SUBSINFO_TASKFLAGS: SUBSCRIPTIONINFOFLAGS = SUBSCRIPTIONINFOFLAGS(256i32); pub const SUBSINFO_GLEAM: SUBSCRIPTIONINFOFLAGS = SUBSCRIPTIONINFOFLAGS(512i32); pub const SUBSINFO_CHANGESONLY: SUBSCRIPTIONINFOFLAGS = SUBSCRIPTIONINFOFLAGS(1024i32); pub const SUBSINFO_CHANNELFLAGS: SUBSCRIPTIONINFOFLAGS = SUBSCRIPTIONINFOFLAGS(2048i32); pub const SUBSINFO_FRIENDLYNAME: SUBSCRIPTIONINFOFLAGS = SUBSCRIPTIONINFOFLAGS(8192i32); pub const SUBSINFO_NEEDPASSWORD: SUBSCRIPTIONINFOFLAGS = SUBSCRIPTIONINFOFLAGS(16384i32); pub const SUBSINFO_TYPE: SUBSCRIPTIONINFOFLAGS = SUBSCRIPTIONINFOFLAGS(32768i32); impl ::core::convert::From<i32> for SUBSCRIPTIONINFOFLAGS { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for SUBSCRIPTIONINFOFLAGS { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] pub struct SUBSCRIPTIONITEMINFO { pub cbSize: u32, pub dwFlags: u32, pub dwPriority: u32, pub ScheduleGroup: ::windows::core::GUID, pub clsidAgent: ::windows::core::GUID, } impl SUBSCRIPTIONITEMINFO {} impl ::core::default::Default for SUBSCRIPTIONITEMINFO { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } impl ::core::fmt::Debug for SUBSCRIPTIONITEMINFO { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("SUBSCRIPTIONITEMINFO").field("cbSize", &self.cbSize).field("dwFlags", &self.dwFlags).field("dwPriority", &self.dwPriority).field("ScheduleGroup", &self.ScheduleGroup).field("clsidAgent", &self.clsidAgent).finish() } } impl ::core::cmp::PartialEq for SUBSCRIPTIONITEMINFO { fn eq(&self, other: &Self) -> bool { self.cbSize == other.cbSize && self.dwFlags == other.dwFlags && self.dwPriority == other.dwPriority && self.ScheduleGroup == other.ScheduleGroup && self.clsidAgent == other.clsidAgent } } impl ::core::cmp::Eq for SUBSCRIPTIONITEMINFO {} unsafe impl ::windows::core::Abi for SUBSCRIPTIONITEMINFO { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct SUBSCRIPTIONSCHEDULE(pub i32); pub const SUBSSCHED_AUTO: SUBSCRIPTIONSCHEDULE = SUBSCRIPTIONSCHEDULE(0i32); pub const SUBSSCHED_DAILY: SUBSCRIPTIONSCHEDULE = SUBSCRIPTIONSCHEDULE(1i32); pub const SUBSSCHED_WEEKLY: SUBSCRIPTIONSCHEDULE = SUBSCRIPTIONSCHEDULE(2i32); pub const SUBSSCHED_CUSTOM: SUBSCRIPTIONSCHEDULE = SUBSCRIPTIONSCHEDULE(3i32); pub const SUBSSCHED_MANUAL: SUBSCRIPTIONSCHEDULE = SUBSCRIPTIONSCHEDULE(4i32); impl ::core::convert::From<i32> for SUBSCRIPTIONSCHEDULE { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for SUBSCRIPTIONSCHEDULE { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct SUBSCRIPTIONTYPE(pub i32); pub const SUBSTYPE_URL: SUBSCRIPTIONTYPE = SUBSCRIPTIONTYPE(0i32); pub const SUBSTYPE_CHANNEL: SUBSCRIPTIONTYPE = SUBSCRIPTIONTYPE(1i32); pub const SUBSTYPE_DESKTOPURL: SUBSCRIPTIONTYPE = SUBSCRIPTIONTYPE(2i32); pub const SUBSTYPE_EXTERNAL: SUBSCRIPTIONTYPE = SUBSCRIPTIONTYPE(3i32); pub const SUBSTYPE_DESKTOPCHANNEL: SUBSCRIPTIONTYPE = SUBSCRIPTIONTYPE(4i32); impl ::core::convert::From<i32> for SUBSCRIPTIONTYPE { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for SUBSCRIPTIONTYPE { type Abi = Self; } pub const SUBSINFO_ALLFLAGS: u32 = 61311u32; pub const SUBSMGRENUM_MASK: u32 = 1u32; pub const SUBSMGRENUM_TEMP: u32 = 1u32; pub const SUBSMGRUPDATE_MASK: u32 = 1u32; pub const SUBSMGRUPDATE_MINIMIZE: u32 = 1u32; pub const SUCCEED: u32 = 1u32; pub const SUCCEED_ABORT: u32 = 2u32; pub const SUCCEED_ASYNC: u32 = 3u32; pub const SubscriptionMgr: ::windows::core::GUID = ::windows::core::GUID::from_u128(0xabbe31d0_6dae_11d0_beca_00c04fd940be); #[derive(:: core :: clone :: Clone)] #[repr(C)] #[cfg(feature = "Win32_Foundation")] pub struct TEXT_SOURCE { pub pfnFillTextBuffer: ::core::option::Option<PFNFILLTEXTBUFFER>, pub awcBuffer: super::super::Foundation::PWSTR, pub iEnd: u32, pub iCur: u32, } #[cfg(feature = "Win32_Foundation")] impl TEXT_SOURCE {} #[cfg(feature = "Win32_Foundation")] impl ::core::default::Default for TEXT_SOURCE { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(feature = "Win32_Foundation")] impl ::core::fmt::Debug for TEXT_SOURCE { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("TEXT_SOURCE").field("awcBuffer", &self.awcBuffer).field("iEnd", &self.iEnd).field("iCur", &self.iCur).finish() } } #[cfg(feature = "Win32_Foundation")] impl ::core::cmp::PartialEq for TEXT_SOURCE { fn eq(&self, other: &Self) -> bool { self.pfnFillTextBuffer.map(|f| f as usize) == other.pfnFillTextBuffer.map(|f| f as usize) && self.awcBuffer == other.awcBuffer && self.iEnd == other.iEnd && self.iCur == other.iCur } } #[cfg(feature = "Win32_Foundation")] impl ::core::cmp::Eq for TEXT_SOURCE {} #[cfg(feature = "Win32_Foundation")] unsafe impl ::windows::core::Abi for TEXT_SOURCE { type Abi = ::core::mem::ManuallyDrop<Self>; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] pub struct TIMEOUT_INFO { pub dwSize: u32, pub dwConnectTimeout: u32, pub dwDataTimeout: u32, } impl TIMEOUT_INFO {} impl ::core::default::Default for TIMEOUT_INFO { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } impl ::core::fmt::Debug for TIMEOUT_INFO { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("TIMEOUT_INFO").field("dwSize", &self.dwSize).field("dwConnectTimeout", &self.dwConnectTimeout).field("dwDataTimeout", &self.dwDataTimeout).finish() } } impl ::core::cmp::PartialEq for TIMEOUT_INFO { fn eq(&self, other: &Self) -> bool { self.dwSize == other.dwSize && self.dwConnectTimeout == other.dwConnectTimeout && self.dwDataTimeout == other.dwDataTimeout } } impl ::core::cmp::Eq for TIMEOUT_INFO {} unsafe impl ::windows::core::Abi for TIMEOUT_INFO { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] pub struct TIMESTAMP_STRUCT { pub year: i16, pub month: u16, pub day: u16, pub hour: u16, pub minute: u16, pub second: u16, pub fraction: u32, } impl TIMESTAMP_STRUCT {} impl ::core::default::Default for TIMESTAMP_STRUCT { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } impl ::core::fmt::Debug for TIMESTAMP_STRUCT { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("TIMESTAMP_STRUCT").field("year", &self.year).field("month", &self.month).field("day", &self.day).field("hour", &self.hour).field("minute", &self.minute).field("second", &self.second).field("fraction", &self.fraction).finish() } } impl ::core::cmp::PartialEq for TIMESTAMP_STRUCT { fn eq(&self, other: &Self) -> bool { self.year == other.year && self.month == other.month && self.day == other.day && self.hour == other.hour && self.minute == other.minute && self.second == other.second && self.fraction == other.fraction } } impl ::core::cmp::Eq for TIMESTAMP_STRUCT {} unsafe impl ::windows::core::Abi for TIMESTAMP_STRUCT { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] pub struct TIME_STRUCT { pub hour: u16, pub minute: u16, pub second: u16, } impl TIME_STRUCT {} impl ::core::default::Default for TIME_STRUCT { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } impl ::core::fmt::Debug for TIME_STRUCT { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("TIME_STRUCT").field("hour", &self.hour).field("minute", &self.minute).field("second", &self.second).finish() } } impl ::core::cmp::PartialEq for TIME_STRUCT { fn eq(&self, other: &Self) -> bool { self.hour == other.hour && self.minute == other.minute && self.second == other.second } } impl ::core::cmp::Eq for TIME_STRUCT {} unsafe impl ::windows::core::Abi for TIME_STRUCT { type Abi = Self; } pub const TRACE_ON: i32 = 1i32; pub const TRACE_VERSION: u32 = 1000u32; pub const TRACE_VS_EVENT_ON: i32 = 2i32; #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] pub struct VECTORRESTRICTION { pub Node: NODERESTRICTION, pub RankMethod: u32, } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl VECTORRESTRICTION {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::default::Default for VECTORRESTRICTION { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::fmt::Debug for VECTORRESTRICTION { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("VECTORRESTRICTION").field("Node", &self.Node).field("RankMethod", &self.RankMethod).finish() } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::cmp::PartialEq for VECTORRESTRICTION { fn eq(&self, other: &Self) -> bool { self.Node == other.Node && self.RankMethod == other.RankMethod } } #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] impl ::core::cmp::Eq for VECTORRESTRICTION {} #[cfg(all(feature = "Win32_Foundation", feature = "Win32_Storage_IndexServer", feature = "Win32_System_Com", feature = "Win32_System_Com_StructuredStorage"))] unsafe impl ::windows::core::Abi for VECTORRESTRICTION { type Abi = Self; } #[derive(:: core :: cmp :: PartialEq, :: core :: cmp :: Eq, :: core :: marker :: Copy, :: core :: clone :: Clone, :: core :: default :: Default, :: core :: fmt :: Debug)] #[repr(transparent)] pub struct WEBCRAWL_RECURSEFLAGS(pub i32); pub const WEBCRAWL_DONT_MAKE_STICKY: WEBCRAWL_RECURSEFLAGS = WEBCRAWL_RECURSEFLAGS(1i32); pub const WEBCRAWL_GET_IMAGES: WEBCRAWL_RECURSEFLAGS = WEBCRAWL_RECURSEFLAGS(2i32); pub const WEBCRAWL_GET_VIDEOS: WEBCRAWL_RECURSEFLAGS = WEBCRAWL_RECURSEFLAGS(4i32); pub const WEBCRAWL_GET_BGSOUNDS: WEBCRAWL_RECURSEFLAGS = WEBCRAWL_RECURSEFLAGS(8i32); pub const WEBCRAWL_GET_CONTROLS: WEBCRAWL_RECURSEFLAGS = WEBCRAWL_RECURSEFLAGS(16i32); pub const WEBCRAWL_LINKS_ELSEWHERE: WEBCRAWL_RECURSEFLAGS = WEBCRAWL_RECURSEFLAGS(32i32); pub const WEBCRAWL_IGNORE_ROBOTSTXT: WEBCRAWL_RECURSEFLAGS = WEBCRAWL_RECURSEFLAGS(128i32); pub const WEBCRAWL_ONLY_LINKS_TO_HTML: WEBCRAWL_RECURSEFLAGS = WEBCRAWL_RECURSEFLAGS(256i32); impl ::core::convert::From<i32> for WEBCRAWL_RECURSEFLAGS { fn from(value: i32) -> Self { Self(value) } } unsafe impl ::windows::core::Abi for WEBCRAWL_RECURSEFLAGS { type Abi = Self; } pub const XML_E_BADSXQL: i32 = -2147212799i32; pub const XML_E_NODEFAULTNS: i32 = -2147212800i32; pub const _MAPI_E_ACCOUNT_DISABLED: i32 = -2147221212i32; pub const _MAPI_E_BAD_CHARWIDTH: i32 = -2147221245i32; pub const _MAPI_E_BAD_COLUMN: i32 = -2147221224i32; pub const _MAPI_E_BUSY: i32 = -2147221237i32; pub const _MAPI_E_COMPUTED: i32 = -2147221222i32; pub const _MAPI_E_CORRUPT_DATA: i32 = -2147221221i32; pub const _MAPI_E_DISK_ERROR: i32 = -2147221226i32; pub const _MAPI_E_END_OF_SESSION: i32 = -2147220992i32; pub const _MAPI_E_EXTENDED_ERROR: i32 = -2147221223i32; pub const _MAPI_E_FAILONEPROVIDER: i32 = -2147221219i32; pub const _MAPI_E_INVALID_ACCESS_TIME: i32 = -2147221213i32; pub const _MAPI_E_INVALID_ENTRYID: i32 = -2147221241i32; pub const _MAPI_E_INVALID_OBJECT: i32 = -2147221240i32; pub const _MAPI_E_INVALID_WORKSTATION_ACCOUNT: i32 = -2147221214i32; pub const _MAPI_E_LOGON_FAILED: i32 = -2147221231i32; pub const _MAPI_E_MISSING_REQUIRED_COLUMN: i32 = -2147220990i32; pub const _MAPI_E_NETWORK_ERROR: i32 = -2147221227i32; pub const _MAPI_E_NOT_ENOUGH_DISK: i32 = -2147221235i32; pub const _MAPI_E_NOT_ENOUGH_RESOURCES: i32 = -2147221234i32; pub const _MAPI_E_NOT_FOUND: i32 = -2147221233i32; pub const _MAPI_E_NO_SUPPORT: i32 = -2147221246i32; pub const _MAPI_E_OBJECT_CHANGED: i32 = -2147221239i32; pub const _MAPI_E_OBJECT_DELETED: i32 = -2147221238i32; pub const _MAPI_E_PASSWORD_CHANGE_REQUIRED: i32 = -2147221216i32; pub const _MAPI_E_PASSWORD_EXPIRED: i32 = -2147221215i32; pub const _MAPI_E_SESSION_LIMIT: i32 = -2147221230i32; pub const _MAPI_E_STRING_TOO_LONG: i32 = -2147221243i32; pub const _MAPI_E_TOO_COMPLEX: i32 = -2147221225i32; pub const _MAPI_E_UNABLE_TO_ABORT: i32 = -2147221228i32; pub const _MAPI_E_UNCONFIGURED: i32 = -2147221220i32; pub const _MAPI_E_UNKNOWN_CPID: i32 = -2147221218i32; pub const _MAPI_E_UNKNOWN_ENTRYID: i32 = -2147220991i32; pub const _MAPI_E_UNKNOWN_FLAGS: i32 = -2147221242i32; pub const _MAPI_E_UNKNOWN_LCID: i32 = -2147221217i32; pub const _MAPI_E_USER_CANCEL: i32 = -2147221229i32; pub const _MAPI_E_VERSION: i32 = -2147221232i32; pub const _MAPI_W_NO_SERVICE: i32 = 262659i32; #[inline] pub unsafe fn bcp_batch(param0: *mut ::core::ffi::c_void) -> i32 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn bcp_batch(param0: *mut ::core::ffi::c_void) -> i32; } ::core::mem::transmute(bcp_batch(::core::mem::transmute(param0))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn bcp_bind(param0: *mut ::core::ffi::c_void, param1: *mut u8, param2: i32, param3: i32, param4: *mut u8, param5: i32, param6: i32, param7: i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn bcp_bind(param0: *mut ::core::ffi::c_void, param1: *mut u8, param2: i32, param3: i32, param4: *mut u8, param5: i32, param6: i32, param7: i32) -> i16; } ::core::mem::transmute(bcp_bind(::core::mem::transmute(param0), ::core::mem::transmute(param1), ::core::mem::transmute(param2), ::core::mem::transmute(param3), ::core::mem::transmute(param4), ::core::mem::transmute(param5), ::core::mem::transmute(param6), ::core::mem::transmute(param7))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn bcp_colfmt(param0: *mut ::core::ffi::c_void, param1: i32, param2: u8, param3: i32, param4: i32, param5: *mut u8, param6: i32, param7: i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn bcp_colfmt(param0: *mut ::core::ffi::c_void, param1: i32, param2: u8, param3: i32, param4: i32, param5: *mut u8, param6: i32, param7: i32) -> i16; } ::core::mem::transmute(bcp_colfmt(::core::mem::transmute(param0), ::core::mem::transmute(param1), ::core::mem::transmute(param2), ::core::mem::transmute(param3), ::core::mem::transmute(param4), ::core::mem::transmute(param5), ::core::mem::transmute(param6), ::core::mem::transmute(param7))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn bcp_collen(param0: *mut ::core::ffi::c_void, param1: i32, param2: i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn bcp_collen(param0: *mut ::core::ffi::c_void, param1: i32, param2: i32) -> i16; } ::core::mem::transmute(bcp_collen(::core::mem::transmute(param0), ::core::mem::transmute(param1), ::core::mem::transmute(param2))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn bcp_colptr(param0: *mut ::core::ffi::c_void, param1: *mut u8, param2: i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn bcp_colptr(param0: *mut ::core::ffi::c_void, param1: *mut u8, param2: i32) -> i16; } ::core::mem::transmute(bcp_colptr(::core::mem::transmute(param0), ::core::mem::transmute(param1), ::core::mem::transmute(param2))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn bcp_columns(param0: *mut ::core::ffi::c_void, param1: i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn bcp_columns(param0: *mut ::core::ffi::c_void, param1: i32) -> i16; } ::core::mem::transmute(bcp_columns(::core::mem::transmute(param0), ::core::mem::transmute(param1))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn bcp_control(param0: *mut ::core::ffi::c_void, param1: i32, param2: *mut ::core::ffi::c_void) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn bcp_control(param0: *mut ::core::ffi::c_void, param1: i32, param2: *mut ::core::ffi::c_void) -> i16; } ::core::mem::transmute(bcp_control(::core::mem::transmute(param0), ::core::mem::transmute(param1), ::core::mem::transmute(param2))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn bcp_done(param0: *mut ::core::ffi::c_void) -> i32 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn bcp_done(param0: *mut ::core::ffi::c_void) -> i32; } ::core::mem::transmute(bcp_done(::core::mem::transmute(param0))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn bcp_exec(param0: *mut ::core::ffi::c_void, param1: *mut i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn bcp_exec(param0: *mut ::core::ffi::c_void, param1: *mut i32) -> i16; } ::core::mem::transmute(bcp_exec(::core::mem::transmute(param0), ::core::mem::transmute(param1))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn bcp_getcolfmt(param0: *mut ::core::ffi::c_void, param1: i32, param2: i32, param3: *mut ::core::ffi::c_void, param4: i32, param5: *mut i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn bcp_getcolfmt(param0: *mut ::core::ffi::c_void, param1: i32, param2: i32, param3: *mut ::core::ffi::c_void, param4: i32, param5: *mut i32) -> i16; } ::core::mem::transmute(bcp_getcolfmt(::core::mem::transmute(param0), ::core::mem::transmute(param1), ::core::mem::transmute(param2), ::core::mem::transmute(param3), ::core::mem::transmute(param4), ::core::mem::transmute(param5))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(feature = "Win32_Foundation")] #[inline] pub unsafe fn bcp_initA<'a, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::PSTR>, Param2: ::windows::core::IntoParam<'a, super::super::Foundation::PSTR>, Param3: ::windows::core::IntoParam<'a, super::super::Foundation::PSTR>>(param0: *mut ::core::ffi::c_void, param1: Param1, param2: Param2, param3: Param3, param4: i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn bcp_initA(param0: *mut ::core::ffi::c_void, param1: super::super::Foundation::PSTR, param2: super::super::Foundation::PSTR, param3: super::super::Foundation::PSTR, param4: i32) -> i16; } ::core::mem::transmute(bcp_initA(::core::mem::transmute(param0), param1.into_param().abi(), param2.into_param().abi(), param3.into_param().abi(), ::core::mem::transmute(param4))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(feature = "Win32_Foundation")] #[inline] pub unsafe fn bcp_initW<'a, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param2: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>, Param3: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(param0: *mut ::core::ffi::c_void, param1: Param1, param2: Param2, param3: Param3, param4: i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn bcp_initW(param0: *mut ::core::ffi::c_void, param1: super::super::Foundation::PWSTR, param2: super::super::Foundation::PWSTR, param3: super::super::Foundation::PWSTR, param4: i32) -> i16; } ::core::mem::transmute(bcp_initW(::core::mem::transmute(param0), param1.into_param().abi(), param2.into_param().abi(), param3.into_param().abi(), ::core::mem::transmute(param4))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn bcp_moretext(param0: *mut ::core::ffi::c_void, param1: i32, param2: *mut u8) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn bcp_moretext(param0: *mut ::core::ffi::c_void, param1: i32, param2: *mut u8) -> i16; } ::core::mem::transmute(bcp_moretext(::core::mem::transmute(param0), ::core::mem::transmute(param1), ::core::mem::transmute(param2))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(feature = "Win32_Foundation")] #[inline] pub unsafe fn bcp_readfmtA<'a, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::PSTR>>(param0: *mut ::core::ffi::c_void, param1: Param1) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn bcp_readfmtA(param0: *mut ::core::ffi::c_void, param1: super::super::Foundation::PSTR) -> i16; } ::core::mem::transmute(bcp_readfmtA(::core::mem::transmute(param0), param1.into_param().abi())) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(feature = "Win32_Foundation")] #[inline] pub unsafe fn bcp_readfmtW<'a, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(param0: *mut ::core::ffi::c_void, param1: Param1) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn bcp_readfmtW(param0: *mut ::core::ffi::c_void, param1: super::super::Foundation::PWSTR) -> i16; } ::core::mem::transmute(bcp_readfmtW(::core::mem::transmute(param0), param1.into_param().abi())) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn bcp_sendrow(param0: *mut ::core::ffi::c_void) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn bcp_sendrow(param0: *mut ::core::ffi::c_void) -> i16; } ::core::mem::transmute(bcp_sendrow(::core::mem::transmute(param0))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[inline] pub unsafe fn bcp_setcolfmt(param0: *mut ::core::ffi::c_void, param1: i32, param2: i32, param3: *mut ::core::ffi::c_void, param4: i32) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn bcp_setcolfmt(param0: *mut ::core::ffi::c_void, param1: i32, param2: i32, param3: *mut ::core::ffi::c_void, param4: i32) -> i16; } ::core::mem::transmute(bcp_setcolfmt(::core::mem::transmute(param0), ::core::mem::transmute(param1), ::core::mem::transmute(param2), ::core::mem::transmute(param3), ::core::mem::transmute(param4))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(feature = "Win32_Foundation")] #[inline] pub unsafe fn bcp_writefmtA<'a, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::PSTR>>(param0: *mut ::core::ffi::c_void, param1: Param1) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn bcp_writefmtA(param0: *mut ::core::ffi::c_void, param1: super::super::Foundation::PSTR) -> i16; } ::core::mem::transmute(bcp_writefmtA(::core::mem::transmute(param0), param1.into_param().abi())) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(feature = "Win32_Foundation")] #[inline] pub unsafe fn bcp_writefmtW<'a, Param1: ::windows::core::IntoParam<'a, super::super::Foundation::PWSTR>>(param0: *mut ::core::ffi::c_void, param1: Param1) -> i16 { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn bcp_writefmtW(param0: *mut ::core::ffi::c_void, param1: super::super::Foundation::PWSTR) -> i16; } ::core::mem::transmute(bcp_writefmtW(::core::mem::transmute(param0), param1.into_param().abi())) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] pub struct dbdatetime { pub dtdays: i32, pub dttime: u32, } impl dbdatetime {} impl ::core::default::Default for dbdatetime { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } impl ::core::fmt::Debug for dbdatetime { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("dbdatetime").field("dtdays", &self.dtdays).field("dttime", &self.dttime).finish() } } impl ::core::cmp::PartialEq for dbdatetime { fn eq(&self, other: &Self) -> bool { self.dtdays == other.dtdays && self.dttime == other.dttime } } impl ::core::cmp::Eq for dbdatetime {} unsafe impl ::windows::core::Abi for dbdatetime { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] pub struct dbdatetime4 { pub numdays: u16, pub nummins: u16, } impl dbdatetime4 {} impl ::core::default::Default for dbdatetime4 { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } impl ::core::fmt::Debug for dbdatetime4 { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("dbdatetime4").field("numdays", &self.numdays).field("nummins", &self.nummins).finish() } } impl ::core::cmp::PartialEq for dbdatetime4 { fn eq(&self, other: &Self) -> bool { self.numdays == other.numdays && self.nummins == other.nummins } } impl ::core::cmp::Eq for dbdatetime4 {} unsafe impl ::windows::core::Abi for dbdatetime4 { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] pub struct dbmoney { pub mnyhigh: i32, pub mnylow: u32, } impl dbmoney {} impl ::core::default::Default for dbmoney { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } impl ::core::fmt::Debug for dbmoney { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("dbmoney").field("mnyhigh", &self.mnyhigh).field("mnylow", &self.mnylow).finish() } } impl ::core::cmp::PartialEq for dbmoney { fn eq(&self, other: &Self) -> bool { self.mnyhigh == other.mnyhigh && self.mnylow == other.mnylow } } impl ::core::cmp::Eq for dbmoney {} unsafe impl ::windows::core::Abi for dbmoney { type Abi = Self; } #[cfg(feature = "Win32_Foundation")] #[inline] pub unsafe fn dbprtypeA(param0: i32) -> super::super::Foundation::PSTR { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn dbprtypeA(param0: i32) -> super::super::Foundation::PSTR; } ::core::mem::transmute(dbprtypeA(::core::mem::transmute(param0))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[cfg(feature = "Win32_Foundation")] #[inline] pub unsafe fn dbprtypeW(param0: i32) -> super::super::Foundation::PWSTR { #[cfg(windows)] { #[link(name = "windows")] extern "system" { fn dbprtypeW(param0: i32) -> super::super::Foundation::PWSTR; } ::core::mem::transmute(dbprtypeW(::core::mem::transmute(param0))) } #[cfg(not(windows))] unimplemented!("Unsupported target OS"); } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] pub struct dbvarybin { pub len: i16, pub array: [u8; 8001], } impl dbvarybin {} impl ::core::default::Default for dbvarybin { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } impl ::core::fmt::Debug for dbvarybin { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("dbvarybin").field("len", &self.len).field("array", &self.array).finish() } } impl ::core::cmp::PartialEq for dbvarybin { fn eq(&self, other: &Self) -> bool { self.len == other.len && self.array == other.array } } impl ::core::cmp::Eq for dbvarybin {} unsafe impl ::windows::core::Abi for dbvarybin { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] pub struct dbvarychar { pub len: i16, pub str: [i8; 8001], } impl dbvarychar {} impl ::core::default::Default for dbvarychar { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } impl ::core::fmt::Debug for dbvarychar { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("dbvarychar").field("len", &self.len).field("str", &self.str).finish() } } impl ::core::cmp::PartialEq for dbvarychar { fn eq(&self, other: &Self) -> bool { self.len == other.len && self.str == other.str } } impl ::core::cmp::Eq for dbvarychar {} unsafe impl ::windows::core::Abi for dbvarychar { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] pub struct sqlperf { pub TimerResolution: u32, pub SQLidu: u32, pub SQLiduRows: u32, pub SQLSelects: u32, pub SQLSelectRows: u32, pub Transactions: u32, pub SQLPrepares: u32, pub ExecDirects: u32, pub SQLExecutes: u32, pub CursorOpens: u32, pub CursorSize: u32, pub CursorUsed: u32, pub PercentCursorUsed: f64, pub AvgFetchTime: f64, pub AvgCursorSize: f64, pub AvgCursorUsed: f64, pub SQLFetchTime: u32, pub SQLFetchCount: u32, pub CurrentStmtCount: u32, pub MaxOpenStmt: u32, pub SumOpenStmt: u32, pub CurrentConnectionCount: u32, pub MaxConnectionsOpened: u32, pub SumConnectionsOpened: u32, pub SumConnectiontime: u32, pub AvgTimeOpened: f64, pub ServerRndTrips: u32, pub BuffersSent: u32, pub BuffersRec: u32, pub BytesSent: u32, pub BytesRec: u32, pub msExecutionTime: u32, pub msNetWorkServerTime: u32, } impl sqlperf {} impl ::core::default::Default for sqlperf { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } impl ::core::fmt::Debug for sqlperf { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("sqlperf") .field("TimerResolution", &self.TimerResolution) .field("SQLidu", &self.SQLidu) .field("SQLiduRows", &self.SQLiduRows) .field("SQLSelects", &self.SQLSelects) .field("SQLSelectRows", &self.SQLSelectRows) .field("Transactions", &self.Transactions) .field("SQLPrepares", &self.SQLPrepares) .field("ExecDirects", &self.ExecDirects) .field("SQLExecutes", &self.SQLExecutes) .field("CursorOpens", &self.CursorOpens) .field("CursorSize", &self.CursorSize) .field("CursorUsed", &self.CursorUsed) .field("PercentCursorUsed", &self.PercentCursorUsed) .field("AvgFetchTime", &self.AvgFetchTime) .field("AvgCursorSize", &self.AvgCursorSize) .field("AvgCursorUsed", &self.AvgCursorUsed) .field("SQLFetchTime", &self.SQLFetchTime) .field("SQLFetchCount", &self.SQLFetchCount) .field("CurrentStmtCount", &self.CurrentStmtCount) .field("MaxOpenStmt", &self.MaxOpenStmt) .field("SumOpenStmt", &self.SumOpenStmt) .field("CurrentConnectionCount", &self.CurrentConnectionCount) .field("MaxConnectionsOpened", &self.MaxConnectionsOpened) .field("SumConnectionsOpened", &self.SumConnectionsOpened) .field("SumConnectiontime", &self.SumConnectiontime) .field("AvgTimeOpened", &self.AvgTimeOpened) .field("ServerRndTrips", &self.ServerRndTrips) .field("BuffersSent", &self.BuffersSent) .field("BuffersRec", &self.BuffersRec) .field("BytesSent", &self.BytesSent) .field("BytesRec", &self.BytesRec) .field("msExecutionTime", &self.msExecutionTime) .field("msNetWorkServerTime", &self.msNetWorkServerTime) .finish() } } impl ::core::cmp::PartialEq for sqlperf { fn eq(&self, other: &Self) -> bool { self.TimerResolution == other.TimerResolution && self.SQLidu == other.SQLidu && self.SQLiduRows == other.SQLiduRows && self.SQLSelects == other.SQLSelects && self.SQLSelectRows == other.SQLSelectRows && self.Transactions == other.Transactions && self.SQLPrepares == other.SQLPrepares && self.ExecDirects == other.ExecDirects && self.SQLExecutes == other.SQLExecutes && self.CursorOpens == other.CursorOpens && self.CursorSize == other.CursorSize && self.CursorUsed == other.CursorUsed && self.PercentCursorUsed == other.PercentCursorUsed && self.AvgFetchTime == other.AvgFetchTime && self.AvgCursorSize == other.AvgCursorSize && self.AvgCursorUsed == other.AvgCursorUsed && self.SQLFetchTime == other.SQLFetchTime && self.SQLFetchCount == other.SQLFetchCount && self.CurrentStmtCount == other.CurrentStmtCount && self.MaxOpenStmt == other.MaxOpenStmt && self.SumOpenStmt == other.SumOpenStmt && self.CurrentConnectionCount == other.CurrentConnectionCount && self.MaxConnectionsOpened == other.MaxConnectionsOpened && self.SumConnectionsOpened == other.SumConnectionsOpened && self.SumConnectiontime == other.SumConnectiontime && self.AvgTimeOpened == other.AvgTimeOpened && self.ServerRndTrips == other.ServerRndTrips && self.BuffersSent == other.BuffersSent && self.BuffersRec == other.BuffersRec && self.BytesSent == other.BytesSent && self.BytesRec == other.BytesRec && self.msExecutionTime == other.msExecutionTime && self.msNetWorkServerTime == other.msNetWorkServerTime } } impl ::core::cmp::Eq for sqlperf {} unsafe impl ::windows::core::Abi for sqlperf { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] pub struct tagDBROWWATCHRANGE { pub hRegion: usize, pub eChangeKind: u32, pub hRow: usize, pub iRow: usize, } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl tagDBROWWATCHRANGE {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::default::Default for tagDBROWWATCHRANGE { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::fmt::Debug for tagDBROWWATCHRANGE { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("tagDBROWWATCHRANGE").field("hRegion", &self.hRegion).field("eChangeKind", &self.eChangeKind).field("hRow", &self.hRow).field("iRow", &self.iRow).finish() } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::cmp::PartialEq for tagDBROWWATCHRANGE { fn eq(&self, other: &Self) -> bool { self.hRegion == other.hRegion && self.eChangeKind == other.eChangeKind && self.hRow == other.hRow && self.iRow == other.iRow } } #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] impl ::core::cmp::Eq for tagDBROWWATCHRANGE {} #[cfg(any(target_arch = "x86_64", target_arch = "aarch64",))] unsafe impl ::windows::core::Abi for tagDBROWWATCHRANGE { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C, packed(2))] #[cfg(any(target_arch = "x86",))] pub struct tagDBROWWATCHRANGE { pub hRegion: usize, pub eChangeKind: u32, pub hRow: usize, pub iRow: usize, } #[cfg(any(target_arch = "x86",))] impl tagDBROWWATCHRANGE {} #[cfg(any(target_arch = "x86",))] impl ::core::default::Default for tagDBROWWATCHRANGE { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(any(target_arch = "x86",))] impl ::core::cmp::PartialEq for tagDBROWWATCHRANGE { fn eq(&self, _other: &Self) -> bool { unimplemented!() } } #[cfg(any(target_arch = "x86",))] impl ::core::cmp::Eq for tagDBROWWATCHRANGE {} #[cfg(any(target_arch = "x86",))] unsafe impl ::windows::core::Abi for tagDBROWWATCHRANGE { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] pub struct tagSQL_DAY_SECOND { pub day: u32, pub hour: u32, pub minute: u32, pub second: u32, pub fraction: u32, } impl tagSQL_DAY_SECOND {} impl ::core::default::Default for tagSQL_DAY_SECOND { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } impl ::core::fmt::Debug for tagSQL_DAY_SECOND { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("tagSQL_DAY_SECOND").field("day", &self.day).field("hour", &self.hour).field("minute", &self.minute).field("second", &self.second).field("fraction", &self.fraction).finish() } } impl ::core::cmp::PartialEq for tagSQL_DAY_SECOND { fn eq(&self, other: &Self) -> bool { self.day == other.day && self.hour == other.hour && self.minute == other.minute && self.second == other.second && self.fraction == other.fraction } } impl ::core::cmp::Eq for tagSQL_DAY_SECOND {} unsafe impl ::windows::core::Abi for tagSQL_DAY_SECOND { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] pub struct tagSQL_YEAR_MONTH { pub year: u32, pub month: u32, } impl tagSQL_YEAR_MONTH {} impl ::core::default::Default for tagSQL_YEAR_MONTH { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } impl ::core::fmt::Debug for tagSQL_YEAR_MONTH { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("tagSQL_YEAR_MONTH").field("year", &self.year).field("month", &self.month).finish() } } impl ::core::cmp::PartialEq for tagSQL_YEAR_MONTH { fn eq(&self, other: &Self) -> bool { self.year == other.year && self.month == other.month } } impl ::core::cmp::Eq for tagSQL_YEAR_MONTH {} unsafe impl ::windows::core::Abi for tagSQL_YEAR_MONTH { type Abi = Self; } #[derive(:: core :: clone :: Clone, :: core :: marker :: Copy)] #[repr(C)] #[cfg(feature = "Win32_Foundation")] pub struct tagSSErrorInfo { pub pwszMessage: super::super::Foundation::PWSTR, pub pwszServer: super::super::Foundation::PWSTR, pub pwszProcedure: super::super::Foundation::PWSTR, pub lNative: i32, pub bState: u8, pub bClass: u8, pub wLineNumber: u16, } #[cfg(feature = "Win32_Foundation")] impl tagSSErrorInfo {} #[cfg(feature = "Win32_Foundation")] impl ::core::default::Default for tagSSErrorInfo { fn default() -> Self { unsafe { ::core::mem::zeroed() } } } #[cfg(feature = "Win32_Foundation")] impl ::core::fmt::Debug for tagSSErrorInfo { fn fmt(&self, fmt: &mut ::core::fmt::Formatter<'_>) -> ::core::fmt::Result { fmt.debug_struct("tagSSErrorInfo").field("pwszMessage", &self.pwszMessage).field("pwszServer", &self.pwszServer).field("pwszProcedure", &self.pwszProcedure).field("lNative", &self.lNative).field("bState", &self.bState).field("bClass", &self.bClass).field("wLineNumber", &self.wLineNumber).finish() } } #[cfg(feature = "Win32_Foundation")] impl ::core::cmp::PartialEq for tagSSErrorInfo { fn eq(&self, other: &Self) -> bool { self.pwszMessage == other.pwszMessage && self.pwszServer == other.pwszServer && self.pwszProcedure == other.pwszProcedure && self.lNative == other.lNative && self.bState == other.bState && self.bClass == other.bClass && self.wLineNumber == other.wLineNumber } } #[cfg(feature = "Win32_Foundation")] impl ::core::cmp::Eq for tagSSErrorInfo {} #[cfg(feature = "Win32_Foundation")] unsafe impl ::windows::core::Abi for tagSSErrorInfo { type Abi = Self; }
use std::env; use std::fs; const SLOPE_X: i32 = 3; const SLOPE_Y: i32 = 1; struct Xy { x: i32, y: i32 } struct Slope { grid_flatten: Vec<bool>, grid_dim: Xy, santa: Xy, delta: Xy, trees_hit:u16 } impl Slope { fn from_lines (lines: &String) -> Slope { let h = lines.split_whitespace().count(); let w= lines.split_whitespace().nth(0).unwrap().len(); let grid_dim = Xy {x: w as i32, y: h as i32}; let mut grid_flatten: Vec<bool> = Vec::new(); for l in lines.split_whitespace() { for c in l.chars() { match c { '#' => grid_flatten.push(true), '.' => grid_flatten.push(false), _ => grid_flatten.push(false) } } } Slope { grid_flatten, grid_dim, santa: Xy {x: 0, y: 0}, delta: Xy {x: SLOPE_X, y: SLOPE_Y }, trees_hit: 0 } } fn here_is_a_tree(&self, here: &Xy) -> bool { let idx = here.y * self.grid_dim.x + here.x; return self.grid_flatten[idx as usize] == true; } fn descend (&mut self) { while self.santa.y + self.delta.y < self.grid_dim.y { self.santa.x = (self.santa.x + self.delta.x) % self.grid_dim.x; self.santa.y += self.delta.y; if self.here_is_a_tree(&self.santa) { self.trees_hit += 1; } } } fn reset (&mut self) { self.santa = Xy {x:0, y:0}; self.trees_hit = 0; } } fn main() { let mut f_in = "example.txt".to_string(); if let Some(arg_1) = env::args().nth(1) { // learning how to use `if let` today f_in = arg_1; } let contents = fs::read_to_string(f_in).expect("Error in reading file"); let mut tobogan = Slope::from_lines(&contents); tobogan.descend(); println!{"Outch! hit {} trees!", tobogan.trees_hit}; tobogan.reset(); let slopes = vec![Xy{x:1, y:1}, Xy{x:3, y:1}, Xy{x:5, y:1}, Xy{x:7, y:1}, Xy{x:1, y:2}]; let mut result : i64 = 1; for s in slopes { tobogan.delta = s; tobogan.descend(); result = result * tobogan.trees_hit as i64; tobogan.reset(); } println!{"multiplied together = {} trees!", result}; }
fn main() { println!("Line one!"); // panic!("Crash n' burn."); println!("Line two!"); let v = vec![1, 2, 3]; v[99]; // RUST_BACKTRACE=1 cargo run }
mod runner; pub use runner::*;
mod abs; mod accdist; mod acos; mod alma; mod asin; mod atan; mod atr; mod avg; mod barstate; mod bb; mod bbw; mod cci; mod ceil; mod change; mod close; mod cmo; mod cog; mod color; mod correlation; mod cos; mod cum; mod dayofmonth; mod dayofweek; mod dev; mod dmi; mod ema; mod exp; mod falling; mod fill; mod fixnan; mod floor; mod high; mod highest; mod highestbars; mod hl2; mod hlc3; mod hline; mod hma; mod hour; mod iff; mod input; mod kc; mod kcw; mod log; mod log10; mod low; mod lowest; mod lowestbars; mod macd; mod max; mod mfi; mod min; mod minute; mod mom; mod month; mod na; mod nz; mod ohlc4; mod open; mod plot; mod pow; mod rising; mod rma; mod round; mod rsi; mod sign; mod sin; mod sma; mod sqrt; mod stdev; mod stoch; mod study; mod sum; mod swma; mod tan; mod time; mod timenow; mod timestamp; mod tr; mod tsi; mod variance; mod vwma; mod weekofyear; mod wma; mod year; use super::DocBase; pub fn declare_vars() -> Vec<DocBase> { vec![ plot::gen_doc(), input::gen_doc(), accdist::gen_doc(), abs::gen_doc(), acos::gen_doc(), alma::gen_doc(), asin::gen_doc(), atan::gen_doc(), atr::gen_doc(), avg::gen_doc(), barstate::gen_doc(), color::gen_doc(), dayofmonth::gen_doc(), dayofweek::gen_doc(), hour::gen_doc(), minute::gen_doc(), month::gen_doc(), time::gen_doc(), timenow::gen_doc(), weekofyear::gen_doc(), year::gen_doc(), hl2::gen_doc(), hlc3::gen_doc(), ohlc4::gen_doc(), tr::gen_doc(), bb::gen_doc(), bbw::gen_doc(), cci::gen_doc(), ceil::gen_doc(), change::gen_doc(), cmo::gen_doc(), cog::gen_doc(), correlation::gen_doc(), cos::gen_doc(), cum::gen_doc(), dev::gen_doc(), dmi::gen_doc(), ema::gen_doc(), exp::gen_doc(), falling::gen_doc(), fill::gen_doc(), fixnan::gen_doc(), floor::gen_doc(), highest::gen_doc(), highestbars::gen_doc(), hline::gen_doc(), hma::gen_doc(), iff::gen_doc(), kc::gen_doc(), kcw::gen_doc(), log::gen_doc(), log10::gen_doc(), lowest::gen_doc(), lowestbars::gen_doc(), macd::gen_doc(), max::gen_doc(), mfi::gen_doc(), min::gen_doc(), mom::gen_doc(), na::gen_doc(), nz::gen_doc(), pow::gen_doc(), rising::gen_doc(), rma::gen_doc(), round::gen_doc(), rsi::gen_doc(), sign::gen_doc(), sin::gen_doc(), sma::gen_doc(), sqrt::gen_doc(), stdev::gen_doc(), stoch::gen_doc(), study::gen_doc(), sum::gen_doc(), swma::gen_doc(), tan::gen_doc(), timestamp::gen_doc(), tsi::gen_doc(), variance::gen_doc(), vwma::gen_doc(), wma::gen_doc(), close::gen_doc(), open::gen_doc(), high::gen_doc(), low::gen_doc(), ] .into_iter() .flatten() .collect() }
use actix_web::{web}; use actix_web::error::BlockingError; use diesel::RunQueryDsl; use diesel::sql_types::BigInt; use diesel::result::Error; use crate::config::database::DbPool; #[derive(QueryableByName, PartialEq, Debug)] pub struct QueryResult { #[sql_type="BigInt"] pub col1: i64, } pub async fn ping(pool: &web::Data<DbPool>) -> Result<QueryResult, BlockingError<Error>>{ let conn = pool.get().unwrap(); let ping = web::block(move || diesel::sql_query("select 1 as col1").get_result::<QueryResult>(&conn)) .await; ping }
use crate::ActionInput; use game_lib::bevy::{prelude::*, utils::HashMap}; #[derive(Clone, Debug)] // TODO: once bevy supports reflection for inputs, uncomment this: // #[derive(Reflect)] pub struct InputBindings { pub keyboard: HashMap<KeyCode, ActionInput>, pub mouse: HashMap<MouseButton, ActionInput>, } impl Default for InputBindings { fn default() -> Self { // Default keyboard bindings let mut keyboard = HashMap::default(); keyboard.insert(KeyCode::Left, ActionInput::CameraLeft); keyboard.insert(KeyCode::Right, ActionInput::CameraRight); keyboard.insert(KeyCode::Up, ActionInput::CameraUp); keyboard.insert(KeyCode::Down, ActionInput::CameraDown); keyboard.insert(KeyCode::Equals, ActionInput::CameraIn); keyboard.insert(KeyCode::Minus, ActionInput::CameraOut); keyboard.insert(KeyCode::C, ActionInput::CycleCameraMode); keyboard.insert(KeyCode::A, ActionInput::PlayerLeft); keyboard.insert(KeyCode::D, ActionInput::PlayerRight); keyboard.insert(KeyCode::Space, ActionInput::PlayerJump); // Default mouse bindings let mouse = HashMap::default(); InputBindings { keyboard, mouse } } }
use crate::{controllers::TypedController, math::Size, BoxConstraints}; use crate::{math::Vector2, Backend}; use super::{TypedWidget, Widget}; pub struct Controlled<T, W, C, B: Backend> { widget: W, controller: C, _b: std::marker::PhantomData<B>, _t: std::marker::PhantomData<T>, } impl<T, W, C, B: Backend> Controlled<T, W, C, B> { pub fn new(widget: W, controller: C) -> Self { Controlled { widget, controller, _b: std::marker::PhantomData, _t: std::marker::PhantomData, } } } impl<T, W: TypedWidget<T, B> + Widget<T>, C: TypedController<T, W, B>, B: Backend> Widget<T> for Controlled<T, W, C, B> { type Primitive = B::Primitive; type Context = B; type Event = B::Event; type Reaction = B::EventReaction; fn layout(&mut self, bc: &BoxConstraints, context: &Self::Context, data: &T) -> Size { TypedWidget::<T, B>::layout(&mut self.widget, bc, context, data) } fn draw(&self, origin: Vector2, size: Size, data: &T) -> Self::Primitive { TypedWidget::<T, B>::draw(&self.widget, origin, size, data) } fn event( &mut self, origin: Vector2, size: Size, data: &mut T, event: Self::Event, ) -> Option<Self::Reaction> { TypedController::<T, W, B>::event( &mut self.controller, &mut self.widget, origin, size, data, event, ) } }
// Copyright 2018 The Fuchsia Authors. All rights reserved. // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. //! Custom error types for the netstack. use failure::Fail; use net_types::ip::{Ip, IpAddress}; use net_types::MulticastAddress; use crate::device::AddressError; use crate::wire::icmp::IcmpIpTypes; /// Results returned from many functions in the netstack. pub(crate) type Result<T> = std::result::Result<T, NetstackError>; /// Results returned from parsing functions in the netstack. pub(crate) type ParseResult<T> = std::result::Result<T, ParseError>; /// Results returned from IP packet parsing functions in the netstack. pub(crate) type IpParseResult<I, T> = std::result::Result<T, IpParseError<I>>; /// Top-level error type the netstack. #[derive(Fail, Debug, PartialEq)] pub enum NetstackError { #[fail(display = "{}", _0)] /// Errors related to packet parsing. Parse(#[cause] ParseError), /// Error when item already exists. #[fail(display = "Item already exists")] Exists, /// Error when item is not found. #[fail(display = "Item not found")] NotFound, // Add error types here as we add more to the stack } impl From<AddressError> for NetstackError { fn from(error: AddressError) -> Self { match error { AddressError::AlreadyExists => Self::Exists, AddressError::NotFound => Self::NotFound, } } } /// Error type for packet parsing. #[derive(Fail, Debug, PartialEq)] pub enum ParseError { #[fail(display = "Operation is not supported")] NotSupported, #[fail(display = "Operation was not expected in this context")] NotExpected, #[fail(display = "Invalid checksum")] Checksum, #[fail(display = "Packet is not formatted properly")] Format, } /// Action to take when an error is encountered while parsing an IP packet. #[derive(Copy, Clone, Debug, PartialEq)] pub enum IpParseErrorAction { /// Discard the packet and do nothing further. DiscardPacket, /// Discard the packet and send an ICMP response. DiscardPacketSendICMP, /// Discard the packet and send an ICMP response if the packet's /// destination address was not a multicast address. DiscardPacketSendICMPNoMulticast, } impl IpParseErrorAction { /// Determines whether or not an ICMP message should be sent. /// /// Returns `true` if we should send an ICMP response. We should send /// an ICMP response if an action is set to `DiscardPacketSendICMP`, or /// if an action is set to `DiscardPacketSendICMPNoMulticast` and `dst_addr` /// (the destination address of the original packet that lead to a parsing /// error) is not a multicast address. pub(crate) fn should_send_icmp<A: IpAddress>(&self, dst_addr: &A) -> bool { match *self { IpParseErrorAction::DiscardPacket => false, IpParseErrorAction::DiscardPacketSendICMP => true, IpParseErrorAction::DiscardPacketSendICMPNoMulticast => !dst_addr.is_multicast(), } } /// Determines whether or not an ICMP message should be sent even if /// the original packet's destination address is a multicast. pub(crate) fn should_send_icmp_to_multicast(&self) -> bool { match *self { IpParseErrorAction::DiscardPacketSendICMP => true, IpParseErrorAction::DiscardPacket | IpParseErrorAction::DiscardPacketSendICMPNoMulticast => false, } } } /// Error type for IP packet parsing. #[derive(Fail, Debug, PartialEq)] pub(crate) enum IpParseError<I: IcmpIpTypes> { #[fail(display = "Parsing Error")] Parse { error: ParseError }, /// For errors where an ICMP Parameter Problem error needs to be /// sent to the source of a packet. /// /// `src_ip` and `dst_ip` are the source and destination IP addresses of the /// original packet. `header_len` is the length of the header that we know /// about up to the point of the parameter problem error. `action` is the /// action we should take after encountering the error. If `must_send_icmp` /// is `true` we MUST send an ICMP response if `action` specifies it; /// otherwise, we MAY choose to just discard the packet and do nothing /// further. `code` is the ICMP (ICMPv4 or ICMPv6) specific parameter /// problem code that provides more granular information about the parameter /// problem encountered. `pointer` is the offset of the erroneous value within /// the IP packet, calculated from the beginning of the IP packet. #[fail(display = "Parameter Problem")] ParameterProblem { src_ip: I::Addr, dst_ip: I::Addr, code: I::ParameterProblemCode, pointer: I::ParameterProblemPointer, must_send_icmp: bool, header_len: I::HeaderLen, action: IpParseErrorAction, }, } impl<I: Ip> From<ParseError> for IpParseError<I> { fn from(error: ParseError) -> Self { IpParseError::Parse { error } } } /// Error when something exists unexpectedly, such as trying to add an /// element when the element is already present. #[derive(Debug, PartialEq, Eq)] pub(crate) struct ExistsError; impl From<ExistsError> for NetstackError { fn from(_: ExistsError) -> NetstackError { NetstackError::Exists } } /// Error when something unexpectedly doesn't exist, such as trying to /// remove an element when the element is not present. #[derive(Debug, PartialEq, Eq)] pub(crate) struct NotFoundError; impl From<NotFoundError> for NetstackError { fn from(_: NotFoundError) -> NetstackError { NetstackError::NotFound } }
// Copyright 2022 Datafuse Labs. // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. use std::sync::Arc; use common_base::base::tokio; use common_catalog::table::Table; use common_catalog::table::TableExt; use common_catalog::table_mutator::TableMutator; use common_exception::ErrorCode; use common_exception::Result; use common_expression::types::number::NumberColumn; use common_expression::types::number::NumberScalar; use common_expression::Column; use common_expression::DataBlock; use common_expression::Scalar; use common_expression::SendableDataBlockStream; use common_expression::Value; use common_storage::DataOperator; use common_storages_fuse::io::MetaReaders; use common_storages_fuse::io::SegmentInfoReader; use common_storages_fuse::io::SegmentWriter; use common_storages_fuse::io::SegmentsIO; use common_storages_fuse::io::TableMetaLocationGenerator; use common_storages_fuse::operations::CompactOptions; use common_storages_fuse::operations::SegmentCompactMutator; use common_storages_fuse::operations::SegmentCompactionState; use common_storages_fuse::operations::SegmentCompactor; use common_storages_fuse::statistics::gen_columns_statistics; use common_storages_fuse::statistics::reducers::merge_statistics_mut; use common_storages_fuse::statistics::StatisticsAccumulator; use common_storages_fuse::FuseStorageFormat; use common_storages_fuse::FuseTable; use databend_query::sessions::QueryContext; use databend_query::sessions::TableContext; use futures_util::TryStreamExt; use rand::thread_rng; use rand::Rng; use storages_common_cache::LoadParams; use storages_common_table_meta::meta::BlockMeta; use storages_common_table_meta::meta::Location; use storages_common_table_meta::meta::SegmentInfo; use storages_common_table_meta::meta::Statistics; use storages_common_table_meta::meta::Versioned; use crate::storages::fuse::block_writer::BlockWriter; use crate::storages::fuse::table_test_fixture::execute_command; use crate::storages::fuse::table_test_fixture::execute_query; use crate::storages::fuse::table_test_fixture::TestFixture; #[tokio::test(flavor = "multi_thread")] async fn test_compact_segment_normal_case() -> Result<()> { let fixture = TestFixture::new().await; let ctx = fixture.ctx(); // setup let qry = "create table t(c int) block_per_segment=10"; execute_command(ctx.clone(), qry).await?; let catalog = ctx.get_catalog("default")?; let num_inserts = 9; append_rows(ctx.clone(), num_inserts).await?; // check count let count_qry = "select count(*) from t"; let stream = execute_query(fixture.ctx(), count_qry).await?; assert_eq!(9, check_count(stream).await?); // compact segment let table = catalog .get_table(ctx.get_tenant().as_str(), "default", "t") .await?; let fuse_table = FuseTable::try_from_table(table.as_ref())?; let mutator = build_mutator(fuse_table, ctx.clone(), None).await?; assert!(mutator.is_some()); let mutator = mutator.unwrap(); mutator.try_commit(table.clone()).await?; // check segment count let qry = "select segment_count as count from fuse_snapshot('default', 't') limit 1"; let stream = execute_query(fixture.ctx(), qry).await?; // after compact, in our case, there should be only 1 segment left assert_eq!(1, check_count(stream).await?); // check block count let qry = "select block_count as count from fuse_snapshot('default', 't') limit 1"; let stream = execute_query(fixture.ctx(), qry).await?; assert_eq!(num_inserts as u64, check_count(stream).await?); Ok(()) } #[tokio::test(flavor = "multi_thread")] async fn test_compact_segment_resolvable_conflict() -> Result<()> { let fixture = TestFixture::new().await; let ctx = fixture.ctx(); // setup let create_tbl_command = "create table t(c int) block_per_segment=10"; execute_command(ctx.clone(), create_tbl_command).await?; let catalog = ctx.get_catalog("default")?; let num_inserts = 9; append_rows(ctx.clone(), num_inserts).await?; // check count let count_qry = "select count(*) from t"; let stream = execute_query(fixture.ctx(), count_qry).await?; assert_eq!(9, check_count(stream).await?); // compact segment let table = catalog .get_table(ctx.get_tenant().as_str(), "default", "t") .await?; let fuse_table = FuseTable::try_from_table(table.as_ref())?; let mutator = build_mutator(fuse_table, ctx.clone(), None).await?; assert!(mutator.is_some()); let mutator = mutator.unwrap(); // before commit compact segments, gives 9 append commits let num_inserts = 9; append_rows(ctx.clone(), num_inserts).await?; mutator.try_commit(table.clone()).await?; // check segment count let count_seg = "select segment_count as count from fuse_snapshot('default', 't') limit 1"; let stream = execute_query(fixture.ctx(), count_seg).await?; // after compact, in our case, there should be only 1 + num_inserts segments left // during compact retry, newly appended segments will NOT be compacted again assert_eq!(1 + num_inserts as u64, check_count(stream).await?); // check block count let count_block = "select block_count as count from fuse_snapshot('default', 't') limit 1"; let stream = execute_query(fixture.ctx(), count_block).await?; assert_eq!(num_inserts as u64 * 2, check_count(stream).await?); // check table statistics let latest = table.refresh(ctx.as_ref()).await?; let latest_fuse_table = FuseTable::try_from_table(latest.as_ref())?; let table_statistics = latest_fuse_table.table_statistics()?.unwrap(); assert_eq!(table_statistics.num_rows.unwrap() as usize, num_inserts * 2); Ok(()) } #[tokio::test(flavor = "multi_thread")] async fn test_compact_segment_unresolvable_conflict() -> Result<()> { let fixture = TestFixture::new().await; let ctx = fixture.ctx(); // setup let create_tbl_command = "create table t(c int) block_per_segment=10"; execute_command(ctx.clone(), create_tbl_command).await?; let catalog = ctx.get_catalog("default")?; let num_inserts = 9; append_rows(ctx.clone(), num_inserts).await?; // check count let count_qry = "select count(*) from t"; let stream = execute_query(fixture.ctx(), count_qry).await?; assert_eq!(num_inserts as u64, check_count(stream).await?); // try compact segment let table = catalog .get_table(ctx.get_tenant().as_str(), "default", "t") .await?; let fuse_table = FuseTable::try_from_table(table.as_ref())?; let mutator = build_mutator(fuse_table, ctx.clone(), None).await?; assert!(mutator.is_some()); let mutator = mutator.unwrap(); { // inject a unresolvable commit compact_segment(ctx.clone(), &table).await?; } // the compact operation committed latter should failed let r = mutator.try_commit(table.clone()).await; assert!(r.is_err()); assert_eq!(r.err().unwrap().code(), ErrorCode::STORAGE_OTHER); Ok(()) } async fn append_rows(ctx: Arc<QueryContext>, n: usize) -> Result<()> { let qry = "insert into t values(1)"; for _ in 0..n { execute_command(ctx.clone(), qry).await?; } Ok(()) } async fn check_count(result_stream: SendableDataBlockStream) -> Result<u64> { let blocks: Vec<DataBlock> = result_stream.try_collect().await?; match &blocks[0].get_by_offset(0).value { Value::Scalar(Scalar::Number(NumberScalar::UInt64(s))) => Ok(*s), Value::Column(Column::Number(NumberColumn::UInt64(c))) => Ok(c[0]), _ => Err(ErrorCode::BadDataValueType(format!( "Expected UInt64, but got {:?}", blocks[0].get_by_offset(0).value ))), } } async fn compact_segment(ctx: Arc<QueryContext>, table: &Arc<dyn Table>) -> Result<()> { let fuse_table = FuseTable::try_from_table(table.as_ref())?; let mutator = build_mutator(fuse_table, ctx.clone(), None).await?.unwrap(); mutator.try_commit(table.clone()).await } async fn build_mutator( tbl: &FuseTable, ctx: Arc<dyn TableContext>, limit: Option<usize>, ) -> Result<Option<Box<dyn TableMutator>>> { let snapshot_opt = tbl.read_table_snapshot().await?; let base_snapshot = if let Some(val) = snapshot_opt { val } else { // no snapshot, no compaction. return Ok(None); }; if base_snapshot.summary.block_count <= 1 { return Ok(None); } let block_per_seg = tbl.get_option("block_per_segment", 1000); let compact_params = CompactOptions { base_snapshot, block_per_seg, limit, }; let mut segment_mutator = SegmentCompactMutator::try_create( ctx.clone(), compact_params, tbl.meta_location_generator().clone(), tbl.get_operator(), )?; if segment_mutator.target_select().await? { Ok(Some(Box::new(segment_mutator))) } else { Ok(None) } } #[tokio::test(flavor = "multi_thread")] async fn test_segment_compactor() -> Result<()> { let fixture = TestFixture::new().await; let ctx = fixture.ctx(); { let case_name = "highly fragmented segments"; let threshold = 10; let case = CompactCase { // 3 fragmented segments // - each of them have number blocks lesser than `threshold` blocks_number_of_input_segments: vec![1, 2, 3], // - these segments should be compacted into one expected_number_of_output_segments: 1, // - which contains 6 blocks expected_block_number_of_new_segments: vec![1 + 2 + 3], case_name, }; // run, and verify that // - numbers are as expected // - number of the newly created segments (which are compacted) // - number of segments unchanged // - other general invariants // - unchanged segments still be there // - blocks and the order of them are not changed // - statistics are as expected // - the output segments could not be compacted further case.run_and_verify(&ctx, threshold, None).await?; } { let case_name = "greedy compact, but not too greedy(1), right assoc"; let threshold = 10; let case = CompactCase { // - 4 segments blocks_number_of_input_segments: vec![1, 8, 2, 8], // - these segments should be compacted into 2 new segments expected_number_of_output_segments: 2, // compaction is right-assoc // - (2 + 8) meets threshold 10 // they should be compacted into one new segment. // although the next segment contains only 1 segment, it should NOT // be compacted (the not too greedy rule) // - (1 + 8) should be compacted into another new segment // // To let the case more readable, we specify the block numbers of new // segments in the order of input segments expected_block_number_of_new_segments: vec![1 + 8, 2 + 8], case_name, }; // run & verify case.run_and_verify(&ctx, threshold, None).await?; } { let case_name = "greedy compact, but not too greedy (2), right-assoc"; let threshold = 10; let case = CompactCase { // 4 segments blocks_number_of_input_segments: vec![5, 2, 3, 6], // these segments should be compacted into 2 segments expected_number_of_output_segments: 2, // (2 + 3 + 6) exceeds the threshold 10 // - but not too much, lesser than 2 * threshold, which is 20; // - they are allowed to be compacted into one, to avoid the ripple effects: // since the order of blocks should be preserved, they might be cases, that // to compact one fragment, a large amount of non-fragmented segments have to be // split into pieces and re-compacted. // - but the last segment of 5 blocks should be kept alone // thus, only one new segment will be generated (the not too greedy rule) // if it is the last segment of the snapshot, we just tolerant this situation. // if a limited expected_block_number_of_new_segments: vec![2 + 3 + 6], case_name, }; // run & verify case.run_and_verify(&ctx, threshold, None).await?; } { // case: fragmented segments, with barrier let case_name = "barrier(1), right-assoc"; let threshold = 10; let case = CompactCase { // input segments blocks_number_of_input_segments: vec![5, 6, 11, 2, 10], // these segments should be compacted into 2 new segments, 1 segment unchanged // unchanged: (10) // new segments: (11 + 2), ( 5 + 6) expected_number_of_output_segments: 2 + 1, expected_block_number_of_new_segments: vec![5 + 6, 11 + 2], case_name, }; case.run_and_verify(&ctx, threshold, None).await?; } { // case: fragmented segments, with barrier let case_name = "barrier(2)"; let threshold = 10; let case = CompactCase { // input segments blocks_number_of_input_segments: vec![10, 10, 1, 2, 10], // these segments should be compacted into // (10), (10), (1 + 2 + 10) expected_number_of_output_segments: 3, expected_block_number_of_new_segments: vec![(1 + 2 + 10)], case_name, }; case.run_and_verify(&ctx, threshold, None).await?; } { // case: fragmented segments, with barrier let case_name = "barrier(3)"; let threshold = 10; let case = CompactCase { // input segments blocks_number_of_input_segments: vec![1, 19, 5, 6], // these segments should be compacted into // (1), (19), (5, 6) expected_number_of_output_segments: 3, expected_block_number_of_new_segments: vec![(5 + 6)], case_name, }; case.run_and_verify(&ctx, threshold, None).await?; } { // edge case: empty segments should be dropped let case_name = "empty segments should be dropped"; let threshold = 10; let case = CompactCase { // input segments blocks_number_of_input_segments: vec![0, 1, 0, 19, 0, 5, 0, 6, 0], // these segments should be compacted into // (1), (19), (5, 6) expected_number_of_output_segments: 3, expected_block_number_of_new_segments: vec![(5 + 6)], case_name, }; case.run_and_verify(&ctx, threshold, None).await?; } { // edge case: single jumbo block let case_name = "single jumbo block"; let threshold = 3; let case = CompactCase { // input segments blocks_number_of_input_segments: vec![10], expected_number_of_output_segments: 1, expected_block_number_of_new_segments: vec![], case_name, }; case.run_and_verify(&ctx, threshold, None).await?; } { let case_name = "jumbo block with single fragment"; let threshold = 3; let case = CompactCase { // input segments blocks_number_of_input_segments: vec![7, 2], // inputs will not be compacted ( 7 > 2 * 3) expected_number_of_output_segments: 2, // no new segment should be generated expected_block_number_of_new_segments: vec![], case_name, }; case.run_and_verify(&ctx, threshold, None).await?; } { let case_name = "right assoc"; let threshold = 10; let case = CompactCase { // input segments blocks_number_of_input_segments: vec![8, 5, 7], expected_number_of_output_segments: 2, // one new segment should be generated, since // - (5 + 7) < 2 * 10 // - but (8 + 5 + 7) = 20 >= 20, which exceed the upper limit expected_block_number_of_new_segments: vec![5 + 7], case_name, }; case.run_and_verify(&ctx, threshold, None).await?; } { let case_name = "limit (normal case)"; let threshold = 5; let case = CompactCase { // input segments blocks_number_of_input_segments: vec![1, 2, 3, 2, 3], expected_number_of_output_segments: 4, expected_block_number_of_new_segments: vec![2 + 3], case_name, }; case.run_and_verify(&ctx, threshold, Some(2)).await?; } { let case_name = "limit (auto adjust limit)"; let threshold = 5; let case = CompactCase { // input segments blocks_number_of_input_segments: vec![1, 2, 3, 2, 3], expected_number_of_output_segments: 4, expected_block_number_of_new_segments: vec![2 + 3], case_name, }; // if limit is specified as 1, it will be adjust to 2 during execution // since at least two fragmented segments are needed for compaction let limit = Some(1); case.run_and_verify(&ctx, threshold, limit).await?; } { let case_name = "limit (abundant limit)"; let threshold = 5; let limit = Some(5); let case = CompactCase { // input segments blocks_number_of_input_segments: vec![1, 1, 3, 2, 3], expected_number_of_output_segments: 2, expected_block_number_of_new_segments: vec![1 + 1 + 3, 2 + 3], case_name, }; case.run_and_verify(&ctx, threshold, limit).await?; } { // case: rand test let case_name = "rand"; let threshold = 3; let mut rng = thread_rng(); // let rounds = 200; // use this setting at home let rounds = 20; for _ in 0..rounds { let num_segments: usize = rng.gen_range(0..10); let mut blocks_number_of_input_segments = Vec::with_capacity(num_segments); // simulate the compaction process, verifies that the test target works as expected let mut num_accumulated_blocks = 0; let mut fragmented_segments = 0; // - number of segment expected in the output of compaction, includes both the compacted // new segments and the unchanged non-fragmented segments let mut expected_number_of_output_segments = 0; // - number of new segments created during the compaction let mut expected_block_number_of_new_segments = vec![]; for _ in 0..num_segments { let block_num: usize = rng.gen_range(0..20); blocks_number_of_input_segments.push(block_num); } // traverse the input segments in reversed order (to let the compaction "right-assoc") for item in blocks_number_of_input_segments.iter().rev() { let block_num = *item; if block_num != 0 { let s = block_num + num_accumulated_blocks; if s < threshold { // input segment is fragmented, but fragments collected so far // are not enough yet. num_accumulated_blocks = s; // only in this branch, the number of fragmented_segments will increase fragmented_segments += 1; } else if s >= threshold && s < 2 * threshold { // input segment is fragmented, and fragments collected are // large enough to be compacted num_accumulated_blocks = 0; // mark that a segment will be included in the output expected_number_of_output_segments += 1; if fragmented_segments > 0 { // mark that a NEW segment will be generated, which // "contains" all the fragmented segments collected so far. expected_block_number_of_new_segments.push(s); } // reset state fragmented_segments = 0; } else { // input segment is larger than threshold // - fragmented segments collected so far should be compacted first if fragmented_segments > 0 { // some fragments left there, check them out if fragmented_segments > 1 { // if there are more than one fragments, a new segment is expected // to be generated expected_block_number_of_new_segments.push(num_accumulated_blocks); } // mark that another segment will be include in the output expected_number_of_output_segments += 1; } // - after compacting the fragments, count this large segment in expected_number_of_output_segments += 1; // no fragments left currently, reset the counters fragmented_segments = 0; num_accumulated_blocks = 0; } } } // finalize, compact left fragments if any if fragmented_segments > 0 { if fragmented_segments > 1 { // if there are more than one fragments left there, a new segment should be created expected_block_number_of_new_segments.push(num_accumulated_blocks); } // mark that another segment will be include in the output expected_number_of_output_segments += 1; } // To make the non-random test cases more readable, paths of newly created segments are // specified in the order of original(Input) order. // But during this simulated compaction, the paths are kept in reversed order, // so here we reverse the paths, to make the test verifications followed pass. expected_block_number_of_new_segments.reverse(); let case = CompactCase { blocks_number_of_input_segments, expected_number_of_output_segments, expected_block_number_of_new_segments, case_name, }; case.run_and_verify(&ctx, threshold as u64, None).await?; } } Ok(()) } pub struct CompactSegmentTestFixture { threshold: u64, ctx: Arc<dyn TableContext>, data_accessor: DataOperator, location_gen: TableMetaLocationGenerator, // blocks of input_segments, order by segment input_blocks: Vec<BlockMeta>, } impl CompactSegmentTestFixture { fn try_new(ctx: &Arc<QueryContext>, block_per_seg: u64) -> Result<Self> { let location_gen = TableMetaLocationGenerator::with_prefix("test/".to_owned()); let data_accessor = ctx.get_data_operator()?; Ok(Self { ctx: ctx.clone(), threshold: block_per_seg, data_accessor, location_gen, input_blocks: vec![], }) } async fn run<'a>( &'a mut self, num_block_of_segments: &'a [usize], limit: Option<usize>, ) -> Result<SegmentCompactionState> { let block_per_seg = self.threshold; let data_accessor = &self.data_accessor.operator(); let location_gen = &self.location_gen; let block_writer = BlockWriter::new(data_accessor, location_gen); let schema = TestFixture::default_table_schema(); let fuse_segment_io = SegmentsIO::create(self.ctx.clone(), data_accessor.clone(), schema); let max_io_requests = self.ctx.get_settings().get_max_storage_io_requests()? as usize; let segment_writer = SegmentWriter::new(data_accessor, location_gen); let seg_acc = SegmentCompactor::new( block_per_seg, max_io_requests, &fuse_segment_io, segment_writer.clone(), ); let rows_per_block = vec![1; num_block_of_segments.len()]; let (locations, blocks, _) = Self::gen_segments( &block_writer, &segment_writer, num_block_of_segments, &rows_per_block, ) .await?; self.input_blocks = blocks; let limit = limit.unwrap_or(usize::MAX); seg_acc .compact(locations, limit, |status| { self.ctx.set_status_info(&status); }) .await } pub async fn gen_segments( block_writer: &BlockWriter<'_>, segment_writer: &SegmentWriter<'_>, block_num_of_segments: &[usize], rows_per_blocks: &[usize], ) -> Result<(Vec<Location>, Vec<BlockMeta>, Vec<SegmentInfo>)> { let mut locations = vec![]; let mut collected_blocks = vec![]; let mut segment_infos = vec![]; for (num_blocks, rows_per_block) in block_num_of_segments .iter() .zip(rows_per_blocks.iter()) .rev() { let (schema, blocks) = TestFixture::gen_sample_blocks_ex(*num_blocks, *rows_per_block, 1); let mut stats_acc = StatisticsAccumulator::default(); for block in blocks { let block = block?; let col_stats = gen_columns_statistics(&block, None, &schema)?; let (block_meta, _index_meta) = block_writer .write(FuseStorageFormat::Parquet, &schema, block, col_stats, None) .await?; collected_blocks.push(block_meta.clone()); stats_acc.add_with_block_meta(block_meta); } let col_stats = stats_acc.summary()?; let segment_info = SegmentInfo::new(stats_acc.blocks_metas, Statistics { row_count: stats_acc.summary_row_count, block_count: stats_acc.summary_block_count, perfect_block_count: stats_acc.perfect_block_count, uncompressed_byte_size: stats_acc.in_memory_size, compressed_byte_size: stats_acc.file_size, index_size: stats_acc.index_size, col_stats, }); let location = segment_writer.write_segment_no_cache(&segment_info).await?; segment_infos.push(segment_info); locations.push(location); } Ok((locations, collected_blocks, segment_infos)) } // verify that newly generated segments contain the proper number of blocks pub async fn verify_new_segments( case_name: &str, new_segment_paths: &[String], expected_num_blocks: &[usize], segment_reader: &SegmentInfoReader, ) -> Result<()> { // traverse the paths of new segments in reversed order for (idx, x) in new_segment_paths.iter().rev().enumerate() { let load_params = LoadParams { location: x.to_string(), len_hint: None, ver: SegmentInfo::VERSION, put_cache: false, }; let seg = segment_reader.read(&load_params).await?; assert_eq!( seg.blocks.len(), expected_num_blocks[idx], "case name :{}, verify_block_number_of_new_segments", case_name ); } Ok(()) } } struct CompactCase { blocks_number_of_input_segments: Vec<usize>, expected_block_number_of_new_segments: Vec<usize>, // number of output segments, newly created and unchanged expected_number_of_output_segments: usize, case_name: &'static str, } impl CompactCase { async fn run_and_verify( &self, ctx: &Arc<QueryContext>, block_per_segment: u64, limit: Option<usize>, ) -> Result<()> { // setup & run let segment_reader = MetaReaders::segment_info_reader( ctx.get_data_operator()?.operator(), TestFixture::default_table_schema(), ); let mut case_fixture = CompactSegmentTestFixture::try_new(ctx, block_per_segment)?; let r = case_fixture .run(&self.blocks_number_of_input_segments, limit) .await?; // verify that: // 1. number of newly generated segment is as expected let expected_num_of_new_segments = self.expected_block_number_of_new_segments.len(); assert_eq!( r.new_segment_paths.len(), expected_num_of_new_segments, "case: {}, step: verify number of new segments generated, segment block size {:?}", self.case_name, self.blocks_number_of_input_segments, ); // 2. number of segments is as expected (including both of the segments that not changed and newly generated segments) assert_eq!( r.segments_locations.len(), self.expected_number_of_output_segments, "case: {}, step: verify number of output segments (new segments and unchanged segments)", self.case_name, ); // 3. each new segment contains expected number of blocks CompactSegmentTestFixture::verify_new_segments( self.case_name, &r.new_segment_paths, &self.expected_block_number_of_new_segments, &segment_reader, ) .await?; // invariants 4 - 6 are general rules, for all the cases. let mut idx = 0; let mut statistics_of_input_segments = Statistics::default(); let mut block_num_of_output_segments = vec![]; // 4. input blocks should be there and in the original order for location in r.segments_locations.iter().rev() { let load_params = LoadParams { location: location.0.clone(), len_hint: None, ver: location.1, put_cache: false, }; let segment = segment_reader.read(&load_params).await?; merge_statistics_mut(&mut statistics_of_input_segments, &segment.summary)?; block_num_of_output_segments.push(segment.blocks.len()); for x in &segment.blocks { let original_block_meta = &case_fixture.input_blocks[idx]; assert_eq!( original_block_meta, x.as_ref(), "case : {}, verify block order", self.case_name ); idx += 1; } } block_num_of_output_segments.reverse(); // 5. statistics should be the same assert_eq!( statistics_of_input_segments, r.statistics, "case : {}", self.case_name ); // 6. the output segments can not be compacted further, if (no limit) if limit.is_none() { let mut case_fixture = CompactSegmentTestFixture::try_new(ctx, block_per_segment)?; let r = case_fixture .run(&block_num_of_output_segments, None) .await?; assert_eq!( r.new_segment_paths.len(), 0, "case: {}, verify number of new segment", self.case_name ); let num_of_output_segments = block_num_of_output_segments.len(); assert_eq!( r.segments_locations.len(), num_of_output_segments, "case: {}, verify number of segments", self.case_name ); } Ok(()) } }
use std::path::PathBuf; use std::io::Result; use glob::glob; /// A struct that allows the user to locate a set of files based on configured options. #[derive(Debug)] pub struct Collecter<'a> { queries: &'a Vec<String>, max_depth: Option<usize>, } impl<'a> Collecter<'a> { /// Creates a new collector that can find all the files necessary for /// searching the regex against. /// /// ### Examples /// /// ``` /// use grusp_core::grusp; /// let queries = vec!["example_dir/**/*.txt".to_string()]; /// let collector = grusp::FileCollector::new(&queries); /// ``` pub fn new(queries: &'a Vec<String>) -> Self { Self { queries: &queries, max_depth: None } } /// Builds the collector to search to a specified max depth. The /// depth is optional. To search all the way use None /// /// ### Examples /// /// *Specifying max_depth* /// /// ``` /// use grusp_core::grusp; /// let queries = vec!["example_dir/".to_string()]; /// let files = grusp::FileCollector::new(&queries).max_depth(Some(0)).collect(); /// assert_eq!(files.len(), 2) /// ``` /// /// *Specifying no max_depth* /// /// ``` /// use grusp_core::grusp; /// let queries = vec!["example_dir/".to_string()]; /// let files = grusp::FileCollector::new(&queries).max_depth(None).collect(); /// assert_eq!(files.len(), 4) /// ``` pub fn max_depth(mut self, max_depth: Option<usize>) -> Self { self.max_depth = max_depth; self } /// Consumes the collector and returns a set of paths that it finds while /// searching recursively through the glob queries. /// /// ### Examples /// /// ``` /// use grusp_core::grusp; /// let queries = vec!["example_dir/**/*.txt".to_string()]; /// let files = grusp::FileCollector::new(&queries).collect(); /// assert_eq!(files.len(), 5) /// ``` pub fn collect(self) -> Vec<PathBuf> { let mut files = Vec::new(); for query in self.queries { glob(&query) .expect("Glob pattern failed") .filter_map(|p| p.ok()) .for_each(|p| { self.recurse(p, &mut files, 0).expect("Unknown file error") }); } files } fn recurse(&self, path: PathBuf, files: &mut Vec<PathBuf>, depth: usize) -> Result<()> { if Self::is_hidden(&path) { return Ok(()) } if path.is_dir() { if let Some(max_depth) = self.max_depth { if max_depth < depth { return Ok(()); }; } let entries = path.read_dir()?; for entry in entries { self.recurse(entry?.path(), files, depth + 1)? } } else { files.push(path.to_owned()); } Ok(()) } fn is_hidden(path: &PathBuf) -> bool { if let Some(file_name) = path.file_name().and_then(|f| f.to_str()) { file_name.starts_with(".") } else { false } } } #[cfg(test)] mod tests { use std::path::Path; use super::*; #[test] fn it_globs_down_a_directory() { let queries = vec!["./example_dir/**/*.txt".to_string()]; let files = Collecter::new(&queries).collect(); assert_eq!(files.len(), 5); assert!(files.contains( &Path::new("example_dir/sub_dir/sub-example-1.txt").to_owned(), )); } #[test] fn it_finds_files_inside_directory_if_path_is_dir() { let query = vec!["./example_dir/sub_dir".to_string()]; let files = Collecter::new(&query).collect(); assert_eq!(files.len(), 2); assert!(files.contains( &Path::new("example_dir/sub_dir/sub-example-1.txt").to_owned(), )); assert!(!files.contains( &Path::new("example_dir/example-1.txt").to_owned(), )); } #[test] fn it_finds_files_inside_sub_directories() { let query = vec!["./example_dir".to_string()]; let files = Collecter::new(&query).collect(); assert_eq!(files.len(), 4); assert!(files.contains( &Path::new("example_dir/sub_dir/sub-example-1.txt").to_owned(), )); assert!(files.contains( &Path::new("example_dir/example-1.txt").to_owned(), )); } #[test] fn it_returns_current_file_if_a_file_is_passed_in() { let query = vec!["./example_dir/example-1.txt".to_string()]; let files = Collecter::new(&query).collect(); assert_eq!(files.len(), 1); let path = Path::new("example_dir/example-1.txt"); assert_eq!(files, &[path]); } #[test] fn it_can_restrict_the_depth() { let query = vec!["./example_dir".to_string()]; let files = Collecter::new(&query).max_depth(Some(0)).collect(); assert_eq!(files.len(), 2); assert!(!files.contains( &Path::new("example_dir/sub_dir/sub-example-1.txt").to_owned(), )); assert!(files.contains( &Path::new("example_dir/example-1.txt").to_owned(), )); } #[test] fn it_ignores_hidden_files() { let query = vec!["./example_dir".to_string()]; let files = Collecter::new(&query).collect(); assert_eq!(files.len(), 4); assert!(!files.contains(&Path::new("example_dir/.hidden.txt").to_owned())); } #[test] fn it_ignores_hidden_directories() { let query = vec!["./example_dir".to_string()]; let files = Collecter::new(&query).collect(); assert_eq!(files.len(), 4); assert!(!files.contains(&Path::new("example_dir/.hidden.txt").to_owned())); } #[test] fn can_determine_whether_a_path_is_hidden() { assert!(!Collecter::is_hidden(&Path::new(".").to_path_buf())); assert!(!Collecter::is_hidden(&Path::new("example_dir").to_path_buf())); assert!(Collecter::is_hidden(&Path::new("example_dir/.hiiden").to_path_buf())); } }
pub mod common; use common::server_fixture::ServerFixture; type Result<T = (), E = Box<dyn std::error::Error>> = std::result::Result<T, E>; #[tokio::test] async fn new_server_needs_onboarded() -> Result { let server_fixture = maybe_skip_integration!(ServerFixture::create_single_use()).await; let client = server_fixture.client(); let res = client.is_onboarding_allowed().await?; assert!(res); // Creating a new setup user without first onboarding is an error let username = "some-user"; let org = "some-org"; let bucket = "some-bucket"; let password = "some-password"; let retention_period_hrs = 0; let err = client .post_setup_user( username, org, bucket, Some(password.to_string()), Some(retention_period_hrs), None, ) .await .expect_err("Expected error, got success"); assert!(matches!( err, influxdb2_client::RequestError::Http { status: reqwest::StatusCode::UNAUTHORIZED, .. } )); Ok(()) } #[tokio::test] async fn onboarding() -> Result { let server_fixture = maybe_skip_integration!(ServerFixture::create_single_use()).await; let client = server_fixture.client(); let username = "some-user"; let org = "some-org"; let bucket = "some-bucket"; let password = "some-password"; let retention_period_hrs = 0; client .onboarding( username, org, bucket, Some(password.to_string()), Some(retention_period_hrs), None, ) .await?; let res = client.is_onboarding_allowed().await?; assert!(!res); // Onboarding twice is an error let err = client .onboarding( username, org, bucket, Some(password.to_string()), Some(retention_period_hrs), None, ) .await .expect_err("Expected error, got success"); assert!(matches!( err, influxdb2_client::RequestError::Http { status: reqwest::StatusCode::UNPROCESSABLE_ENTITY, .. } )); Ok(()) } #[tokio::test] async fn create_users() -> Result { // Using a server that has been set up let server_fixture = maybe_skip_integration!(ServerFixture::create_shared()).await; let client = server_fixture.client(); let username = "another-user"; let org = "another-org"; let bucket = "another-bucket"; let password = "another-password"; let retention_period_hrs = 0; // Creating a user should work client .post_setup_user( username, org, bucket, Some(password.to_string()), Some(retention_period_hrs), None, ) .await?; Ok(()) }
use std; use std::io::Read; use flate2; use byteorder::ReadBytesExt; use ::{protocol, Error, Result, Rect}; struct ZlibReader<'a> { decompressor: flate2::Decompress, input: &'a [u8] } impl<'a> ZlibReader<'a> { fn new(decompressor: flate2::Decompress, input: &'a [u8]) -> ZlibReader<'a> { ZlibReader { decompressor: decompressor, input: input } } fn into_inner(self) -> Result<flate2::Decompress> { if self.input.len() == 0 { Ok(self.decompressor) } else { Err(Error::Unexpected("leftover ZRLE byte data")) } } } impl<'a> Read for ZlibReader<'a> { fn read(&mut self, output: &mut [u8]) -> std::io::Result<usize> { let in_before = self.decompressor.total_in(); let out_before = self.decompressor.total_out(); let result = self.decompressor.decompress(self.input, output, flate2::Flush::None); let consumed = (self.decompressor.total_in() - in_before) as usize; let produced = (self.decompressor.total_out() - out_before) as usize; self.input = &self.input[consumed..]; match result { Ok(flate2::Status::Ok) => Ok(produced), Ok(flate2::Status::BufError) => Ok(0), Err(error) => Err(std::io::Error::new(std::io::ErrorKind::InvalidData, error)), Ok(flate2::Status::StreamEnd) => Err(std::io::Error::new(std::io::ErrorKind::InvalidData, "ZRLE stream end")) } } } struct BitReader<T: Read> { reader: T, buffer: u8, position: usize } impl<T: Read> BitReader<T> { fn new(reader: T) -> BitReader<T> { BitReader { reader: reader, buffer: 0, position: 8 } } fn into_inner(self) -> Result<T> { if self.position == 8 { Ok(self.reader) } else { Err(Error::Unexpected("leftover ZRLE bit data")) } } fn read_bits(&mut self, count: usize) -> std::io::Result<u8> { assert!(count > 0 && count <= 8); if self.position == 8 { self.buffer = try!(self.reader.read_u8()); self.position = 0; } if self.position + count <= 8 { let shift = 8 - (count + self.position); let mask = (1 << count) - 1; let result = (self.buffer >> shift) & mask; self.position += count; Ok(result) } else { Err(std::io::Error::new(std::io::ErrorKind::InvalidData, "unaligned ZRLE bit read")) } } fn read_bit(&mut self) -> std::io::Result<bool> { Ok(try!(self.read_bits(1)) != 0) } fn align(&mut self) { self.position = 8; } } impl<T: Read> Read for BitReader<T> { fn read(&mut self, buf: &mut [u8]) -> std::io::Result<usize> { if self.position == 8 { self.reader.read(buf) } else { Err(std::io::Error::new(std::io::ErrorKind::InvalidData, "unaligned ZRLE byte read")) } } } pub struct Decoder { decompressor: Option<flate2::Decompress> } impl Decoder { pub fn new() -> Decoder { Decoder { decompressor: Some(flate2::Decompress::new(/*zlib_header*/true)) } } pub fn decode<F>(&mut self, format: protocol::PixelFormat, rect: Rect, input: &[u8], mut callback: F) -> Result<bool> where F: FnMut(Rect, Vec<u8>) -> Result<bool> { fn read_run_length(reader: &mut Read) -> Result<usize> { let mut run_length_part = try!(reader.read_u8()); let mut run_length = 1 + run_length_part as usize; while run_length_part == 255 { run_length_part = try!(reader.read_u8()); run_length += run_length_part as usize; } Ok(run_length) } fn copy_true_color(reader: &mut Read, pixels: &mut Vec<u8>, pad: bool, compressed_bpp: usize, bpp: usize) -> Result<()> { let mut buf = [0; 4]; try!(reader.read_exact(&mut buf[pad as usize..pad as usize + compressed_bpp])); pixels.extend_from_slice(&buf[..bpp]); Ok(()) } fn copy_indexed(palette: &[u8], pixels: &mut Vec<u8>, bpp: usize, index: u8) { let start = index as usize * bpp; pixels.extend_from_slice(&palette[start..start + bpp]) } let bpp = format.bits_per_pixel as usize / 8; let pixel_mask = (format.red_max as u32) << format.red_shift | (format.green_max as u32) << format.green_shift | (format.blue_max as u32) << format.blue_shift; let (compressed_bpp, pad_pixel) = if format.bits_per_pixel == 32 && format.true_colour == true && format.depth <= 24 { if pixel_mask & 0x000000ff == 0 { (3, !format.big_endian) } else if pixel_mask & 0xff000000 == 0 { (3, format.big_endian) } else { (4, false) } } else { (bpp, false) }; let mut palette = Vec::with_capacity(128 * bpp); let mut reader = BitReader::new(ZlibReader::new(self.decompressor.take().unwrap(), input)); let mut y = 0; while y < rect.height { let height = if y + 64 > rect.height { rect.height - y } else { 64 }; let mut x = 0; while x < rect.width { let width = if x + 64 > rect.width { rect.width - x } else { 64 }; let pixel_count = height as usize * width as usize; let is_rle = try!(reader.read_bit()); let palette_size = try!(reader.read_bits(7)); palette.truncate(0); for _ in 0..palette_size { try!(copy_true_color(&mut reader, &mut palette, pad_pixel, compressed_bpp, bpp)) } let mut pixels = Vec::with_capacity(pixel_count * bpp); match (is_rle, palette_size) { (false, 0) => { // True Color pixels for _ in 0..pixel_count { try!(copy_true_color(&mut reader, &mut pixels, pad_pixel, compressed_bpp, bpp)) } }, (false, 1) => { // Color fill for _ in 0..pixel_count { copy_indexed(&palette, &mut pixels, bpp, 0) } }, (false, 2) | (false, 3...4) | (false, 5...16) => { // Indexed pixels let bits_per_index = match palette_size { 2 => 1, 3...4 => 2, 5...16 => 4, _ => unreachable!() }; for _ in 0..height { for _ in 0..width { let index = try!(reader.read_bits(bits_per_index)); copy_indexed(&palette, &mut pixels, bpp, index) } reader.align(); } }, (true, 0) => { // True Color RLE let mut count = 0; let mut pixel = Vec::new(); while count < pixel_count { pixel.truncate(0); try!(copy_true_color(&mut reader, &mut pixel, pad_pixel, compressed_bpp, bpp)); let run_length = try!(read_run_length(&mut reader)); for _ in 0..run_length { pixels.extend(&pixel) } count += run_length; } }, (true, 2...127) => { // Indexed RLE let mut count = 0; while count < pixel_count { let longer_than_one = try!(reader.read_bit()); let index = try!(reader.read_bits(7)); let run_length = if longer_than_one { try!(read_run_length(&mut reader)) } else { 1 }; for _ in 0..run_length { copy_indexed(&palette, &mut pixels, bpp, index); } count += run_length; } }, _ => return Err(Error::Unexpected("ZRLE subencoding")) } let tile = Rect { top: rect.top + y, left: rect.left + x, width: width, height: height }; if let false = try!(callback(tile, pixels)) { return Ok(false) } x += width; } y += height; } self.decompressor = Some(try!(try!(reader.into_inner()).into_inner())); Ok(true) } }
#[doc = "Reader of register MACL3L4C0R"] pub type R = crate::R<u32, super::MACL3L4C0R>; #[doc = "Writer for register MACL3L4C0R"] pub type W = crate::W<u32, super::MACL3L4C0R>; #[doc = "Register MACL3L4C0R `reset()`'s with value 0"] impl crate::ResetValue for super::MACL3L4C0R { type Type = u32; #[inline(always)] fn reset_value() -> Self::Type { 0 } } #[doc = "Reader of field `L3PEN0`"] pub type L3PEN0_R = crate::R<bool, bool>; #[doc = "Write proxy for field `L3PEN0`"] pub struct L3PEN0_W<'a> { w: &'a mut W, } impl<'a> L3PEN0_W<'a> { #[doc = r"Sets the field bit"] #[inline(always)] pub fn set_bit(self) -> &'a mut W { self.bit(true) } #[doc = r"Clears the field bit"] #[inline(always)] pub fn clear_bit(self) -> &'a mut W { self.bit(false) } #[doc = r"Writes raw bits to the field"] #[inline(always)] pub fn bit(self, value: bool) -> &'a mut W { self.w.bits = (self.w.bits & !0x01) | ((value as u32) & 0x01); self.w } } #[doc = "Reader of field `L3SAM0`"] pub type L3SAM0_R = crate::R<bool, bool>; #[doc = "Write proxy for field `L3SAM0`"] pub struct L3SAM0_W<'a> { w: &'a mut W, } impl<'a> L3SAM0_W<'a> { #[doc = r"Sets the field bit"] #[inline(always)] pub fn set_bit(self) -> &'a mut W { self.bit(true) } #[doc = r"Clears the field bit"] #[inline(always)] pub fn clear_bit(self) -> &'a mut W { self.bit(false) } #[doc = r"Writes raw bits to the field"] #[inline(always)] pub fn bit(self, value: bool) -> &'a mut W { self.w.bits = (self.w.bits & !(0x01 << 2)) | (((value as u32) & 0x01) << 2); self.w } } #[doc = "Reader of field `L3SAIM0`"] pub type L3SAIM0_R = crate::R<bool, bool>; #[doc = "Write proxy for field `L3SAIM0`"] pub struct L3SAIM0_W<'a> { w: &'a mut W, } impl<'a> L3SAIM0_W<'a> { #[doc = r"Sets the field bit"] #[inline(always)] pub fn set_bit(self) -> &'a mut W { self.bit(true) } #[doc = r"Clears the field bit"] #[inline(always)] pub fn clear_bit(self) -> &'a mut W { self.bit(false) } #[doc = r"Writes raw bits to the field"] #[inline(always)] pub fn bit(self, value: bool) -> &'a mut W { self.w.bits = (self.w.bits & !(0x01 << 3)) | (((value as u32) & 0x01) << 3); self.w } } #[doc = "Reader of field `L3DAM0`"] pub type L3DAM0_R = crate::R<bool, bool>; #[doc = "Write proxy for field `L3DAM0`"] pub struct L3DAM0_W<'a> { w: &'a mut W, } impl<'a> L3DAM0_W<'a> { #[doc = r"Sets the field bit"] #[inline(always)] pub fn set_bit(self) -> &'a mut W { self.bit(true) } #[doc = r"Clears the field bit"] #[inline(always)] pub fn clear_bit(self) -> &'a mut W { self.bit(false) } #[doc = r"Writes raw bits to the field"] #[inline(always)] pub fn bit(self, value: bool) -> &'a mut W { self.w.bits = (self.w.bits & !(0x01 << 4)) | (((value as u32) & 0x01) << 4); self.w } } #[doc = "Reader of field `L3DAIM0`"] pub type L3DAIM0_R = crate::R<bool, bool>; #[doc = "Write proxy for field `L3DAIM0`"] pub struct L3DAIM0_W<'a> { w: &'a mut W, } impl<'a> L3DAIM0_W<'a> { #[doc = r"Sets the field bit"] #[inline(always)] pub fn set_bit(self) -> &'a mut W { self.bit(true) } #[doc = r"Clears the field bit"] #[inline(always)] pub fn clear_bit(self) -> &'a mut W { self.bit(false) } #[doc = r"Writes raw bits to the field"] #[inline(always)] pub fn bit(self, value: bool) -> &'a mut W { self.w.bits = (self.w.bits & !(0x01 << 5)) | (((value as u32) & 0x01) << 5); self.w } } #[doc = "Reader of field `L3HSBM0`"] pub type L3HSBM0_R = crate::R<u8, u8>; #[doc = "Write proxy for field `L3HSBM0`"] pub struct L3HSBM0_W<'a> { w: &'a mut W, } impl<'a> L3HSBM0_W<'a> { #[doc = r"Writes raw bits to the field"] #[inline(always)] pub unsafe fn bits(self, value: u8) -> &'a mut W { self.w.bits = (self.w.bits & !(0x1f << 6)) | (((value as u32) & 0x1f) << 6); self.w } } #[doc = "Reader of field `L3HDBM0`"] pub type L3HDBM0_R = crate::R<u8, u8>; #[doc = "Write proxy for field `L3HDBM0`"] pub struct L3HDBM0_W<'a> { w: &'a mut W, } impl<'a> L3HDBM0_W<'a> { #[doc = r"Writes raw bits to the field"] #[inline(always)] pub unsafe fn bits(self, value: u8) -> &'a mut W { self.w.bits = (self.w.bits & !(0x1f << 11)) | (((value as u32) & 0x1f) << 11); self.w } } #[doc = "Reader of field `L4PEN0`"] pub type L4PEN0_R = crate::R<bool, bool>; #[doc = "Write proxy for field `L4PEN0`"] pub struct L4PEN0_W<'a> { w: &'a mut W, } impl<'a> L4PEN0_W<'a> { #[doc = r"Sets the field bit"] #[inline(always)] pub fn set_bit(self) -> &'a mut W { self.bit(true) } #[doc = r"Clears the field bit"] #[inline(always)] pub fn clear_bit(self) -> &'a mut W { self.bit(false) } #[doc = r"Writes raw bits to the field"] #[inline(always)] pub fn bit(self, value: bool) -> &'a mut W { self.w.bits = (self.w.bits & !(0x01 << 16)) | (((value as u32) & 0x01) << 16); self.w } } #[doc = "Reader of field `L4SPM0`"] pub type L4SPM0_R = crate::R<bool, bool>; #[doc = "Write proxy for field `L4SPM0`"] pub struct L4SPM0_W<'a> { w: &'a mut W, } impl<'a> L4SPM0_W<'a> { #[doc = r"Sets the field bit"] #[inline(always)] pub fn set_bit(self) -> &'a mut W { self.bit(true) } #[doc = r"Clears the field bit"] #[inline(always)] pub fn clear_bit(self) -> &'a mut W { self.bit(false) } #[doc = r"Writes raw bits to the field"] #[inline(always)] pub fn bit(self, value: bool) -> &'a mut W { self.w.bits = (self.w.bits & !(0x01 << 18)) | (((value as u32) & 0x01) << 18); self.w } } #[doc = "Reader of field `L4SPIM0`"] pub type L4SPIM0_R = crate::R<bool, bool>; #[doc = "Write proxy for field `L4SPIM0`"] pub struct L4SPIM0_W<'a> { w: &'a mut W, } impl<'a> L4SPIM0_W<'a> { #[doc = r"Sets the field bit"] #[inline(always)] pub fn set_bit(self) -> &'a mut W { self.bit(true) } #[doc = r"Clears the field bit"] #[inline(always)] pub fn clear_bit(self) -> &'a mut W { self.bit(false) } #[doc = r"Writes raw bits to the field"] #[inline(always)] pub fn bit(self, value: bool) -> &'a mut W { self.w.bits = (self.w.bits & !(0x01 << 19)) | (((value as u32) & 0x01) << 19); self.w } } #[doc = "Reader of field `L4DPM0`"] pub type L4DPM0_R = crate::R<bool, bool>; #[doc = "Write proxy for field `L4DPM0`"] pub struct L4DPM0_W<'a> { w: &'a mut W, } impl<'a> L4DPM0_W<'a> { #[doc = r"Sets the field bit"] #[inline(always)] pub fn set_bit(self) -> &'a mut W { self.bit(true) } #[doc = r"Clears the field bit"] #[inline(always)] pub fn clear_bit(self) -> &'a mut W { self.bit(false) } #[doc = r"Writes raw bits to the field"] #[inline(always)] pub fn bit(self, value: bool) -> &'a mut W { self.w.bits = (self.w.bits & !(0x01 << 20)) | (((value as u32) & 0x01) << 20); self.w } } #[doc = "Reader of field `L4DPIM0`"] pub type L4DPIM0_R = crate::R<bool, bool>; #[doc = "Write proxy for field `L4DPIM0`"] pub struct L4DPIM0_W<'a> { w: &'a mut W, } impl<'a> L4DPIM0_W<'a> { #[doc = r"Sets the field bit"] #[inline(always)] pub fn set_bit(self) -> &'a mut W { self.bit(true) } #[doc = r"Clears the field bit"] #[inline(always)] pub fn clear_bit(self) -> &'a mut W { self.bit(false) } #[doc = r"Writes raw bits to the field"] #[inline(always)] pub fn bit(self, value: bool) -> &'a mut W { self.w.bits = (self.w.bits & !(0x01 << 21)) | (((value as u32) & 0x01) << 21); self.w } } impl R { #[doc = "Bit 0 - Layer 3 Protocol Enable"] #[inline(always)] pub fn l3pen0(&self) -> L3PEN0_R { L3PEN0_R::new((self.bits & 0x01) != 0) } #[doc = "Bit 2 - Layer 3 IP SA Match Enable"] #[inline(always)] pub fn l3sam0(&self) -> L3SAM0_R { L3SAM0_R::new(((self.bits >> 2) & 0x01) != 0) } #[doc = "Bit 3 - Layer 3 IP SA Inverse Match Enable"] #[inline(always)] pub fn l3saim0(&self) -> L3SAIM0_R { L3SAIM0_R::new(((self.bits >> 3) & 0x01) != 0) } #[doc = "Bit 4 - Layer 3 IP DA Match Enable"] #[inline(always)] pub fn l3dam0(&self) -> L3DAM0_R { L3DAM0_R::new(((self.bits >> 4) & 0x01) != 0) } #[doc = "Bit 5 - Layer 3 IP DA Inverse Match Enable"] #[inline(always)] pub fn l3daim0(&self) -> L3DAIM0_R { L3DAIM0_R::new(((self.bits >> 5) & 0x01) != 0) } #[doc = "Bits 6:10 - Layer 3 IP SA Higher Bits Match"] #[inline(always)] pub fn l3hsbm0(&self) -> L3HSBM0_R { L3HSBM0_R::new(((self.bits >> 6) & 0x1f) as u8) } #[doc = "Bits 11:15 - Layer 3 IP DA Higher Bits Match"] #[inline(always)] pub fn l3hdbm0(&self) -> L3HDBM0_R { L3HDBM0_R::new(((self.bits >> 11) & 0x1f) as u8) } #[doc = "Bit 16 - Layer 4 Protocol Enable"] #[inline(always)] pub fn l4pen0(&self) -> L4PEN0_R { L4PEN0_R::new(((self.bits >> 16) & 0x01) != 0) } #[doc = "Bit 18 - Layer 4 Source Port Match Enable"] #[inline(always)] pub fn l4spm0(&self) -> L4SPM0_R { L4SPM0_R::new(((self.bits >> 18) & 0x01) != 0) } #[doc = "Bit 19 - Layer 4 Source Port Inverse Match Enable"] #[inline(always)] pub fn l4spim0(&self) -> L4SPIM0_R { L4SPIM0_R::new(((self.bits >> 19) & 0x01) != 0) } #[doc = "Bit 20 - Layer 4 Destination Port Match Enable"] #[inline(always)] pub fn l4dpm0(&self) -> L4DPM0_R { L4DPM0_R::new(((self.bits >> 20) & 0x01) != 0) } #[doc = "Bit 21 - Layer 4 Destination Port Inverse Match Enable"] #[inline(always)] pub fn l4dpim0(&self) -> L4DPIM0_R { L4DPIM0_R::new(((self.bits >> 21) & 0x01) != 0) } } impl W { #[doc = "Bit 0 - Layer 3 Protocol Enable"] #[inline(always)] pub fn l3pen0(&mut self) -> L3PEN0_W { L3PEN0_W { w: self } } #[doc = "Bit 2 - Layer 3 IP SA Match Enable"] #[inline(always)] pub fn l3sam0(&mut self) -> L3SAM0_W { L3SAM0_W { w: self } } #[doc = "Bit 3 - Layer 3 IP SA Inverse Match Enable"] #[inline(always)] pub fn l3saim0(&mut self) -> L3SAIM0_W { L3SAIM0_W { w: self } } #[doc = "Bit 4 - Layer 3 IP DA Match Enable"] #[inline(always)] pub fn l3dam0(&mut self) -> L3DAM0_W { L3DAM0_W { w: self } } #[doc = "Bit 5 - Layer 3 IP DA Inverse Match Enable"] #[inline(always)] pub fn l3daim0(&mut self) -> L3DAIM0_W { L3DAIM0_W { w: self } } #[doc = "Bits 6:10 - Layer 3 IP SA Higher Bits Match"] #[inline(always)] pub fn l3hsbm0(&mut self) -> L3HSBM0_W { L3HSBM0_W { w: self } } #[doc = "Bits 11:15 - Layer 3 IP DA Higher Bits Match"] #[inline(always)] pub fn l3hdbm0(&mut self) -> L3HDBM0_W { L3HDBM0_W { w: self } } #[doc = "Bit 16 - Layer 4 Protocol Enable"] #[inline(always)] pub fn l4pen0(&mut self) -> L4PEN0_W { L4PEN0_W { w: self } } #[doc = "Bit 18 - Layer 4 Source Port Match Enable"] #[inline(always)] pub fn l4spm0(&mut self) -> L4SPM0_W { L4SPM0_W { w: self } } #[doc = "Bit 19 - Layer 4 Source Port Inverse Match Enable"] #[inline(always)] pub fn l4spim0(&mut self) -> L4SPIM0_W { L4SPIM0_W { w: self } } #[doc = "Bit 20 - Layer 4 Destination Port Match Enable"] #[inline(always)] pub fn l4dpm0(&mut self) -> L4DPM0_W { L4DPM0_W { w: self } } #[doc = "Bit 21 - Layer 4 Destination Port Inverse Match Enable"] #[inline(always)] pub fn l4dpim0(&mut self) -> L4DPIM0_W { L4DPIM0_W { w: self } } }
use std::io; fn day13a() { let mut line = String::new(); io::stdin().read_line(&mut line).unwrap(); let arrival_time = line.trim().parse::<u64>().unwrap(); line.clear(); io::stdin().read_line(&mut line).unwrap(); let bus_ids: Vec<_> = line .trim() .split(',') .filter(|id| *id != "x") .map(|id| id.parse::<u64>().unwrap()) .collect(); let remainders: Vec<_> = bus_ids.iter().map(|id| id - (arrival_time % id)).collect(); let a = remainders .iter() .enumerate() .min_by_key(|(_, x)| *x) .unwrap(); let bus_id = bus_ids[a.0] as u64; let remainder = a.1; println!( "bus: {}, waiting time: {}, ans: {}", bus_id, remainder, (bus_id as u64) * remainder ); } fn extended_euclidean(a: &i128, b: &i128) -> (i128, i128) { // return quotients (s, t) such that s*a + t*b = gcd(a, b) if a < b { let (s, t) = extended_euclidean(b, a); return (t, s); } assert_eq!(a >= b, true); let mut r0 = *a; let mut r1 = *b; let mut s0 = 1; let mut s1 = 0; let mut t0 = 0; let mut t1 = 1; while r1 != 0 { let q = r0 / r1; let r = r0 % r1; let s = s0 - q * s1; let t = t0 - q * t1; r0 = r1; s0 = s1; t0 = t1; r1 = r; s1 = s; t1 = t; } (s0, t0) } fn day13b() { let mut buf = String::new(); io::stdin().read_line(&mut buf).unwrap(); buf.clear(); io::stdin().read_line(&mut buf).unwrap(); let bus_ids: Vec<_> = buf .trim() .split(',') .enumerate() .filter(|(_, id)| *id != "x") .map(|(t, id)| { let bus_id = id.parse::<i128>().unwrap(); ((bus_id - (t as i128)).rem_euclid(bus_id), bus_id) }) .collect(); if bus_ids.len() == 1 { // Only one bus, so the earliest time is its ID. println!("Ans: {}", bus_ids[0].1); return; } // Chinese remainder theorem // use the construction as shown on the Wikipedia page. let (a, b) = (bus_ids[0].0, bus_ids[1].0); let (s, t) = extended_euclidean(&bus_ids[0].1, &bus_ids[1].1); let mut x = b * s * bus_ids[0].1 + a * t * bus_ids[1].1; let mut prod = bus_ids[0].1 * bus_ids[1].1; x = x.rem_euclid(prod); println!("s: {}, t: {}, {} {}", s, t, x, prod); for (remainder, bus_id) in bus_ids[2..].iter() { let (s, t) = extended_euclidean(&prod, bus_id); x = remainder * s * prod + (x % prod) * t * bus_id; prod *= bus_id; x = x.rem_euclid(prod); println!("s: {}, t: {}, {} {} {}", s, t, bus_id, x, prod); } println!("{} {}", x, prod); } pub fn day13(part_a: bool) { if part_a { day13a() } else { day13b() } }
use crate::virtual_filesystem_core::graph::{NodePointer, Graph}; use crate::virtual_filesystem_core::filesystem::{FileNode, FileNodePointer, FileType, FileObject, Name, Data}; pub fn ls(directory: &FileNodePointer) -> String { let nodes = &directory.borrow().1; let mut iter = nodes.iter(); let _ = iter.next(); iter.map(|x| x.borrow().0.name().to_string()).collect::<Vec<String>>().join("\t") } pub fn pwd(current: &FileNodePointer) -> String { let mut stack: Vec<String> = Vec::new(); let mut position = current.clone(); loop { if let Some(parent) = position.clone().borrow().1.iter().next() { stack.push(position.borrow().0.name().to_string()); if NodePointer::ptr_eq(parent, &position) { break } position = parent.clone(); } else { break } } if stack.len() == 1 { stack.push("".to_string()) } stack.reverse(); stack.join("/") } pub fn mkdir(directory: &FileNodePointer, name: Name) { directory.borrow_mut().connect( FileNode::create_directory(name, vec![directory.clone()]).to_pointer() ); } pub fn touch(directory: &FileNodePointer, name: Name, data: Data) { directory.borrow_mut().connect( FileNode::create_file(name, data, vec![directory.clone()]).to_pointer() ); } pub fn write(file: &FileNodePointer, input: &str) -> Result<(), ()> { let n = &mut file.borrow_mut().0; match n { FileType::File{ name: _, data } => { *data = data.to_string() + &input; Ok(()) }, _ => { Err(()) } } } pub fn read(file: &FileNodePointer) -> Result<Data, ()> { let n = &file.borrow().0; match n { FileType::File{ name: _, data } => { Ok(data.to_string()) }, _ => { Err(()) } } } pub fn find(directory: &FileNodePointer, target: &str) -> Result<NodePointer<FileType>, ()> { let edges = &directory.borrow().1; for e in edges { let s = e.borrow() .0 .name() .to_string(); if s == target { return Ok(NodePointer::clone(e)); } } Err(()) } #[cfg(test)] mod tests { use crate::virtual_filesystem_core::graph::{Graph, Edge}; use crate::virtual_filesystem_core::filesystem::{FileNode, FileObject}; use crate::virtual_filesystem::command::{ls, pwd, mkdir, touch, write, read, find}; #[test] fn test_command() { let root = &FileNode::create_directory("".to_string(), Edge::new()).to_pointer(); let current = &root.clone(); root.borrow_mut().connect(current.clone()); mkdir(current, "home".to_string()); mkdir(current, "root".to_string()); touch(current, "file1".to_string(), "file1 test".to_string()); assert_eq!(ls(current), "home\troot\tfile1"); if let Ok(pointer) = find(current, "file1") { { let node = &pointer.borrow(); let file = &node.0; let name = file.name(); let data = read(&pointer); assert_eq!(name, "file1"); assert_eq!(data, Ok("file1 test".to_string())); } { assert_eq!(write(&pointer, "\nadd writing"), Ok(())); let node = &pointer.borrow(); let file = &node.0; let name = file.name(); let data = read(&pointer); assert_eq!(name, "file1"); assert_eq!(data, Ok("file1 test\nadd writing".to_string())); } } else { assert!(false) } assert_eq!(pwd(current), "/".to_string()); if let Ok(home) = find(current, "home") { assert_eq!(pwd(&home), "/home".to_string()) } else { assert!(false) } } }
use juniper::GraphQLObject; #[derive(GraphQLObject)] struct Object { __test: String, } fn main() {}
// Copyright 2022 Datafuse Labs. // // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at // // http://www.apache.org/licenses/LICENSE-2.0 // // Unless required by applicable law or agreed to in writing, software // distributed under the License is distributed on an "AS IS" BASIS, // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. // See the License for the specific language governing permissions and // limitations under the License. use std::collections::HashMap; use std::sync::Arc; use common_config::DATABEND_COMMIT_VERSION; use common_expression::types::StringType; use common_expression::utils::FromData; use common_expression::DataBlock; use common_expression::DataSchema; use common_expression::DataSchemaRef; use common_expression::TableDataType; use common_expression::TableField; use common_expression::TableSchemaRef; use common_expression::TableSchemaRefExt; use ctor::ctor; use regex::Regex; use crate::servers::federated_helper::FederatedHelper; use crate::servers::federated_helper::LazyBlockFunc; use crate::servers::mysql::MYSQL_VERSION; #[allow(dead_code)] pub struct MySQLFederated { mysql_version: String, databend_version: String, } impl MySQLFederated { pub fn create() -> Self { MySQLFederated { mysql_version: MYSQL_VERSION.to_string(), databend_version: DATABEND_COMMIT_VERSION.to_string(), } } // Build block for select @@variable. // Format: // |@@variable| // |value| #[allow(dead_code)] fn select_variable_block(name: &str, value: &str) -> Option<(TableSchemaRef, DataBlock)> { let schema = TableSchemaRefExt::create(vec![TableField::new( &format!("@@{}", name), TableDataType::String, )]); let block = DataBlock::new_from_columns(vec![StringType::from_data(vec![ value.as_bytes().to_vec(), ])]); Some((schema, block)) } // Build block for select function. // Format: // |function_name| // |value| fn select_function_block(name: &str, value: &str) -> Option<(TableSchemaRef, DataBlock)> { let schema = TableSchemaRefExt::create(vec![TableField::new(name, TableDataType::String)]); let block = DataBlock::new_from_columns(vec![StringType::from_data(vec![ value.as_bytes().to_vec(), ])]); Some((schema, block)) } // Build block for show variable statement. // Format is: // |variable_name| Value| // | xx | yy | fn show_variables_block(name: &str, value: &str) -> Option<(TableSchemaRef, DataBlock)> { let schema = TableSchemaRefExt::create(vec![ TableField::new("Variable_name", TableDataType::String), TableField::new("Value", TableDataType::String), ]); let block = DataBlock::new_from_columns(vec![ StringType::from_data(vec![name.as_bytes().to_vec()]), StringType::from_data(vec![value.as_bytes().to_vec()]), ]); Some((schema, block)) } // SELECT @@aa, @@bb as cc, @dd... // Block is built by the variables. fn select_variable_data_block(query: &str) -> Option<(TableSchemaRef, DataBlock)> { let mut default_map = HashMap::new(); // DBeaver. default_map.insert("tx_isolation", "REPEATABLE-READ"); default_map.insert("session.tx_isolation", "REPEATABLE-READ"); default_map.insert("transaction_isolation", "REPEATABLE-READ"); default_map.insert("session.transaction_isolation", "REPEATABLE-READ"); default_map.insert("session.transaction_read_only", "0"); default_map.insert("time_zone", "UTC"); default_map.insert("system_time_zone", "UTC"); // 128M default_map.insert("max_allowed_packet", "134217728"); default_map.insert("interactive_timeout", "31536000"); default_map.insert("wait_timeout", "31536000"); default_map.insert("net_write_timeout", "31536000"); let mut fields = vec![]; let mut values = vec![]; let query = query.to_lowercase(); // select @@aa, @@bb, @@cc as yy, @@dd let mut vars: Vec<&str> = query.split("@@").collect(); if vars.len() > 1 { vars.remove(0); for var in vars { let var = var.trim_end_matches(|c| c == ' ' || c == ','); let vars_as: Vec<&str> = var.split(" as ").collect(); if vars_as.len() == 2 { // @@cc as yy: // var_as is 'yy' as the field name. let var_as = vars_as[1]; fields.push(TableField::new(var_as, TableDataType::String)); // var is 'cc'. let var = vars_as[0]; let value = default_map.get(var).unwrap_or(&"0").to_string(); values.push(StringType::from_data(vec![value.as_bytes().to_vec()])); } else { // @@aa // var is 'aa' fields.push(TableField::new( &format!("@@{}", var), TableDataType::String, )); let value = default_map.get(var).unwrap_or(&"0").to_string(); values.push(StringType::from_data(vec![value.as_bytes().to_vec()])); } } } let schema = TableSchemaRefExt::create(fields); let block = DataBlock::new_from_columns(values); Some((schema, block)) } // Check SELECT @@variable, @@variable fn federated_select_variable_check(&self, query: &str) -> Option<(TableSchemaRef, DataBlock)> { #[ctor] static SELECT_VARIABLES_LAZY_RULES: Vec<(Regex, LazyBlockFunc)> = vec![ ( Regex::new("(?i)^(SELECT @@(.*))").unwrap(), MySQLFederated::select_variable_data_block, ), ( Regex::new("(?i)^(/\\* mysql-connector-java(.*))").unwrap(), MySQLFederated::select_variable_data_block, ), ]; FederatedHelper::lazy_block_match_rule(query, &SELECT_VARIABLES_LAZY_RULES) } // Check SHOW VARIABLES LIKE. fn federated_show_variables_check(&self, query: &str) -> Option<(TableSchemaRef, DataBlock)> { #[ctor] static SHOW_VARIABLES_RULES: Vec<(Regex, Option<(TableSchemaRef, DataBlock)>)> = vec![ ( // sqlalchemy < 1.4.30 Regex::new("(?i)^(SHOW VARIABLES LIKE 'sql_mode'(.*))").unwrap(), MySQLFederated::show_variables_block( "sql_mode", "ONLY_FULL_GROUP_BY STRICT_TRANS_TABLES NO_ZERO_IN_DATE NO_ZERO_DATE ERROR_FOR_DIVISION_BY_ZERO NO_ENGINE_SUBSTITUTION", ), ), ( Regex::new("(?i)^(SHOW VARIABLES LIKE 'lower_case_table_names'(.*))").unwrap(), MySQLFederated::show_variables_block("lower_case_table_names", "0"), ), ( Regex::new("(?i)^(show collation where(.*))").unwrap(), MySQLFederated::show_variables_block("", ""), ), ( Regex::new("(?i)^(SHOW VARIABLES(.*))").unwrap(), MySQLFederated::show_variables_block("", ""), ), ]; FederatedHelper::block_match_rule(query, &SHOW_VARIABLES_RULES) } // Check for SET or others query, this is the final check of the federated query. fn federated_mixed_check(&self, query: &str) -> Option<(TableSchemaRef, DataBlock)> { #[ctor] static MIXED_RULES: Vec<(Regex, Option<(TableSchemaRef, DataBlock)>)> = vec![ // Txn. (Regex::new("(?i)^(ROLLBACK(.*))").unwrap(), None), (Regex::new("(?i)^(COMMIT(.*))").unwrap(), None), (Regex::new("(?i)^(START(.*))").unwrap(), None), (Regex::new("(?i)^(SET NAMES(.*))").unwrap(), None), (Regex::new("(?i)^(SET character_set_results(.*))").unwrap(), None), (Regex::new("(?i)^(SET net_write_timeout(.*))").unwrap(), None), (Regex::new("(?i)^(SET FOREIGN_KEY_CHECKS(.*))").unwrap(), None), (Regex::new("(?i)^(SET AUTOCOMMIT(.*))").unwrap(), None), (Regex::new("(?i)^(SET SQL_LOG_BIN(.*))").unwrap(), None), (Regex::new("(?i)^(SET sql_mode(.*))").unwrap(), None), (Regex::new("(?i)^(SET SQL_SELECT_LIMIT(.*))").unwrap(), None), (Regex::new("(?i)^(SET @@(.*))").unwrap(), None), // Now databend not support charset and collation // https://github.com/datafuselabs/databend/issues/5853 (Regex::new("(?i)^(SHOW COLLATION)").unwrap(), None), (Regex::new("(?i)^(SHOW CHARSET)").unwrap(), None), ( // SELECT TIMEDIFF(NOW(), UTC_TIMESTAMP()); Regex::new("(?i)^(SELECT TIMEDIFF\\(NOW\\(\\), UTC_TIMESTAMP\\(\\)\\))").unwrap(), MySQLFederated::select_function_block("TIMEDIFF(NOW(), UTC_TIMESTAMP())", "00:00:00"), ), // mysqldump. (Regex::new("(?i)^(SET SESSION(.*))").unwrap(), None), (Regex::new("(?i)^(SET SQL_QUOTE_SHOW_CREATE(.*))").unwrap(), None), (Regex::new("(?i)^(LOCK TABLES(.*))").unwrap(), None), (Regex::new("(?i)^(UNLOCK TABLES(.*))").unwrap(), None), ( Regex::new("(?i)^(SELECT LOGFILE_GROUP_NAME, FILE_NAME, TOTAL_EXTENTS, INITIAL_SIZE, ENGINE, EXTRA FROM INFORMATION_SCHEMA.FILES(.*))").unwrap(), None, ), // mydumper. (Regex::new("(?i)^(/\\*!80003 SET(.*) \\*/)$").unwrap(), None), (Regex::new("(?i)^(SHOW MASTER STATUS)").unwrap(), None), (Regex::new("(?i)^(SHOW ALL SLAVES STATUS)").unwrap(), None), (Regex::new("(?i)^(LOCK BINLOG FOR BACKUP)").unwrap(), None), (Regex::new("(?i)^(LOCK TABLES FOR BACKUP)").unwrap(), None), (Regex::new("(?i)^(UNLOCK BINLOG(.*))").unwrap(), None), (Regex::new("(?i)^(/\\*!40101 SET(.*) \\*/)$").unwrap(), None), // DBeaver. (Regex::new("(?i)^(SHOW WARNINGS)").unwrap(), None), (Regex::new("(?i)^(/\\* ApplicationName=(.*)SHOW WARNINGS)").unwrap(), None), (Regex::new("(?i)^(/\\* ApplicationName=(.*)SHOW PLUGINS)").unwrap(), None), (Regex::new("(?i)^(/\\* ApplicationName=(.*)SHOW COLLATION)").unwrap(), None), (Regex::new("(?i)^(/\\* ApplicationName=(.*)SHOW CHARSET)").unwrap(), None), (Regex::new("(?i)^(/\\* ApplicationName=(.*)SHOW ENGINES)").unwrap(), None), (Regex::new("(?i)^(/\\* ApplicationName=(.*)SELECT @@(.*))").unwrap(), None), (Regex::new("(?i)^(/\\* ApplicationName=(.*)SHOW @@(.*))").unwrap(), None), ( Regex::new("(?i)^(/\\* ApplicationName=(.*)SET net_write_timeout(.*))").unwrap(), None, ), ( Regex::new("(?i)^(/\\* ApplicationName=(.*)SET SQL_SELECT_LIMIT(.*))").unwrap(), None, ), (Regex::new("(?i)^(/\\* ApplicationName=(.*)SHOW VARIABLES(.*))").unwrap(), None), // mysqldump 5.7.16 (Regex::new("(?i)^(/\\*!40100 SET(.*) \\*/)$").unwrap(), None), (Regex::new("(?i)^(/\\*!40103 SET(.*) \\*/)$").unwrap(), None), (Regex::new("(?i)^(/\\*!40111 SET(.*) \\*/)$").unwrap(), None), (Regex::new("(?i)^(/\\*!40101 SET(.*) \\*/)$").unwrap(), None), (Regex::new("(?i)^(/\\*!40014 SET(.*) \\*/)$").unwrap(), None), (Regex::new("(?i)^(/\\*!40000 SET(.*) \\*/)$").unwrap(), None), (Regex::new("(?i)^(/\\*!40000 ALTER(.*) \\*/)$").unwrap(), None), ]; FederatedHelper::block_match_rule(query, &MIXED_RULES) } // Check the query is a federated or driver setup command. // Here we fake some values for the command which Databend not supported. pub fn check(&self, query: &str) -> Option<(DataSchemaRef, DataBlock)> { // First to check the select @@variables. let select_variable = self .federated_select_variable_check(query) .map(|(schema, chunk)| (Arc::new(DataSchema::from(schema)), chunk)); if select_variable.is_some() { return select_variable; } // Then to check the show variables like ''. let show_variables = self .federated_show_variables_check(query) .map(|(schema, chunk)| (Arc::new(DataSchema::from(schema)), chunk)); if show_variables.is_some() { return show_variables; } // Last check. self.federated_mixed_check(query) .map(|(schema, chunk)| (Arc::new(DataSchema::from(schema)), chunk)) } }
use std::sync::Arc; use async_graphql::*; use futures_util::{Stream, StreamExt}; #[tokio::test] pub async fn test_all_validator() { struct Query; #[Object] #[allow(unreachable_code, unused_variables)] impl Query { async fn multiple_of(&self, #[graphql(validator(multiple_of = 10))] n: i32) -> i32 { todo!() } async fn maximum(&self, #[graphql(validator(maximum = 10))] n: i32) -> i32 { todo!() } async fn minimum(&self, #[graphql(validator(minimum = 10))] n: i32) -> i32 { todo!() } async fn max_length(&self, #[graphql(validator(max_length = 10))] n: String) -> i32 { todo!() } async fn min_length(&self, #[graphql(validator(min_length = 10))] n: String) -> i32 { todo!() } async fn max_items(&self, #[graphql(validator(max_items = 10))] n: Vec<String>) -> i32 { todo!() } async fn min_items(&self, #[graphql(validator(min_items = 10))] n: Vec<String>) -> i32 { todo!() } async fn chars_max_length( &self, #[graphql(validator(chars_max_length = 10))] n: String, ) -> i32 { todo!() } async fn chars_length( &self, #[graphql(validator(chars_min_length = 10))] n: String, ) -> i32 { todo!() } async fn email(&self, #[graphql(validator(email))] n: String) -> i32 { todo!() } async fn url(&self, #[graphql(validator(url))] n: String) -> i32 { todo!() } async fn ip(&self, #[graphql(validator(ip))] n: String) -> i32 { todo!() } async fn regex(&self, #[graphql(validator(regex = "^[0-9]+$"))] n: String) -> i32 { todo!() } async fn list_email(&self, #[graphql(validator(list, email))] n: Vec<String>) -> i32 { todo!() } } } #[tokio::test] pub async fn test_validator_on_object_field_args() { struct Query; #[Object] impl Query { async fn value(&self, #[graphql(validator(maximum = 10))] n: i32) -> i32 { n } } let schema = Schema::new(Query, EmptyMutation, EmptySubscription); assert_eq!( schema .execute("{ value(n: 5) }") .await .into_result() .unwrap() .data, value!({ "value": 5 }) ); assert_eq!( schema .execute("{ value(n: 11) }") .await .into_result() .unwrap_err(), vec![ServerError { message: r#"Failed to parse "Int": the value is 11, must be less than or equal to 10"# .to_string(), source: None, locations: vec![Pos { line: 1, column: 12 }], path: vec![PathSegment::Field("value".to_string())], extensions: None }] ); } #[tokio::test] pub async fn test_validator_on_input_object_field() { #[derive(InputObject)] struct MyInput { #[graphql(validator(maximum = 10))] a: i32, #[graphql(validator(maximum = 10))] b: Option<i32>, } struct Query; #[Object] impl Query { async fn value(&self, input: MyInput) -> i32 { input.a + input.b.unwrap_or_default() } } let schema = Schema::new(Query, EmptyMutation, EmptySubscription); assert_eq!( schema .execute("{ value(input: {a: 5}) }") .await .into_result() .unwrap() .data, value!({ "value": 5 }) ); let schema = Schema::new(Query, EmptyMutation, EmptySubscription); assert_eq!( schema .execute("{ value(input: {a: 5, b: 7}) }") .await .into_result() .unwrap() .data, value!({ "value": 12 }) ); assert_eq!( schema .execute("{ value(input: {a: 11}) }") .await .into_result() .unwrap_err(), vec![ServerError { message: r#"Failed to parse "Int": the value is 11, must be less than or equal to 10 (occurred while parsing "MyInput")"# .to_string(), source: None, locations: vec![Pos { line: 1, column: 16 }], path: vec![PathSegment::Field("value".to_string())], extensions: None }] ); assert_eq!( schema .execute("{ value(input: {a: 5, b: 20}) }") .await .into_result() .unwrap_err(), vec![ServerError { message: r#"Failed to parse "Int": the value is 20, must be less than or equal to 10 (occurred while parsing "MyInput")"# .to_string(), source: None, locations: vec![Pos { line: 1, column: 16 }], path: vec![PathSegment::Field("value".to_string())], extensions: None }] ); } #[tokio::test] pub async fn test_validator_on_complex_object_field_args() { #[derive(SimpleObject)] #[graphql(complex)] struct Query { a: i32, } #[ComplexObject] impl Query { async fn value(&self, #[graphql(validator(maximum = 10))] n: i32) -> i32 { n } } let schema = Schema::new(Query { a: 10 }, EmptyMutation, EmptySubscription); assert_eq!( schema .execute("{ value(n: 5) }") .await .into_result() .unwrap() .data, value!({ "value": 5 }) ); assert_eq!( schema .execute("{ value(n: 11) }") .await .into_result() .unwrap_err(), vec![ServerError { message: r#"Failed to parse "Int": the value is 11, must be less than or equal to 10"# .to_string(), source: None, locations: vec![Pos { line: 1, column: 12 }], path: vec![PathSegment::Field("value".to_string())], extensions: None }] ); } #[tokio::test] pub async fn test_validator_on_subscription_field_args() { struct Query; #[Object] impl Query { async fn value(&self) -> i32 { 1 } } struct Subscription; #[Subscription] impl Subscription { async fn value( &self, #[graphql(validator(maximum = 10))] n: i32, ) -> impl Stream<Item = i32> { futures_util::stream::iter(vec![n]) } } let schema = Schema::new(Query, EmptyMutation, Subscription); assert_eq!( schema .execute_stream("subscription { value(n: 5) }") .collect::<Vec<_>>() .await .remove(0) .into_result() .unwrap() .data, value!({ "value": 5 }) ); assert_eq!( schema .execute_stream("subscription { value(n: 11) }") .collect::<Vec<_>>() .await .remove(0) .into_result() .unwrap_err(), vec![ServerError { message: r#"Failed to parse "Int": the value is 11, must be less than or equal to 10"# .to_string(), source: None, locations: vec![Pos { line: 1, column: 25 }], path: vec![PathSegment::Field("value".to_string())], extensions: None }] ); } #[tokio::test] pub async fn test_custom_validator() { struct MyValidator { expect: i32, } impl MyValidator { pub fn new(n: i32) -> Self { MyValidator { expect: n } } } impl CustomValidator<i32> for MyValidator { fn check(&self, value: &i32) -> Result<(), InputValueError<i32>> { if *value == self.expect { Ok(()) } else { Err(InputValueError::custom(format!( "expect 100, actual {}", value ))) } } } #[derive(InputObject)] struct MyInput { #[graphql(validator(custom = "MyValidator::new(100)"))] n: i32, } struct Query; #[Object] impl Query { async fn value( &self, #[graphql(validator(custom = "MyValidator::new(100)"))] n: i32, ) -> i32 { n } async fn input(&self, input: MyInput) -> i32 { input.n } async fn value2( &self, #[graphql(validator(list, custom = "MyValidator::new(100)"))] values: Vec<i32>, ) -> i32 { values.into_iter().sum() } async fn value3( &self, #[graphql(validator(list, custom = "MyValidator::new(100)"))] values: Option<Vec<i32>>, ) -> i32 { values.into_iter().flatten().sum() } } struct Subscription; #[Subscription] impl Subscription { async fn value( &self, #[graphql(validator(custom = "MyValidator::new(100)"))] n: i32, ) -> impl Stream<Item = i32> { futures_util::stream::iter(vec![n]) } } let schema = Schema::new(Query, EmptyMutation, Subscription); assert_eq!( schema .execute("{ value(n: 100) }") .await .into_result() .unwrap() .data, value!({ "value": 100 }) ); assert_eq!( schema .execute("{ value(n: 11) }") .await .into_result() .unwrap_err(), vec![ServerError { message: r#"Failed to parse "Int": expect 100, actual 11"#.to_string(), source: None, locations: vec![Pos { line: 1, column: 12 }], path: vec![PathSegment::Field("value".to_string())], extensions: None }] ); assert_eq!( schema .execute("{ input(input: {n: 100} ) }") .await .into_result() .unwrap() .data, value!({ "input": 100 }) ); assert_eq!( schema .execute("{ input(input: {n: 11} ) }") .await .into_result() .unwrap_err(), vec![ServerError { message: r#"Failed to parse "Int": expect 100, actual 11 (occurred while parsing "MyInput")"# .to_string(), source: None, locations: vec![Pos { line: 1, column: 16 }], path: vec![PathSegment::Field("input".to_string())], extensions: None }] ); assert_eq!( schema .execute_stream("subscription { value(n: 100 ) }") .next() .await .unwrap() .into_result() .unwrap() .data, value!({ "value": 100 }) ); assert_eq!( schema .execute_stream("subscription { value(n: 11 ) }") .next() .await .unwrap() .into_result() .unwrap_err(), vec![ServerError { message: r#"Failed to parse "Int": expect 100, actual 11"#.to_string(), source: None, locations: vec![Pos { line: 1, column: 25 }], path: vec![PathSegment::Field("value".to_string())], extensions: None }] ); assert_eq!( schema .execute("{ value2(values: [77, 88] ) }") .await .into_result() .unwrap_err(), vec![ServerError { message: r#"Failed to parse "Int": expect 100, actual 77"#.to_string(), source: None, locations: vec![Pos { line: 1, column: 18 }], path: vec![PathSegment::Field("value2".to_string())], extensions: None }] ); assert_eq!( schema .execute("{ value3(values: [77, 88] ) }") .await .into_result() .unwrap_err(), vec![ServerError { message: r#"Failed to parse "Int": expect 100, actual 77"#.to_string(), source: None, locations: vec![Pos { line: 1, column: 18 }], path: vec![PathSegment::Field("value3".to_string())], extensions: None }] ); assert_eq!( schema .execute("{ value3(values: null ) }") .await .into_result() .unwrap() .data, value!({ "value3": 0 }) ); } #[tokio::test] pub async fn test_custom_validator_with_fn() { fn check_100(value: &i32) -> Result<(), String> { if *value == 100 { Ok(()) } else { Err(format!("expect 100, actual {}", value)) } } struct Query; #[Object] impl Query { async fn value(&self, #[graphql(validator(custom = "check_100"))] n: i32) -> i32 { n } } let schema = Schema::new(Query, EmptyMutation, EmptySubscription); assert_eq!( schema .execute("{ value(n: 100) }") .await .into_result() .unwrap() .data, value!({ "value": 100 }) ); assert_eq!( schema .execute("{ value(n: 11) }") .await .into_result() .unwrap_err(), vec![ServerError { message: r#"Failed to parse "Int": expect 100, actual 11"#.to_string(), source: None, locations: vec![Pos { line: 1, column: 12 }], path: vec![PathSegment::Field("value".to_string())], extensions: None }] ); } #[tokio::test] pub async fn test_custom_validator_with_extensions() { struct MyValidator { expect: i32, } impl MyValidator { pub fn new(n: i32) -> Self { MyValidator { expect: n } } } impl CustomValidator<i32> for MyValidator { fn check(&self, value: &i32) -> Result<(), InputValueError<i32>> { if *value == self.expect { Ok(()) } else { Err( InputValueError::custom(format!("expect 100, actual {}", value)) .with_extension("code", 99), ) } } } struct Query; #[Object] impl Query { async fn value( &self, #[graphql(validator(custom = "MyValidator::new(100)"))] n: i32, ) -> i32 { n } } let schema = Schema::new(Query, EmptyMutation, EmptySubscription); assert_eq!( schema .execute("{ value(n: 100) }") .await .into_result() .unwrap() .data, value!({ "value": 100 }) ); let mut error_extensions = ErrorExtensionValues::default(); error_extensions.set("code", 99); assert_eq!( schema .execute("{ value(n: 11) }") .await .into_result() .unwrap_err(), vec![ServerError { message: r#"Failed to parse "Int": expect 100, actual 11"#.to_string(), source: None, locations: vec![Pos { line: 1, column: 12 }], path: vec![PathSegment::Field("value".to_string())], extensions: Some(error_extensions) }] ); } #[tokio::test] pub async fn test_list_validator() { struct Query; #[Object] impl Query { async fn value(&self, #[graphql(validator(maximum = 3, list))] n: Vec<i32>) -> i32 { n.into_iter().sum() } } let schema = Schema::new(Query, EmptyMutation, EmptySubscription); assert_eq!( schema .execute("{ value(n: [1, 2, 3]) }") .await .into_result() .unwrap() .data, value!({ "value": 6 }) ); assert_eq!( schema .execute("{ value(n: [1, 2, 3, 4]) }") .await .into_result() .unwrap_err(), vec![ServerError { message: r#"Failed to parse "Int": the value is 4, must be less than or equal to 3"# .to_string(), source: None, locations: vec![Pos { line: 1, column: 12 }], path: vec![PathSegment::Field("value".to_string())], extensions: None }] ); } #[tokio::test] pub async fn test_validate_wrapper_types() { #[derive(NewType)] struct Size(i32); struct Query; #[Object] impl Query { async fn a(&self, #[graphql(validator(maximum = 10))] n: Option<i32>) -> i32 { n.unwrap_or_default() } async fn b(&self, #[graphql(validator(maximum = 10))] n: Option<Option<i32>>) -> i32 { n.unwrap_or_default().unwrap_or_default() } async fn c(&self, #[graphql(validator(maximum = 10))] n: MaybeUndefined<i32>) -> i32 { n.take().unwrap_or_default() } async fn d(&self, #[graphql(validator(maximum = 10))] n: Box<i32>) -> i32 { *n } async fn e(&self, #[graphql(validator(maximum = 10))] n: Arc<i32>) -> i32 { *n } async fn f(&self, #[graphql(validator(maximum = 10))] n: Json<i32>) -> i32 { n.0 } async fn g(&self, #[graphql(validator(maximum = 10))] n: Option<Json<i32>>) -> i32 { n.map(|n| n.0).unwrap_or_default() } async fn h(&self, #[graphql(validator(maximum = 10))] n: Size) -> i32 { n.0 } async fn i(&self, #[graphql(validator(list, maximum = 10))] n: Vec<i32>) -> i32 { n.into_iter().sum() } } let schema = Schema::new(Query, EmptyMutation, EmptySubscription); let successes = [ ("{ a(n: 5) }", value!({ "a": 5 })), ("{ a }", value!({ "a": 0 })), ("{ b(n: 5) }", value!({ "b": 5 })), ("{ b }", value!({ "b": 0 })), ("{ c(n: 5) }", value!({ "c": 5 })), ("{ c(n: null) }", value!({ "c": 0 })), ("{ c }", value!({ "c": 0 })), ("{ d(n: 5) }", value!({ "d": 5 })), ("{ e(n: 5) }", value!({ "e": 5 })), ("{ f(n: 5) }", value!({ "f": 5 })), ("{ g(n: 5) }", value!({ "g": 5 })), ("{ g }", value!({ "g": 0 })), ("{ h(n: 5) }", value!({ "h": 5 })), ("{ i(n: [1, 2, 3]) }", value!({ "i": 6 })), ]; for (query, res) in successes { assert_eq!(schema.execute(query).await.into_result().unwrap().data, res); } assert_eq!( schema .execute("{ a(n:20) }") .await .into_result() .unwrap_err(), vec![ServerError { message: r#"Failed to parse "Int": the value is 20, must be less than or equal to 10"# .to_string(), source: None, locations: vec![Pos { line: 1, column: 7 }], path: vec![PathSegment::Field("a".to_string())], extensions: None }] ); assert_eq!( schema .execute("{ b(n:20) }") .await .into_result() .unwrap_err(), vec![ServerError { message: r#"Failed to parse "Int": the value is 20, must be less than or equal to 10"# .to_string(), source: None, locations: vec![Pos { line: 1, column: 7 }], path: vec![PathSegment::Field("b".to_string())], extensions: None }] ); assert_eq!( schema .execute("{ f(n:20) }") .await .into_result() .unwrap_err(), vec![ServerError { message: r#"Failed to parse "Int": the value is 20, must be less than or equal to 10"# .to_string(), source: None, locations: vec![Pos { line: 1, column: 7 }], path: vec![PathSegment::Field("f".to_string())], extensions: None }] ); } #[tokio::test] pub async fn test_list_both_max_items_and_max_length() { struct Query; #[Object] impl Query { async fn value( &self, #[graphql(validator(list, max_length = 3, max_items = 2))] values: Vec<String>, ) -> String { values.into_iter().collect() } async fn value2( &self, #[graphql(validator(list, max_length = 3, max_items = 2))] values: Option<Vec<String>>, ) -> String { values.into_iter().flatten().collect() } } let schema = Schema::new(Query, EmptyMutation, EmptySubscription); assert_eq!( schema .execute(r#"{ value(values: ["a", "b", "cdef"])}"#) .await .into_result() .unwrap_err(), vec![ServerError { message: r#"Failed to parse "[String!]": the value length is 3, must be less than or equal to 2"#.to_string(), source: None, locations: vec![Pos { column: 17, line: 1}], path: vec![PathSegment::Field("value".to_string())], extensions: None }] ); assert_eq!( schema .execute(r#"{ value(values: ["a", "cdef"])}"#) .await .into_result() .unwrap_err(), vec![ServerError { message: r#"Failed to parse "String": the string length is 4, must be less than or equal to 3"#.to_string(), source: None, locations: vec![Pos { column: 17, line: 1}], path: vec![PathSegment::Field("value".to_string())], extensions: None }] ); assert_eq!( schema .execute(r#"{ value(values: ["a", "b"])}"#) .await .into_result() .unwrap() .data, value!({ "value": "ab" }) ); assert_eq!( schema .execute(r#"{ value2(values: ["a", "b", "cdef"])}"#) .await .into_result() .unwrap_err(), vec![ServerError { message: r#"Failed to parse "[String!]": the value length is 3, must be less than or equal to 2"#.to_string(), source: None, locations: vec![Pos { column: 18, line: 1}], path: vec![PathSegment::Field("value2".to_string())], extensions: None }] ); assert_eq!( schema .execute(r#"{ value2(values: ["a", "cdef"])}"#) .await .into_result() .unwrap_err(), vec![ServerError { message: r#"Failed to parse "String": the string length is 4, must be less than or equal to 3"#.to_string(), source: None, locations: vec![Pos { column: 18, line: 1}], path: vec![PathSegment::Field("value2".to_string())], extensions: None }] ); assert_eq!( schema .execute(r#"{ value2(values: ["a", "b", "cdef"])}"#) .await .into_result() .unwrap_err(), vec![ServerError { message: r#"Failed to parse "[String!]": the value length is 3, must be less than or equal to 2"#.to_string(), source: None, locations: vec![Pos { column: 18, line: 1}], path: vec![PathSegment::Field("value2".to_string())], extensions: None }] ); assert_eq!( schema .execute(r#"{ value2(values: null)}"#) .await .into_result() .unwrap() .data, value!({ "value2": "" }) ); } #[tokio::test] pub async fn test_issue_1164() { struct PasswordValidator; impl CustomValidator<String> for PasswordValidator { /// Check if `value` only contains allowed chars fn check(&self, value: &String) -> Result<(), InputValueError<String>> { let allowed_chars = ['1', '2', '3', '4', '5', '6']; if value .chars() .all(|c| allowed_chars.contains(&c.to_ascii_lowercase())) { Ok(()) } else { Err(InputValueError::custom(format!( "illegal char in password: `{}`", value ))) } } } struct Query; #[Object] impl Query { async fn a( &self, #[graphql(validator(min_length = 6, max_length = 16, custom = "PasswordValidator"))] value: String, ) -> String { value } } let schema = Schema::new(Query, EmptyMutation, EmptySubscription); assert_eq!( schema .execute(r#"{ a(value: "123456")}"#) .await .into_result() .unwrap() .data, value!({ "a": "123456" }) ); assert_eq!( schema .execute(r#"{ a(value: "123") }"#) .await .into_result() .unwrap_err(), vec![ServerError { message: r#"Failed to parse "String": the string length is 3, must be greater than or equal to 6"#.to_string(), source: None, locations: vec![Pos { column: 12, line: 1}], path: vec![PathSegment::Field("a".to_string())], extensions: None }] ); assert_eq!( schema .execute(r#"{ a(value: "123123123123123123") }"#) .await .into_result() .unwrap_err(), vec![ServerError { message: r#"Failed to parse "String": the string length is 18, must be less than or equal to 16"#.to_string(), source: None, locations: vec![Pos { column: 12, line: 1}], path: vec![PathSegment::Field("a".to_string())], extensions: None }] ); assert_eq!( schema .execute(r#"{ a(value: "abcdef") }"#) .await .into_result() .unwrap_err(), vec![ServerError { message: r#"Failed to parse "String": illegal char in password: `abcdef`"#.to_string(), source: None, locations: vec![Pos { column: 12, line: 1 }], path: vec![PathSegment::Field("a".to_string())], extensions: None }] ); }
use std::cmp::{Ord, PartialOrd, Eq, PartialEq, Ordering}; use std::collections::BinaryHeap; pub enum Node { Leaf(u8), Parent { left: Box<Node>, right: Box<Node> }, } struct NodeFreqPair { freq: u64, node: Node, } impl PartialEq for NodeFreqPair { fn eq(&self, other: &NodeFreqPair) -> bool { self.freq == other.freq } } impl Eq for NodeFreqPair {} impl PartialOrd for NodeFreqPair { fn partial_cmp(&self, other: &NodeFreqPair) -> Option<Ordering> { Some(other.freq.cmp(&self.freq)) } } impl Ord for NodeFreqPair { fn cmp(&self, other: &NodeFreqPair) -> Ordering { other.freq.cmp(&self.freq) } } pub fn build_tree(freq_table: [u64; 256]) -> Option<Node> { let mut q = BinaryHeap::new(); for (symbol, &freq) in freq_table.iter().enumerate() { if freq > 0 { q.push(NodeFreqPair { freq: freq, node: Node::Leaf(symbol as u8), }); } } while q.len() > 1 { if let Some(x) = q.pop() { if let Some(y) = q.pop() { q.push(NodeFreqPair { freq: x.freq + y.freq, node: Node::Parent { left: Box::new(x.node), right: Box::new(y.node), }, }); } } } q.pop().map(|x| x.node) }
static DIRS : [(i32, i32); 8] = [(-1, -1), (0, -1), (1, -1), (-1, 0), (1, 0), (-1, 1), (0, 1), (1, 1)]; fn permute_seats<F>(seats : &Vec<char>, w : usize, h: usize, limit : usize, f : F) -> Vec<char> where F : Fn(usize, usize) -> usize { let mut res = seats.clone(); for y in 0..h { for x in 0..w { let i = y * w + x; if seats[i] == 'L' && f(x, y) == 0 { res[i] = '#'; } else if seats[i] == '#' && f(x, y) >= limit { res[i] = 'L'; } } } return res; } fn seating_rules(seats : &Vec<char>, w : usize, h : usize) -> Vec<char> { let adj_seats_occupied = |x : usize, y : usize| { DIRS.iter() .map(move |(dx, dy)| (x as i32 + dx, y as i32 + dy)) .filter(|(new_x, new_y)| (0..w as i32).contains(new_x) && (0..h as i32).contains(new_y)) .map(|(x, y)| (x as usize, y as usize)) .filter(|(x, y)| seats[y * w + x] == '#').count() }; permute_seats(seats, w, h, 4, adj_seats_occupied) } fn seating_rules2(seats : &Vec<char>, w : usize, h : usize) -> Vec<char> { let vis_seats_occupied = |x : usize, y : usize| { let mut occupied = 0; for (dx, dy) in DIRS.iter() { let mut new_x = x as i32 + dx; let mut new_y = y as i32 + dy; loop { if !((0..w as i32).contains(&new_x) && (0..h as i32).contains(&new_y)) { break; } let i = new_y * w as i32 + new_x; match seats[i as usize] { 'L' => break, '#' => { occupied += 1; break; } _ => (), } new_x += dx; new_y += dy; } } return occupied; }; permute_seats(seats, w, h, 5, vis_seats_occupied) } fn repeat_apply_rules<F>(init_seats : Vec<char>, w : usize, h : usize, f : F) -> usize where F : Fn(&Vec<char>, usize, usize) -> Vec<char> { let mut seats = init_seats; loop { let new_seats = f(&seats, w, h); if new_seats == seats { return new_seats.iter().filter(|seat| **seat == '#').count(); } seats = new_seats; } } fn main() { let mut w : usize = 0; let mut h : usize = 0; let mut init_seats : Vec<char> = Vec::new(); let mut v : Vec<char> = Vec::new(); for line in aoc::file_lines_iter("./day11.txt") { v.clear(); v.extend(line.chars()); w = v.len(); h += 1; init_seats.append(&mut v); } let part1 = repeat_apply_rules(init_seats.clone(), w, h, seating_rules); println!("Part 1: {}", part1); let part2 = repeat_apply_rules(init_seats.clone(), w, h, seating_rules2); println!("Part 2: {}", part2); }
use std::cell::RefCell; use std::rc::Rc; use super::action::Action; use super::action::TypedAction; use super::action::Action::Flag; use super::generic::StoreConstAction; use super::{StoreTrue, StoreFalse}; impl TypedAction<bool> for StoreTrue { fn bind<'x>(&self, cell: Rc<RefCell<&'x mut bool>>) -> Action<'x> { return Flag(Box::new(StoreConstAction { cell: cell, value: true })); } } impl TypedAction<bool> for StoreFalse { fn bind<'x>(&self, cell: Rc<RefCell<&'x mut bool>>) -> Action<'x> { return Flag(Box::new(StoreConstAction { cell: cell, value: false })); } }
use minidom::Element; use std::convert::TryFrom; use crate::xml::ElementExt; use crate::Error; use crate::Point; #[derive(Debug)] pub enum Geometry { Polygon(Vec<Point>), } impl<'a> TryFrom<&'a Element> for Geometry { type Error = Error; fn try_from(element: &Element) -> Result<Self, Self::Error> { let points: Result<Vec<_>, _> = element .get_element("POLYGON")? .text() .split(',') .map(|s| s.parse()) .collect(); Ok(Geometry::Polygon(points?)) } }
#![deny(rust_2018_idioms)] mod chain; mod felt; mod hash; mod serde; pub use chain::HashChain; pub use felt::{Felt, HexParseError, OverflowError}; pub use hash::stark_hash;
use std::iter::FromIterator; use proc_macro2::Span; use syn::punctuated::Punctuated; use syn::token::{Gt, Lt}; use syn::visit_mut::{self, VisitMut}; use syn::{ GenericArgument, GenericParam, Generics, Lifetime, LifetimeDef, Receiver, TypeReference, }; pub struct Lifetimes { pub elided: Vec<Lifetime>, pub explicit: Vec<Lifetime>, pub name: &'static str, } impl Lifetimes { pub fn new(name: &'static str) -> Self { Lifetimes { elided: Vec::new(), explicit: Vec::new(), name, } } pub fn generics(&self) -> Generics { Generics { lt_token: Some(Lt::default()), params: Punctuated::from_iter( self.explicit .iter() .chain(&self.elided) .filter(|lifetime| lifetime.ident != "static") .map(|lifetime| { GenericParam::Lifetime(LifetimeDef { attrs: Vec::new(), lifetime: lifetime.clone(), colon_token: None, bounds: Punctuated::new(), }) }), ), gt_token: Some(Gt::default()), where_clause: None, } } fn visit_opt_lifetime(&mut self, lifetime: &mut Option<Lifetime>) { match lifetime { None => *lifetime = Some(self.next_lifetime()), Some(lifetime) => self.visit_lifetime(lifetime), } } fn visit_lifetime(&mut self, lifetime: &mut Lifetime) { if lifetime.ident == "_" { *lifetime = self.next_lifetime(); } else { self.explicit.push(lifetime.clone()); } } fn next_lifetime(&mut self) -> Lifetime { let name = format!("{}{}", self.name, self.elided.len()); let life = Lifetime::new(&name, Span::call_site()); self.elided.push(life.clone()); life } } impl VisitMut for Lifetimes { fn visit_receiver_mut(&mut self, arg: &mut Receiver) { if let Some((_, lifetime)) = &mut arg.reference { self.visit_opt_lifetime(lifetime); } } fn visit_type_reference_mut(&mut self, ty: &mut TypeReference) { self.visit_opt_lifetime(&mut ty.lifetime); visit_mut::visit_type_reference_mut(self, ty); } fn visit_generic_argument_mut(&mut self, gen: &mut GenericArgument) { if let GenericArgument::Lifetime(lifetime) = gen { self.visit_lifetime(lifetime); } visit_mut::visit_generic_argument_mut(self, gen); } }
use crate::backend::c; use bitflags::bitflags; bitflags! { /// `*_OK` constants for use with [`accessat`]. /// /// [`accessat`]: fn.accessat.html #[repr(transparent)] #[derive(Copy, Clone, Eq, PartialEq, Hash, Debug)] pub struct Access: c::c_uint { /// `R_OK` const READ_OK = linux_raw_sys::general::R_OK; /// `W_OK` const WRITE_OK = linux_raw_sys::general::W_OK; /// `X_OK` const EXEC_OK = linux_raw_sys::general::X_OK; /// `F_OK` const EXISTS = linux_raw_sys::general::F_OK; } } bitflags! { /// `AT_*` constants for use with [`openat`], [`statat`], and other `*at` /// functions. /// /// [`openat`]: crate::fs::openat /// [`statat`]: crate::fs::statat #[repr(transparent)] #[derive(Copy, Clone, Eq, PartialEq, Hash, Debug)] pub struct AtFlags: c::c_uint { /// `AT_SYMLINK_NOFOLLOW` const SYMLINK_NOFOLLOW = linux_raw_sys::general::AT_SYMLINK_NOFOLLOW; /// `AT_EACCESS` const EACCESS = linux_raw_sys::general::AT_EACCESS; /// `AT_REMOVEDIR` const REMOVEDIR = linux_raw_sys::general::AT_REMOVEDIR; /// `AT_SYMLINK_FOLLOW` const SYMLINK_FOLLOW = linux_raw_sys::general::AT_SYMLINK_FOLLOW; /// `AT_NO_AUTOMOUNT` const NO_AUTOMOUNT = linux_raw_sys::general::AT_NO_AUTOMOUNT; /// `AT_EMPTY_PATH` const EMPTY_PATH = linux_raw_sys::general::AT_EMPTY_PATH; /// `AT_STATX_SYNC_AS_STAT` const STATX_SYNC_AS_STAT = linux_raw_sys::general::AT_STATX_SYNC_AS_STAT; /// `AT_STATX_FORCE_SYNC` const STATX_FORCE_SYNC = linux_raw_sys::general::AT_STATX_FORCE_SYNC; /// `AT_STATX_DONT_SYNC` const STATX_DONT_SYNC = linux_raw_sys::general::AT_STATX_DONT_SYNC; } } bitflags! { /// `S_I*` constants for use with [`openat`], [`chmodat`], and [`fchmod`]. /// /// [`openat`]: crate::fs::openat /// [`chmodat`]: crate::fs::chmodat /// [`fchmod`]: crate::fs::fchmod #[repr(transparent)] #[derive(Copy, Clone, Eq, PartialEq, Hash, Debug)] pub struct Mode: RawMode { /// `S_IRWXU` const RWXU = linux_raw_sys::general::S_IRWXU; /// `S_IRUSR` const RUSR = linux_raw_sys::general::S_IRUSR; /// `S_IWUSR` const WUSR = linux_raw_sys::general::S_IWUSR; /// `S_IXUSR` const XUSR = linux_raw_sys::general::S_IXUSR; /// `S_IRWXG` const RWXG = linux_raw_sys::general::S_IRWXG; /// `S_IRGRP` const RGRP = linux_raw_sys::general::S_IRGRP; /// `S_IWGRP` const WGRP = linux_raw_sys::general::S_IWGRP; /// `S_IXGRP` const XGRP = linux_raw_sys::general::S_IXGRP; /// `S_IRWXO` const RWXO = linux_raw_sys::general::S_IRWXO; /// `S_IROTH` const ROTH = linux_raw_sys::general::S_IROTH; /// `S_IWOTH` const WOTH = linux_raw_sys::general::S_IWOTH; /// `S_IXOTH` const XOTH = linux_raw_sys::general::S_IXOTH; /// `S_ISUID` const SUID = linux_raw_sys::general::S_ISUID; /// `S_ISGID` const SGID = linux_raw_sys::general::S_ISGID; /// `S_ISVTX` const SVTX = linux_raw_sys::general::S_ISVTX; } } impl Mode { /// Construct a `Mode` from the mode bits of the `st_mode` field of a /// `Stat`. #[inline] pub const fn from_raw_mode(st_mode: RawMode) -> Self { Self::from_bits_truncate(st_mode) } /// Construct an `st_mode` value from `Stat`. #[inline] pub const fn as_raw_mode(self) -> RawMode { self.bits() } } impl From<RawMode> for Mode { /// Support conversions from raw mode values to `Mode`. /// /// ``` /// use rustix::fs::{Mode, RawMode}; /// assert_eq!(Mode::from(0o700), Mode::RWXU); /// ``` #[inline] fn from(st_mode: RawMode) -> Self { Self::from_raw_mode(st_mode) } } impl From<Mode> for RawMode { /// Support conversions from `Mode` to raw mode values. /// /// ``` /// use rustix::fs::{Mode, RawMode}; /// assert_eq!(RawMode::from(Mode::RWXU), 0o700); /// ``` #[inline] fn from(mode: Mode) -> Self { mode.as_raw_mode() } } bitflags! { /// `O_*` constants for use with [`openat`]. /// /// [`openat`]: crate::fs::openat #[repr(transparent)] #[derive(Copy, Clone, Eq, PartialEq, Hash, Debug)] pub struct OFlags: c::c_uint { /// `O_ACCMODE` const ACCMODE = linux_raw_sys::general::O_ACCMODE; /// Similar to `ACCMODE`, but just includes the read/write flags, and /// no other flags. /// /// Some implementations include `O_PATH` in `O_ACCMODE`, when /// sometimes we really just want the read/write bits. Caution is /// indicated, as the presence of `O_PATH` may mean that the read/write /// bits don't have their usual meaning. const RWMODE = linux_raw_sys::general::O_RDONLY | linux_raw_sys::general::O_WRONLY | linux_raw_sys::general::O_RDWR; /// `O_APPEND` const APPEND = linux_raw_sys::general::O_APPEND; /// `O_CREAT` #[doc(alias = "CREAT")] const CREATE = linux_raw_sys::general::O_CREAT; /// `O_DIRECTORY` const DIRECTORY = linux_raw_sys::general::O_DIRECTORY; /// `O_DSYNC`. Linux 2.6.32 only supports `O_SYNC`. const DSYNC = linux_raw_sys::general::O_SYNC; /// `O_EXCL` const EXCL = linux_raw_sys::general::O_EXCL; /// `O_FSYNC`. Linux 2.6.32 only supports `O_SYNC`. const FSYNC = linux_raw_sys::general::O_SYNC; /// `O_NOFOLLOW` const NOFOLLOW = linux_raw_sys::general::O_NOFOLLOW; /// `O_NONBLOCK` const NONBLOCK = linux_raw_sys::general::O_NONBLOCK; /// `O_RDONLY` const RDONLY = linux_raw_sys::general::O_RDONLY; /// `O_WRONLY` const WRONLY = linux_raw_sys::general::O_WRONLY; /// `O_RDWR` const RDWR = linux_raw_sys::general::O_RDWR; /// `O_NOCTTY` const NOCTTY = linux_raw_sys::general::O_NOCTTY; /// `O_RSYNC`. Linux 2.6.32 only supports `O_SYNC`. const RSYNC = linux_raw_sys::general::O_SYNC; /// `O_SYNC` const SYNC = linux_raw_sys::general::O_SYNC; /// `O_TRUNC` const TRUNC = linux_raw_sys::general::O_TRUNC; /// `O_PATH` const PATH = linux_raw_sys::general::O_PATH; /// `O_CLOEXEC` const CLOEXEC = linux_raw_sys::general::O_CLOEXEC; /// `O_TMPFILE` const TMPFILE = linux_raw_sys::general::O_TMPFILE; /// `O_NOATIME` const NOATIME = linux_raw_sys::general::O_NOATIME; /// `O_DIRECT` const DIRECT = linux_raw_sys::general::O_DIRECT; } } bitflags! { /// `RESOLVE_*` constants for use with [`openat2`]. /// /// [`openat2`]: crate::fs::openat2 #[repr(transparent)] #[derive(Default, Copy, Clone, Eq, PartialEq, Hash, Debug)] pub struct ResolveFlags: u64 { /// `RESOLVE_NO_XDEV` const NO_XDEV = linux_raw_sys::general::RESOLVE_NO_XDEV as u64; /// `RESOLVE_NO_MAGICLINKS` const NO_MAGICLINKS = linux_raw_sys::general::RESOLVE_NO_MAGICLINKS as u64; /// `RESOLVE_NO_SYMLINKS` const NO_SYMLINKS = linux_raw_sys::general::RESOLVE_NO_SYMLINKS as u64; /// `RESOLVE_BENEATH` const BENEATH = linux_raw_sys::general::RESOLVE_BENEATH as u64; /// `RESOLVE_IN_ROOT` const IN_ROOT = linux_raw_sys::general::RESOLVE_IN_ROOT as u64; /// `RESOLVE_CACHED` (since Linux 5.12) const CACHED = linux_raw_sys::general::RESOLVE_CACHED as u64; } } bitflags! { /// `RENAME_*` constants for use with [`renameat_with`]. /// /// [`renameat_with`]: crate::fs::renameat_with #[repr(transparent)] #[derive(Copy, Clone, Eq, PartialEq, Hash, Debug)] pub struct RenameFlags: c::c_uint { /// `RENAME_EXCHANGE` const EXCHANGE = linux_raw_sys::general::RENAME_EXCHANGE; /// `RENAME_NOREPLACE` const NOREPLACE = linux_raw_sys::general::RENAME_NOREPLACE; /// `RENAME_WHITEOUT` const WHITEOUT = linux_raw_sys::general::RENAME_WHITEOUT; } } /// `S_IF*` constants for use with [`mknodat`] and [`Stat`]'s `st_mode` field. /// /// [`mknodat`]: crate::fs::mknodat /// [`Stat`]: crate::fs::Stat #[derive(Clone, Copy, Debug, PartialEq, Eq)] pub enum FileType { /// `S_IFREG` RegularFile = linux_raw_sys::general::S_IFREG as isize, /// `S_IFDIR` Directory = linux_raw_sys::general::S_IFDIR as isize, /// `S_IFLNK` Symlink = linux_raw_sys::general::S_IFLNK as isize, /// `S_IFIFO` #[doc(alias = "IFO")] Fifo = linux_raw_sys::general::S_IFIFO as isize, /// `S_IFSOCK` Socket = linux_raw_sys::general::S_IFSOCK as isize, /// `S_IFCHR` CharacterDevice = linux_raw_sys::general::S_IFCHR as isize, /// `S_IFBLK` BlockDevice = linux_raw_sys::general::S_IFBLK as isize, /// An unknown filesystem object. Unknown, } impl FileType { /// Construct a `FileType` from the `S_IFMT` bits of the `st_mode` field of /// a `Stat`. #[inline] pub const fn from_raw_mode(st_mode: RawMode) -> Self { match st_mode & linux_raw_sys::general::S_IFMT { linux_raw_sys::general::S_IFREG => Self::RegularFile, linux_raw_sys::general::S_IFDIR => Self::Directory, linux_raw_sys::general::S_IFLNK => Self::Symlink, linux_raw_sys::general::S_IFIFO => Self::Fifo, linux_raw_sys::general::S_IFSOCK => Self::Socket, linux_raw_sys::general::S_IFCHR => Self::CharacterDevice, linux_raw_sys::general::S_IFBLK => Self::BlockDevice, _ => Self::Unknown, } } /// Construct an `st_mode` value from `Stat`. #[inline] pub const fn as_raw_mode(self) -> RawMode { match self { Self::RegularFile => linux_raw_sys::general::S_IFREG, Self::Directory => linux_raw_sys::general::S_IFDIR, Self::Symlink => linux_raw_sys::general::S_IFLNK, Self::Fifo => linux_raw_sys::general::S_IFIFO, Self::Socket => linux_raw_sys::general::S_IFSOCK, Self::CharacterDevice => linux_raw_sys::general::S_IFCHR, Self::BlockDevice => linux_raw_sys::general::S_IFBLK, Self::Unknown => linux_raw_sys::general::S_IFMT, } } /// Construct a `FileType` from the `d_type` field of a `c::dirent`. #[inline] pub(crate) const fn from_dirent_d_type(d_type: u8) -> Self { match d_type as u32 { linux_raw_sys::general::DT_REG => Self::RegularFile, linux_raw_sys::general::DT_DIR => Self::Directory, linux_raw_sys::general::DT_LNK => Self::Symlink, linux_raw_sys::general::DT_SOCK => Self::Socket, linux_raw_sys::general::DT_FIFO => Self::Fifo, linux_raw_sys::general::DT_CHR => Self::CharacterDevice, linux_raw_sys::general::DT_BLK => Self::BlockDevice, // linux_raw_sys::general::DT_UNKNOWN | _ => Self::Unknown, } } } /// `POSIX_FADV_*` constants for use with [`fadvise`]. /// /// [`fadvise`]: crate::fs::fadvise #[derive(Debug, Copy, Clone, Eq, PartialEq)] #[repr(u32)] pub enum Advice { /// `POSIX_FADV_NORMAL` Normal = linux_raw_sys::general::POSIX_FADV_NORMAL, /// `POSIX_FADV_SEQUENTIAL` Sequential = linux_raw_sys::general::POSIX_FADV_SEQUENTIAL, /// `POSIX_FADV_RANDOM` Random = linux_raw_sys::general::POSIX_FADV_RANDOM, /// `POSIX_FADV_NOREUSE` NoReuse = linux_raw_sys::general::POSIX_FADV_NOREUSE, /// `POSIX_FADV_WILLNEED` WillNeed = linux_raw_sys::general::POSIX_FADV_WILLNEED, /// `POSIX_FADV_DONTNEED` DontNeed = linux_raw_sys::general::POSIX_FADV_DONTNEED, } bitflags! { /// `MFD_*` constants for use with [`memfd_create`]. /// /// [`memfd_create`]: crate::fs::memfd_create #[repr(transparent)] #[derive(Copy, Clone, Eq, PartialEq, Hash, Debug)] pub struct MemfdFlags: c::c_uint { /// `MFD_CLOEXEC` const CLOEXEC = linux_raw_sys::general::MFD_CLOEXEC; /// `MFD_ALLOW_SEALING` const ALLOW_SEALING = linux_raw_sys::general::MFD_ALLOW_SEALING; /// `MFD_HUGETLB` (since Linux 4.14) const HUGETLB = linux_raw_sys::general::MFD_HUGETLB; /// `MFD_HUGE_64KB` const HUGE_64KB = linux_raw_sys::general::MFD_HUGE_64KB; /// `MFD_HUGE_512JB` const HUGE_512KB = linux_raw_sys::general::MFD_HUGE_512KB; /// `MFD_HUGE_1MB` const HUGE_1MB = linux_raw_sys::general::MFD_HUGE_1MB; /// `MFD_HUGE_2MB` const HUGE_2MB = linux_raw_sys::general::MFD_HUGE_2MB; /// `MFD_HUGE_8MB` const HUGE_8MB = linux_raw_sys::general::MFD_HUGE_8MB; /// `MFD_HUGE_16MB` const HUGE_16MB = linux_raw_sys::general::MFD_HUGE_16MB; /// `MFD_HUGE_32MB` const HUGE_32MB = linux_raw_sys::general::MFD_HUGE_32MB; /// `MFD_HUGE_256MB` const HUGE_256MB = linux_raw_sys::general::MFD_HUGE_256MB; /// `MFD_HUGE_512MB` const HUGE_512MB = linux_raw_sys::general::MFD_HUGE_512MB; /// `MFD_HUGE_1GB` const HUGE_1GB = linux_raw_sys::general::MFD_HUGE_1GB; /// `MFD_HUGE_2GB` const HUGE_2GB = linux_raw_sys::general::MFD_HUGE_2GB; /// `MFD_HUGE_16GB` const HUGE_16GB = linux_raw_sys::general::MFD_HUGE_16GB; } } bitflags! { /// `F_SEAL_*` constants for use with [`fcntl_add_seals`] and /// [`fcntl_get_seals`]. /// /// [`fcntl_add_seals`]: crate::fs::fcntl_add_seals /// [`fcntl_get_seals`]: crate::fs::fcntl_get_seals #[repr(transparent)] #[derive(Copy, Clone, Eq, PartialEq, Hash, Debug)] pub struct SealFlags: u32 { /// `F_SEAL_SEAL`. const SEAL = linux_raw_sys::general::F_SEAL_SEAL; /// `F_SEAL_SHRINK`. const SHRINK = linux_raw_sys::general::F_SEAL_SHRINK; /// `F_SEAL_GROW`. const GROW = linux_raw_sys::general::F_SEAL_GROW; /// `F_SEAL_WRITE`. const WRITE = linux_raw_sys::general::F_SEAL_WRITE; /// `F_SEAL_FUTURE_WRITE` (since Linux 5.1) const FUTURE_WRITE = linux_raw_sys::general::F_SEAL_FUTURE_WRITE; } } bitflags! { /// `STATX_*` constants for use with [`statx`]. /// /// [`statx`]: crate::fs::statx #[repr(transparent)] #[derive(Copy, Clone, Eq, PartialEq, Hash, Debug)] pub struct StatxFlags: u32 { /// `STATX_TYPE` const TYPE = linux_raw_sys::general::STATX_TYPE; /// `STATX_MODE` const MODE = linux_raw_sys::general::STATX_MODE; /// `STATX_NLINK` const NLINK = linux_raw_sys::general::STATX_NLINK; /// `STATX_UID` const UID = linux_raw_sys::general::STATX_UID; /// `STATX_GID` const GID = linux_raw_sys::general::STATX_GID; /// `STATX_ATIME` const ATIME = linux_raw_sys::general::STATX_ATIME; /// `STATX_MTIME` const MTIME = linux_raw_sys::general::STATX_MTIME; /// `STATX_CTIME` const CTIME = linux_raw_sys::general::STATX_CTIME; /// `STATX_INO` const INO = linux_raw_sys::general::STATX_INO; /// `STATX_SIZE` const SIZE = linux_raw_sys::general::STATX_SIZE; /// `STATX_BLOCKS` const BLOCKS = linux_raw_sys::general::STATX_BLOCKS; /// `STATX_BASIC_STATS` const BASIC_STATS = linux_raw_sys::general::STATX_BASIC_STATS; /// `STATX_BTIME` const BTIME = linux_raw_sys::general::STATX_BTIME; /// `STATX_MNT_ID` (since Linux 5.8) const MNT_ID = linux_raw_sys::general::STATX_MNT_ID; /// `STATX_DIOALIGN` (since Linux 6.1) const DIOALIGN = linux_raw_sys::general::STATX_DIOALIGN; /// `STATX_ALL` const ALL = linux_raw_sys::general::STATX_ALL; } } bitflags! { /// `FALLOC_FL_*` constants for use with [`fallocate`]. /// /// [`fallocate`]: crate::fs::fallocate #[repr(transparent)] #[derive(Copy, Clone, Eq, PartialEq, Hash, Debug)] pub struct FallocateFlags: u32 { /// `FALLOC_FL_KEEP_SIZE` const KEEP_SIZE = linux_raw_sys::general::FALLOC_FL_KEEP_SIZE; /// `FALLOC_FL_PUNCH_HOLE` const PUNCH_HOLE = linux_raw_sys::general::FALLOC_FL_PUNCH_HOLE; /// `FALLOC_FL_NO_HIDE_STALE` const NO_HIDE_STALE = linux_raw_sys::general::FALLOC_FL_NO_HIDE_STALE; /// `FALLOC_FL_COLLAPSE_RANGE` const COLLAPSE_RANGE = linux_raw_sys::general::FALLOC_FL_COLLAPSE_RANGE; /// `FALLOC_FL_ZERO_RANGE` const ZERO_RANGE = linux_raw_sys::general::FALLOC_FL_ZERO_RANGE; /// `FALLOC_FL_INSERT_RANGE` const INSERT_RANGE = linux_raw_sys::general::FALLOC_FL_INSERT_RANGE; /// `FALLOC_FL_UNSHARE_RANGE` const UNSHARE_RANGE = linux_raw_sys::general::FALLOC_FL_UNSHARE_RANGE; } } bitflags! { /// `ST_*` constants for use with [`StatVfs`]. #[repr(transparent)] #[derive(Copy, Clone, Eq, PartialEq, Hash, Debug)] pub struct StatVfsMountFlags: u64 { /// `ST_MANDLOCK` const MANDLOCK = linux_raw_sys::general::MS_MANDLOCK as u64; /// `ST_NOATIME` const NOATIME = linux_raw_sys::general::MS_NOATIME as u64; /// `ST_NODEV` const NODEV = linux_raw_sys::general::MS_NODEV as u64; /// `ST_NODIRATIME` const NODIRATIME = linux_raw_sys::general::MS_NODIRATIME as u64; /// `ST_NOEXEC` const NOEXEC = linux_raw_sys::general::MS_NOEXEC as u64; /// `ST_NOSUID` const NOSUID = linux_raw_sys::general::MS_NOSUID as u64; /// `ST_RDONLY` const RDONLY = linux_raw_sys::general::MS_RDONLY as u64; /// `ST_RELATIME` const RELATIME = linux_raw_sys::general::MS_RELATIME as u64; /// `ST_SYNCHRONOUS` const SYNCHRONOUS = linux_raw_sys::general::MS_SYNCHRONOUS as u64; } } /// `LOCK_*` constants for use with [`flock`] and [`fcntl_lock`]. /// /// [`flock`]: crate::fs::flock /// [`fcntl_lock`]: crate::fs::fcntl_lock #[derive(Clone, Copy, Debug, PartialEq, Eq)] #[repr(u32)] pub enum FlockOperation { /// `LOCK_SH` LockShared = linux_raw_sys::general::LOCK_SH, /// `LOCK_EX` LockExclusive = linux_raw_sys::general::LOCK_EX, /// `LOCK_UN` Unlock = linux_raw_sys::general::LOCK_UN, /// `LOCK_SH | LOCK_NB` NonBlockingLockShared = linux_raw_sys::general::LOCK_SH | linux_raw_sys::general::LOCK_NB, /// `LOCK_EX | LOCK_NB` NonBlockingLockExclusive = linux_raw_sys::general::LOCK_EX | linux_raw_sys::general::LOCK_NB, /// `LOCK_UN | LOCK_NB` NonBlockingUnlock = linux_raw_sys::general::LOCK_UN | linux_raw_sys::general::LOCK_NB, } /// `struct stat` for use with [`statat`] and [`fstat`]. /// /// [`statat`]: crate::fs::statat /// [`fstat`]: crate::fs::fstat // On 32-bit, and mips64, Linux's `struct stat64` has a 32-bit `st_mtime` and // friends, so we use our own struct, populated from `statx` where possible, to // avoid the y2038 bug. #[cfg(any( target_pointer_width = "32", target_arch = "mips64", target_arch = "mips64r6" ))] #[repr(C)] #[derive(Debug, Copy, Clone)] #[allow(missing_docs)] pub struct Stat { pub st_dev: u64, pub st_mode: u32, pub st_nlink: u32, pub st_uid: u32, pub st_gid: u32, pub st_rdev: u64, pub st_size: i64, pub st_blksize: u32, pub st_blocks: u64, pub st_atime: u64, pub st_atime_nsec: u32, pub st_mtime: u64, pub st_mtime_nsec: u32, pub st_ctime: u64, pub st_ctime_nsec: u32, pub st_ino: u64, } /// `struct stat` for use with [`statat`] and [`fstat`]. /// /// [`statat`]: crate::fs::statat /// [`fstat`]: crate::fs::fstat #[cfg(all( target_pointer_width = "64", not(target_arch = "mips64"), not(target_arch = "mips64r6") ))] pub type Stat = linux_raw_sys::general::stat; /// `struct statfs` for use with [`statfs`] and [`fstatfs`]. /// /// [`statfs`]: crate::fs::statfs /// [`fstatfs`]: crate::fs::fstatfs #[allow(clippy::module_name_repetitions)] pub type StatFs = linux_raw_sys::general::statfs64; /// `struct statvfs` for use with [`statvfs`] and [`fstatvfs`]. /// /// [`statvfs`]: crate::fs::statvfs /// [`fstatvfs`]: crate::fs::fstatvfs #[allow(missing_docs)] pub struct StatVfs { pub f_bsize: u64, pub f_frsize: u64, pub f_blocks: u64, pub f_bfree: u64, pub f_bavail: u64, pub f_files: u64, pub f_ffree: u64, pub f_favail: u64, pub f_fsid: u64, pub f_flag: StatVfsMountFlags, pub f_namemax: u64, } /// `struct statx` for use with [`statx`]. /// /// [`statx`]: crate::fs::statx pub type Statx = linux_raw_sys::general::statx; /// `struct statx_timestamp` for use with [`Statx`]. pub type StatxTimestamp = linux_raw_sys::general::statx_timestamp; /// `mode_t` #[cfg(not(any( target_arch = "x86", target_arch = "sparc", target_arch = "avr", target_arch = "arm", )))] pub type RawMode = linux_raw_sys::general::__kernel_mode_t; /// `mode_t` #[cfg(any( target_arch = "x86", target_arch = "sparc", target_arch = "avr", target_arch = "arm", ))] // Don't use `__kernel_mode_t` since it's `u16` which differs from `st_size`. pub type RawMode = c::c_uint; /// `dev_t` // Within the kernel the dev_t is 32-bit, but userspace uses a 64-bit field. pub type Dev = u64; /// `__fsword_t` #[cfg(not(any(target_arch = "mips64", target_arch = "mips64r6")))] pub type FsWord = linux_raw_sys::general::__fsword_t; /// `__fsword_t` #[cfg(any(target_arch = "mips64", target_arch = "mips64r6"))] pub type FsWord = i64;
use std::net::{TcpListener, TcpStream}; use std::io::{ Write, BufReader, BufRead}; fn handle_connection(mut stream: TcpStream){ let mut s = String::new(); println!("[*] Connection received: {:?}", stream); let stream_clone = match stream.try_clone(){ Ok(s) => s, Err(_) => return }; let mut reader = BufReader::new(stream_clone); loop { s.clear(); let _ = stream.write_all(b"> "); let len_recv = reader.read_line(&mut s); match len_recv { Ok(l) => if l <= 0 { break } , Err(_) => break } println!("[*] Received: {}", s.trim()); if s.trim() == "exit"{ break; } } let _ = stream.write_all(b"Goodbye!"); println!("[*] Ending connection"); } fn main() { let listen = TcpListener::bind("0.0.0.0:9999"); let listen = match listen { Ok(listen) => listen, Err(_) => panic!("Error establishing listener") }; for stream in listen.incoming(){ if let Ok(s) = stream { handle_connection(s); } } }
// Copyright 2018 The Rust Project Developers. See the COPYRIGHT // file at the top-level directory of this distribution and at // http://rust-lang.org/COPYRIGHT. // // Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or // http://www.apache.org/licenses/LICENSE-2.0> or the MIT license // <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your // option. This file may not be copied, modified, or distributed // except according to those terms. use num::NonZeroUsize; use super::waitqueue::{WaitVariable, WaitQueue, SpinMutex, NotifiedTcs, try_lock_or_false}; pub struct RWLock { readers: SpinMutex<WaitVariable<Option<NonZeroUsize>>>, writer: SpinMutex<WaitVariable<bool>>, } //unsafe impl Send for RWLock {} //unsafe impl Sync for RWLock {} // FIXME impl RWLock { pub const fn new() -> RWLock { RWLock { readers: SpinMutex::new(WaitVariable::new(None)), writer: SpinMutex::new(WaitVariable::new(false)) } } #[inline] pub unsafe fn read(&self) { let mut rguard = self.readers.lock(); let wguard = self.writer.lock(); if *wguard.lock_var() || !wguard.queue_empty() { // Another thread has or is waiting for the write lock, wait drop(wguard); WaitQueue::wait(rguard); // Another thread has passed the lock to us } else { // No waiting writers, acquire the read lock *rguard.lock_var_mut() = NonZeroUsize::new(rguard.lock_var().map_or(0, |n| n.get()) + 1); } } #[inline] pub unsafe fn try_read(&self) -> bool { let mut rguard = try_lock_or_false!(self.readers); let wguard = try_lock_or_false!(self.writer); if *wguard.lock_var() || !wguard.queue_empty() { // Another thread has or is waiting for the write lock false } else { // No waiting writers, acquire the read lock *rguard.lock_var_mut() = NonZeroUsize::new(rguard.lock_var().map_or(0, |n| n.get()) + 1); true } } #[inline] pub unsafe fn write(&self) { let rguard = self.readers.lock(); let mut wguard = self.writer.lock(); if *wguard.lock_var() || rguard.lock_var().is_some() { // Another thread has the lock, wait drop(rguard); WaitQueue::wait(wguard); // Another thread has passed the lock to us } else { // We are just now obtaining the lock *wguard.lock_var_mut() = true; } } #[inline] pub unsafe fn try_write(&self) -> bool { let rguard = try_lock_or_false!(self.readers); let mut wguard = try_lock_or_false!(self.writer); if *wguard.lock_var() || rguard.lock_var().is_some() { // Another thread has the lock false } else { // We are just now obtaining the lock *wguard.lock_var_mut() = true; true } } #[inline] pub unsafe fn read_unlock(&self) { let mut rguard = self.readers.lock(); let wguard = self.writer.lock(); *rguard.lock_var_mut() = NonZeroUsize::new(rguard.lock_var().unwrap().get() - 1); if rguard.lock_var().is_some() { // There are other active readers } else { if let Ok(mut wguard) = WaitQueue::notify_one(wguard) { // A writer was waiting, pass the lock *wguard.lock_var_mut() = true; } else { // No writers were waiting, the lock is released assert!(rguard.queue_empty()); } } } #[inline] pub unsafe fn write_unlock(&self) { let rguard = self.readers.lock(); let wguard = self.writer.lock(); if let Err(mut wguard) = WaitQueue::notify_one(wguard) { // No writers waiting, release the write lock *wguard.lock_var_mut() = false; if let Ok(mut rguard) = WaitQueue::notify_all(rguard) { // One or more readers were waiting, pass the lock to them if let NotifiedTcs::All { count } = rguard.notified_tcs() { *rguard.lock_var_mut() = Some(count) } else { unreachable!() // called notify_all } } else { // No readers waiting, the lock is released } } else { // There was a thread waiting for write, just pass the lock } } #[inline] pub unsafe fn destroy(&self) {} }
use crate::load_function_ptrs; use crate::prelude::*; use std::os::raw::c_void; load_function_ptrs!(DeviceFunctions, { vkDestroyDevice(device: VkDevice, pAllocator: *const VkAllocationCallbacks) -> (), vkGetDeviceQueue( device: VkDevice, queueFamilyIndex: u32, queueIndex: u32, pQueue: *mut VkQueue ) -> (), vkWaitForFences( device: VkDevice, fenceCount: u32, pFences: *const VkFence, waitAll: VkBool32, timeout: u64 ) -> VkResult, vkGetQueryPoolResults( device: VkDevice, queryPool: VkQueryPool, firstQuery: u32, queryCount: u32, dataSize: usize, pData: *mut c_void, stride: VkDeviceSize, flags: VkQueryResultFlagBits ) -> VkResult, // Queue vkQueueSubmit( queue: VkQueue, submitCount: u32, pSubmits: *const VkSubmitInfo, fence: VkFence ) -> VkResult, vkQueueWaitIdle(queue: VkQueue) -> VkResult, // buffer vkCreateBuffer( device: VkDevice, pCreateInfo: *const VkBufferCreateInfo, pAllocator: *const VkAllocationCallbacks, pBuffer: *mut VkBuffer ) -> VkResult, vkDestroyBuffer( device: VkDevice, buffer: VkBuffer, pAllocator: *const VkAllocationCallbacks ) -> (), vkGetBufferMemoryRequirements( device: VkDevice, buffer: VkBuffer, pMemoryRequirements: *mut VkMemoryRequirements ) -> (), // memory vkAllocateMemory( device: VkDevice, pAllocateInfo: *const VkMemoryAllocateInfo, pAllocator: *const VkAllocationCallbacks, pMemory: *mut VkDeviceMemory ) -> VkResult, vkFreeMemory( device: VkDevice, memory: VkDeviceMemory, pAllocator: *const VkAllocationCallbacks ) -> (), vkMapMemory( device: VkDevice, memory: VkDeviceMemory, offset: VkDeviceSize, size: VkDeviceSize, flags: VkMemoryMapFlags, ppData: *mut *mut c_void ) -> VkResult, vkUnmapMemory(device: VkDevice, memory: VkDeviceMemory) -> (), vkBindBufferMemory( device: VkDevice, buffer: VkBuffer, memory: VkDeviceMemory, memoryOffset: VkDeviceSize ) -> VkResult, // render pass vkCreateRenderPass( device: VkDevice, pCreateInfo: *const VkRenderPassCreateInfo, pAllocator: *const VkAllocationCallbacks, pRenderPass: *mut VkRenderPass ) -> VkResult, vkDestroyRenderPass( device: VkDevice, renderPass: VkRenderPass, pAllocator: *const VkAllocationCallbacks ) -> (), // image vkCreateImage( device: VkDevice, pCreateInfo: *const VkImageCreateInfo, pAllocator: *const VkAllocationCallbacks, pImage: *mut VkImage ) -> VkResult, vkDestroyImage( device: VkDevice, image: VkImage, pAllocator: *const VkAllocationCallbacks ) -> (), vkGetImageSubresourceLayout( device: VkDevice, image: VkImage, pSubresource: *const VkImageSubresource, pLayout: *mut VkSubresourceLayout ) -> (), vkCreateImageView( device: VkDevice, pCreateInfo: *const VkImageViewCreateInfo, pAllocator: *const VkAllocationCallbacks, pView: *mut VkImageView ) -> VkResult, vkDestroyImageView( device: VkDevice, imageView: VkImageView, pAllocator: *const VkAllocationCallbacks ) -> (), vkGetImageMemoryRequirements( device: VkDevice, image: VkImage, pMemoryRequirements: *mut VkMemoryRequirements ) -> (), vkGetImageSparseMemoryRequirements( device: VkDevice, image: VkImage, pSparseMemoryRequirementCount: *mut u32, pSparseMemoryRequirements: *mut VkSparseImageMemoryRequirements ) -> (), vkBindImageMemory( device: VkDevice, image: VkImage, memory: VkDeviceMemory, memoryOffset: VkDeviceSize ) -> VkResult, vkCreateSampler( device: VkDevice, pCreateInfo: *const VkSamplerCreateInfo, pAllocator: *const VkAllocationCallbacks, pSampler: *mut VkSampler ) -> VkResult, vkDestroySampler( device: VkDevice, sampler: VkSampler, pAllocator: *const VkAllocationCallbacks ) -> (), // buffer view vkCreateBufferView( device: VkDevice, pCreateInfo: *const VkBufferViewCreateInfo, pAllocator: *const VkAllocationCallbacks, pView: *mut VkBufferView ) -> VkResult, vkDestroyBufferView( device: VkDevice, bufferView: VkBufferView, pAllocator: *const VkAllocationCallbacks ) -> (), // fence vkCreateFence( device: VkDevice, pCreateInfo: *const VkFenceCreateInfo, pAllocator: *const VkAllocationCallbacks, pFence: *mut VkFence ) -> VkResult, vkDestroyFence( device: VkDevice, fence: VkFence, pAllocator: *const VkAllocationCallbacks ) -> (), vkResetFences(device: VkDevice, fenceCount: u32, pFences: *const VkFence) -> VkResult, // semaphore vkCreateSemaphore( device: VkDevice, pCreateInfo: *const VkSemaphoreCreateInfo, pAllocator: *const VkAllocationCallbacks, pSemaphore: *mut VkSemaphore ) -> VkResult, vkDestroySemaphore( device: VkDevice, semaphore: VkSemaphore, pAllocator: *const VkAllocationCallbacks ) -> (), // shadermodule vkCreateShaderModule( device: VkDevice, pCreateInfo: *const VkShaderModuleCreateInfo, pAllocator: *const VkAllocationCallbacks, pShaderModule: *mut VkShaderModule ) -> VkResult, vkDestroyShaderModule( device: VkDevice, shaderModule: VkShaderModule, pAllocator: *const VkAllocationCallbacks ) -> (), // descriptor pool vkCreateDescriptorPool( device: VkDevice, pCreateInfo: *const VkDescriptorPoolCreateInfo, pAllocator: *const VkAllocationCallbacks, pDescriptorPool: *mut VkDescriptorPool ) -> VkResult, vkDestroyDescriptorPool( device: VkDevice, descriptorPool: VkDescriptorPool, pAllocator: *const VkAllocationCallbacks ) -> (), vkResetDescriptorPool( device: VkDevice, descriptorPool: VkDescriptorPool, flags: VkDescriptorPoolResetFlags ) -> VkResult, // descriptor set layout vkCreateDescriptorSetLayout( device: VkDevice, pCreateInfo: *const VkDescriptorSetLayoutCreateInfo, pAllocator: *const VkAllocationCallbacks, pSetLayout: *mut VkDescriptorSetLayout ) -> VkResult, vkDestroyDescriptorSetLayout( device: VkDevice, descriptorSetLayout: VkDescriptorSetLayout, pAllocator: *const VkAllocationCallbacks ) -> (), // descriptor set vkAllocateDescriptorSets( device: VkDevice, pAllocateInfo: *const VkDescriptorSetAllocateInfo<'_>, pDescriptorSets: *mut VkDescriptorSet ) -> VkResult, vkFreeDescriptorSets( device: VkDevice, descriptorPool: VkDescriptorPool, descriptorSetCount: u32, pDescriptorSets: *const VkDescriptorSet ) -> VkResult, vkUpdateDescriptorSets( device: VkDevice, descriptorWriteCount: u32, pDescriptorWrites: *const VkWriteDescriptorSet, descriptorCopyCount: u32, pDescriptorCopies: *const VkCopyDescriptorSet ) -> (), // event vkCreateEvent( device: VkDevice, pCreateInfo: *const VkEventCreateInfo, pAllocator: *const VkAllocationCallbacks, pEvent: *mut VkEvent ) -> VkResult, vkDestroyEvent( device: VkDevice, event: VkEvent, pAllocator: *const VkAllocationCallbacks ) ->(), vkGetEventStatus(device: VkDevice, event: VkEvent) -> VkResult, vkSetEvent(device: VkDevice, event: VkEvent) -> VkResult, vkResetEvent(device: VkDevice, event: VkEvent) -> VkResult, // command pool vkCreateCommandPool( device: VkDevice, pCreateInfo: *const VkCommandPoolCreateInfo, pAllocator: *const VkAllocationCallbacks, pCommandPool: *mut VkCommandPool ) -> VkResult, vkDestroyCommandPool( device: VkDevice, commandPool: VkCommandPool, pAllocator: *const VkAllocationCallbacks ) -> (), vkResetCommandPool( device: VkDevice, commandPool: VkCommandPool, flags: VkCommandPoolResetFlags ) -> VkResult, vkTrimCommandPool( device: VkDevice, commandPool: VkCommandPool, flags: VkCommandPoolTrimFlags ) -> (), // framebuffer vkCreateFramebuffer( device: VkDevice, pCreateInfo: *const VkFramebufferCreateInfo, pAllocator: *const VkAllocationCallbacks, pFramebuffer: *mut VkFramebuffer ) -> VkResult, vkDestroyFramebuffer( device: VkDevice, framebuffer: VkFramebuffer, pAllocator: *const VkAllocationCallbacks ) -> (), // command buffer vkAllocateCommandBuffers( device: VkDevice, pAllocateInfo: *const VkCommandBufferAllocateInfo, pCommandBuffers: *mut VkCommandBuffer ) -> VkResult, vkFreeCommandBuffers( device: VkDevice, commandPool: VkCommandPool, commandBufferCount: u32, pCommandBuffers: *const VkCommandBuffer ) -> (), vkBeginCommandBuffer( commandBuffer: VkCommandBuffer, pBeginInfo: *const VkCommandBufferBeginInfo ) -> VkResult, vkEndCommandBuffer(commandBuffer: VkCommandBuffer) -> VkResult, vkResetCommandBuffer( commandBuffer: VkCommandBuffer, flags: VkCommandBufferResetFlagBits ) -> VkResult, vkCmdBindPipeline( commandBuffer: VkCommandBuffer, pipelineBindPoint: VkPipelineBindPoint, pipeline: VkPipeline ) -> (), vkCmdSetViewport( commandBuffer: VkCommandBuffer, firstViewport: u32, viewportCount: u32, pViewports: *const VkViewport ) -> (), vkCmdSetScissor( commandBuffer: VkCommandBuffer, firstScissor: u32, scissorCount: u32, pScissors: *const VkRect2D ) -> (), vkCmdSetLineWidth(commandBuffer: VkCommandBuffer, lineWidth: f32) -> (), vkCmdSetDepthBias( commandBuffer: VkCommandBuffer, depthBiasConstantFactor: f32, depthBiasClamp: f32, depthBiasSlopeFactor: f32 ) -> (), vkCmdSetBlendConstants(commandBuffer: VkCommandBuffer, blendConstants: [f32; 4]) -> (), vkCmdSetDepthBounds( commandBuffer: VkCommandBuffer, minDepthBounds: f32, maxDepthBounds: f32 ) -> (), vkCmdSetStencilCompareMask( commandBuffer: VkCommandBuffer, faceMask: VkStencilFaceFlags, compareMask: u32 ) -> (), vkCmdSetStencilWriteMask( commandBuffer: VkCommandBuffer, faceMask: VkStencilFaceFlags, writeMask: u32 ) -> (), vkCmdSetStencilReference( commandBuffer: VkCommandBuffer, faceMask: VkStencilFaceFlags, reference: u32 ) -> (), vkCmdBindDescriptorSets( commandBuffer: VkCommandBuffer, pipelineBindPoint: VkPipelineBindPoint, layout: VkPipelineLayout, firstSet: u32, descriptorSetCount: u32, pDescriptorSets: *const VkDescriptorSet, dynamicOffsetCount: u32, pDynamicOffsets: *const u32 ) -> (), vkCmdBindIndexBuffer( commandBuffer: VkCommandBuffer, buffer: VkBuffer, offset: VkDeviceSize, indexType: VkIndexType ) -> (), vkCmdBindVertexBuffers( commandBuffer: VkCommandBuffer, firstBinding: u32, bindingCount: u32, pBuffers: *const VkBuffer, pOffsets: *const VkDeviceSize ) -> (), vkCmdDraw( commandBuffer: VkCommandBuffer, vertexCount: u32, instanceCount: u32, firstVertex: u32, firstInstance: u32 ) -> (), vkCmdDrawIndexed( commandBuffer: VkCommandBuffer, indexCount: u32, instanceCount: u32, firstIndex: u32, vertexOffset: i32, firstInstance: u32 ) -> (), vkCmdDrawIndirect( commandBuffer: VkCommandBuffer, buffer: VkBuffer, offset: VkDeviceSize, drawCount: u32, stride: u32 ) -> (), vkCmdDrawIndexedIndirect( commandBuffer: VkCommandBuffer, buffer: VkBuffer, offset: VkDeviceSize, drawCount: u32, stride: u32 ) -> (), vkCmdDispatch(commandBuffer: VkCommandBuffer, x: u32, y: u32, z: u32) -> (), vkCmdDispatchIndirect( commandBuffer: VkCommandBuffer, buffer: VkBuffer, offset: VkDeviceSize ) -> (), vkCmdCopyBuffer( commandBuffer: VkCommandBuffer, srcBuffer: VkBuffer, dstBuffer: VkBuffer, regionCount: u32, pRegions: *const VkBufferCopy ) -> (), vkCmdCopyImage( commandBuffer: VkCommandBuffer, srcImage: VkImage, srcImageLayout: VkImageLayout, dstImage: VkImage, dstImageLayout: VkImageLayout, regionCount: u32, pRegions: *const VkImageCopy ) -> (), vkCmdBlitImage( commandBuffer: VkCommandBuffer, srcImage: VkImage, srcImageLayout: VkImageLayout, dstImage: VkImage, dstImageLayout: VkImageLayout, regionCount: u32, pRegions: *const VkImageBlit, filter: VkFilter ) -> (), vkCmdCopyBufferToImage( commandBuffer: VkCommandBuffer, srcBuffer: VkBuffer, dstImage: VkImage, dstImageLayout: VkImageLayout, regionCount: u32, pRegions: *const VkBufferImageCopy ) -> (), vkCmdCopyImageToBuffer( commandBuffer: VkCommandBuffer, srcImage: VkImage, srcImageLayout: VkImageLayout, dstBuffer: VkBuffer, regionCount: u32, pRegions: *const VkBufferImageCopy ) -> (), vkCmdUpdateBuffer( commandBuffer: VkCommandBuffer, dstBuffer: VkBuffer, dstOffset: VkDeviceSize, dataSize: VkDeviceSize, pData: *const u32 ) -> (), vkCmdFillBuffer( commandBuffer: VkCommandBuffer, dstBuffer: VkBuffer, dstOffset: VkDeviceSize, size: VkDeviceSize, data: u32 ) -> (), vkCmdClearColorImage( commandBuffer: VkCommandBuffer, image: VkImage, imageLayout: VkImageLayout, pColor: *const VkClearColorValue, rangeCount: u32, pRanges: *const VkImageSubresourceRange ) -> (), vkCmdClearDepthStencilImage( commandBuffer: VkCommandBuffer, image: VkImage, imageLayout: VkImageLayout, pDepthStencil: *const VkClearDepthStencilValue, rangeCount: u32, pRanges: *const VkImageSubresourceRange ) -> (), vkCmdClearAttachments( commandBuffer: VkCommandBuffer, attachmentCount: u32, pAttachments: *const VkClearAttachment, VkRectCount: u32, pRects: *const VkClearRect ) -> (), vkCmdResolveImage( commandBuffer: VkCommandBuffer, srcImage: VkImage, srcImageLayout: VkImageLayout, dstImage: VkImage, dstImageLayout: VkImageLayout, regionCount: u32, pRegions: *const VkImageResolve ) -> (), vkCmdSetEvent( commandBuffer: VkCommandBuffer, event: VkEvent, stageMask: VkPipelineStageFlags ) -> (), vkCmdResetEvent( commandBuffer: VkCommandBuffer, event: VkEvent, stageMask: VkPipelineStageFlags ) -> (), vkCmdWaitEvents( commandBuffer: VkCommandBuffer, eventCount: u32, pEvents: *const VkEvent, srcStageMask: VkPipelineStageFlags, dstStageMask: VkPipelineStageFlags, memoryBarrierCount: u32, pMemoryBarriers: *const VkMemoryBarrier, bufferMemoryBarrierCount: u32, pBufferMemoryBarriers: *const VkBufferMemoryBarrier, imageMemoryBarrierCount: u32, pImageMemoryBarriers: *const VkImageMemoryBarrier ) -> (), vkCmdPipelineBarrier( commandBuffer: VkCommandBuffer, srcStageMask: VkPipelineStageFlagBits, dstStageMask: VkPipelineStageFlagBits, dependencyFlags: VkDependencyFlagBits, memoryBarrierCount: u32, pMemoryBarriers: *const VkMemoryBarrier, bufferMemoryBarrierCount: u32, pBufferMemoryBarriers: *const VkBufferMemoryBarrier, imageMemoryBarrierCount: u32, pImageMemoryBarriers: *const VkImageMemoryBarrier ) -> (), vkCmdBeginQuery( commandBuffer: VkCommandBuffer, queryPool: VkQueryPool, query: u32, flags: VkQueryControlFlagBits ) -> (), vkCmdEndQuery(commandBuffer: VkCommandBuffer, queryPool: VkQueryPool, query: u32) -> (), vkCmdResetQueryPool( commandBuffer: VkCommandBuffer, queryPool: VkQueryPool, firstQuery: u32, queryCount: u32 ) -> (), vkCmdWriteTimestamp( commandBuffer: VkCommandBuffer, pipelineStage: VkPipelineStageFlagBits, queryPool: VkQueryPool, query: u32 ) -> (), vkCmdCopyQueryPoolResults( commandBuffer: VkCommandBuffer, queryPool: VkQueryPool, firstQuery: u32, queryCount: u32, dstBuffer: VkBuffer, dstOffset: VkDeviceSize, stride: VkDeviceSize, flags: VkQueryResultFlags ) -> (), vkCmdPushConstants( commandBuffer: VkCommandBuffer, layout: VkPipelineLayout, stageFlags: VkShaderStageFlagBits, offset: u32, size: u32, pValues: *const c_void ) -> (), vkCmdBeginRenderPass( commandBuffer: VkCommandBuffer, pRenderPassBegin: *const VkRenderPassBeginInfo, contents: VkSubpassContents ) -> (), vkCmdNextSubpass(commandBuffer: VkCommandBuffer, contents: VkSubpassContents) -> (), vkCmdEndRenderPass(commandBuffer: VkCommandBuffer) -> (), vkCmdExecuteCommands( commandBuffer: VkCommandBuffer, commandBufferCount: u32, pCommandBuffers: *const VkCommandBuffer ) -> (), // query pool vkCreateQueryPool( device: VkDevice, pCreateInfo: *const VkQueryPoolCreateInfo, pAllocator: *const VkAllocationCallbacks, pQueryPool: *mut VkQueryPool ) -> VkResult, vkDestroyQueryPool( device: VkDevice, queryPool: VkQueryPool, pAllocator: *const VkAllocationCallbacks ) -> (), // pipeline cache vkCreatePipelineCache( device: VkDevice, pCreateInfo: *const VkPipelineCacheCreateInfo, pAllocator: *const VkAllocationCallbacks, pPipelineCache: *mut VkPipelineCache ) -> VkResult, vkDestroyPipelineCache( device: VkDevice, pipelineCache: VkPipelineCache, pAllocator: *const VkAllocationCallbacks ) -> (), vkGetPipelineCacheData( device: VkDevice, pipelineCache: VkPipelineCache, pDataSize: *mut usize, pData: *mut c_void ) -> VkResult, vkMergePipelineCaches( device: VkDevice, dstCache: VkPipelineCache, srcCacheCount: u32, pSrcCaches: *const VkPipelineCache ) -> VkResult, // pipeline layout vkCreatePipelineLayout( device: VkDevice, pCreateInfo: *const VkPipelineLayoutCreateInfo, pAllocator: *const VkAllocationCallbacks, pPipelineLayout: *mut VkPipelineLayout ) -> VkResult, vkDestroyPipelineLayout( device: VkDevice, pipelineLayout: VkPipelineLayout, pAllocator: *const VkAllocationCallbacks ) -> (), // pipeline vkCreateGraphicsPipelines( device: VkDevice, pipelineCache: VkPipelineCache, createInfoCount: u32, pCreateInfos: *const VkGraphicsPipelineCreateInfo, pAllocator: *const VkAllocationCallbacks, pPipelines: *mut VkPipeline ) -> VkResult, vkCreateComputePipelines( device: VkDevice, pipelineCache: VkPipelineCache, createInfoCount: u32, pCreateInfos: *const VkComputePipelineCreateInfo, pAllocator: *const VkAllocationCallbacks, pPipelines: *mut VkPipeline ) -> VkResult, vkDestroyPipeline( device: VkDevice, pipeline: VkPipeline, pAllocator: *const VkAllocationCallbacks ) -> (), });
use std::ffi::{CStr, CString}; use std::os::raw::c_char; use function_parameter::FunctionParameter; use primitive_result::PrimitiveResult; use v8facade::{JavaScriptError, Output, V8Facade}; pub mod function_parameter; pub mod primitive_result; pub mod v8facade; #[repr(C)] #[derive(Debug)] pub struct Primitive { pub number_value: f64, pub number_value_set: bool, pub bigint_value: i64, pub bigint_value_set: bool, pub bool_value: bool, pub bool_value_set: bool, pub string_value: *mut c_char, pub symbol_value: *mut c_char, pub object_value: *mut c_char, } #[repr(C)] #[derive(Debug)] pub struct V8HeapStatistics { pub total_heap_size: usize, pub total_heap_size_executable: usize, pub total_physical_size: usize, pub total_available_size: usize, pub used_heap_size: usize, pub heap_size_limit: usize, pub malloced_memory: usize, pub does_zap_garbage: usize, pub number_of_native_contexts: usize, pub number_of_detached_contexts: usize, pub peak_malloced_memory: usize, pub used_global_handles_size: usize, pub total_global_handles_size: usize, } // http://jakegoulding.com/rust-ffi-omnibus/objects/ #[no_mangle] pub extern "C" fn get_v8() -> *mut V8Facade { Box::into_raw(Box::new(V8Facade::new())) } #[no_mangle] pub extern "C" fn free_v8(v8_facade_ptr: *mut V8Facade) { if v8_facade_ptr.is_null() { return; } unsafe { let v8_facade = Box::from_raw(v8_facade_ptr); let _ = v8_facade.shutdown().unwrap(); let _ = v8_facade.handle.join().unwrap(); } } #[no_mangle] pub unsafe extern "C" fn exec( v8_facade_ptr: *mut V8Facade, script: *const c_char, ) -> *mut PrimitiveResult { let script = CStr::from_ptr(script).to_string_lossy().into_owned(); let instance = { assert!(!v8_facade_ptr.is_null()); &mut *v8_facade_ptr }; let result = instance.run(script).unwrap(); PrimitiveResult::from_output(result).into_raw() } #[no_mangle] pub unsafe extern "C" fn begin_exec( v8_facade_ptr: *mut V8Facade, script: *const c_char, on_complete: extern "C" fn(*mut PrimitiveResult), ) { let script = CStr::from_ptr(script).to_string_lossy().into_owned(); let instance = { assert!(!v8_facade_ptr.is_null()); &mut *v8_facade_ptr }; instance .begin_run(script, move |output| { let result = PrimitiveResult::from_output(output); on_complete(result.into_raw()); }) .unwrap(); } #[no_mangle] pub unsafe extern "C" fn call( v8_facade_ptr: *mut V8Facade, func_name: *const c_char, parameters: *const Primitive, parameter_count: usize, ) -> *mut PrimitiveResult { let func_name = CStr::from_ptr(func_name).to_string_lossy().into_owned(); let parameters: &[Primitive] = std::slice::from_raw_parts(parameters, parameter_count); let parameters = parameters .iter() .map(|p| FunctionParameter::from(p)) .collect(); let instance = { assert!(!v8_facade_ptr.is_null()); &mut *v8_facade_ptr }; let result = match instance.call(func_name, parameters) { Ok(o) => o, Err(e) => Output::Error(JavaScriptError { exception: e, stack_trace: String::from(""), }), }; PrimitiveResult::from_output(result).into_raw() } #[no_mangle] pub unsafe extern "C" fn begin_call( v8_facade_ptr: *mut V8Facade, func_name: *const c_char, parameters: *const Primitive, parameter_count: usize, on_complete: extern "C" fn(*mut PrimitiveResult), ) { let func_name = CStr::from_ptr(func_name).to_string_lossy().into_owned(); let parameters: &[Primitive] = std::slice::from_raw_parts(parameters, parameter_count); let parameters = parameters .iter() .map(|p| FunctionParameter::from(p)) .collect(); let instance = { assert!(!v8_facade_ptr.is_null()); &mut *v8_facade_ptr }; instance .begin_call(func_name, parameters, move |output| { let result = PrimitiveResult::from_output(output); on_complete(result.into_raw()); }) .unwrap(); } #[no_mangle] pub unsafe extern "C" fn get_heap_statistics( v8_facade_ptr: *mut V8Facade, ) -> *mut V8HeapStatistics { let instance = { assert!(!v8_facade_ptr.is_null()); &mut *v8_facade_ptr }; let heap_stats = instance.get_heap_statistics().unwrap(); Box::into_raw(Box::new(heap_stats)) } #[no_mangle] pub unsafe extern "C" fn begin_get_heap_statistics( v8_facade_ptr: *mut V8Facade, on_complete: extern "C" fn(*mut V8HeapStatistics), ) { let instance = { assert!(!v8_facade_ptr.is_null()); &mut *v8_facade_ptr }; instance .begin_get_heap_statistics(move |s| { let result = Box::new(s); let result = Box::into_raw(result); on_complete(result); }) .unwrap(); } #[no_mangle] pub unsafe extern "C" fn free_string(string_ptr: *mut c_char) { if string_ptr.is_null() { return; } CString::from_raw(string_ptr); // This should be OK because the string that we are freeing was created "by Rust". } #[no_mangle] pub unsafe extern "C" fn free_primitive_result(primitive_result_ptr: *mut PrimitiveResult) { PrimitiveResult::free_raw(primitive_result_ptr); } #[no_mangle] pub unsafe extern "C" fn free_heap_stats(heap_stats_ptr: *mut V8HeapStatistics) { if !heap_stats_ptr.is_null() { Box::from_raw(heap_stats_ptr); } }
use std::io; // io module fn main() { let name = "Andrew"; let another_name = "Edcarla"; println!("{} and {}", name, another_name); let first = "Pascal".to_string(); say_name(&first); say_name(&first); // Reading user input let mut second_name = String::new(); println!("Enter your name: "); io::stdin().read_line(&mut second_name); // takes a mutable reference to the string buffer println!("Hello {}", second_name); } fn say_name(name: &String) { println!("{}", name); } fn sum()
use super::Specifier; use crate::hash::Hash; use crate::id::ManifestId; use crate::name::Name; #[derive(Clone, Debug, Eq, Hash, PartialEq)] pub struct ManifestSpec { name: Name, version: Option<String>, hash: Option<Hash>, } impl ManifestSpec { pub const fn new(name: Name, version: Option<String>, hash: Option<Hash>) -> Self { ManifestSpec { name, version, hash, } } #[inline] pub fn name(&self) -> &str { self.name.as_str() } #[inline] pub fn version(&self) -> Option<&String> { self.version.as_ref() } #[inline] pub fn hash(&self) -> Option<&Hash> { self.hash.as_ref() } } impl Specifier for ManifestSpec { type Id = ManifestId; fn matches(&self, id: &Self::Id) -> bool { let name_matches = self.name == id.name(); let version_matches = self .version .as_ref() .map(|ver| ver == id.version()) .unwrap_or(true); let hash_matches = self .hash .as_ref() .map(|hash| hash == id.hash()) .unwrap_or(true); name_matches && version_matches && hash_matches } }
// -*- rust -*- tag clam[T] { signed(int); unsigned(uint); } fn getclam[T]() -> clam[T] { ret signed[T](42); } obj impatience[T]() { fn moreclam() -> clam[T] { be getclam[T](); } } fn main() { }
use lib_package::government::public::power; fn main() { power(); }
use models::error::RuntimeError; use std::time::{Duration, Instant}; use tokio::prelude::*; use tokio_timer::Interval; pub fn new( basis: Instant, interval_millis: u64, ) -> impl Stream<Item = Instant, Error = RuntimeError> { Interval::new(basis, Duration::from_millis(interval_millis)) .map_err(|e| RuntimeError::Timer(Box::new(e))) }
use crate::opt::ConnectOpts; use anyhow::{bail, Context}; use console::style; use remove_dir_all::remove_dir_all; use sqlx::any::{AnyConnectOptions, AnyKind}; use sqlx::Connection; use std::collections::{BTreeMap, BTreeSet}; use std::fs::File; use std::io::{BufReader, BufWriter}; use std::path::{Path, PathBuf}; use std::process::Command; use std::str::FromStr; use std::{env, fs}; use crate::metadata::Metadata; type QueryData = BTreeMap<String, serde_json::Value>; type JsonObject = serde_json::Map<String, serde_json::Value>; #[derive(serde::Serialize, serde::Deserialize)] struct DataFile { db: String, #[serde(flatten)] data: QueryData, } pub async fn run( connect_opts: &ConnectOpts, merge: bool, cargo_args: Vec<String>, ) -> anyhow::Result<()> { // Ensure the database server is available. crate::connect(connect_opts).await?.close().await?; let url = &connect_opts.database_url; let db_kind = get_db_kind(url)?; let data = run_prepare_step(url, merge, cargo_args)?; if data.is_empty() { println!( "{} no queries found; please ensure that the `offline` feature is enabled in sqlx", style("warning:").yellow() ); } serde_json::to_writer_pretty( BufWriter::new( File::create("sqlx-data.json").context("failed to create/open `sqlx-data.json`")?, ), &DataFile { db: db_kind.to_owned(), data, }, ) .context("failed to write to `sqlx-data.json`")?; println!( "query data written to `sqlx-data.json` in the current directory; \ please check this into version control" ); Ok(()) } pub async fn check( connect_opts: &ConnectOpts, merge: bool, cargo_args: Vec<String>, ) -> anyhow::Result<()> { // Ensure the database server is available. crate::connect(connect_opts).await?.close().await?; let url = &connect_opts.database_url; let db_kind = get_db_kind(url)?; let data = run_prepare_step(url, merge, cargo_args)?; let data_file = File::open("sqlx-data.json").context( "failed to open `sqlx-data.json`; you may need to run `cargo sqlx prepare` first", )?; let DataFile { db: expected_db, data: saved_data, } = serde_json::from_reader(BufReader::new(data_file))?; if db_kind != expected_db { bail!( "saved prepare data is for {}, not {} (inferred from `DATABASE_URL`)", expected_db, db_kind ) } if data != saved_data { bail!("`cargo sqlx prepare` needs to be rerun") } Ok(()) } fn run_prepare_step(url: &str, merge: bool, cargo_args: Vec<String>) -> anyhow::Result<QueryData> { anyhow::ensure!( Path::new("Cargo.toml").exists(), r#"Failed to read `Cargo.toml`. hint: This command only works in the manifest directory of a Cargo package."# ); // path to the Cargo executable let cargo = env::var("CARGO") .context("`prepare` subcommand may only be invoked as `cargo sqlx prepare`")?; let output = Command::new(&cargo) .args(&["metadata", "--format-version=1"]) .output() .context("Could not fetch metadata")?; let output_str = std::str::from_utf8(&output.stdout).context("Invalid `cargo metadata` output")?; let metadata: Metadata = output_str.parse()?; // try removing the target/sqlx directory before running, as stale files // have repeatedly caused issues in the past. let _ = remove_dir_all(metadata.target_directory().join("sqlx")); // Try only triggering a recompile on crates that use `sqlx-macros`, falling back to a full // clean on error. match setup_minimal_project_recompile(&cargo, &metadata, merge) { Ok(()) => {} Err(err) => { println!( "Failed minimal recompile setup. Cleaning entire project. Err: {}", err ); let clean_status = Command::new(&cargo).arg("clean").status()?; if !clean_status.success() { bail!("`cargo clean` failed with status: {}", clean_status); } } }; // Compile the queries. let check_status = { let mut check_command = Command::new(&cargo); check_command .arg("check") .args(cargo_args) .env("SQLX_OFFLINE", "false") .env("DATABASE_URL", url); // `cargo check` recompiles on changed rust flags which can be set either via the env var // or through the `rustflags` field in `$CARGO_HOME/config` when the env var isn't set. // Because of this we only pass in `$RUSTFLAGS` when present. if let Ok(rustflags) = env::var("RUSTFLAGS") { check_command.env("RUSTFLAGS", rustflags); } check_command.status()? }; if !check_status.success() { bail!("`cargo check` failed with status: {}", check_status); } // Combine the queries into one file. let package_dir = if merge { // Merge queries from all workspace crates. "**" } else { // Use a separate sub-directory for each crate in a workspace. This avoids a race condition // where `prepare` can pull in queries from multiple crates if they happen to be generated // simultaneously (e.g. Rust Analyzer building in the background). metadata .current_package() .map(|pkg| pkg.name()) .context("Resolving the crate package for the current working directory failed")? }; let pattern = metadata .target_directory() .join("sqlx") .join(package_dir) .join("query-*.json"); let mut data = BTreeMap::new(); for path in glob::glob( pattern .to_str() .context("CARGO_TARGET_DIR not valid UTF-8")?, )? { let path = path?; let contents = fs::read(&*path)?; let mut query_data: JsonObject = serde_json::from_slice(&contents)?; // we lift the `hash` key to the outer map let hash = query_data .remove("hash") .context("expected key `hash` in query data")?; if let serde_json::Value::String(hash) = hash { data.insert(hash, serde_json::Value::Object(query_data)); } else { bail!( "expected key `hash` in query data to be string, was {:?} instead; file: {}", hash, path.display() ) } // lazily remove the file, we don't care too much if we can't let _ = fs::remove_file(&path); } Ok(data) } #[derive(Debug, PartialEq)] struct ProjectRecompileAction { // The names of the packages clean_packages: Vec<String>, touch_paths: Vec<PathBuf>, } /// Sets up recompiling only crates that depend on `sqlx-macros` /// /// This gets a listing of all crates that depend on `sqlx-macros` (direct and transitive). The /// crates within the current workspace have their source file's mtimes updated while crates /// outside the workspace are selectively `cargo clean -p`ed. In this way we can trigger a /// recompile of crates that may be using compile-time macros without forcing a full recompile. /// /// If `workspace` is false, only the current package will have its files' mtimes updated. fn setup_minimal_project_recompile( cargo: &str, metadata: &Metadata, workspace: bool, ) -> anyhow::Result<()> { let ProjectRecompileAction { clean_packages, touch_paths, } = if workspace { minimal_project_recompile_action(metadata)? } else { // Only touch the current crate. ProjectRecompileAction { clean_packages: Vec::new(), touch_paths: metadata.current_package().context("Failed to get package in current working directory, pass `--merged` if running from a workspace root")?.src_paths().to_vec(), } }; for file in touch_paths { let now = filetime::FileTime::now(); filetime::set_file_times(&file, now, now) .with_context(|| format!("Failed to update mtime for {:?}", file))?; } for pkg_id in &clean_packages { let clean_status = Command::new(cargo) .args(&["clean", "-p", pkg_id]) .status()?; if !clean_status.success() { bail!("`cargo clean -p {}` failed", pkg_id); } } Ok(()) } fn minimal_project_recompile_action(metadata: &Metadata) -> anyhow::Result<ProjectRecompileAction> { // Get all the packages that depend on `sqlx-macros` let mut sqlx_macros_dependents = BTreeSet::new(); let sqlx_macros_ids: BTreeSet<_> = metadata .entries() // We match just by name instead of name and url because some people may have it installed // through different means like vendoring .filter(|(_, package)| package.name() == "sqlx-macros") .map(|(id, _)| id) .collect(); for sqlx_macros_id in sqlx_macros_ids { sqlx_macros_dependents.extend(metadata.all_dependents_of(sqlx_macros_id)); } // Figure out which `sqlx-macros` dependents are in the workspace vs out let mut in_workspace_dependents = Vec::new(); let mut out_of_workspace_dependents = Vec::new(); for dependent in sqlx_macros_dependents { if metadata.workspace_members().contains(&dependent) { in_workspace_dependents.push(dependent); } else { out_of_workspace_dependents.push(dependent); } } // In-workspace dependents have their source file's mtime updated. Out-of-workspace get // `cargo clean -p <PKGID>`ed let files_to_touch: Vec<_> = in_workspace_dependents .iter() .filter_map(|id| { metadata .package(id) .map(|package| package.src_paths().to_owned()) }) .flatten() .collect(); let packages_to_clean: Vec<_> = out_of_workspace_dependents .iter() .filter_map(|id| { metadata .package(id) .map(|package| package.name().to_owned()) }) .collect(); Ok(ProjectRecompileAction { clean_packages: packages_to_clean, touch_paths: files_to_touch, }) } fn get_db_kind(url: &str) -> anyhow::Result<&'static str> { let options = AnyConnectOptions::from_str(&url)?; // these should match the values of `DatabaseExt::NAME` in `sqlx-macros` match options.kind() { #[cfg(feature = "postgres")] AnyKind::Postgres => Ok("PostgreSQL"), #[cfg(feature = "mysql")] AnyKind::MySql => Ok("MySQL"), #[cfg(feature = "sqlite")] AnyKind::Sqlite => Ok("SQLite"), #[cfg(feature = "mssql")] AnyKind::Mssql => Ok("MSSQL"), } } #[cfg(test)] mod tests { use super::*; use serde_json::json; use std::assert_eq; #[test] fn data_file_serialization_works() { let data_file = DataFile { db: "mysql".to_owned(), data: { let mut data = BTreeMap::new(); data.insert("a".to_owned(), json!({"key1": "value1"})); data.insert("z".to_owned(), json!({"key2": "value2"})); data }, }; let data_file = serde_json::to_string(&data_file).expect("Data file serialized."); assert_eq!( data_file, "{\"db\":\"mysql\",\"a\":{\"key1\":\"value1\"},\"z\":{\"key2\":\"value2\"}}" ); } #[test] fn data_file_deserialization_works() { let data_file = "{\"db\":\"mysql\",\"a\":{\"key1\":\"value1\"},\"z\":{\"key2\":\"value2\"}}"; let data_file: DataFile = serde_json::from_str(data_file).expect("Data file deserialized."); let DataFile { db, data } = data_file; assert_eq!(db, "mysql"); assert_eq!(data.len(), 2); assert_eq!(data.get("a"), Some(&json!({"key1": "value1"}))); assert_eq!(data.get("z"), Some(&json!({"key2": "value2"}))); } #[test] fn data_file_deserialization_works_for_ordered_keys() { let data_file = "{\"a\":{\"key1\":\"value1\"},\"db\":\"mysql\",\"z\":{\"key2\":\"value2\"}}"; let data_file: DataFile = serde_json::from_str(data_file).expect("Data file deserialized."); let DataFile { db, data } = data_file; assert_eq!(db, "mysql"); assert_eq!(data.len(), 2); assert_eq!(data.get("a"), Some(&json!({"key1": "value1"}))); assert_eq!(data.get("z"), Some(&json!({"key2": "value2"}))); } #[test] fn minimal_project_recompile_action_works() -> anyhow::Result<()> { let sample_metadata_path = Path::new("tests") .join("assets") .join("sample_metadata.json"); let sample_metadata = std::fs::read_to_string(sample_metadata_path)?; let metadata: Metadata = sample_metadata.parse()?; let action = minimal_project_recompile_action(&metadata)?; assert_eq!( action, ProjectRecompileAction { clean_packages: vec!["sqlx".into()], touch_paths: vec![ "/home/user/problematic/workspace/b_in_workspace_lib/src/lib.rs".into(), "/home/user/problematic/workspace/c_in_workspace_bin/src/main.rs".into(), ] } ); Ok(()) } }
use crate::res::*; use autopilot::bitmap::*; use autopilot::geometry::*; use autopilot::*; use std::thread::sleep; use std::time::Duration; fn stupid_screenshot() -> autopilot::bitmap::Bitmap { let screen = autopilot::bitmap::capture_screen().expect("Failed to capture screen"); screen.image.save(RES_PATH.join("screenshot.png")).unwrap(); Bitmap::new( image::open(RES_PATH.join("screenshot.png")) .expect("Can't open screen") .grayscale(), None, ) } pub fn shifted_point(point: &Point, (dx, dy): (f64, f64)) -> Point { Point::new(point.x + dx, point.y + dy) } pub fn move_to(point: &Point) { mouse::move_to(point.scaled(1.0 / screen::scale())).expect("Failed to move the mouse"); } pub fn tap_with_mod<T: key::KeyCodeConvertible + Copy>( key: &T, flags: &[key::Flag], delay_ms: u64, ) { key::toggle(key, true, flags, delay_ms); key::toggle(key, false, flags, delay_ms); } pub fn double_click(point: &Point) { move_to(point); mouse::click(mouse::Button::Left, None); std::thread::sleep(std::time::Duration::from_millis(100)); mouse::click(mouse::Button::Left, None); } pub fn click(point: &Point) { move_to(point); mouse::click(mouse::Button::Left, None); } pub fn search_for(needle: &Bitmap, rect: Option<Rect>, tries: u32) -> Option<Point> { let mut tries = tries.clone(); let screenshot = stupid_screenshot(); let mut location = screenshot.find_bitmap(needle, Some(0.05), rect, None); tries -= 1; while location == None && tries > 0 { sleep(Duration::from_millis(1000)); let screenshot = stupid_screenshot(); location = screenshot.find_bitmap(needle, Some(0.05), rect, None); tries -= 1; } location } pub fn search_till_disappear(needle: &Bitmap, rect: Option<Rect>, tries: u32) -> Option<Point> { let mut tries = tries.clone(); let screenshot = stupid_screenshot(); let mut location = screenshot.find_bitmap(needle, Some(0.05), rect, None); tries -= 1; while location.is_some() && tries > 0 { sleep(Duration::from_millis(1000)); let screenshot = stupid_screenshot(); location = screenshot.find_bitmap(needle, Some(0.05), rect, None); tries -= 1; } location }
use solana_program::instruction::InstructionError::Custom; use solana_sdk::transaction::TransactionError; use solana_program::{instruction::*, program_pack::Pack, pubkey::Pubkey, system_program, system_instruction, sysvar::rent}; use solana_program_test::*; use solana_sdk::{ account::Account, signature::{Keypair, Signer}, transaction::{Transaction}, }; use solanalotto::{processor::{Processor}, state::Lottery}; use assert_matches::assert_matches; #[tokio::test] async fn test_lottery_initialization() { let program_id = solanalotto::id(); let pt = ProgramTest::new( "solanalotto", program_id, processor!(Processor::process), ); let lottery_account_keypair = Keypair::new(); let lottery_account_pubkey = lottery_account_keypair.pubkey(); let (mut banks_client, payer, recent_blockhash) = pt.start().await; let rent = banks_client.get_rent().await.unwrap(); let lottery_account_rent = rent.minimum_balance(Lottery::LEN); let ticket_price = 10 * 10000000000; // 10 SOL let mut instruction_data = vec![0]; instruction_data.extend_from_slice(&payer.pubkey().to_bytes()); let mut transaction = Transaction::new_with_payer( &[ system_instruction::create_account(&payer.pubkey(), &lottery_account_pubkey, lottery_account_rent + ticket_price, Lottery::LEN as u64, &program_id), // Account is owned by lottery program and gets rent + ticket_price Instruction { program_id, accounts: vec![AccountMeta::new(lottery_account_pubkey, false), AccountMeta::new_readonly(rent::ID, false)], data: instruction_data, } ], Some(&payer.pubkey()), ); transaction.sign(&[&payer, &lottery_account_keypair], recent_blockhash); assert_matches!(banks_client.process_transaction(transaction).await, Ok(())); let lottery_account = banks_client.get_account(lottery_account_pubkey).await.unwrap().unwrap(); let lottery_info = Lottery::unpack_unchecked(&lottery_account.data).unwrap(); let mut expected_entrants = [Pubkey::default(); 5]; expected_entrants[0] = payer.pubkey(); assert_eq!(lottery_info.is_initialized, true); assert_eq!(lottery_info.initializer_pubkey, payer.pubkey()); assert_eq!(lottery_info.ticket_price, ticket_price); assert_eq!(lottery_info.entrants, expected_entrants); assert_eq!(lottery_account.lamports, lottery_account_rent + ticket_price); } #[tokio::test] async fn test_enter_lottery() { // Create lottery, then get ticket // TODO: Share code with above init test let program_id = solanalotto::id(); let mut pt = ProgramTest::new( "solanalotto", program_id, processor!(Processor::process), ); let ticket_price = 10 * 10000000000; // 10 SOL let lottery_account_keypair = Keypair::new(); let lottery_account_pubkey = lottery_account_keypair.pubkey(); let second_user_keypair = Keypair::new(); pt.add_account(second_user_keypair.pubkey(), Account {lamports: ticket_price * 2, ..Account::default()}); let third_user_keypair = Keypair::new(); let (mut banks_client, payer, recent_blockhash) = pt.start().await; let rent = banks_client.get_rent().await.unwrap(); let lottery_account_rent = rent.minimum_balance(Lottery::LEN); let mut instruction_data = vec![0]; instruction_data.extend_from_slice(&payer.pubkey().to_bytes()); let mut transaction = Transaction::new_with_payer( &[ system_instruction::create_account(&payer.pubkey(), &lottery_account_pubkey, lottery_account_rent + ticket_price, Lottery::LEN as u64, &program_id), // Account is owned by lottery program and gets rent + ticket_price Instruction { program_id, accounts: vec![AccountMeta::new(lottery_account_pubkey, false), AccountMeta::new_readonly(rent::ID, false)], data: instruction_data, } ], Some(&payer.pubkey()), ); transaction.sign(&[&payer, &lottery_account_keypair], recent_blockhash); assert_matches!(banks_client.process_transaction(transaction).await, Ok(())); // END of copy pasta let mut transaction = Transaction::new_with_payer( &[ Instruction { program_id, accounts: vec![ AccountMeta::new_readonly(second_user_keypair.pubkey(), true), AccountMeta::new(lottery_account_pubkey, false), AccountMeta::new(system_program::id(), false), ], data: vec![1], } ], Some(&second_user_keypair.pubkey()), ); let recent_blockhash = banks_client.get_recent_blockhash().await.unwrap(); transaction.sign(&[&second_user_keypair], recent_blockhash); assert_matches!(banks_client.process_transaction(transaction).await, Ok(())); let lottery_account = banks_client.get_account(lottery_account_pubkey).await.unwrap().unwrap(); let lottery_info = Lottery::unpack_unchecked(&lottery_account.data).unwrap(); let mut expected_entrants = [Pubkey::default(); 5]; expected_entrants[0] = payer.pubkey(); expected_entrants[1] = second_user_keypair.pubkey(); assert_eq!(lottery_info.is_initialized, true); assert_eq!(lottery_info.initializer_pubkey, payer.pubkey()); assert_eq!(lottery_info.ticket_price, ticket_price); assert_eq!(lottery_info.entrants, expected_entrants); assert_eq!(lottery_account.lamports, lottery_account_rent + 2 * ticket_price); // Fund third user with just not enough let mut transaction = Transaction::new_with_payer( &[system_instruction::create_account(&payer.pubkey(), &third_user_keypair.pubkey(), ticket_price - 1, 0, &system_program::id())], Some(&payer.pubkey()), ); let recent_blockhash = banks_client.get_recent_blockhash().await.unwrap(); transaction.sign(&[&payer, &third_user_keypair], recent_blockhash); banks_client.process_transaction(transaction).await.unwrap(); // Third user does not have at least ticket price let mut transaction = Transaction::new_with_payer( &[Instruction { program_id, accounts: vec![ AccountMeta::new_readonly(third_user_keypair.pubkey(), true), AccountMeta::new(lottery_account_pubkey, false), AccountMeta::new(system_program::id(), false) ], data: vec![1], }], Some(&payer.pubkey()), ); let recent_blockhash = banks_client.get_recent_blockhash().await.unwrap(); transaction.sign(&[&payer, &third_user_keypair], recent_blockhash); assert_eq!( banks_client.process_transaction(transaction).await.unwrap_err().unwrap(), TransactionError::InstructionError(0, Custom(1)) ); } #[tokio::test] async fn test_lottery_concludes() { // Last user enters and lottery ends transfering lamports to winner let program_id = solanalotto::id(); let mut pt = ProgramTest::new( "solanalotto", program_id, processor!(Processor::process), ); let ticket_price = 10 * 10000000000; // 10 SOL let lottery_account_keypair = Keypair::new(); let lottery_account_pubkey = lottery_account_keypair.pubkey(); let user_keypairs = [Keypair::new(), Keypair::new(), Keypair::new(), Keypair::new()]; for keypair in user_keypairs.iter() { pt.add_account(keypair.pubkey(), Account {lamports: ticket_price * 2, ..Account::default()}); } let (mut banks_client, payer, recent_blockhash) = pt.start().await; let rent = banks_client.get_rent().await.unwrap(); let lottery_account_rent = rent.minimum_balance(Lottery::LEN); let mut instruction_data = vec![0]; instruction_data.extend_from_slice(&payer.pubkey().to_bytes()); let mut transaction = Transaction::new_with_payer( &[ system_instruction::create_account(&payer.pubkey(), &lottery_account_pubkey, lottery_account_rent + ticket_price, Lottery::LEN as u64, &program_id), // Account is owned by lottery program and gets rent + ticket_price Instruction { program_id, accounts: vec![AccountMeta::new(lottery_account_pubkey, false), AccountMeta::new_readonly(rent::ID, false)], data: instruction_data, } ], Some(&payer.pubkey()), ); transaction.sign(&[&payer, &lottery_account_keypair], recent_blockhash); assert_matches!(banks_client.process_transaction(transaction).await, Ok(())); // Iterate 4 different payers, to send to lottery for keypair in user_keypairs.iter() { let mut transaction = Transaction::new_with_payer( &[ Instruction { program_id, accounts: vec![ AccountMeta::new_readonly(keypair.pubkey(), true), AccountMeta::new(lottery_account_pubkey, false), AccountMeta::new(system_program::id(), false), ], data: vec![1], } ], Some(&keypair.pubkey()), ); let recent_blockhash = banks_client.get_recent_blockhash().await.unwrap(); transaction.sign(&[keypair], recent_blockhash); assert_matches!(banks_client.process_transaction(transaction).await, Ok(())); } let lottery_account = banks_client.get_account(lottery_account_pubkey).await.unwrap().unwrap(); let lottery_info = Lottery::unpack_unchecked(&lottery_account.data).unwrap(); let winner_keypair = user_keypairs.iter() .find(|keypair| keypair.pubkey() == lottery_info.winner) .expect("Could not find winner in user keypairs"); // Winner gets his winnings let winner_account_lamports = banks_client.get_account(winner_keypair.pubkey()).await.unwrap().unwrap().lamports; let mut transaction = Transaction::new_with_payer( &[ Instruction { program_id, accounts: vec![ AccountMeta::new(winner_keypair.pubkey(), true), AccountMeta::new(lottery_account_pubkey, false), ], data: vec![2], } ], Some(&payer.pubkey()), ); let recent_blockhash = banks_client.get_recent_blockhash().await.unwrap(); transaction.sign(&[winner_keypair, &payer], recent_blockhash); assert_matches!(banks_client.process_transaction(transaction).await, Ok(())); let winner_account = banks_client.get_account(lottery_info.winner).await.unwrap().unwrap(); assert_eq!(winner_account.lamports, winner_account_lamports + lottery_account_rent + 5 * ticket_price); } #[tokio::test] async fn test_lottery_cancel() { // Test a lottery can only be cancelled when there is no other entrant than the initializer or some deal like that }
#![feature(proc_macro_hygiene, decl_macro)] #[macro_use] extern crate rocket; #[macro_use] extern crate rocket_contrib; #[macro_use] extern crate serde_derive; mod counter; mod database; mod todo; use counter::Counter; use database::Db; use rocket::State; use rocket_contrib::json::{Json, JsonValue}; use todo::Todo; #[get("/todos", format = "json")] fn get_all_todos(db: State<Db>) -> JsonValue { let map = db.lock().expect("mutex lock"); let values: Vec<&Todo> = map.values().collect::<Vec<_>>(); json!(values) } #[post("/todos", format = "json", data = "<todo>")] fn new_todo(db: State<Db>, counter: State<Counter>, todo: Json<Todo>) -> JsonValue { let mut map = db.lock().expect("mutex lock"); let id = counter.increment(); let new_todo = Todo::new(id, todo.get_name().clone(), false); let returned_value = json!(new_todo); map.insert(id, new_todo); returned_value } #[get("/todos/<id>", format = "json")] fn get_todo(db: State<Db>, id: u32) -> Option<JsonValue> { let map = db.lock().unwrap(); map.get(&id).map(|todo| json!(todo)) } #[put("/todos/<id>", format = "json", data = "<new_todo>")] fn update_todo(db: State<Db>, id: u32, new_todo: Json<Todo>) -> Option<JsonValue> { let mut map = db.lock().unwrap(); if map.contains_key(&id) { let todo = Todo::new(id, new_todo.0.get_name().clone(), new_todo.0.is_complete()); let old_todo = map.insert(id, todo).unwrap(); Some(json!(old_todo)) } else { None } } #[delete("/todos/<id>")] fn delete_todo(db: State<Db>, id: u32) -> Option<JsonValue> { let mut map = db.lock().unwrap(); map.remove(&id).map(|todo| json!(todo)) } #[catch(404)] fn not_found() -> JsonValue { json!({ "status": 404, "error": "id not found" }) } fn main() { rocket::ignite() .mount( "/", routes![get_all_todos, new_todo, get_todo, update_todo, delete_todo], ) .manage(database::create_map()) .manage(counter::create_counter()) .register(catchers![not_found]) .launch(); }
use crate::{ rendering::Display, simulation::{Simulation, Time}, }; #[cfg_attr(feature = "persistence", derive(serde::Deserialize, serde::Serialize))] pub struct StatApp; impl StatApp { pub fn update(&mut self, ctx: &egui::CtxRef, display: &Display, simulation: &Simulation) { let time = simulation.resources.get::<Time>().unwrap(); let cam = &display.cam; egui::SidePanel::left("Debug Info").show(ctx, |ui| { ui.style_mut().wrap = Some(false); ui.heading("Stats"); ui.label(format!("Time: {:.2}", time.time_since_start().as_secs_f32())); ui.label(format!("Ticks / s: {:}", time.tick_rate)); ui.label(format!("Entities: {}", simulation.world.len())); ui.separator(); ui.heading("Camera"); ui.label(format!("Position: ({:.2}, {:.2})", cam.pos().x, cam.pos().y)); ui.label(format!( "Window Size: ({:.2}, {:.2})", cam.window_size.x, cam.window_size.y )); ui.label(format!("Zoom Factor: ({:.2})", cam.zoom)); ui.label(format!("Mouse Position: ({})", cam.screen2world(display.mouse.pos))); }); } }
#[cfg(feature = "Win32_Foundation")] ::windows_sys::core::link ! ( "kernel32.dll""system" #[doc = "*Required features: `\"Win32_System_IO\"`, `\"Win32_Foundation\"`*"] fn BindIoCompletionCallback ( filehandle : super::super::Foundation:: HANDLE , function : LPOVERLAPPED_COMPLETION_ROUTINE , flags : u32 ) -> super::super::Foundation:: BOOL ); #[cfg(feature = "Win32_Foundation")] ::windows_sys::core::link ! ( "kernel32.dll""system" #[doc = "*Required features: `\"Win32_System_IO\"`, `\"Win32_Foundation\"`*"] fn CancelIo ( hfile : super::super::Foundation:: HANDLE ) -> super::super::Foundation:: BOOL ); #[cfg(feature = "Win32_Foundation")] ::windows_sys::core::link ! ( "kernel32.dll""system" #[doc = "*Required features: `\"Win32_System_IO\"`, `\"Win32_Foundation\"`*"] fn CancelIoEx ( hfile : super::super::Foundation:: HANDLE , lpoverlapped : *const OVERLAPPED ) -> super::super::Foundation:: BOOL ); #[cfg(feature = "Win32_Foundation")] ::windows_sys::core::link ! ( "kernel32.dll""system" #[doc = "*Required features: `\"Win32_System_IO\"`, `\"Win32_Foundation\"`*"] fn CancelSynchronousIo ( hthread : super::super::Foundation:: HANDLE ) -> super::super::Foundation:: BOOL ); #[cfg(feature = "Win32_Foundation")] ::windows_sys::core::link ! ( "kernel32.dll""system" #[doc = "*Required features: `\"Win32_System_IO\"`, `\"Win32_Foundation\"`*"] fn CreateIoCompletionPort ( filehandle : super::super::Foundation:: HANDLE , existingcompletionport : super::super::Foundation:: HANDLE , completionkey : usize , numberofconcurrentthreads : u32 ) -> super::super::Foundation:: HANDLE ); #[cfg(feature = "Win32_Foundation")] ::windows_sys::core::link ! ( "kernel32.dll""system" #[doc = "*Required features: `\"Win32_System_IO\"`, `\"Win32_Foundation\"`*"] fn DeviceIoControl ( hdevice : super::super::Foundation:: HANDLE , dwiocontrolcode : u32 , lpinbuffer : *const ::core::ffi::c_void , ninbuffersize : u32 , lpoutbuffer : *mut ::core::ffi::c_void , noutbuffersize : u32 , lpbytesreturned : *mut u32 , lpoverlapped : *mut OVERLAPPED ) -> super::super::Foundation:: BOOL ); #[cfg(feature = "Win32_Foundation")] ::windows_sys::core::link ! ( "kernel32.dll""system" #[doc = "*Required features: `\"Win32_System_IO\"`, `\"Win32_Foundation\"`*"] fn GetOverlappedResult ( hfile : super::super::Foundation:: HANDLE , lpoverlapped : *const OVERLAPPED , lpnumberofbytestransferred : *mut u32 , bwait : super::super::Foundation:: BOOL ) -> super::super::Foundation:: BOOL ); #[cfg(feature = "Win32_Foundation")] ::windows_sys::core::link ! ( "kernel32.dll""system" #[doc = "*Required features: `\"Win32_System_IO\"`, `\"Win32_Foundation\"`*"] fn GetOverlappedResultEx ( hfile : super::super::Foundation:: HANDLE , lpoverlapped : *const OVERLAPPED , lpnumberofbytestransferred : *mut u32 , dwmilliseconds : u32 , balertable : super::super::Foundation:: BOOL ) -> super::super::Foundation:: BOOL ); #[cfg(feature = "Win32_Foundation")] ::windows_sys::core::link ! ( "kernel32.dll""system" #[doc = "*Required features: `\"Win32_System_IO\"`, `\"Win32_Foundation\"`*"] fn GetQueuedCompletionStatus ( completionport : super::super::Foundation:: HANDLE , lpnumberofbytestransferred : *mut u32 , lpcompletionkey : *mut usize , lpoverlapped : *mut *mut OVERLAPPED , dwmilliseconds : u32 ) -> super::super::Foundation:: BOOL ); #[cfg(feature = "Win32_Foundation")] ::windows_sys::core::link ! ( "kernel32.dll""system" #[doc = "*Required features: `\"Win32_System_IO\"`, `\"Win32_Foundation\"`*"] fn GetQueuedCompletionStatusEx ( completionport : super::super::Foundation:: HANDLE , lpcompletionportentries : *mut OVERLAPPED_ENTRY , ulcount : u32 , ulnumentriesremoved : *mut u32 , dwmilliseconds : u32 , falertable : super::super::Foundation:: BOOL ) -> super::super::Foundation:: BOOL ); #[cfg(feature = "Win32_Foundation")] ::windows_sys::core::link ! ( "kernel32.dll""system" #[doc = "*Required features: `\"Win32_System_IO\"`, `\"Win32_Foundation\"`*"] fn PostQueuedCompletionStatus ( completionport : super::super::Foundation:: HANDLE , dwnumberofbytestransferred : u32 , dwcompletionkey : usize , lpoverlapped : *const OVERLAPPED ) -> super::super::Foundation:: BOOL ); #[repr(C)] #[doc = "*Required features: `\"Win32_System_IO\"`, `\"Win32_Foundation\"`*"] #[cfg(feature = "Win32_Foundation")] pub struct OVERLAPPED { pub Internal: usize, pub InternalHigh: usize, pub Anonymous: OVERLAPPED_0, pub hEvent: super::super::Foundation::HANDLE, } #[cfg(feature = "Win32_Foundation")] impl ::core::marker::Copy for OVERLAPPED {} #[cfg(feature = "Win32_Foundation")] impl ::core::clone::Clone for OVERLAPPED { fn clone(&self) -> Self { *self } } #[repr(C)] #[doc = "*Required features: `\"Win32_System_IO\"`, `\"Win32_Foundation\"`*"] #[cfg(feature = "Win32_Foundation")] pub union OVERLAPPED_0 { pub Anonymous: OVERLAPPED_0_0, pub Pointer: *mut ::core::ffi::c_void, } #[cfg(feature = "Win32_Foundation")] impl ::core::marker::Copy for OVERLAPPED_0 {} #[cfg(feature = "Win32_Foundation")] impl ::core::clone::Clone for OVERLAPPED_0 { fn clone(&self) -> Self { *self } } #[repr(C)] #[doc = "*Required features: `\"Win32_System_IO\"`, `\"Win32_Foundation\"`*"] #[cfg(feature = "Win32_Foundation")] pub struct OVERLAPPED_0_0 { pub Offset: u32, pub OffsetHigh: u32, } #[cfg(feature = "Win32_Foundation")] impl ::core::marker::Copy for OVERLAPPED_0_0 {} #[cfg(feature = "Win32_Foundation")] impl ::core::clone::Clone for OVERLAPPED_0_0 { fn clone(&self) -> Self { *self } } #[repr(C)] #[doc = "*Required features: `\"Win32_System_IO\"`, `\"Win32_Foundation\"`*"] #[cfg(feature = "Win32_Foundation")] pub struct OVERLAPPED_ENTRY { pub lpCompletionKey: usize, pub lpOverlapped: *mut OVERLAPPED, pub Internal: usize, pub dwNumberOfBytesTransferred: u32, } #[cfg(feature = "Win32_Foundation")] impl ::core::marker::Copy for OVERLAPPED_ENTRY {} #[cfg(feature = "Win32_Foundation")] impl ::core::clone::Clone for OVERLAPPED_ENTRY { fn clone(&self) -> Self { *self } } #[doc = "*Required features: `\"Win32_System_IO\"`, `\"Win32_Foundation\"`*"] #[cfg(feature = "Win32_Foundation")] pub type LPOVERLAPPED_COMPLETION_ROUTINE = ::core::option::Option<unsafe extern "system" fn(dwerrorcode: u32, dwnumberofbytestransfered: u32, lpoverlapped: *mut OVERLAPPED) -> ()>;
use structopt::StructOpt; #[derive(Debug, StructOpt)] #[structopt(about = "Run the server process for the ACRONYM Week of Code 2021")] pub struct Arguments { /// Reload the map on the server (can take a significant amount of time) #[structopt(long, short="r")] pub reload_map: bool, /// Load the map from the server (can take a significant amount of time) #[structopt(long, short="l")] pub load_map: bool, }
#[doc = "Reader of register FPUIMR"] pub type R = crate::R<u32, super::FPUIMR>; #[doc = "Writer for register FPUIMR"] pub type W = crate::W<u32, super::FPUIMR>; #[doc = "Register FPUIMR `reset()`'s with value 0x1f"] impl crate::ResetValue for super::FPUIMR { type Type = u32; #[inline(always)] fn reset_value() -> Self::Type { 0x1f } } #[doc = "Reader of field `FPU_IE`"] pub type FPU_IE_R = crate::R<u8, u8>; #[doc = "Write proxy for field `FPU_IE`"] pub struct FPU_IE_W<'a> { w: &'a mut W, } impl<'a> FPU_IE_W<'a> { #[doc = r"Writes raw bits to the field"] #[inline(always)] pub unsafe fn bits(self, value: u8) -> &'a mut W { self.w.bits = (self.w.bits & !0x3f) | ((value as u32) & 0x3f); self.w } } impl R { #[doc = "Bits 0:5 - Floating point unit interrupts enable bits"] #[inline(always)] pub fn fpu_ie(&self) -> FPU_IE_R { FPU_IE_R::new((self.bits & 0x3f) as u8) } } impl W { #[doc = "Bits 0:5 - Floating point unit interrupts enable bits"] #[inline(always)] pub fn fpu_ie(&mut self) -> FPU_IE_W { FPU_IE_W { w: self } } }
use crate::erlang::not_1::result; use crate::test::strategy; #[test] fn without_boolean_errors_badarg() { run!( |arc_process| strategy::term::is_not_boolean(arc_process.clone()), |boolean| { prop_assert_is_not_boolean!(result(boolean), boolean); Ok(()) }, ); } #[test] fn with_false_returns_true() { assert_eq!(result(false.into()), Ok(true.into())); } #[test] fn with_true_returns_false() { assert_eq!(result(true.into()), Ok(false.into())); }
use std::process::Command; #[test] fn test_no_function() { let output = Command::new("cargo") .arg("run") .arg("tests/script.sh") .output() .expect("failed to execute process"); let stdout = String::from_utf8(output.stdout).unwrap(); assert_eq!(output.status.success(), true); assert_eq!(stdout.contains("script.sh"), true); assert_eq!(stdout.contains("First line of file header comment"), true); assert_eq!(stdout.contains("Second line of file header comment"), true); assert_eq!(stdout.contains("Usage"), true); assert_eq!(stdout.contains("some_function This function"), true); assert_eq!(stdout.contains("This function is very clever and"), true); assert_eq!(stdout.contains("And here is some more detailed"), true); assert_eq!(stdout.contains("some_function"), true); assert_eq!(stdout.contains("another_function"), true); assert_eq!(stdout.contains("yet_more_functions"), true); } #[test] fn test_with_empty_script() { let output = Command::new("cargo") .arg("run") .arg("tests/empty_script.sh") .output() .expect("failed to execute process"); assert_eq!(output.status.success(), true); let stdout = String::from_utf8(output.stdout).unwrap(); assert_eq!(stdout.contains("Runsh has found no functions "), true); } #[test] fn test_with_function() { let output = Command::new("cargo") .arg("run") .arg("tests/script.sh") .arg("another_function") .output() .expect("failed to execute process"); // Should return a non-0 exit code, allowing bash to || "$@", // thereby running the script's function itself. assert_eq!(output.status.success(), false); } #[test] fn test_with_bad_function_name() { let output = Command::new("cargo") .arg("run") .arg("tests/script.sh") .arg("bad_function_name") .output() .expect("failed to execute process"); assert_eq!(output.status.success(), true); let stdout = String::from_utf8(output.stdout).unwrap(); assert_eq!(stdout.contains("Function does not exist"), true); } #[test] fn test_function_params() { let output = Command::new("cargo") .arg("run") .arg("tests/script.sh") .arg("another_function") .arg("a_param") .output() .expect("failed to execute process"); // Should return a non-0 exit code, allowing bash to || "$@", // thereby running the script's function itself. let stdout = String::from_utf8(output.stdout).unwrap(); assert_eq!(stdout.contains("USAGE"), false); } #[test] fn bad_script_path() { let output = Command::new("cargo") .arg("run") .arg("bad_script_path.sh") .arg("another_function") .output() .expect("failed to execute process"); assert_eq!(output.status.success(), true); let stdout = String::from_utf8(output.stdout).unwrap(); assert_eq!( stdout.contains("Unable to get functions from bad_script_path.sh"), true ); }
/// The RetrieveMessageRequest is used for requesting the set of stored messages from neighbouring peer nodes. If a /// start_time is provided then only messages after the specified time will be sent, otherwise all applicable messages /// will be sent. #[derive(Clone, PartialEq, ::prost::Message)] pub struct StoredMessagesRequest { #[prost(message, optional, tag = "1")] pub since: ::std::option::Option<::prost_types::Timestamp>, #[prost(uint32, tag = "2")] pub request_id: u32, #[prost(bytes, tag = "3")] pub dist_threshold: std::vec::Vec<u8>, } /// Storage for a single message envelope, including the date and time when the element was stored #[derive(Clone, PartialEq, ::prost::Message)] pub struct StoredMessage { #[prost(message, optional, tag = "1")] pub stored_at: ::std::option::Option<::prost_types::Timestamp>, #[prost(uint32, tag = "2")] pub version: u32, #[prost(message, optional, tag = "3")] pub dht_header: ::std::option::Option<super::envelope::DhtHeader>, #[prost(bytes, tag = "4")] pub body: std::vec::Vec<u8>, } /// The StoredMessages contains the set of applicable messages retrieved from a neighbouring peer node. #[derive(Clone, PartialEq, ::prost::Message)] pub struct StoredMessagesResponse { #[prost(message, repeated, tag = "1")] pub messages: ::std::vec::Vec<StoredMessage>, #[prost(uint32, tag = "2")] pub request_id: u32, #[prost(enumeration = "stored_messages_response::SafResponseType", tag = "3")] pub response_type: i32, } pub mod stored_messages_response { #[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, PartialOrd, Ord, ::prost::Enumeration)] #[repr(i32)] pub enum SafResponseType { /// Messages for the requested public key or node ID ForMe = 0, /// Discovery messages that could be for the requester Discovery = 1, /// Join messages that the requester could be interested in Join = 2, /// Messages without an explicit destination and with an unidentified encrypted source Anonymous = 3, /// Messages within the requesting node's region InRegion = 4, } }
use super::{PositionIterInternal, PyGenericAlias, PyTupleRef, PyType, PyTypeRef}; use crate::atomic_func; use crate::common::lock::{ PyMappedRwLockReadGuard, PyMutex, PyRwLock, PyRwLockReadGuard, PyRwLockWriteGuard, }; use crate::{ class::PyClassImpl, convert::ToPyObject, function::{ArgSize, FuncArgs, OptionalArg, PyComparisonValue}, iter::PyExactSizeIterator, protocol::{PyIterReturn, PyMappingMethods, PySequenceMethods}, recursion::ReprGuard, sequence::{MutObjectSequenceOp, OptionalRangeArgs, SequenceExt, SequenceMutExt}, sliceable::{SequenceIndex, SliceableSequenceMutOp, SliceableSequenceOp}, types::{ AsMapping, AsSequence, Comparable, Constructor, Initializer, IterNext, Iterable, PyComparisonOp, Representable, SelfIter, Unconstructible, }, utils::collection_repr, vm::VirtualMachine, AsObject, Context, Py, PyObject, PyObjectRef, PyPayload, PyRef, PyResult, }; use std::{fmt, ops::DerefMut}; #[pyclass(module = false, name = "list", unhashable = true, traverse)] #[derive(Default)] pub struct PyList { elements: PyRwLock<Vec<PyObjectRef>>, } impl fmt::Debug for PyList { fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { // TODO: implement more detailed, non-recursive Debug formatter f.write_str("list") } } impl From<Vec<PyObjectRef>> for PyList { fn from(elements: Vec<PyObjectRef>) -> Self { PyList { elements: PyRwLock::new(elements), } } } impl FromIterator<PyObjectRef> for PyList { fn from_iter<T: IntoIterator<Item = PyObjectRef>>(iter: T) -> Self { Vec::from_iter(iter).into() } } impl PyPayload for PyList { fn class(ctx: &Context) -> &'static Py<PyType> { ctx.types.list_type } } impl ToPyObject for Vec<PyObjectRef> { fn to_pyobject(self, vm: &VirtualMachine) -> PyObjectRef { PyList::new_ref(self, &vm.ctx).into() } } impl PyList { pub fn new_ref(elements: Vec<PyObjectRef>, ctx: &Context) -> PyRef<Self> { PyRef::new_ref(Self::from(elements), ctx.types.list_type.to_owned(), None) } pub fn borrow_vec(&self) -> PyMappedRwLockReadGuard<'_, [PyObjectRef]> { PyRwLockReadGuard::map(self.elements.read(), |v| &**v) } pub fn borrow_vec_mut(&self) -> PyRwLockWriteGuard<'_, Vec<PyObjectRef>> { self.elements.write() } fn repeat(&self, n: isize, vm: &VirtualMachine) -> PyResult<PyRef<Self>> { let elements = &*self.borrow_vec(); let v = elements.mul(vm, n)?; Ok(Self::new_ref(v, &vm.ctx)) } fn irepeat(zelf: PyRef<Self>, n: isize, vm: &VirtualMachine) -> PyResult<PyRef<Self>> { zelf.borrow_vec_mut().imul(vm, n)?; Ok(zelf) } } #[derive(FromArgs, Default, Traverse)] pub(crate) struct SortOptions { #[pyarg(named, default)] key: Option<PyObjectRef>, #[pytraverse(skip)] #[pyarg(named, default = "false")] reverse: bool, } pub type PyListRef = PyRef<PyList>; #[pyclass( with( Constructor, Initializer, AsMapping, Iterable, Comparable, AsSequence, Representable ), flags(BASETYPE) )] impl PyList { #[pymethod] pub(crate) fn append(&self, x: PyObjectRef) { self.borrow_vec_mut().push(x); } #[pymethod] pub(crate) fn extend(&self, x: PyObjectRef, vm: &VirtualMachine) -> PyResult<()> { let mut new_elements = x.try_to_value(vm)?; self.borrow_vec_mut().append(&mut new_elements); Ok(()) } #[pymethod] pub(crate) fn insert(&self, position: isize, element: PyObjectRef) { let mut elements = self.borrow_vec_mut(); let position = elements.saturate_index(position); elements.insert(position, element); } fn concat(&self, other: &PyObject, vm: &VirtualMachine) -> PyResult<PyRef<Self>> { let other = other.payload_if_subclass::<PyList>(vm).ok_or_else(|| { vm.new_type_error(format!( "Cannot add {} and {}", Self::class(&vm.ctx).name(), other.class().name() )) })?; let mut elements = self.borrow_vec().to_vec(); elements.extend(other.borrow_vec().iter().cloned()); Ok(Self::new_ref(elements, &vm.ctx)) } #[pymethod(magic)] fn add(&self, other: PyObjectRef, vm: &VirtualMachine) -> PyResult<PyRef<Self>> { self.concat(&other, vm) } fn inplace_concat( zelf: &Py<Self>, other: &PyObject, vm: &VirtualMachine, ) -> PyResult<PyObjectRef> { let mut seq = extract_cloned(other, Ok, vm)?; zelf.borrow_vec_mut().append(&mut seq); Ok(zelf.to_owned().into()) } #[pymethod(magic)] fn iadd(zelf: PyRef<Self>, other: PyObjectRef, vm: &VirtualMachine) -> PyResult<PyRef<Self>> { let mut seq = extract_cloned(&other, Ok, vm)?; zelf.borrow_vec_mut().append(&mut seq); Ok(zelf) } #[pymethod(magic)] fn bool(&self) -> bool { !self.borrow_vec().is_empty() } #[pymethod] fn clear(&self) { let _removed = std::mem::take(self.borrow_vec_mut().deref_mut()); } #[pymethod] fn copy(&self, vm: &VirtualMachine) -> PyRef<Self> { Self::new_ref(self.borrow_vec().to_vec(), &vm.ctx) } #[pymethod(magic)] fn len(&self) -> usize { self.borrow_vec().len() } #[pymethod(magic)] fn sizeof(&self) -> usize { std::mem::size_of::<Self>() + self.elements.read().capacity() * std::mem::size_of::<PyObjectRef>() } #[pymethod] fn reverse(&self) { self.borrow_vec_mut().reverse(); } #[pymethod(magic)] fn reversed(zelf: PyRef<Self>) -> PyListReverseIterator { let position = zelf.len().saturating_sub(1); PyListReverseIterator { internal: PyMutex::new(PositionIterInternal::new(zelf, position)), } } fn _getitem(&self, needle: &PyObject, vm: &VirtualMachine) -> PyResult { match SequenceIndex::try_from_borrowed_object(vm, needle, "list")? { SequenceIndex::Int(i) => self.borrow_vec().getitem_by_index(vm, i), SequenceIndex::Slice(slice) => self .borrow_vec() .getitem_by_slice(vm, slice) .map(|x| vm.ctx.new_list(x).into()), } } #[pymethod(magic)] fn getitem(&self, needle: PyObjectRef, vm: &VirtualMachine) -> PyResult { self._getitem(&needle, vm) } fn _setitem(&self, needle: &PyObject, value: PyObjectRef, vm: &VirtualMachine) -> PyResult<()> { match SequenceIndex::try_from_borrowed_object(vm, needle, "list")? { SequenceIndex::Int(index) => self.borrow_vec_mut().setitem_by_index(vm, index, value), SequenceIndex::Slice(slice) => { let sec = extract_cloned(&value, Ok, vm)?; self.borrow_vec_mut().setitem_by_slice(vm, slice, &sec) } } } #[pymethod(magic)] fn setitem( &self, needle: PyObjectRef, value: PyObjectRef, vm: &VirtualMachine, ) -> PyResult<()> { self._setitem(&needle, value, vm) } #[pymethod(magic)] #[pymethod(name = "__rmul__")] fn mul(&self, n: ArgSize, vm: &VirtualMachine) -> PyResult<PyRef<Self>> { self.repeat(n.into(), vm) } #[pymethod(magic)] fn imul(zelf: PyRef<Self>, n: ArgSize, vm: &VirtualMachine) -> PyResult<PyRef<Self>> { Self::irepeat(zelf, n.into(), vm) } #[pymethod] fn count(&self, needle: PyObjectRef, vm: &VirtualMachine) -> PyResult<usize> { self.mut_count(vm, &needle) } #[pymethod(magic)] pub(crate) fn contains(&self, needle: PyObjectRef, vm: &VirtualMachine) -> PyResult<bool> { self.mut_contains(vm, &needle) } #[pymethod] fn index( &self, needle: PyObjectRef, range: OptionalRangeArgs, vm: &VirtualMachine, ) -> PyResult<usize> { let (start, stop) = range.saturate(self.len(), vm)?; let index = self.mut_index_range(vm, &needle, start..stop)?; if let Some(index) = index.into() { Ok(index) } else { Err(vm.new_value_error(format!("'{}' is not in list", needle.str(vm)?))) } } #[pymethod] fn pop(&self, i: OptionalArg<isize>, vm: &VirtualMachine) -> PyResult { let mut i = i.into_option().unwrap_or(-1); let mut elements = self.borrow_vec_mut(); if i < 0 { i += elements.len() as isize; } if elements.is_empty() { Err(vm.new_index_error("pop from empty list".to_owned())) } else if i < 0 || i as usize >= elements.len() { Err(vm.new_index_error("pop index out of range".to_owned())) } else { Ok(elements.remove(i as usize)) } } #[pymethod] fn remove(&self, needle: PyObjectRef, vm: &VirtualMachine) -> PyResult<()> { let index = self.mut_index(vm, &needle)?; if let Some(index) = index.into() { // defer delete out of borrow let is_inside_range = index < self.borrow_vec().len(); Ok(is_inside_range.then(|| self.borrow_vec_mut().remove(index))) } else { Err(vm.new_value_error(format!("'{}' is not in list", needle.str(vm)?))) } .map(drop) } fn _delitem(&self, needle: &PyObject, vm: &VirtualMachine) -> PyResult<()> { match SequenceIndex::try_from_borrowed_object(vm, needle, "list")? { SequenceIndex::Int(i) => self.borrow_vec_mut().delitem_by_index(vm, i), SequenceIndex::Slice(slice) => self.borrow_vec_mut().delitem_by_slice(vm, slice), } } #[pymethod(magic)] fn delitem(&self, subscript: PyObjectRef, vm: &VirtualMachine) -> PyResult<()> { self._delitem(&subscript, vm) } #[pymethod] pub(crate) fn sort(&self, options: SortOptions, vm: &VirtualMachine) -> PyResult<()> { // replace list contents with [] for duration of sort. // this prevents keyfunc from messing with the list and makes it easy to // check if it tries to append elements to it. let mut elements = std::mem::take(self.borrow_vec_mut().deref_mut()); let res = do_sort(vm, &mut elements, options.key, options.reverse); std::mem::swap(self.borrow_vec_mut().deref_mut(), &mut elements); res?; if !elements.is_empty() { return Err(vm.new_value_error("list modified during sort".to_owned())); } Ok(()) } #[pyclassmethod(magic)] fn class_getitem(cls: PyTypeRef, args: PyObjectRef, vm: &VirtualMachine) -> PyGenericAlias { PyGenericAlias::new(cls, args, vm) } } fn extract_cloned<F, R>(obj: &PyObject, mut f: F, vm: &VirtualMachine) -> PyResult<Vec<R>> where F: FnMut(PyObjectRef) -> PyResult<R>, { use crate::builtins::PyTuple; if let Some(tuple) = obj.payload_if_exact::<PyTuple>(vm) { tuple.iter().map(|x| f(x.clone())).collect() } else if let Some(list) = obj.payload_if_exact::<PyList>(vm) { list.borrow_vec().iter().map(|x| f(x.clone())).collect() } else { let iter = obj.to_owned().get_iter(vm)?; let iter = iter.iter::<PyObjectRef>(vm)?; let len = obj.to_sequence(vm).length_opt(vm).transpose()?.unwrap_or(0); let mut v = Vec::with_capacity(len); for x in iter { v.push(f(x?)?); } v.shrink_to_fit(); Ok(v) } } impl MutObjectSequenceOp for PyList { type Guard<'a> = PyMappedRwLockReadGuard<'a, [PyObjectRef]>; fn do_get<'a>(index: usize, guard: &'a Self::Guard<'_>) -> Option<&'a PyObjectRef> { guard.get(index) } fn do_lock(&self) -> Self::Guard<'_> { self.borrow_vec() } } impl Constructor for PyList { type Args = FuncArgs; fn py_new(cls: PyTypeRef, _args: FuncArgs, vm: &VirtualMachine) -> PyResult { PyList::default() .into_ref_with_type(vm, cls) .map(Into::into) } } impl Initializer for PyList { type Args = OptionalArg<PyObjectRef>; fn init(zelf: PyRef<Self>, iterable: Self::Args, vm: &VirtualMachine) -> PyResult<()> { let mut elements = if let OptionalArg::Present(iterable) = iterable { iterable.try_to_value(vm)? } else { vec![] }; std::mem::swap(zelf.borrow_vec_mut().deref_mut(), &mut elements); Ok(()) } } impl AsMapping for PyList { fn as_mapping() -> &'static PyMappingMethods { static AS_MAPPING: PyMappingMethods = PyMappingMethods { length: atomic_func!(|mapping, _vm| Ok(PyList::mapping_downcast(mapping).len())), subscript: atomic_func!( |mapping, needle, vm| PyList::mapping_downcast(mapping)._getitem(needle, vm) ), ass_subscript: atomic_func!(|mapping, needle, value, vm| { let zelf = PyList::mapping_downcast(mapping); if let Some(value) = value { zelf._setitem(needle, value, vm) } else { zelf._delitem(needle, vm) } }), }; &AS_MAPPING } } impl AsSequence for PyList { fn as_sequence() -> &'static PySequenceMethods { static AS_SEQUENCE: PySequenceMethods = PySequenceMethods { length: atomic_func!(|seq, _vm| Ok(PyList::sequence_downcast(seq).len())), concat: atomic_func!(|seq, other, vm| { PyList::sequence_downcast(seq) .concat(other, vm) .map(|x| x.into()) }), repeat: atomic_func!(|seq, n, vm| { PyList::sequence_downcast(seq) .repeat(n, vm) .map(|x| x.into()) }), item: atomic_func!(|seq, i, vm| { PyList::sequence_downcast(seq) .borrow_vec() .getitem_by_index(vm, i) }), ass_item: atomic_func!(|seq, i, value, vm| { let zelf = PyList::sequence_downcast(seq); if let Some(value) = value { zelf.borrow_vec_mut().setitem_by_index(vm, i, value) } else { zelf.borrow_vec_mut().delitem_by_index(vm, i) } }), contains: atomic_func!(|seq, target, vm| { let zelf = PyList::sequence_downcast(seq); zelf.mut_contains(vm, target) }), inplace_concat: atomic_func!(|seq, other, vm| { let zelf = PyList::sequence_downcast(seq); PyList::inplace_concat(zelf, other, vm) }), inplace_repeat: atomic_func!(|seq, n, vm| { let zelf = PyList::sequence_downcast(seq); Ok(PyList::irepeat(zelf.to_owned(), n, vm)?.into()) }), }; &AS_SEQUENCE } } impl Iterable for PyList { fn iter(zelf: PyRef<Self>, vm: &VirtualMachine) -> PyResult { Ok(PyListIterator { internal: PyMutex::new(PositionIterInternal::new(zelf, 0)), } .into_pyobject(vm)) } } impl Comparable for PyList { fn cmp( zelf: &Py<Self>, other: &PyObject, op: PyComparisonOp, vm: &VirtualMachine, ) -> PyResult<PyComparisonValue> { if let Some(res) = op.identical_optimization(zelf, other) { return Ok(res.into()); } let other = class_or_notimplemented!(Self, other); let a = &*zelf.borrow_vec(); let b = &*other.borrow_vec(); a.iter() .richcompare(b.iter(), op, vm) .map(PyComparisonValue::Implemented) } } impl Representable for PyList { #[inline] fn repr_str(zelf: &Py<Self>, vm: &VirtualMachine) -> PyResult<String> { let s = if zelf.len() == 0 { "[]".to_owned() } else if let Some(_guard) = ReprGuard::enter(vm, zelf.as_object()) { collection_repr(None, "[", "]", zelf.borrow_vec().iter(), vm)? } else { "[...]".to_owned() }; Ok(s) } } fn do_sort( vm: &VirtualMachine, values: &mut Vec<PyObjectRef>, key_func: Option<PyObjectRef>, reverse: bool, ) -> PyResult<()> { let op = if reverse { PyComparisonOp::Lt } else { PyComparisonOp::Gt }; let cmp = |a: &PyObjectRef, b: &PyObjectRef| a.rich_compare_bool(b, op, vm); if let Some(ref key_func) = key_func { let mut items = values .iter() .map(|x| Ok((x.clone(), key_func.call((x.clone(),), vm)?))) .collect::<Result<Vec<_>, _>>()?; timsort::try_sort_by_gt(&mut items, |a, b| cmp(&a.1, &b.1))?; *values = items.into_iter().map(|(val, _)| val).collect(); } else { timsort::try_sort_by_gt(values, cmp)?; } Ok(()) } #[pyclass(module = false, name = "list_iterator", traverse)] #[derive(Debug)] pub struct PyListIterator { internal: PyMutex<PositionIterInternal<PyListRef>>, } impl PyPayload for PyListIterator { fn class(ctx: &Context) -> &'static Py<PyType> { ctx.types.list_iterator_type } } #[pyclass(with(Constructor, IterNext, Iterable))] impl PyListIterator { #[pymethod(magic)] fn length_hint(&self) -> usize { self.internal.lock().length_hint(|obj| obj.len()) } #[pymethod(magic)] fn setstate(&self, state: PyObjectRef, vm: &VirtualMachine) -> PyResult<()> { self.internal .lock() .set_state(state, |obj, pos| pos.min(obj.len()), vm) } #[pymethod(magic)] fn reduce(&self, vm: &VirtualMachine) -> PyTupleRef { self.internal .lock() .builtins_iter_reduce(|x| x.clone().into(), vm) } } impl Unconstructible for PyListIterator {} impl SelfIter for PyListIterator {} impl IterNext for PyListIterator { fn next(zelf: &Py<Self>, _vm: &VirtualMachine) -> PyResult<PyIterReturn> { zelf.internal.lock().next(|list, pos| { let vec = list.borrow_vec(); Ok(PyIterReturn::from_result(vec.get(pos).cloned().ok_or(None))) }) } } #[pyclass(module = false, name = "list_reverseiterator", traverse)] #[derive(Debug)] pub struct PyListReverseIterator { internal: PyMutex<PositionIterInternal<PyListRef>>, } impl PyPayload for PyListReverseIterator { fn class(ctx: &Context) -> &'static Py<PyType> { ctx.types.list_reverseiterator_type } } #[pyclass(with(Constructor, IterNext, Iterable))] impl PyListReverseIterator { #[pymethod(magic)] fn length_hint(&self) -> usize { self.internal.lock().rev_length_hint(|obj| obj.len()) } #[pymethod(magic)] fn setstate(&self, state: PyObjectRef, vm: &VirtualMachine) -> PyResult<()> { self.internal .lock() .set_state(state, |obj, pos| pos.min(obj.len()), vm) } #[pymethod(magic)] fn reduce(&self, vm: &VirtualMachine) -> PyTupleRef { self.internal .lock() .builtins_reversed_reduce(|x| x.clone().into(), vm) } } impl Unconstructible for PyListReverseIterator {} impl SelfIter for PyListReverseIterator {} impl IterNext for PyListReverseIterator { fn next(zelf: &Py<Self>, _vm: &VirtualMachine) -> PyResult<PyIterReturn> { zelf.internal.lock().rev_next(|list, pos| { let vec = list.borrow_vec(); Ok(PyIterReturn::from_result(vec.get(pos).cloned().ok_or(None))) }) } } pub fn init(context: &Context) { let list_type = &context.types.list_type; PyList::extend_class(context, list_type); PyListIterator::extend_class(context, context.types.list_iterator_type); PyListReverseIterator::extend_class(context, context.types.list_reverseiterator_type); }
use winapi::um::winnt::HANDLE; use winapi::um::winuser::IMAGE_CURSOR; use crate::win32::resources_helper as rh; use crate::{OemCursor, OemImage, NwgError}; use std::ptr; #[cfg(feature = "embed-resource")] use super::EmbedResource; /** A wrapper over a cursor file (*.cur) Cursor resources can be used with the `cursor` feature Example: ```rust use native_windows_gui as nwg; fn load_cursor() -> nwg::Cursor { nwg::Cursor::from_file("Hello.cur", true).unwrap() } fn load_cursor_builder() -> nwg::Cursor { let mut cursor = nwg::Cursor::default(); nwg::Cursor::builder() .source_file(Some("Hello.cur")) .strict(true) .build(&mut cursor) .unwrap(); cursor } */ #[allow(unused)] pub struct Cursor { pub handle: HANDLE, pub(crate) owned: bool } impl Cursor { pub fn builder<'a>() -> CursorBuilder<'a> { CursorBuilder { source_text: None, source_system: None, size: None, #[cfg(feature = "embed-resource")] source_embed: None, #[cfg(feature = "embed-resource")] source_embed_id: 0, #[cfg(feature = "embed-resource")] source_embed_str: None, strict: false } } pub fn from_system(cursor: OemCursor) -> Cursor { let mut out = Self::default(); // Default cursor creation cannot fail Self::builder() .source_system(Some(cursor)) .build(&mut out) .unwrap(); out } /** Single line helper function over the cursor builder api. Use a file resource. */ pub fn from_file(path: &str, strict: bool) -> Result<Cursor, NwgError> { let mut cursor = Cursor::default(); Cursor::builder() .source_file(Some(path)) .strict(strict) .build(&mut cursor)?; Ok(cursor) } /** Single line helper function over the cursor builder api. Use an embedded resource. Either `embed_id` or `embed_str` must be defined, not both. Requires the `embed-resource` feature. */ #[cfg(feature = "embed-resource")] pub fn from_embed(embed: &EmbedResource, embed_id: Option<usize>, embed_str: Option<&str>) -> Result<Cursor, NwgError> { let mut bitmap = Cursor::default(); Cursor::builder() .source_embed(Some(embed)) .source_embed_id(embed_id.unwrap_or(0)) .source_embed_str(embed_str) .build(&mut bitmap)?; Ok(bitmap) } } pub struct CursorBuilder<'a> { source_text: Option<&'a str>, source_system: Option<OemCursor>, size: Option<(u32, u32)>, #[cfg(feature = "embed-resource")] source_embed: Option<&'a EmbedResource>, #[cfg(feature = "embed-resource")] source_embed_id: usize, #[cfg(feature = "embed-resource")] source_embed_str: Option<&'a str>, strict: bool, } impl<'a> CursorBuilder<'a> { pub fn source_file(mut self, t: Option<&'a str>) -> CursorBuilder<'a> { self.source_text = t; self } pub fn source_system(mut self, t: Option<OemCursor>) -> CursorBuilder<'a> { self.source_system = t; self } #[cfg(feature = "embed-resource")] pub fn source_embed(mut self, em: Option<&'a EmbedResource>) -> CursorBuilder<'a> { self.source_embed = em; self } #[cfg(feature = "embed-resource")] pub fn source_embed_id(mut self, id: usize) -> CursorBuilder<'a> { self.source_embed_id = id; self } #[cfg(feature = "embed-resource")] pub fn source_embed_str(mut self, id: Option<&'a str>) -> CursorBuilder<'a> { self.source_embed_str = id; self } pub fn size(mut self, s: Option<(u32, u32)>) -> CursorBuilder<'a> { self.size = s; self } pub fn strict(mut self, s: bool) -> CursorBuilder<'a> { self.strict = s; self } pub fn build(self, b: &mut Cursor) -> Result<(), NwgError> { if let Some(src) = self.source_text { let handle = unsafe { rh::build_image(src, self.size, self.strict, IMAGE_CURSOR)? }; *b = Cursor { handle, owned: true }; } else if let Some(src) = self.source_system { let handle = unsafe { rh::build_oem_image(OemImage::Cursor(src), self.size)? }; *b = Cursor { handle, owned: true }; } else { #[cfg(feature = "embed-resource")] fn build_embed(builder: CursorBuilder) -> Result<Cursor, NwgError> { match builder.source_embed { Some(embed) => { match builder.source_embed_str { Some(src) => embed.cursor_str(src) .ok_or_else(|| NwgError::resource_create(format!("No cursor in embed resource identified by {}", src))), None => embed.cursor(builder.source_embed_id) .ok_or_else(|| NwgError::resource_create(format!("No cursor in embed resource identified by {}", builder.source_embed_id))) } }, None => Err(NwgError::resource_create("No source provided for Cursor")) } } #[cfg(not(feature = "embed-resource"))] fn build_embed(_builder: CursorBuilder) -> Result<Cursor, NwgError> { Err(NwgError::resource_create("No source provided for Cursor")) } *b = build_embed(self)?; } Ok(()) } } impl Default for Cursor { fn default() -> Cursor { Cursor { handle: ptr::null_mut(), owned: false } } } impl PartialEq for Cursor { fn eq(&self, other: &Self) -> bool { self.handle == other.handle } } impl Drop for Cursor { fn drop(&mut self) { if self.owned && !self.handle.is_null() { rh::destroy_cursor(self.handle); } } }
/* 给定一个非空整数数组,除了某个元素只出现一次以外,其余每个元素均出现了三次。找出那个只出现了一次的元素。 说明: 你的算法应该具有线性时间复杂度。 你可以不使用额外空间来实现吗? 示例 1: 输入: [2,2,3,2] 输出: 3 示例 2: 输入: [0,1,0,1,0,1,99] 输出: 99 来源:力扣(LeetCode) 链接:https://leetcode-cn.com/problems/single-number-ii 著作权归领扣网络所有。商业转载请联系官方授权,非商业转载请注明出处。 */ impl Solution { pub fn single_number(nums: Vec<i32>) -> i32 { let mut one = 0; // 某位为1表示该位出现了1次 let mut two = 0; // 某位为1表示该位出现了2次 for num in nums { // one & num 上一轮的one 和 num 同时为1 &后为1的位则表示 哪些位需要从1位变为2位 two |= one & num; // 新一轮的one 应该是 上一轮的one 和 num 不同时为 1 的位,因为同时为1的位已经被上一行统计过了 one ^= num; // 如果 one 和 two 同时为1 则表示该位出现三次了 let three = one & two; // 将出现了三次的位置0 one &= !three; two &= !three; } assert_eq!(two, 0); one } } fn main() { let data = vec![0, 1, 0, 1, 0, 1, 7]; let res = Solution::single_number(data); dbg!(res); } struct Solution {}
use crate::{commands, Error, Messenger, Result}; use irc::client::prelude::*; use irc::error::IrcError; use log::{info, warn}; impl Messenger for IrcClient { fn init(&self) -> Result<()> { Ok(self.identify()?) } fn run(&self, handler: impl Fn(&str) -> commands::Result<String>) -> Result<()> { Ok(self.for_each_incoming(|message| { if let Command::PRIVMSG(ref target, ref msg) = message.command { match handler(&msg) { Ok(response) => { self.send_privmsg(message.response_target().unwrap(), &response) .unwrap_or_else(|e| warn!("{}", e)) } Err(e) => warn!("{}: {}", target, e), } info!("{} said {} to {}", message.source_nickname().unwrap(), msg, target); } })?) } } impl From<IrcError> for Error { fn from(e: IrcError) -> Error { Error::Messenger(Box::new(e)) } }
// Copyright 2019 The Tari Project // // Redistribution and use in source and binary forms, with or without modification, are permitted provided that the // following conditions are met: // // 1. Redistributions of source code must retain the above copyright notice, this list of conditions and the following // disclaimer. // // 2. Redistributions in binary form must reproduce the above copyright notice, this list of conditions and the // following disclaimer in the documentation and/or other materials provided with the distribution. // // 3. Neither the name of the copyright holder nor the names of its contributors may be used to endorse or promote // products derived from this software without specific prior written permission. // // THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, // INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE // DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, // SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR // SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, // WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE // USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. use super::{error::LivenessError, state::Metadata}; use crate::{proto::liveness::MetadataKey, services::liveness::state::NodeStats}; use futures::{stream::Fuse, StreamExt}; use tari_broadcast_channel::Subscriber; use tari_comms::peer_manager::NodeId; use tari_service_framework::reply_channel::SenderService; use tower::Service; /// Request types made through the `LivenessHandle` and are handled by the `LivenessService` #[derive(Debug, Clone)] pub enum LivenessRequest { /// Send a ping to the given node ID SendPing(NodeId), /// Retrieve the total number of pings received GetPingCount, /// Retrieve the total number of pongs received GetPongCount, /// Get average latency for node ID GetAvgLatency(NodeId), /// Set the metadata attached to each pong message SetPongMetadata(MetadataKey, Vec<u8>), /// Add NodeId to be monitored AddNodeId(NodeId), /// Get stats for a monitored NodeId GetNodeIdStats(NodeId), } /// Response type for `LivenessService` #[derive(Debug)] pub enum LivenessResponse { /// Indicates that the request succeeded Ok, /// Used to return a counter value from `GetPingCount` and `GetPongCount` Count(usize), /// Response for GetAvgLatency AvgLatency(Option<u32>), /// The number of active neighbouring peers NumActiveNeighbours(usize), NodeIdAdded, NodeIdStats(NodeStats), } #[derive(Clone, Debug, PartialEq, Eq)] pub enum LivenessEvent { /// A ping was received ReceivedPing, /// A pong was received. The latency to the peer (if available) and the metadata contained /// within the received pong message are included as part of the event ReceivedPong(Box<PongEvent>), BroadcastedNeighbourPings(usize), BroadcastedMonitoredNodeIdPings(usize), } /// Repressents a pong event #[derive(Clone, Debug, PartialEq, Eq)] pub struct PongEvent { /// The node id of the node which sent this pong pub node_id: NodeId, /// Latency if available (i.e. a corresponding ping was sent within the Liveness state inflight ping TTL) pub latency: Option<u32>, /// Pong metadata pub metadata: Metadata, /// True if the pong was from a neighbouring peer, otherwise false pub is_neighbour: bool, /// True if the pong was from a monitored node, otherwise false pub is_monitored: bool, } impl PongEvent { pub(super) fn new( node_id: NodeId, latency: Option<u32>, metadata: Metadata, is_neighbour: bool, is_monitored: bool, ) -> Self { Self { node_id, latency, metadata, is_neighbour, is_monitored, } } } #[derive(Clone)] pub struct LivenessHandle { handle: SenderService<LivenessRequest, Result<LivenessResponse, LivenessError>>, event_stream: Subscriber<LivenessEvent>, } impl LivenessHandle { pub fn new( handle: SenderService<LivenessRequest, Result<LivenessResponse, LivenessError>>, event_stream: Subscriber<LivenessEvent>, ) -> Self { Self { handle, event_stream } } /// Returns a fused event stream for the liveness service pub fn get_event_stream_fused(&self) -> Fuse<Subscriber<LivenessEvent>> { self.event_stream.clone().fuse() } /// Send a ping to a given node ID pub async fn send_ping(&mut self, node_id: NodeId) -> Result<(), LivenessError> { match self.handle.call(LivenessRequest::SendPing(node_id)).await?? { LivenessResponse::Ok => Ok(()), _ => Err(LivenessError::UnexpectedApiResponse), } } /// Retrieve the global ping count pub async fn get_ping_count(&mut self) -> Result<usize, LivenessError> { match self.handle.call(LivenessRequest::GetPingCount).await?? { LivenessResponse::Count(c) => Ok(c), _ => Err(LivenessError::UnexpectedApiResponse), } } /// Retrieve the global pong count pub async fn get_pong_count(&mut self) -> Result<usize, LivenessError> { match self.handle.call(LivenessRequest::GetPongCount).await?? { LivenessResponse::Count(c) => Ok(c), _ => Err(LivenessError::UnexpectedApiResponse), } } /// Set metadata entry for the pong message pub async fn set_pong_metadata_entry(&mut self, key: MetadataKey, value: Vec<u8>) -> Result<(), LivenessError> { match self.handle.call(LivenessRequest::SetPongMetadata(key, value)).await?? { LivenessResponse::Ok => Ok(()), _ => Err(LivenessError::UnexpectedApiResponse), } } /// Add NodeId to be monitored pub async fn add_node_id(&mut self, node_id: NodeId) -> Result<(), LivenessError> { match self.handle.call(LivenessRequest::AddNodeId(node_id)).await?? { LivenessResponse::NodeIdAdded => Ok(()), _ => Err(LivenessError::UnexpectedApiResponse), } } /// Get stats for NodeId that is being monitored pub async fn get_node_id_stats(&mut self, node_id: NodeId) -> Result<NodeStats, LivenessError> { match self.handle.call(LivenessRequest::GetNodeIdStats(node_id)).await?? { LivenessResponse::NodeIdStats(n) => Ok(n), _ => Err(LivenessError::UnexpectedApiResponse), } } }
#[doc = "Reader of register EXTICR2"] pub type R = crate::R<u32, super::EXTICR2>; #[doc = "Writer for register EXTICR2"] pub type W = crate::W<u32, super::EXTICR2>; #[doc = "Register EXTICR2 `reset()`'s with value 0"] impl crate::ResetValue for super::EXTICR2 { type Type = u32; #[inline(always)] fn reset_value() -> Self::Type { 0 } } #[doc = "Reader of field `EXTI0_7`"] pub type EXTI0_7_R = crate::R<u8, u8>; #[doc = "Write proxy for field `EXTI0_7`"] pub struct EXTI0_7_W<'a> { w: &'a mut W, } impl<'a> EXTI0_7_W<'a> { #[doc = r"Writes raw bits to the field"] #[inline(always)] pub unsafe fn bits(self, value: u8) -> &'a mut W { self.w.bits = (self.w.bits & !0xff) | ((value as u32) & 0xff); self.w } } #[doc = "Reader of field `EXTI8_15`"] pub type EXTI8_15_R = crate::R<u8, u8>; #[doc = "Write proxy for field `EXTI8_15`"] pub struct EXTI8_15_W<'a> { w: &'a mut W, } impl<'a> EXTI8_15_W<'a> { #[doc = r"Writes raw bits to the field"] #[inline(always)] pub unsafe fn bits(self, value: u8) -> &'a mut W { self.w.bits = (self.w.bits & !(0xff << 8)) | (((value as u32) & 0xff) << 8); self.w } } #[doc = "Reader of field `EXTI16_23`"] pub type EXTI16_23_R = crate::R<u8, u8>; #[doc = "Write proxy for field `EXTI16_23`"] pub struct EXTI16_23_W<'a> { w: &'a mut W, } impl<'a> EXTI16_23_W<'a> { #[doc = r"Writes raw bits to the field"] #[inline(always)] pub unsafe fn bits(self, value: u8) -> &'a mut W { self.w.bits = (self.w.bits & !(0xff << 16)) | (((value as u32) & 0xff) << 16); self.w } } #[doc = "Reader of field `EXTI24_31`"] pub type EXTI24_31_R = crate::R<u8, u8>; #[doc = "Write proxy for field `EXTI24_31`"] pub struct EXTI24_31_W<'a> { w: &'a mut W, } impl<'a> EXTI24_31_W<'a> { #[doc = r"Writes raw bits to the field"] #[inline(always)] pub unsafe fn bits(self, value: u8) -> &'a mut W { self.w.bits = (self.w.bits & !(0xff << 24)) | (((value as u32) & 0xff) << 24); self.w } } impl R { #[doc = "Bits 0:7 - EXTIm GPIO port selection"] #[inline(always)] pub fn exti0_7(&self) -> EXTI0_7_R { EXTI0_7_R::new((self.bits & 0xff) as u8) } #[doc = "Bits 8:15 - EXTIm+1 GPIO port selection"] #[inline(always)] pub fn exti8_15(&self) -> EXTI8_15_R { EXTI8_15_R::new(((self.bits >> 8) & 0xff) as u8) } #[doc = "Bits 16:23 - EXTIm+2 GPIO port selection"] #[inline(always)] pub fn exti16_23(&self) -> EXTI16_23_R { EXTI16_23_R::new(((self.bits >> 16) & 0xff) as u8) } #[doc = "Bits 24:31 - EXTIm+3 GPIO port selection"] #[inline(always)] pub fn exti24_31(&self) -> EXTI24_31_R { EXTI24_31_R::new(((self.bits >> 24) & 0xff) as u8) } } impl W { #[doc = "Bits 0:7 - EXTIm GPIO port selection"] #[inline(always)] pub fn exti0_7(&mut self) -> EXTI0_7_W { EXTI0_7_W { w: self } } #[doc = "Bits 8:15 - EXTIm+1 GPIO port selection"] #[inline(always)] pub fn exti8_15(&mut self) -> EXTI8_15_W { EXTI8_15_W { w: self } } #[doc = "Bits 16:23 - EXTIm+2 GPIO port selection"] #[inline(always)] pub fn exti16_23(&mut self) -> EXTI16_23_W { EXTI16_23_W { w: self } } #[doc = "Bits 24:31 - EXTIm+3 GPIO port selection"] #[inline(always)] pub fn exti24_31(&mut self) -> EXTI24_31_W { EXTI24_31_W { w: self } } }
#[cfg(not(feature = "lib"))] use std::{cell::RefCell, rc::Rc}; use std::mem; use mold::{Path, Point}; #[cfg(not(feature = "lib"))] use crate::{Context, PathId}; #[derive(Debug)] pub struct PathBuilder { #[cfg(not(feature = "lib"))] context: Rc<RefCell<Context>>, current_path: Path, end_point: Point<f32>, end_control_point: Point<f32>, } impl PathBuilder { #[cfg(feature = "lib")] pub fn new() -> Self { Self { current_path: Path::new(), end_point: Point::new(0.0, 0.0), end_control_point: Point::new(0.0, 0.0), } } #[cfg(not(feature = "lib"))] pub fn new(context: Rc<RefCell<Context>>) -> Self { Self { context, current_path: Path::new(), end_point: Point::new(0.0, 0.0), end_control_point: Point::new(0.0, 0.0), } } pub fn move_to(&mut self, x0: f32, y0: f32) { let point = Point::new(x0, y0); self.end_point = point; self.end_control_point = point; } pub fn line_to(&mut self, x1: f32, y1: f32) { let p1 = Point::new(x1, y1); self.current_path.line(self.end_point, p1); self.end_point = p1; self.end_control_point = p1; } pub fn quad_to(&mut self, x1: f32, y1: f32, x2: f32, y2: f32) { let p1 = Point::new(x1, y1); let p2 = Point::new(x2, y2); self.current_path.quad(self.end_point, p1, p2); self.end_point = p2; self.end_control_point = p1; } pub fn quad_smooth_to(&mut self, x2: f32, y2: f32) { let p1 = Point::new( 2.0 * self.end_point.x - self.end_control_point.x, 2.0 * self.end_point.y - self.end_control_point.y, ); let p2 = Point::new(x2, y2); self.current_path.quad(self.end_point, p1, p2); self.end_point = p2; self.end_control_point = p1; } pub fn cubic_to(&mut self, x1: f32, y1: f32, x2: f32, y2: f32, x3: f32, y3: f32) { let p1 = Point::new(x1, y1); let p2 = Point::new(x2, y2); let p3 = Point::new(x3, y3); self.current_path.cubic(self.end_point, p1, p2, p3); self.end_point = p3; self.end_control_point = p2; } pub fn cubic_smooth_to(&mut self, x2: f32, y2: f32, x3: f32, y3: f32) { let p1 = Point::new( 2.0 * self.end_point.x - self.end_control_point.x, 2.0 * self.end_point.y - self.end_control_point.y, ); let p2 = Point::new(x2, y2); let p3 = Point::new(x3, y3); self.current_path.cubic(self.end_point, p1, p2, p3); self.end_point = p3; self.end_control_point = p2; } pub fn rat_quad_to(&mut self, x1: f32, y1: f32, x2: f32, y2: f32, w0: f32) { let p1 = Point::new(x1, y1); let p2 = Point::new(x2, y2); self.current_path .rat_quad((self.end_point, 1.0), (p1, w0), (p2, 1.0)); self.end_point = p2; self.end_control_point = p2; } pub fn rat_cubic_to( &mut self, x1: f32, y1: f32, x2: f32, y2: f32, x3: f32, y3: f32, w0: f32, w1: f32, ) { let p1 = Point::new(x1, y1); let p2 = Point::new(x2, y2); let p3 = Point::new(x3, y3); self.current_path .rat_cubic((self.end_point, 1.0), (p1, w0), (p2, w1), (p3, 1.0)); self.end_point = p3; self.end_control_point = p3; } #[cfg(feature = "lib")] pub fn build(&mut self) -> Path { let mut path = Path::new(); mem::swap(&mut self.current_path, &mut path); path } #[cfg(not(feature = "lib"))] pub fn build(&mut self) -> PathId { let mut path = Path::new(); mem::swap(&mut self.current_path, &mut path); self.context.borrow_mut().insert_path(path) } }
#![feature(asm)] #![feature(plugin)] #![plugin(bytestool)] #![feature(type_ascription)] macro_rules! build_const_mesg { ($bstr1:expr, $bstr2:expr) => {{ const LEN1 : usize = byte_size_of!($bstr1); const LEN2 : usize = byte_size_of!($bstr2); let result : &[u8; LEN1 + LEN2] = concat_bytes!($bstr1, $bstr2); result }}; } fn send_hello() { let mesg_hello = build_const_mesg!(b"HELLO", [23u8, 10u8, 10u8, 0u8] ); // send out the byte message via network } fn send_bye() { let mesg_bye = build_const_mesg!(b"BYE", [23u8, 10u8, 10u8, 0u8] ); // send out the byte message via network } fn main() {} #[cfg(test)] mod tests { #[test] fn test_byte_size_of() { assert_eq!(byte_size_of!(b"012345"), 6); // rust strings without NULL-termination assert_eq!(byte_size_of!(b"A"), 1); // rust strings without NULL-termination assert_eq!(byte_size_of!(b""), 0); assert_eq!(byte_size_of!(b"\x00"), 4); // escaped chars not supported yet assert_eq!(byte_size_of!([0u8, 1u8]), 2); // u8 array } #[test] fn test_concat_bytes() { assert_eq!(concat_bytes!(b"0123", b"45"), b"012345"); assert_eq!(concat_bytes!(b"0123", b"45"), &[48u8, 49u8, 50u8, 51u8, 52u8, 53u8]); assert_eq!(concat_bytes!(b"0123", [52u8, 53u8]), b"012345"); assert_eq!(concat_bytes!([0u8], b"AA", [0u8]), &[0u8, 65u8, 65u8, 0u8]); let const_bytes: &[u8; 4] = concat_bytes!([0u8], b"AA", [0u8]); assert_eq!(const_bytes, &[0u8, 65u8, 65u8, 0u8]); let const_bytes: &[u8; byte_size_of!([0u8, 65u8, 65u8, 0u8])] = concat_bytes!([0u8], b"AA", [0u8]); assert_eq!(const_bytes, &[0u8, 65u8, 65u8, 0u8]); let const_bytes: &[u8; byte_size_of!([65u8, 65u8]) + 2] = concat_bytes!([0u8], b"AA", [0u8]); assert_eq!(const_bytes, &[0u8, 65u8, 65u8, 0u8]); } #[test] fn test_in_macro() { let assembled = assemble!(b"0123", b"45"); assert_eq!(assembled, &[48u8, 49u8, 50u8, 51u8, 52u8, 53u8]); let assembled = assemble!([48u8, 49u8, 50u8, 51u8], [52u8, 53u8]); assert_eq!(assembled, &[48u8, 49u8, 50u8, 51u8, 52u8, 53u8]); } }
use anyhow::{bail,ensure,Context,Result}; use std::path::PathBuf; use clap::Clap; use std::fs::File; use std::io::{stdin,BufRead,BufReader}; struct RpnCalculator(bool); impl RpnCalculator{ pub fn new(verbose:bool) -> Self{ Self(verbose) } pub fn eval(&self,formula: &str)->Result<i32>{ let mut tokens=formula.split_whitespace().rev().collect::<Vec<_>>(); self.eval_inner(&mut tokens) } pub fn eval_inner(&self,tokens: &mut Vec<&str>)->Result<i32>{ let mut stack=Vec::new(); let mut pos=0; while let Some(token)=tokens.pop(){ pos+=1; if let Ok(x)=token.parse::<i32>(){ stack.push(x); }else{ let y = stack.pop().context(format!("invalid syntax at {}",pos))?; let x = stack.pop().context(format!("invalid syntax at {}",pos))?; let res = match token{ "+" => x+y, "-" => x-y, "*" => x*y, "/" => x/y, "%" => x%y, _ => bail!("invalid token at {}",pos), }; stack.push(res); } //-vオプションが指定されている場合は, この時点でのトークンとスタックの状態を出力 if self.0{ println!("{:?} {:?}",tokens,stack); } } ensure!(stack.len()==1,"invalid syntax"); Ok(stack[0]) } } #[derive(Clap,Debug)] #[clap( name="My RPN program", version="1.0.0", author="Your name", about="Super awesome sample RPN calculator" )] struct Opts{ ///Sets the level of verbosity #[clap(short,long)] verbose: bool, ///Formullas written in RPN #[clap(name="FILE")] formula_file: Option<PathBuf>, } fn main()->Result<()>{ let opts = Opts::parse(); if let Some(path)=opts.formula_file{ let f=File::open(path)?; let reader = BufReader::new(f); run(reader, opts.verbose) }else { let stdin=stdin(); let reader=stdin.lock(); run(reader,opts.verbose) } } fn run<R: BufRead>(reader: R, verbose: bool)->Result<()>{ let calc = RpnCalculator::new(verbose); for line in reader.lines(){ let line = line?; match calc.eval(&line){ Ok(answer)=> println!("{}",answer), Err(e)=>eprintln!("{:#?}",e), } } Ok(()) } #[cfg(test)] mod tests{ use super::*; #[test] fn test_ok(){ let calc=RpnCalculator::new(false); assert_eq!(calc.eval("5").unwrap(),5); assert_eq!(calc.eval("50").unwrap(),50); assert_eq!(calc.eval("-50").unwrap(),-50); assert_eq!(calc.eval("2 3 +").unwrap(),5); assert_eq!(calc.eval("2 3 *").unwrap(),6); assert_eq!(calc.eval("2 3 -").unwrap(),-1); assert_eq!(calc.eval("2 3 /").unwrap(),0); assert_eq!(calc.eval("2 3 %").unwrap(),2); } #[test] #[should_panic] fn test_ng(){ let calc=RpnCalculator::new(false); assert!(calc.eval("").is_err()); assert!(calc.eval("1 1 1 +").is_err()); assert!(calc.eval("+ 1 1").is_err()); } }
extern crate bytes; extern crate iovec; use bytes::{Buf, BufMut, Bytes, BytesMut}; use bytes::buf::Chain; use iovec::IoVec; use std::io::Cursor; #[test] fn collect_two_bufs() { let a = Cursor::new(Bytes::from(&b"hello"[..])); let b = Cursor::new(Bytes::from(&b"world"[..])); let res: Vec<u8> = a.chain(b).collect(); assert_eq!(res, &b"helloworld"[..]); } #[test] fn writing_chained() { let mut a = BytesMut::with_capacity(64); let mut b = BytesMut::with_capacity(64); { let mut buf = Chain::new(&mut a, &mut b); for i in 0..128 { buf.put(i as u8); } } assert_eq!(64, a.len()); assert_eq!(64, b.len()); for i in 0..64 { let expect = i as u8; assert_eq!(expect, a[i]); assert_eq!(expect + 64, b[i]); } } #[test] fn iterating_two_bufs() { let a = Cursor::new(Bytes::from(&b"hello"[..])); let b = Cursor::new(Bytes::from(&b"world"[..])); let res: Vec<u8> = a.chain(b).iter().collect(); assert_eq!(res, &b"helloworld"[..]); } #[test] fn vectored_read() { let a = Cursor::new(Bytes::from(&b"hello"[..])); let b = Cursor::new(Bytes::from(&b"world"[..])); let mut buf = a.chain(b); { let b1: &[u8] = &mut [0]; let b2: &[u8] = &mut [0]; let b3: &[u8] = &mut [0]; let b4: &[u8] = &mut [0]; let mut iovecs: [&IoVec; 4] = [b1.into(), b2.into(), b3.into(), b4.into()]; assert_eq!(2, buf.bytes_vec(&mut iovecs)); assert_eq!(iovecs[0][..], b"hello"[..]); assert_eq!(iovecs[1][..], b"world"[..]); assert_eq!(iovecs[2][..], b"\0"[..]); assert_eq!(iovecs[3][..], b"\0"[..]); } buf.advance(2); { let b1: &[u8] = &mut [0]; let b2: &[u8] = &mut [0]; let b3: &[u8] = &mut [0]; let b4: &[u8] = &mut [0]; let mut iovecs: [&IoVec; 4] = [b1.into(), b2.into(), b3.into(), b4.into()]; assert_eq!(2, buf.bytes_vec(&mut iovecs)); assert_eq!(iovecs[0][..], b"llo"[..]); assert_eq!(iovecs[1][..], b"world"[..]); assert_eq!(iovecs[2][..], b"\0"[..]); assert_eq!(iovecs[3][..], b"\0"[..]); } buf.advance(3); { let b1: &[u8] = &mut [0]; let b2: &[u8] = &mut [0]; let b3: &[u8] = &mut [0]; let b4: &[u8] = &mut [0]; let mut iovecs: [&IoVec; 4] = [b1.into(), b2.into(), b3.into(), b4.into()]; assert_eq!(1, buf.bytes_vec(&mut iovecs)); assert_eq!(iovecs[0][..], b"world"[..]); assert_eq!(iovecs[1][..], b"\0"[..]); assert_eq!(iovecs[2][..], b"\0"[..]); assert_eq!(iovecs[3][..], b"\0"[..]); } buf.advance(3); { let b1: &[u8] = &mut [0]; let b2: &[u8] = &mut [0]; let b3: &[u8] = &mut [0]; let b4: &[u8] = &mut [0]; let mut iovecs: [&IoVec; 4] = [b1.into(), b2.into(), b3.into(), b4.into()]; assert_eq!(1, buf.bytes_vec(&mut iovecs)); assert_eq!(iovecs[0][..], b"ld"[..]); assert_eq!(iovecs[1][..], b"\0"[..]); assert_eq!(iovecs[2][..], b"\0"[..]); assert_eq!(iovecs[3][..], b"\0"[..]); } }
use crate::{Icon, ResampleError}; use std::{ convert::From, error::Error, fmt::{self, Debug, Display, Formatter}, io }; /// The error type for operations of the `Encode` trait. pub enum EncodingError<I: Icon + Send + Sync> { /// The icon family already contains this icon. AlreadyIncluded(I), /// A resampling error. Resample(ResampleError), /// The icon family aready stores the maximum number of icons possible. Full(u16) } impl<I: Icon + Send + Sync> Display for EncodingError<I> { fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { match self { Self::AlreadyIncluded(_) => write!( f, "The icon family already contains this icon" ), Self::Resample(err) => <ResampleError as Display>::fmt(&err, f), Self::Full(max_n) => write!( f, "The icon family has already reached it's maximum capacity ({} icons)", max_n ) } } } impl<I: Icon + Send + Sync + Debug> Debug for EncodingError<I> { fn fmt(&self, f: &mut Formatter) -> fmt::Result { match self { Self::AlreadyIncluded(e) => write!( f, "EncodingError::AlreadyIncluded({:?})", e ), Self::Resample(err) => write!(f, "EncodingError::Resample({:?})", err), Self::Full(n) => write!(f, "EncodingError::Full({})", n) } } } impl<I: Icon + Send + Sync + Debug> Error for EncodingError<I> { fn source(&self) -> Option<&(dyn Error + 'static)> { if let Self::Resample(ref err) = self { err.source() } else { None } } } impl<I: Icon + Send + Sync> From<ResampleError> for EncodingError<I> { fn from(err: ResampleError) -> Self { Self::Resample(err) } } impl<I: Icon + Send + Sync> From<io::Error> for EncodingError<I> { fn from(err: io::Error) -> Self { Self::from(ResampleError::from(err)) } } impl<I: Icon + Send + Sync> From<EncodingError<I>> for io::Error { fn from(err: EncodingError<I>) -> io::Error { if let EncodingError::Resample(err) = err { err.into() } else { io::Error::new(io::ErrorKind::InvalidInput, format!("{}", err)) } } }
use std::marker::PhantomData; use futures::{try_ready, Async, Future, Poll}; use super::{IntoNewService, NewService, Service}; use crate::cell::Cell; /// Service for the `and_then` combinator, chaining a computation onto the end /// of another service which completes successfully. /// /// This is created by the `ServiceExt::and_then` method. pub struct AndThen<A, B> { a: A, b: Cell<B>, } impl<A, B> AndThen<A, B> { /// Create new `AndThen` combinator pub fn new(a: A, b: B) -> Self where A: Service, B: Service<Request = A::Response, Error = A::Error>, { Self { a, b: Cell::new(b) } } } impl<A, B> Clone for AndThen<A, B> where A: Clone, { fn clone(&self) -> Self { AndThen { a: self.a.clone(), b: self.b.clone(), } } } impl<A, B> Service for AndThen<A, B> where A: Service, B: Service<Request = A::Response, Error = A::Error>, { type Request = A::Request; type Response = B::Response; type Error = A::Error; type Future = AndThenFuture<A, B>; fn poll_ready(&mut self) -> Poll<(), Self::Error> { try_ready!(self.a.poll_ready()); self.b.get_mut().poll_ready() } fn call(&mut self, req: A::Request) -> Self::Future { AndThenFuture::new(self.a.call(req), self.b.clone()) } } pub struct AndThenFuture<A, B> where A: Service, B: Service<Request = A::Response, Error = A::Error>, { b: Cell<B>, fut_b: Option<B::Future>, fut_a: Option<A::Future>, } impl<A, B> AndThenFuture<A, B> where A: Service, B: Service<Request = A::Response, Error = A::Error>, { fn new(a: A::Future, b: Cell<B>) -> Self { AndThenFuture { b, fut_a: Some(a), fut_b: None, } } } impl<A, B> Future for AndThenFuture<A, B> where A: Service, B: Service<Request = A::Response, Error = A::Error>, { type Item = B::Response; type Error = A::Error; fn poll(&mut self) -> Poll<Self::Item, Self::Error> { if let Some(ref mut fut) = self.fut_b { return fut.poll(); } match self.fut_a.as_mut().expect("Bug in actix-service").poll() { Ok(Async::Ready(resp)) => { let _ = self.fut_a.take(); self.fut_b = Some(self.b.get_mut().call(resp)); self.poll() } Ok(Async::NotReady) => Ok(Async::NotReady), Err(err) => Err(err), } } } /// `AndThenNewService` new service combinator pub struct AndThenNewService<A, B, C> { a: A, b: B, _t: PhantomData<C>, } impl<A, B, C> AndThenNewService<A, B, C> { /// Create new `AndThen` combinator pub fn new<F: IntoNewService<B, C>>(a: A, f: F) -> Self where A: NewService<C>, B: NewService<C, Request = A::Response, Error = A::Error, InitError = A::InitError>, { Self { a, b: f.into_new_service(), _t: PhantomData, } } } impl<A, B, C> NewService<C> for AndThenNewService<A, B, C> where A: NewService<C>, B: NewService<C, Request = A::Response, Error = A::Error, InitError = A::InitError>, { type Request = A::Request; type Response = B::Response; type Error = A::Error; type Service = AndThen<A::Service, B::Service>; type InitError = A::InitError; type Future = AndThenNewServiceFuture<A, B, C>; fn new_service(&self, cfg: &C) -> Self::Future { AndThenNewServiceFuture::new(self.a.new_service(cfg), self.b.new_service(cfg)) } } impl<A, B, C> Clone for AndThenNewService<A, B, C> where A: Clone, B: Clone, { fn clone(&self) -> Self { Self { a: self.a.clone(), b: self.b.clone(), _t: PhantomData, } } } pub struct AndThenNewServiceFuture<A, B, C> where A: NewService<C>, B: NewService<C, Request = A::Response>, { fut_b: B::Future, fut_a: A::Future, a: Option<A::Service>, b: Option<B::Service>, } impl<A, B, C> AndThenNewServiceFuture<A, B, C> where A: NewService<C>, B: NewService<C, Request = A::Response>, { fn new(fut_a: A::Future, fut_b: B::Future) -> Self { AndThenNewServiceFuture { fut_a, fut_b, a: None, b: None, } } } impl<A, B, C> Future for AndThenNewServiceFuture<A, B, C> where A: NewService<C>, B: NewService<C, Request = A::Response, Error = A::Error, InitError = A::InitError>, { type Item = AndThen<A::Service, B::Service>; type Error = A::InitError; fn poll(&mut self) -> Poll<Self::Item, Self::Error> { if self.a.is_none() { if let Async::Ready(service) = self.fut_a.poll()? { self.a = Some(service); } } if self.b.is_none() { if let Async::Ready(service) = self.fut_b.poll()? { self.b = Some(service); } } if self.a.is_some() && self.b.is_some() { Ok(Async::Ready(AndThen::new( self.a.take().unwrap(), self.b.take().unwrap(), ))) } else { Ok(Async::NotReady) } } } #[cfg(test)] mod tests { use futures::future::{ok, FutureResult}; use futures::{Async, Poll}; use std::cell::Cell; use std::rc::Rc; use super::*; use crate::{NewService, Service, ServiceExt}; struct Srv1(Rc<Cell<usize>>); impl Service for Srv1 { type Request = &'static str; type Response = &'static str; type Error = (); type Future = FutureResult<Self::Response, ()>; fn poll_ready(&mut self) -> Poll<(), Self::Error> { self.0.set(self.0.get() + 1); Ok(Async::Ready(())) } fn call(&mut self, req: &'static str) -> Self::Future { ok(req) } } #[derive(Clone)] struct Srv2(Rc<Cell<usize>>); impl Service for Srv2 { type Request = &'static str; type Response = (&'static str, &'static str); type Error = (); type Future = FutureResult<Self::Response, ()>; fn poll_ready(&mut self) -> Poll<(), Self::Error> { self.0.set(self.0.get() + 1); Ok(Async::Ready(())) } fn call(&mut self, req: &'static str) -> Self::Future { ok((req, "srv2")) } } #[test] fn test_poll_ready() { let cnt = Rc::new(Cell::new(0)); let mut srv = Srv1(cnt.clone()).and_then(Srv2(cnt.clone())); let res = srv.poll_ready(); assert!(res.is_ok()); assert_eq!(res.unwrap(), Async::Ready(())); assert_eq!(cnt.get(), 2); } #[test] fn test_call() { let cnt = Rc::new(Cell::new(0)); let mut srv = Srv1(cnt.clone()).and_then(Srv2(cnt)); let res = srv.call("srv1").poll(); assert!(res.is_ok()); assert_eq!(res.unwrap(), Async::Ready(("srv1", "srv2"))); } #[test] fn test_new_service() { let cnt = Rc::new(Cell::new(0)); let cnt2 = cnt.clone(); let blank = move || Ok::<_, ()>(Srv1(cnt2.clone())); let new_srv = blank .into_new_service() .and_then(move || Ok(Srv2(cnt.clone()))); if let Async::Ready(mut srv) = new_srv.new_service(&()).poll().unwrap() { let res = srv.call("srv1").poll(); assert!(res.is_ok()); assert_eq!(res.unwrap(), Async::Ready(("srv1", "srv2"))); } else { panic!() } } }
use std::sync::Arc; use super::{structure, Error}; use crate::{tokenizer::tag::Tagger, types::*}; use crate::{utils, utils::regex::SerializeRegex}; use lazy_static::lazy_static; use onig::Regex; use serde::{Deserialize, Serialize}; pub use structure::{read_disambiguation_rules, read_rules}; use crate::rule::disambiguation::*; use crate::rule::engine::composition::concrete::*; use crate::rule::engine::composition::*; use crate::rule::engine::*; use crate::rule::grammar::*; use crate::rule::{DisambiguationRule, Rule, Unification}; // TODO: should be an option in config OR restricted to one sentence fn max_matches() -> usize { 20 } #[derive(Serialize, Deserialize, Debug)] pub struct RegexCache { cache: DefaultHashMap<u64, Option<DefaultHashSet<WordIdInt>>>, // this is compared with the hash of the word store of the tagger word_hash: u64, } impl RegexCache { pub fn new(word_hash: u64) -> Self { RegexCache { cache: DefaultHashMap::default(), word_hash, } } pub fn word_hash(&self) -> &u64 { &self.word_hash } pub fn set_word_hash(&self) -> &u64 { &self.word_hash } pub(crate) fn get(&self, key: &u64) -> Option<&Option<DefaultHashSet<WordIdInt>>> { self.cache.get(key) } pub(crate) fn insert(&mut self, key: u64, value: Option<DefaultHashSet<WordIdInt>>) { self.cache.insert(key, value); } } pub struct BuildInfo { tagger: Arc<Tagger>, regex_cache: RegexCache, } impl BuildInfo { pub fn new(tagger: Arc<Tagger>, regex_cache: RegexCache) -> Self { BuildInfo { tagger, regex_cache, } } pub fn tagger(&self) -> &Arc<Tagger> { &self.tagger } pub fn mut_regex_cache(&mut self) -> &mut RegexCache { &mut self.regex_cache } } fn parse_match_attribs( attribs: impl structure::MatchAttributes, text: Option<&str>, case_sensitive: bool, text_match_idx: Option<usize>, info: &mut BuildInfo, ) -> Result<Atom, Error> { let mut atoms: Vec<Atom> = Vec::new(); let case_sensitive = match attribs.case_sensitive().as_deref() { Some("yes") => true, Some("no") => false, None => case_sensitive, x => panic!("unknown case_sensitive value {:?}", x), }; let inflected = match attribs.inflected().as_deref() { Some("yes") => true, Some("no") => false, None => false, x => panic!("unknown inflected value {:?}", x), }; let is_regex = match attribs.regexp().as_deref() { Some("yes") => true, None => false, x => panic!("unknown regexp value {:?}", x), }; let is_postag_regexp = match attribs.postag_regexp().as_deref() { Some("yes") => true, None => false, x => panic!("unknown postag_regexp value {:?}", x), }; let negate = match attribs.negate().as_deref() { Some("yes") => true, None => false, x => panic!("unknown negate value {:?}", x), }; let negate_pos = match attribs.negate_pos().as_deref() { Some("yes") => true, None => false, x => panic!("unknown negate_pos value {:?}", x), }; let mut inflect_matcher = None; let mut pos_matcher = None; if text.is_some() || text_match_idx.is_some() { let matcher = if is_regex { if let Some(text) = text { let regex = SerializeRegex::new(text.trim(), true, case_sensitive); Matcher::new_regex(regex?, negate, inflected) } else { return Err(Error::Unexpected("`text` must be set if regex".into())); } } else { Matcher::new_string( text_match_idx.map_or_else( || { either::Left( text.expect("either `text_match_idx` or `text` are set.") .trim() .to_string(), ) }, // this is validated in Composition::new, otherwise creating a graph id is not valid! |id| either::Right(GraphId(id)), ), negate, case_sensitive, inflected, ) }; if inflected { inflect_matcher = Some(matcher); } else { atoms.push( (TextAtom { matcher: TextMatcher::new(matcher, info), }) .into(), ); } } if let Some(postag) = attribs.postag() { let raw_matcher = if is_postag_regexp { let regex = SerializeRegex::new(&postag.trim(), true, true); Matcher::new_regex(regex?, negate_pos, true) } else { Matcher::new_string( either::Left(postag.trim().to_string()), negate_pos, true, true, ) }; pos_matcher = Some(PosMatcher::new(raw_matcher, info)); } if pos_matcher.is_some() || inflect_matcher.is_some() { let matcher = WordDataMatcher { pos_matcher, inflect_matcher: inflect_matcher.map(|x| TextMatcher::new(x, info)), }; atoms.push( (WordDataAtom { matcher, case_sensitive, }) .into(), ); } match (attribs.chunk(), attribs.chunk_re()) { (Some(chunk), None) => { let chunk_atom = ChunkAtom { matcher: Matcher::new_string( either::Left(chunk.trim().to_string()), false, true, true, ), }; atoms.push(chunk_atom.into()); } (None, Some(chunk_re)) => { let regex = SerializeRegex::new(chunk_re.trim(), true, true)?; let chunk_atom = ChunkAtom { matcher: Matcher::new_regex(regex, false, true), }; atoms.push(chunk_atom.into()); } (None, None) => {} _ => panic!("unexpected combination of chunk / chunk_re values."), } if let Some(chunk) = attribs.chunk() { let chunk_atom = ChunkAtom { matcher: Matcher::new_string(either::Left(chunk.trim().to_string()), false, true, true), }; atoms.push(chunk_atom.into()); } if let Some(space_before) = attribs.spacebefore() { let value = match space_before.as_str() { "yes" => true, "no" => false, _ => panic!("unknown spacebefore value {}", space_before), }; atoms.push((SpaceBeforeAtom { value }).into()); } Ok(AndAtom::and(atoms)) } fn get_exceptions( token: &structure::Token, case_sensitive: bool, only_shifted: bool, info: &mut BuildInfo, ) -> Result<Atom, Error> { if let Some(parts) = &token.parts { let exceptions: Vec<Atom> = parts .iter() .filter_map(|x| match x { structure::TokenPart::Exception(x) => Some(x), _ => None, }) .filter_map(|x| { let exception_text = if let Some(exception_text) = &x.text { Some(exception_text.as_str()) } else { None }; let mut atom = match parse_match_attribs(x, exception_text, case_sensitive, None, info) { Ok(atom) => atom, Err(err) => return Some(Err(err)), }; let offset = if let Some(scope) = &x.scope { match scope.as_str() { "next" => 1, "current" => 0, "previous" => -1, _ => panic!("unknown scope value {}", scope), } } else { 0 }; if offset != 0 { atom = OffsetAtom::new(atom, offset).into(); } if !only_shifted || (offset != 0) { Some(Ok(atom)) } else { None } }) .collect::<Result<Vec<_>, Error>>()?; Ok(NotAtom::not(OrAtom::or(exceptions))) } else { Ok((TrueAtom {}).into()) } } fn parse_token( token: &structure::Token, case_sensitive: bool, info: &mut BuildInfo, ) -> Result<Vec<Part>, Error> { let mut parts = Vec::new(); let text = if let Some(parts) = &token.parts { parts.iter().find_map(|x| match x { structure::TokenPart::Text(text) => Some(text.as_str()), _ => None, }) } else { None }; let text_match_idx = if let Some(parts) = &token.parts { match parts.iter().find_map(|x| match x { structure::TokenPart::Sub(sub) => Some(sub.no.parse::<usize>().map(|x| x + 1)), _ => None, }) { None => None, Some(Ok(x)) => Some(x), Some(Err(err)) => return Err(err.into()), } } else { None }; let min = token .min .clone() .map(|x| { if x == "-1" { max_matches() } else { x.parse().expect("can't parse min as usize") } }) .unwrap_or(1usize); let mut max = token .max .clone() .map(|x| { if x == "-1" { max_matches() } else { x.parse().expect("can't parse max as usize") } }) .unwrap_or(1usize); if min > 1 && max == 1 { max = max_matches(); } let quantifier = Quantifier::new(min, max); let mut atom = parse_match_attribs(token, text, case_sensitive, text_match_idx, info)?; atom = AndAtom::and(vec![ atom, get_exceptions(token, case_sensitive, false, info)?, ]); parts.push(Part { atom, quantifier, visible: true, greedy: true, unify: token.unify.as_ref().map(|x| x == "yes"), }); if let Some(to_skip) = token.skip.clone() { let to_skip = if to_skip == "-1" { max_matches() } else { to_skip.parse().expect("can't parse skip as usize or -1") }; parts.push(Part { atom: get_exceptions(token, case_sensitive, true, info)?, quantifier: Quantifier::new(0, to_skip), visible: false, greedy: false, unify: None, }); } Ok(parts) } fn parse_match(m: structure::Match, engine: &Engine, info: &mut BuildInfo) -> Result<Match, Error> { if m.postag.is_some() || m.postag_regex.is_some() || m.postag_replace.is_some() || m.text.is_some() { return Err(Error::Unimplemented( "postag, postag_regex, postag_replace and text in `match` are not implemented.".into(), )); } if m.include_skipped.is_some() { return Err(Error::Unimplemented( "include_skipped in `match` is not implemented.".into(), )); } let id = m.no.parse::<usize>() .expect("no must be parsable as usize."); let case_conversion = if let Some(conversion) = &m.case_conversion { Some(conversion.as_str()) } else { None }; let pos_replacer = if let Some(postag) = m.postag { if postag.contains("+DT") || postag.contains("+INDT") { return Err(Error::Unimplemented( "+DT and +INDT determiners are not implemented.".into(), )); } let matcher = match m.postag_regex.as_deref() { Some("yes") => { let regex = SerializeRegex::new(&postag, true, false)?; Matcher::new_regex(regex, false, true) } None => Matcher::new_string(either::Left(postag), false, false, true), x => panic!("unknown postag_regex value {:?}", x), }; Some(PosReplacer { matcher: PosMatcher::new(matcher, info), }) } else { None }; let regex_replacer = match (m.regexp_match, m.regexp_replace) { (Some(regex_match), Some(regex_replace)) => Some(( SerializeRegex::new(&regex_match, false, true)?, regex_replace, )), _ => None, }; Ok(Match { id: engine.to_graph_id(id)?, conversion: match case_conversion { Some("alllower") => Conversion::AllLower, Some("startlower") => Conversion::StartLower, Some("startupper") => Conversion::StartUpper, Some("allupper") => Conversion::AllUpper, Some(x) => { return Err(Error::Unimplemented(format!( "case conversion {} not supported.", x ))) } None => Conversion::Nop, }, pos_replacer, regex_replacer, }) } fn parse_synthesizer_text(text: &str, engine: &Engine) -> Result<Vec<SynthesizerPart>, Error> { lazy_static! { static ref MATCH_REGEX: Regex = Regex::new(r"\\(\d)").expect("number regex is valid"); } let mut parts = Vec::new(); let mut end_index = 0; for capture in MATCH_REGEX.captures_iter(&text) { let (start, end) = capture.pos(0).expect("0th regex group exists"); if end_index != start { parts.push(SynthesizerPart::Text((&text[end_index..start]).to_string())) } let id = capture .at(1) .expect("1st regex group exists") .parse::<usize>() .expect("match regex capture must be parsable as usize."); parts.push(SynthesizerPart::Match(Match { id: engine.to_graph_id(id)?, conversion: Conversion::Nop, pos_replacer: None, regex_replacer: None, })); end_index = end; } if end_index < text.len() { parts.push(SynthesizerPart::Text((&text[end_index..]).to_string())) } Ok(parts) } fn parse_suggestion( data: structure::Suggestion, engine: &Engine, info: &mut BuildInfo, ) -> Result<Synthesizer, Error> { let mut parts = Vec::new(); for part in data.parts { match part { structure::SuggestionPart::Text(text) => { parts.extend(parse_synthesizer_text(text.as_str(), engine)?); } structure::SuggestionPart::Match(m) => { parts.push(SynthesizerPart::Match(parse_match(m, engine, info)?)); } } } Ok(Synthesizer { parts, // use titlecase adjustment (i. e. make replacement title case if match is title case) if token rule use_titlecase_adjust: matches!(engine, Engine::Token(_)), }) } fn get_last_id(parts: &[Part]) -> isize { parts.iter().fold(1, |a, x| a + x.visible as isize) } fn parse_parallel_tokens( tokens: &[structure::Token], case_sensitive: bool, info: &mut BuildInfo, ) -> Result<Vec<Atom>, Error> { tokens .iter() .map(|x| { let mut parsed = parse_token(x, case_sensitive, info)?; if parsed.len() != 1 || parsed[0].quantifier.min != 1 || parsed[0].quantifier.max != 1 { return Err(Error::Unimplemented( "control flow in parallel tokens is not implemented.".into(), )); } Ok(parsed.remove(0).atom) }) .collect() } fn parse_tokens( tokens: &[structure::TokenCombination], case_sensitive: bool, info: &mut BuildInfo, ) -> Result<Vec<Part>, Error> { let mut out = Vec::new(); for token_combination in tokens { out.extend(match token_combination { structure::TokenCombination::Token(token) => parse_token(token, case_sensitive, info)?, structure::TokenCombination::And(tokens) => { let atom = AndAtom::and(parse_parallel_tokens(&tokens.tokens, case_sensitive, info)?); vec![Part { atom, quantifier: Quantifier::new(1, 1), greedy: true, visible: true, unify: tokens.tokens[0].unify.as_ref().map(|x| x == "yes"), }] } structure::TokenCombination::Or(tokens) => { let atom = OrAtom::or(parse_parallel_tokens(&tokens.tokens, case_sensitive, info)?); vec![Part { atom, quantifier: Quantifier::new(1, 1), greedy: true, visible: true, unify: tokens.tokens[0].unify.as_ref().map(|x| x == "yes"), }] } structure::TokenCombination::Feature(_) => Vec::new(), }); } Ok(out) } fn parse_pattern( pattern: structure::Pattern, info: &mut BuildInfo, ) -> Result<(Composition, usize, usize), Error> { let mut start = None; let mut end = None; let mut composition_parts = Vec::new(); let case_sensitive = match &pattern.case_sensitive { Some(string) => string == "yes", None => false, }; for part in &pattern.parts { match part { structure::PatternPart::Token(token) => { composition_parts.extend(parse_token(token, case_sensitive, info)?) } structure::PatternPart::Marker(marker) => { start = Some(get_last_id(&composition_parts)); composition_parts.extend(parse_tokens(&marker.tokens, case_sensitive, info)?); end = Some(get_last_id(&composition_parts)); } structure::PatternPart::And(tokens) => { let atom = AndAtom::and(parse_parallel_tokens(&tokens.tokens, case_sensitive, info)?); composition_parts.push(Part { atom, quantifier: Quantifier::new(1, 1), greedy: true, visible: true, unify: tokens.tokens[0].unify.as_ref().map(|x| x == "yes"), }); } structure::PatternPart::Or(tokens) => { let atom = OrAtom::or(parse_parallel_tokens(&tokens.tokens, case_sensitive, info)?); composition_parts.push(Part { atom, quantifier: Quantifier::new(1, 1), greedy: true, visible: true, unify: tokens.tokens[0].unify.as_ref().map(|x| x == "yes"), }); } structure::PatternPart::Feature(_) => {} } } let start = start.unwrap_or(1) as usize; let end = end.unwrap_or_else(|| get_last_id(&composition_parts)) as usize - 1; let composition = Composition::new(composition_parts)?; Ok((composition, start, end)) } fn parse_features( pattern: &structure::Pattern, unifications: &Option<Vec<structure::Unification>>, info: &mut BuildInfo, ) -> Vec<Vec<POSFilter>> { let mut filters = Vec::new(); let mut parse_feature = |id: &str| -> Vec<POSFilter> { let unification = unifications .as_ref() .unwrap() .iter() .find(|x| x.feature == id) .unwrap(); unification .equivalences .iter() .map(|equiv| { parse_pos_filter( &equiv.token.postag, equiv.token.postag_regexp.as_deref(), info, ) }) .collect() }; for part in &pattern.parts { match part { structure::PatternPart::Feature(feature) => filters.push(parse_feature(&feature.id)), structure::PatternPart::Marker(marker) => { for token_combination in &marker.tokens { if let structure::TokenCombination::Feature(feature) = token_combination { filters.push(parse_feature(&feature.id)); } } } _ => {} } } filters } impl Rule { pub fn from_rule_structure(data: structure::Rule, info: &mut BuildInfo) -> Result<Rule, Error> { if data.filter.is_some() { return Err(Error::Unimplemented( "rules with filter are not implemented.".into(), )); } let (engine, start, end) = match (&data.pattern, data.regex) { (Some(_), Some(_)) => Err(Error::Unexpected( "must not contain both `pattern` and `regexp`.".into(), )), (None, None) => Err(Error::Unexpected( "either `pattern` or `regexp` must be supplied.".into(), )), (Some(pattern), None) => { let (composition, start, end) = parse_pattern(pattern.clone(), info)?; let antipatterns = if let Some(antipatterns) = data.antipatterns { antipatterns .into_iter() .map(|pattern| parse_pattern(pattern, info).map(|x| x.0)) .collect::<Result<Vec<_>, Error>>()? } else { Vec::new() }; if antipatterns .iter() .any(|pattern| pattern.parts.iter().any(|x| x.unify.is_some())) { return Err(Error::Unimplemented( "`unify` in antipattern is not supported.".into(), )); } Ok(( Engine::Token(TokenEngine { composition, antipatterns, }), start, end, )) } (None, Some(regex)) => { let case_sensitive = match regex.case_sensitive.as_deref() { Some("yes") => true, None => false, x => panic!("unknown case_sensitive value {:?}", x), }; let mark = regex.mark.map_or(Ok(0), |x| x.parse())?; let regex = SerializeRegex::new(&regex.text, false, case_sensitive)?; let id_to_idx: DefaultHashMap<GraphId, usize> = (0..regex.captures_len() + 1) .enumerate() // the IDs in a regex rule are just the same as indices .map(|(key, value)| (GraphId(key), value)) .collect(); Ok((Engine::Text(regex, id_to_idx), mark, mark)) } }?; let maybe_composition = if let Engine::Token(engine) = &engine { Some(&engine.composition) } else { None }; let unify_data = if let Some(pattern) = &data.pattern { let unify_filters = parse_features(&pattern, &data.unifications, info); let unify_mask: Vec<_> = maybe_composition .unwrap() .parts .iter() .map(|part| part.unify) .collect(); Some((unify_filters, unify_mask)) } else { None }; let mut message_parts = Vec::new(); let mut suggesters = Vec::new(); for part in data.message.parts { match part { structure::MessagePart::Suggestion(suggestion) => { let suggester = parse_suggestion(suggestion.clone(), &engine, info)?; // simpler to just parse a second time than cloning the result message_parts.extend(parse_suggestion(suggestion, &engine, info)?.parts); suggesters.push(suggester); } structure::MessagePart::Text(text) => { message_parts.extend(parse_synthesizer_text(text.as_str(), &engine)?); } structure::MessagePart::Match(m) => { message_parts.push(SynthesizerPart::Match(parse_match(m, &engine, info)?)); } } } if let Some(suggestions) = data.suggestions { for suggestion in suggestions { suggesters.push(parse_suggestion(suggestion, &engine, info)?); } } if suggesters.is_empty() { return Err(Error::Unimplemented( "rules with no suggestion are not implemented.".into(), )); } assert!(!message_parts.is_empty(), "Rules must have a message."); let mut examples = Vec::new(); for example in &data.examples { if example.kind.is_some() { return Err(Error::Unimplemented( "examples with `type` (i. e. 'triggers_error') are not implemented.".into(), )); } let mut texts = Vec::new(); let mut char_length = 0; let mut suggestion: Option<Suggestion> = None; for part in &example.parts { match part { structure::ExamplePart::Text(text) => { texts.push(text.as_str()); char_length += text.chars().count(); } structure::ExamplePart::Marker(marker) => { if suggestion.is_some() { return Err(Error::Unexpected( "example must have one or zero markers".into(), )); } texts.push(marker.text.as_str()); let length = marker.text.chars().count(); if let Some(correction_text) = &example.correction { let mut replacements: Vec<_> = correction_text.split('|').map(|x| x.to_string()).collect(); replacements = if char_length == 0 { // title case if at start replacements .into_iter() .map(|x| { utils::apply_to_first(&x, |c| c.to_uppercase().collect()) }) .collect() } else { replacements }; suggestion = Some(Suggestion { source: "_Test".to_string(), message: "_Test".to_string(), start: char_length, end: char_length + length, replacements, }); } char_length += marker.text.chars().count(); } } } examples.push(Example { text: texts.join(""), suggestion, }); } let unification = if let Some((unify_filters, unify_mask)) = unify_data { if unify_filters.is_empty() { None } else { Some(Unification { filters: unify_filters, mask: unify_mask, }) } } else { None }; Ok(Rule { start: engine.to_graph_id(start)?, end: engine.to_graph_id(end)?, engine, unification, examples, suggesters, message: Synthesizer { parts: message_parts, use_titlecase_adjust: true, }, url: data.url.map(|x| x.to_string()), short: data.short.map(|x| x.to_string()), // attributes below need information from rule group / category, so are set later id: String::new(), name: String::new(), on: true, category_id: String::new(), category_name: String::new(), category_type: None, }) } } fn parse_tag_form(form: &str, info: &mut BuildInfo) -> Result<owned::Word, Error> { lazy_static! { static ref REGEX: Regex = Regex::new(r"(.+?)\[(.+?)\]").expect("tag form regex is valid"); } let captures = REGEX .captures(form) .ok_or_else(|| Error::Unexpected(format!("tag form must match regex, found '{}'", form)))?; let text = captures.at(1).expect("1st regex group exists").to_string(); let tags = captures.at(2).expect("2nd regex group exists"); let tags = tags .split(',') .filter_map(|x| { if x == "</S>" { // special symbol, presumably for SENT_END, can be ignored return None; } let parts: Vec<_> = x.split('/').collect(); if parts.len() < 2 { None } else { Some(owned::WordData::new( info.tagger.id_word(parts[0].into()).to_owned_id(), info.tagger.id_tag(parts[1]).to_owned_id(), )) } }) .collect(); Ok(owned::Word { text: info.tagger.id_word(text.into()).to_owned_id(), tags, }) } impl owned::WordData { fn from_structure(data: structure::WordData, info: &mut BuildInfo) -> Self { owned::WordData::new( info.tagger .id_word(data.lemma.unwrap_or_else(String::new).into()) .to_owned_id(), info.tagger .id_tag(data.pos.as_ref().map_or("", |x| x.as_str().trim())) .to_owned_id(), ) } } fn parse_pos_filter(postag: &str, postag_regexp: Option<&str>, info: &mut BuildInfo) -> POSFilter { match postag_regexp.as_deref() { Some("yes") => POSFilter::new(PosMatcher::new( Matcher::new_regex( SerializeRegex::new(&postag, true, true).unwrap(), false, true, ), info, )), Some(_) | None => POSFilter::new(PosMatcher::new( Matcher::new_string(either::Left(postag.into()), false, false, true), info, )), } } impl DisambiguationRule { pub fn from_rule_structure( data: structure::DisambiguationRule, info: &mut BuildInfo, ) -> Result<DisambiguationRule, Error> { // might need the pattern later so clone it here let (composition, start, end) = parse_pattern(data.pattern.clone(), info)?; let unify_filters = parse_features(&data.pattern, &data.unifications, info); let unify_mask: Vec<_> = composition.parts.iter().map(|part| part.unify).collect(); let antipatterns = if let Some(antipatterns) = data.antipatterns { antipatterns .into_iter() .map(|pattern| parse_pattern(pattern, info).map(|x| x.0)) .collect::<Result<Vec<_>, Error>>()? } else { Vec::new() }; if antipatterns .iter() .any(|pattern| pattern.parts.iter().any(|x| x.unify.is_some())) { return Err(Error::Unimplemented( "`unify` in antipattern is not supported.".into(), )); } let engine = Engine::Token(TokenEngine { composition, antipatterns, }); let word_datas: Vec<_> = if let Some(wds) = data.disambig.word_datas { wds.into_iter() .map(|part| match part { structure::DisambiguationPart::WordData(x) => { either::Left(owned::WordData::from_structure(x, info)) } structure::DisambiguationPart::Match(x) => either::Right(parse_pos_filter( &x.postag.unwrap(), x.postag_regexp.as_deref(), info, )), }) .collect() } else { Vec::new() }; let disambiguations = match data.disambig.action.as_deref() { Some("remove") => { if let Some(postag) = data.disambig.postag.as_ref() { Ok(Disambiguation::Remove(vec![either::Right( parse_pos_filter(postag, Some("yes"), info), )])) } else { Ok(Disambiguation::Remove(word_datas.into_iter().collect())) } } Some("add") => { if data.disambig.postag.is_some() { return Err(Error::Unimplemented( "postag not supported for `add`.".into(), )); } Ok(Disambiguation::Add( word_datas .into_iter() .map(|x| x.left().expect("match not supported for `add`")) .collect(), )) } Some("replace") => Ok(Disambiguation::Replace( word_datas .into_iter() .map(|x| { x.left() .expect("match not supported for `replace` disambiguation") }) .collect(), )), Some("ignore_spelling") => Ok(Disambiguation::Nop), // ignore_spelling can be ignored since we dont check spelling Some("immunize") => Ok(Disambiguation::Nop), // immunize can probably not be ignored Some("filterall") => { let mut disambig = Vec::new(); let mut marker_disambig = Vec::new(); let mut has_marker = false; for part in &data.pattern.parts { match part { structure::PatternPart::Marker(marker) => { has_marker = true; for token in &marker.tokens { let token = match token { structure::TokenCombination::Token(token) => token, structure::TokenCombination::And(tokens) | structure::TokenCombination::Or(tokens) => &tokens.tokens[0], structure::TokenCombination::Feature(_) => continue, }; marker_disambig.push(token.postag.as_ref().map(|x| { either::Right(parse_pos_filter( x, token.postag_regexp.as_deref(), info, )) })); } } structure::PatternPart::Token(token) => { disambig.push(token.postag.as_ref().map(|x| { either::Right(parse_pos_filter( x, token.postag_regexp.as_deref(), info, )) })) } structure::PatternPart::And(tokens) | structure::PatternPart::Or(tokens) => { disambig.push(tokens.tokens[0].postag.as_ref().map(|x| { either::Right(parse_pos_filter( x, tokens.tokens[0].postag_regexp.as_deref(), info, )) })) } structure::PatternPart::Feature(_) => {} } } let disambiguations = if has_marker { marker_disambig } else { disambig }; Ok(Disambiguation::Filter( disambiguations.into_iter().collect(), )) } Some("filter") => { if let Some(postag) = data.disambig.postag.as_ref() { Ok(Disambiguation::Filter(vec![Some(either::Right( parse_pos_filter(postag, Some("yes"), info), ))])) } else { Ok(Disambiguation::Filter( word_datas.into_iter().map(Some).collect(), )) } } Some("unify") => { let mut mask = Vec::new(); let mut marker_mask = Vec::new(); let mut disambig = Vec::new(); let mut marker_disambig = Vec::new(); let mut has_marker = false; for part in &data.pattern.parts { match part { structure::PatternPart::Marker(marker) => { has_marker = true; for token in &marker.tokens { let token = match token { structure::TokenCombination::Token(token) => token, structure::TokenCombination::And(tokens) | structure::TokenCombination::Or(tokens) => &tokens.tokens[0], structure::TokenCombination::Feature(_) => continue, }; marker_disambig.push(token.postag.as_ref().map(|x| { parse_pos_filter(x, token.postag_regexp.as_deref(), info) })); marker_mask.push(token.unify.is_some()) } } structure::PatternPart::Token(token) => { disambig.push(token.postag.as_ref().map(|x| { parse_pos_filter(x, token.postag_regexp.as_deref(), info) })); mask.push(token.unify.is_some()); } structure::PatternPart::And(tokens) | structure::PatternPart::Or(tokens) => { disambig.push(tokens.tokens[0].postag.as_ref().map(|x| { parse_pos_filter(x, tokens.tokens[0].postag_regexp.as_deref(), info) })); mask.push(tokens.tokens[0].unify.is_some()); } structure::PatternPart::Feature(_) => {} } } let (disambig, mask) = if has_marker { (marker_disambig, marker_mask) } else { (disambig, mask) }; Ok(Disambiguation::Unify(unify_filters.clone(), disambig, mask)) } None => { if let Some(postag) = data.disambig.postag.as_ref() { Ok(Disambiguation::Filter(vec![Some(either::Left( owned::WordData::new( info.tagger.id_word("".into()).to_owned_id(), info.tagger.id_tag(postag).to_owned_id(), ), ))])) } else { Ok(Disambiguation::Filter( word_datas.into_iter().map(Some).collect(), )) } } Some(x) => Err(Error::Unimplemented(format!("action {}", x))), }?; let filter = if let Some(filter_data) = data.filter { let args = filter_data .args .split(' ') .map(|x| { let idx = x.find(':').unwrap(); ( x[..idx].to_string(), x[(idx + ':'.len_utf8())..].to_string(), ) }) .collect(); Some(super::impls::filters::get_filter( filter_data.class.split('.').next_back().unwrap(), args, &engine, )?) } else { None }; let mut examples = Vec::new(); if let Some(examples_structure) = data.examples.as_ref() { for example in examples_structure { let mut texts = Vec::new(); let mut char_span: Option<(usize, usize)> = None; let mut char_length = 0; for part in &example.parts { match part { structure::ExamplePart::Text(text) => { texts.push(text.as_str()); char_length += text.chars().count(); } structure::ExamplePart::Marker(marker) => { if char_span.is_some() { return Err(Error::Unexpected( "example must have one or zero markers".into(), )); } texts.push(marker.text.as_str()); let length = marker.text.chars().count(); char_span = Some((char_length, char_length + length)); char_length += marker.text.chars().count(); } } } let text = texts.join(""); let test = match example.kind.as_str() { "untouched" => DisambiguationExample::Unchanged(text), "ambiguous" => DisambiguationExample::Changed(DisambiguationChange { text, before: parse_tag_form( example .inputform .as_ref() .expect("must have inputform when ambiguous example"), info, )?, after: parse_tag_form( &example .outputform .as_ref() .expect("must have inputform when ambiguous example"), info, )?, char_span: char_span.expect("must have marker when ambiguous example"), }), x => panic!("unknown disambiguation example type {}", x), }; examples.push(test); } } Ok(DisambiguationRule { start: engine.to_graph_id(start)?, end: engine.to_graph_id(end)?, engine, unification: if unify_filters.is_empty() { None } else { Some(Unification { filters: unify_filters, mask: unify_mask, }) }, filter, disambiguations, examples, id: String::new(), }) } }
use serde::{Deserialize, Serialize}; use tide::{Body, Request, StatusCode, Error}; use uuid::Uuid; use std::collections::HashMap; use std::sync::{Arc, RwLock}; #[derive(Default, Clone)] struct Store(Arc<RwLock<HashMap<String, Item>>>); #[derive(Debug, Clone, Serialize)] struct Item { id: String, name: String, value: i32, } #[derive(Debug, Clone, Deserialize)] struct ItemInput { name: String, value: i32, } #[async_std::main] async fn main() -> tide::Result<()> { let store = Store::default(); let mut app = tide::with_state(store); app.at("/items") .post(create_item) .get(all_items); app.at("/items/:id").get(find_item); app.listen("127.0.0.1:8080").await?; Ok(()) } fn error(msg: String) -> Error { Error::from_str(StatusCode::InternalServerError, msg) } async fn create_item(mut req: Request<Store>) -> tide::Result { let input: ItemInput = req.body_json().await?; let mut store = req.state().0.write().map_err(|e| error(format!("write lock error: {:?}", e)) )?; let item = Item { id: format!("item-{}", Uuid::new_v4()), name: input.name.clone(), value: input.value, }; if store.insert(item.id.clone(), item.clone()).is_none() { Body::from_json(&item).map(Body::into) } else { Err(error("duplicate id".to_string())) } } async fn all_items(req: Request<Store>) -> tide::Result { let store = req.state().0.read().map_err(|e| error(format!("read lock error: {:?}", e)) )?; let items: Vec<_> = store.values().cloned().collect(); Body::from_json(&items) .map(Body::into) } async fn find_item(req: Request<Store>) -> tide::Result { let store = req.state().0.read().map_err(|e| error(format!("read lock error: {:?}", e)) )?; req.param("id") .map(|id| store.get(id) .ok_or(Error::from_str(StatusCode::NotFound, "")) )? .map(Body::from_json)? .map(Body::into) }
#[doc = r" Value read from the register"] pub struct R { bits: u32, } #[doc = r" Value to write to the register"] pub struct W { bits: u32, } impl super::FREQUENCY { #[doc = r" Modifies the contents of the register"] #[inline] pub fn modify<F>(&self, f: F) where for<'w> F: FnOnce(&R, &'w mut W) -> &'w mut W, { let bits = self.register.get(); let r = R { bits: bits }; let mut w = W { bits: bits }; f(&r, &mut w); self.register.set(w.bits); } #[doc = r" Reads the contents of the register"] #[inline] pub fn read(&self) -> R { R { bits: self.register.get(), } } #[doc = r" Writes to the register"] #[inline] pub fn write<F>(&self, f: F) where F: FnOnce(&mut W) -> &mut W, { let mut w = W::reset_value(); f(&mut w); self.register.set(w.bits); } #[doc = r" Writes the reset value to the register"] #[inline] pub fn reset(&self) { self.write(|w| w) } } #[doc = "Possible values of the field `FREQUENCY`"] #[derive(Clone, Copy, Debug, PartialEq)] pub enum FREQUENCYR { #[doc = "100 kbps."] K100, #[doc = "250 kbps."] K250, #[doc = "400 kbps."] K400, #[doc = r" Reserved"] _Reserved(u32), } impl FREQUENCYR { #[doc = r" Value of the field as raw bits"] #[inline] pub fn bits(&self) -> u32 { match *self { FREQUENCYR::K100 => 26738688, FREQUENCYR::K250 => 67108864, FREQUENCYR::K400 => 107479040, FREQUENCYR::_Reserved(bits) => bits, } } #[allow(missing_docs)] #[doc(hidden)] #[inline] pub fn _from(value: u32) -> FREQUENCYR { match value { 26738688 => FREQUENCYR::K100, 67108864 => FREQUENCYR::K250, 107479040 => FREQUENCYR::K400, i => FREQUENCYR::_Reserved(i), } } #[doc = "Checks if the value of the field is `K100`"] #[inline] pub fn is_k100(&self) -> bool { *self == FREQUENCYR::K100 } #[doc = "Checks if the value of the field is `K250`"] #[inline] pub fn is_k250(&self) -> bool { *self == FREQUENCYR::K250 } #[doc = "Checks if the value of the field is `K400`"] #[inline] pub fn is_k400(&self) -> bool { *self == FREQUENCYR::K400 } } #[doc = "Values that can be written to the field `FREQUENCY`"] pub enum FREQUENCYW { #[doc = "100 kbps."] K100, #[doc = "250 kbps."] K250, #[doc = "400 kbps."] K400, } impl FREQUENCYW { #[allow(missing_docs)] #[doc(hidden)] #[inline] pub fn _bits(&self) -> u32 { match *self { FREQUENCYW::K100 => 26738688, FREQUENCYW::K250 => 67108864, FREQUENCYW::K400 => 107479040, } } } #[doc = r" Proxy"] pub struct _FREQUENCYW<'a> { w: &'a mut W, } impl<'a> _FREQUENCYW<'a> { #[doc = r" Writes `variant` to the field"] #[inline] pub fn variant(self, variant: FREQUENCYW) -> &'a mut W { unsafe { self.bits(variant._bits()) } } #[doc = "100 kbps."] #[inline] pub fn k100(self) -> &'a mut W { self.variant(FREQUENCYW::K100) } #[doc = "250 kbps."] #[inline] pub fn k250(self) -> &'a mut W { self.variant(FREQUENCYW::K250) } #[doc = "400 kbps."] #[inline] pub fn k400(self) -> &'a mut W { self.variant(FREQUENCYW::K400) } #[doc = r" Writes raw bits to the field"] #[inline] pub unsafe fn bits(self, value: u32) -> &'a mut W { const MASK: u32 = 4294967295; const OFFSET: u8 = 0; self.w.bits &= !((MASK as u32) << OFFSET); self.w.bits |= ((value & MASK) as u32) << OFFSET; self.w } } impl R { #[doc = r" Value of the register as raw bits"] #[inline] pub fn bits(&self) -> u32 { self.bits } #[doc = "Bits 0:31 - Two-wire master clock frequency."] #[inline] pub fn frequency(&self) -> FREQUENCYR { FREQUENCYR::_from({ const MASK: u32 = 4294967295; const OFFSET: u8 = 0; ((self.bits >> OFFSET) & MASK as u32) as u32 }) } } impl W { #[doc = r" Reset value of the register"] #[inline] pub fn reset_value() -> W { W { bits: 67108864 } } #[doc = r" Writes raw bits to the register"] #[inline] pub unsafe fn bits(&mut self, bits: u32) -> &mut Self { self.bits = bits; self } #[doc = "Bits 0:31 - Two-wire master clock frequency."] #[inline] pub fn frequency(&mut self) -> _FREQUENCYW { _FREQUENCYW { w: self } } }
#[doc = "Reader of register FDCAN_RXF0S"] pub type R = crate::R<u32, super::FDCAN_RXF0S>; #[doc = "Writer for register FDCAN_RXF0S"] pub type W = crate::W<u32, super::FDCAN_RXF0S>; #[doc = "Register FDCAN_RXF0S `reset()`'s with value 0"] impl crate::ResetValue for super::FDCAN_RXF0S { type Type = u32; #[inline(always)] fn reset_value() -> Self::Type { 0 } } #[doc = "Reader of field `F0FL`"] pub type F0FL_R = crate::R<u8, u8>; #[doc = "Write proxy for field `F0FL`"] pub struct F0FL_W<'a> { w: &'a mut W, } impl<'a> F0FL_W<'a> { #[doc = r"Writes raw bits to the field"] #[inline(always)] pub unsafe fn bits(self, value: u8) -> &'a mut W { self.w.bits = (self.w.bits & !0x0f) | ((value as u32) & 0x0f); self.w } } #[doc = "Reader of field `F0GI`"] pub type F0GI_R = crate::R<u8, u8>; #[doc = "Write proxy for field `F0GI`"] pub struct F0GI_W<'a> { w: &'a mut W, } impl<'a> F0GI_W<'a> { #[doc = r"Writes raw bits to the field"] #[inline(always)] pub unsafe fn bits(self, value: u8) -> &'a mut W { self.w.bits = (self.w.bits & !(0x03 << 8)) | (((value as u32) & 0x03) << 8); self.w } } #[doc = "Reader of field `F0PI`"] pub type F0PI_R = crate::R<u8, u8>; #[doc = "Write proxy for field `F0PI`"] pub struct F0PI_W<'a> { w: &'a mut W, } impl<'a> F0PI_W<'a> { #[doc = r"Writes raw bits to the field"] #[inline(always)] pub unsafe fn bits(self, value: u8) -> &'a mut W { self.w.bits = (self.w.bits & !(0x03 << 16)) | (((value as u32) & 0x03) << 16); self.w } } #[doc = "Reader of field `F0F`"] pub type F0F_R = crate::R<bool, bool>; #[doc = "Write proxy for field `F0F`"] pub struct F0F_W<'a> { w: &'a mut W, } impl<'a> F0F_W<'a> { #[doc = r"Sets the field bit"] #[inline(always)] pub fn set_bit(self) -> &'a mut W { self.bit(true) } #[doc = r"Clears the field bit"] #[inline(always)] pub fn clear_bit(self) -> &'a mut W { self.bit(false) } #[doc = r"Writes raw bits to the field"] #[inline(always)] pub fn bit(self, value: bool) -> &'a mut W { self.w.bits = (self.w.bits & !(0x01 << 24)) | (((value as u32) & 0x01) << 24); self.w } } #[doc = "Reader of field `RF0L`"] pub type RF0L_R = crate::R<bool, bool>; #[doc = "Write proxy for field `RF0L`"] pub struct RF0L_W<'a> { w: &'a mut W, } impl<'a> RF0L_W<'a> { #[doc = r"Sets the field bit"] #[inline(always)] pub fn set_bit(self) -> &'a mut W { self.bit(true) } #[doc = r"Clears the field bit"] #[inline(always)] pub fn clear_bit(self) -> &'a mut W { self.bit(false) } #[doc = r"Writes raw bits to the field"] #[inline(always)] pub fn bit(self, value: bool) -> &'a mut W { self.w.bits = (self.w.bits & !(0x01 << 25)) | (((value as u32) & 0x01) << 25); self.w } } impl R { #[doc = "Bits 0:3 - Rx FIFO 0 Fill Level"] #[inline(always)] pub fn f0fl(&self) -> F0FL_R { F0FL_R::new((self.bits & 0x0f) as u8) } #[doc = "Bits 8:9 - Rx FIFO 0 Get Index"] #[inline(always)] pub fn f0gi(&self) -> F0GI_R { F0GI_R::new(((self.bits >> 8) & 0x03) as u8) } #[doc = "Bits 16:17 - Rx FIFO 0 Put Index"] #[inline(always)] pub fn f0pi(&self) -> F0PI_R { F0PI_R::new(((self.bits >> 16) & 0x03) as u8) } #[doc = "Bit 24 - Rx FIFO 0 Full"] #[inline(always)] pub fn f0f(&self) -> F0F_R { F0F_R::new(((self.bits >> 24) & 0x01) != 0) } #[doc = "Bit 25 - Rx FIFO 0 Message Lost"] #[inline(always)] pub fn rf0l(&self) -> RF0L_R { RF0L_R::new(((self.bits >> 25) & 0x01) != 0) } } impl W { #[doc = "Bits 0:3 - Rx FIFO 0 Fill Level"] #[inline(always)] pub fn f0fl(&mut self) -> F0FL_W { F0FL_W { w: self } } #[doc = "Bits 8:9 - Rx FIFO 0 Get Index"] #[inline(always)] pub fn f0gi(&mut self) -> F0GI_W { F0GI_W { w: self } } #[doc = "Bits 16:17 - Rx FIFO 0 Put Index"] #[inline(always)] pub fn f0pi(&mut self) -> F0PI_W { F0PI_W { w: self } } #[doc = "Bit 24 - Rx FIFO 0 Full"] #[inline(always)] pub fn f0f(&mut self) -> F0F_W { F0F_W { w: self } } #[doc = "Bit 25 - Rx FIFO 0 Message Lost"] #[inline(always)] pub fn rf0l(&mut self) -> RF0L_W { RF0L_W { w: self } } }
extern crate futures; use futures::prelude::*; use futures::future::{ok, err}; #[test] fn smoke() { let mut counter = 0; { let work = ok::<u32, u32>(40).inspect(|val| { counter += *val; }); assert_eq!(work.wait(), Ok(40)); } assert_eq!(counter, 40); { let work = err::<u32, u32>(4).inspect(|val| { counter += *val; }); assert_eq!(work.wait(), Err(4)); } assert_eq!(counter, 40); }
use super::VarResult; use crate::ast::stat_expr_types::VarIndex; use crate::ast::syntax_type::{FunctionType, FunctionTypes, SimpleSyntaxType, SyntaxType}; use crate::helper::err_msgs::*; use crate::helper::session::TradeTimeSpan; use crate::helper::str_replace; use crate::helper::{ ensure_srcs, move_element, pine_ref_to_bool, pine_ref_to_color, pine_ref_to_f64, pine_ref_to_i64, pine_ref_to_string, }; use crate::runtime::context::{downcast_ctx, Ctx}; use crate::runtime::output::{OutputData, OutputInfo, PlotInfo}; use crate::types::{ Bool, Callable, CallableFactory, DataType, Float, Int, Object, ParamCollectCall, PineClass, PineFrom, PineRef, PineType, RefData, RuntimeErr, SecondType, Series, NA, }; use chrono_tz::Tz; use std::cell::{Cell, RefCell}; use std::collections::BTreeMap; use std::rc::Rc; #[derive(Debug, PartialEq, Clone)] struct BarStateProps { barindex_index: Cell<VarIndex>, time_index: Cell<VarIndex>, data_ranges: RefCell<Vec<(i32, i32)>>, } impl BarStateProps { pub fn new() -> BarStateProps { BarStateProps { barindex_index: Cell::new(VarIndex::new(0, 0)), time_index: Cell::new(VarIndex::new(0, 0)), data_ranges: RefCell::new(vec![(0, 0)]), } } fn get_varindex<'a>(&self, ctx: &mut dyn Ctx<'a>) -> i64 { let barindex = ctx.get_var(self.barindex_index.get()).clone(); pine_ref_to_i64(barindex).unwrap() } fn is_last<'a>(&self, ctx: &mut dyn Ctx<'a>) -> bool { let index = self.get_varindex(ctx); let (_, end) = downcast_ctx(ctx.get_main_ctx()).get_data_range(); index == (end.unwrap() - 1) as i64 } fn is_in_trade<'a>(&self, ctx: &mut dyn Ctx<'a>) -> bool { match downcast_ctx(ctx.get_main_ctx()).get_syminfo() { Some(syminfo) => { let tz = syminfo.timezone.parse().unwrap(); let timespan = TradeTimeSpan::parse_str(&syminfo.trade_start, &syminfo.trade_end); let time_index = self.time_index.get(); let cur_time = pine_ref_to_i64(ctx.get_var(time_index).clone()).unwrap(); if timespan.is_in(cur_time, &tz) { true } else { false } } _ => true, } } } impl<'a> PineClass<'a> for BarStateProps { fn custom_type(&self) -> &str { "barstate" } fn get(&self, _ctx: &mut dyn Ctx<'a>, name: &str) -> Result<PineRef<'a>, RuntimeErr> { if self.barindex_index.get() == VarIndex::new(0, 0) { let index = _ctx.get_top_varname_index("bar_index").unwrap(); self.barindex_index.set(index); ensure_srcs(_ctx, vec!["_time"], |indexs| { self.time_index.set(indexs[0]); }); } let (start, end) = downcast_ctx(_ctx.get_main_ctx()).get_data_range(); if self.data_ranges.borrow().last() != Some(&(start.unwrap(), end.unwrap())) { self.data_ranges .borrow_mut() .push((start.unwrap(), end.unwrap())); } match name { "isfirst" => { let index = self.get_varindex(_ctx); if index == 0 { Ok(PineRef::new_rc(Series::from(true))) } else { Ok(PineRef::new_rc(Series::from(false))) } } "islast" => { if self.is_last(_ctx) { Ok(PineRef::new_rc(Series::from(true))) } else { Ok(PineRef::new_rc(Series::from(false))) } } "ishistory" => { if !self.is_last(_ctx) { Ok(PineRef::new_rc(Series::from(true))) } else { // The point is the last point and in trade time. Ok(PineRef::new_rc(Series::from(!self.is_in_trade(_ctx)))) } } "isrealtime" => { if !self.is_last(_ctx) { Ok(PineRef::new_rc(Series::from(false))) } else { // The point is the last point and in trade time. Ok(PineRef::new_rc(Series::from(self.is_in_trade(_ctx)))) } } "isnew" => { let index = self.get_varindex(_ctx) as i32; let appear_count = self .data_ranges .borrow() .iter() .filter(|range| index >= range.0 && index < range.1) .count(); if appear_count > 1 { Ok(PineRef::new_rc(Series::from(false))) } else { Ok(PineRef::new_rc(Series::from(true))) } } "isconfirmed" => { let index = self.get_varindex(_ctx) as i32; let appear_count = self .data_ranges .borrow() .iter() .filter(|range| index >= range.0 && index < range.1) .count(); if appear_count > 1 { let end_index = self.data_ranges.borrow().last().unwrap().1; // appearing not only once but not the last on is considered as onfirmed. Ok(PineRef::new_rc(Series::from(index != end_index - 1))) } else { Ok(PineRef::new_rc(Series::from(false))) } } _ => Err(RuntimeErr::NotImplement(str_replace( NO_FIELD_IN_OBJECT, vec![String::from(name), String::from("plot")], ))), } } fn copy(&self) -> Box<dyn PineClass<'a> + 'a> { Box::new(self.clone()) } } pub const VAR_NAME: &'static str = "barstate"; pub fn declare_var<'a>() -> VarResult<'a> { let value = PineRef::new(Object::new(Box::new(BarStateProps::new()))); let mut obj_type = BTreeMap::new(); obj_type.insert("isfirst", SyntaxType::bool()); obj_type.insert("islast", SyntaxType::bool()); obj_type.insert("ishistory", SyntaxType::bool()); obj_type.insert("isrealtime", SyntaxType::bool()); obj_type.insert("isnew", SyntaxType::bool()); obj_type.insert("isconfirmed", SyntaxType::bool()); let syntax_type = SyntaxType::Object(Rc::new(obj_type)); VarResult::new(value, syntax_type, VAR_NAME) } #[cfg(test)] mod tests { use super::*; use crate::runtime::context::VarOperate; use crate::runtime::{AnySeries, NoneCallback, SymbolInfo}; use crate::{LibInfo, PineParser, PineRunner}; use chrono::offset::TimeZone; use std::mem; fn gen_ts(h: u32, m: u32) -> i64 { Tz::Asia__Shanghai .ymd(2020, 2, 17) .and_hms(h, m, 0) .timestamp() * 1000 } #[test] fn plot_test() { let lib_info = LibInfo::new( vec![declare_var()], vec![ ("close", SyntaxType::Series(SimpleSyntaxType::Float)), ("_time", SyntaxType::Series(SimpleSyntaxType::Int)), ("bar_index", SyntaxType::Series(SimpleSyntaxType::Int)), ], ); // [ // , barstate.islast, barstate.ishistory, // barstate.isrealtime, barstate.isnew, barstate.isconfirmed let src = "m1=barstate.isfirst m2=barstate.islast m3=barstate.ishistory m4=barstate.isrealtime m5=barstate.isnew m6=barstate.isconfirmed "; let blk = PineParser::new(src, &lib_info).parse_blk().unwrap(); let mut runner = PineRunner::new(&lib_info, &blk, &NoneCallback()); downcast_ctx(runner.get_context()).update_data_range((Some(0), Some(2))); runner .run( &vec![ ( "close", AnySeries::from_float_vec(vec![Some(1f64), Some(2f64)]), ), ( "_time", AnySeries::from_int_vec(vec![Some(gen_ts(10, 0)), Some(gen_ts(14, 0))]), ), ], Some(Rc::new(SymbolInfo { symbol_type: String::from(""), timezone: String::from("Asia/Shanghai"), ticker: String::from(""), session: String::from(""), trade_start: String::from("9:30"), trade_end: String::from("15:00"), root: None, currency: String::from(""), description: String::from(""), mintick: 1f64, })), ) .unwrap(); assert_eq!( runner.get_context().get_var(VarIndex::new(0, 0)), &Some(PineRef::new(Series::from_vec(vec![true, false]))) ); assert_eq!( runner.get_context().get_var(VarIndex::new(1, 0)), &Some(PineRef::new(Series::from_vec(vec![false, true]))) ); assert_eq!( runner.get_context().get_var(VarIndex::new(2, 0)), &Some(PineRef::new(Series::from_vec(vec![true, false]))) ); assert_eq!( runner.get_context().get_var(VarIndex::new(3, 0)), &Some(PineRef::new(Series::from_vec(vec![false, true]))) ); assert_eq!( runner.get_context().get_var(VarIndex::new(4, 0)), &Some(PineRef::new(Series::from_vec(vec![true, true]))) ); assert_eq!( runner.get_context().get_var(VarIndex::new(5, 0)), &Some(PineRef::new(Series::from_vec(vec![false, false]))) ); runner .update(&vec![ ( "close", AnySeries::from_float_vec(vec![Some(1f64), Some(2f64)]), ), ( "_time", AnySeries::from_int_vec(vec![Some(gen_ts(14, 0)), Some(gen_ts(15, 0))]), ), ]) .unwrap(); assert_eq!( runner.get_context().get_var(VarIndex::new(4, 0)), &Some(PineRef::new(Series::from_vec(vec![true, false, true]))) ); assert_eq!( runner.get_context().get_var(VarIndex::new(5, 0)), &Some(PineRef::new(Series::from_vec(vec![false, true, false]))) ); } #[test] fn barstate_test() { let lib_info = LibInfo::new( vec![declare_var()], vec![ ("close", SyntaxType::Series(SimpleSyntaxType::Float)), ("_time", SyntaxType::Series(SimpleSyntaxType::Int)), ("bar_index", SyntaxType::Series(SimpleSyntaxType::Int)), ], ); let src = r#" float a1 = barstate.isconfirmed ? close :na float a2 = barstate.isfirst ? close :na float a3 = barstate.ishistory? close :na float a4 = barstate.islast ? close :na float a5 = barstate.isnew ? close :na float a6 = barstate.isrealtime ? close :na "#; let blk = PineParser::new(src, &lib_info).parse_blk().unwrap(); let mut runner = PineRunner::new(&lib_info, &blk, &NoneCallback()); downcast_ctx(runner.get_context()).update_data_range((Some(0), Some(2))); runner .run( &vec![ ( "close", AnySeries::from_float_vec(vec![Some(1f64), Some(2f64)]), ), ( "_time", AnySeries::from_int_vec(vec![Some(gen_ts(10, 0)), Some(gen_ts(14, 0))]), ), ], Some(Rc::new(SymbolInfo { symbol_type: String::from(""), timezone: String::from("Asia/Shanghai"), ticker: String::from(""), session: String::from(""), trade_start: String::from("9:30"), trade_end: String::from("15:00"), root: None, currency: String::from(""), description: String::from(""), mintick: 1f64, })), ) .unwrap(); } }
use crate::cmd::sync; use crate::config; use crate::util::{self, color}; use anyhow::Result; /// Prints any diffs between any remote and local dotfiles. pub fn diff() -> Result<()> { let config = config::get_config()?; let tittle_config_dir = config::tittle_config_dir(); for (remote, local) in config.dests().iter() { let files = sync::remote_and_local_files(&remote, &local)?; for (remote_file, local_file) in files.iter() { match util::diff(remote_file, local_file)? { None => continue, Some(diff) => { util::info(format!( "diff {}\n{}\n", color::path(remote_file.strip_prefix(&tittle_config_dir)?), diff )); } } } } Ok(()) }