common/types: flatten to types

This commit is contained in:
2025-12-08 04:14:32 +09:00
parent 183174ae33
commit e9cf44f006
123 changed files with 111 additions and 122 deletions
@@ -1,6 +1,6 @@
use crate::{
commands::{Command, empty_command_response, single_item_command_request},
common::types::AudioOutputId,
types::AudioOutputId,
};
pub struct DisableOutput;
@@ -1,6 +1,6 @@
use crate::{
commands::{Command, empty_command_response, single_item_command_request},
common::types::AudioOutputId,
types::AudioOutputId,
};
pub struct EnableOutput;
+1 -1
View File
@@ -4,8 +4,8 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandResponse, ResponseParserError, empty_command_request},
common::types::AudioOutputId,
response_tokenizer::{ResponseAttributes, expect_property_type},
types::AudioOutputId,
};
pub struct Outputs;
@@ -2,8 +2,8 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, RequestParserError, empty_command_response},
common::types::AudioOutputId,
request_tokenizer::RequestTokenizer,
types::AudioOutputId,
};
pub struct OutputSet;
@@ -1,6 +1,6 @@
use crate::{
commands::{Command, empty_command_response, single_item_command_request},
common::types::AudioOutputId,
types::AudioOutputId,
};
pub struct ToggleOutput;
+1 -1
View File
@@ -2,8 +2,8 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandResponse, ResponseParserError, empty_command_request},
common::types::ChannelName,
response_tokenizer::{ResponseAttributes, expect_property_type},
types::ChannelName,
};
pub struct Channels;
@@ -2,8 +2,8 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandResponse, ResponseParserError, empty_command_request},
common::types::ChannelName,
response_tokenizer::{ResponseAttributes, expect_property_type},
types::ChannelName,
};
pub struct ReadMessages;
+1 -1
View File
@@ -2,8 +2,8 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, RequestParserError, empty_command_response},
common::types::ChannelName,
request_tokenizer::RequestTokenizer,
types::ChannelName,
};
pub struct SendMessage;
+1 -1
View File
@@ -1,6 +1,6 @@
use crate::{
commands::{Command, empty_command_response, single_item_command_request},
common::types::ChannelName,
types::ChannelName,
};
pub struct Subscribe;
+1 -1
View File
@@ -1,6 +1,6 @@
use crate::{
commands::{Command, empty_command_response, single_item_command_request},
common::types::ChannelName,
types::ChannelName,
};
pub struct Unsubscribe;
@@ -1,7 +1,7 @@
use crate::{
commands::{Command, CommandRequest, RequestParserError, empty_command_response},
common::types::Feature,
request_tokenizer::RequestTokenizer,
types::Feature,
};
pub struct ProtocolDisable;
@@ -1,7 +1,7 @@
use crate::{
commands::{Command, CommandRequest, RequestParserError, empty_command_response},
common::types::Feature,
request_tokenizer::RequestTokenizer,
types::Feature,
};
pub struct ProtocolEnable;
@@ -1,7 +1,7 @@
use crate::{
commands::{Command, CommandRequest, RequestParserError, empty_command_response},
common::types::TagName,
request_tokenizer::RequestTokenizer,
types::TagName,
};
pub struct TagTypesDisable;
@@ -1,7 +1,7 @@
use crate::{
commands::{Command, CommandRequest, RequestParserError, empty_command_response},
common::types::TagName,
request_tokenizer::RequestTokenizer,
types::TagName,
};
pub struct TagTypesEnable;
@@ -1,7 +1,7 @@
use crate::{
commands::{Command, CommandRequest, RequestParserError, empty_command_response},
common::types::TagName,
request_tokenizer::RequestTokenizer,
types::TagName,
};
pub struct TagTypesReset;
+1 -1
View File
@@ -1,6 +1,6 @@
use crate::{
commands::{Command, empty_command_response, single_item_command_request},
common::types::SongPosition,
types::SongPosition,
};
pub struct Play;
+1 -1
View File
@@ -1,6 +1,6 @@
use crate::{
commands::{Command, empty_command_response, single_item_command_request},
common::types::SongId,
types::SongId,
};
pub struct PlayId;
+1 -1
View File
@@ -2,8 +2,8 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, RequestParserError, empty_command_response},
common::types::{SongPosition, TimeWithFractions},
request_tokenizer::RequestTokenizer,
types::{SongPosition, TimeWithFractions},
};
pub struct Seek;
+1 -1
View File
@@ -2,8 +2,8 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, RequestParserError, empty_command_response},
common::types::{SeekMode, TimeWithFractions},
request_tokenizer::RequestTokenizer,
types::{SeekMode, TimeWithFractions},
};
pub struct SeekCur;
+1 -1
View File
@@ -2,8 +2,8 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, RequestParserError, empty_command_response},
common::types::{SongId, TimeWithFractions},
request_tokenizer::RequestTokenizer,
types::{SongId, TimeWithFractions},
};
pub struct SeekId;
+1 -1
View File
@@ -2,8 +2,8 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, RequestParserError, empty_command_response},
common::types::{MountPath, Uri},
request_tokenizer::RequestTokenizer,
types::{MountPath, Uri},
};
pub struct Mount;
+1 -1
View File
@@ -1,8 +1,8 @@
use crate::{
MountPath,
commands::{
Command, CommandRequest, RequestParserError, RequestTokenizer, empty_command_response,
},
types::MountPath,
};
pub struct Unmount;
+1 -1
View File
@@ -4,9 +4,9 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, CommandResponse, RequestParserError, ResponseParserError},
common::types::{Offset, Uri},
request_tokenizer::RequestTokenizer,
response_tokenizer::{ResponseAttributes, get_and_parse_property, get_property},
types::{Offset, Uri},
};
pub struct AlbumArt;
+1 -1
View File
@@ -4,10 +4,10 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, CommandResponse, RequestParserError, ResponseParserError},
common::types::GroupType,
filter::Filter,
request_tokenizer::RequestTokenizer,
response_tokenizer::{ResponseAttributes, get_and_parse_property},
types::GroupType,
};
pub struct Count;
+1 -1
View File
@@ -2,10 +2,10 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, CommandResponse, RequestParserError, ResponseParserError},
common::types::{DbSelectionPrintResponse, DbSongInfo, Sort, WindowRange},
filter::Filter,
request_tokenizer::RequestTokenizer,
response_tokenizer::ResponseAttributes,
types::{DbSelectionPrintResponse, DbSongInfo, Sort, WindowRange},
};
pub struct Find;
+1 -1
View File
@@ -2,9 +2,9 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, RequestParserError, empty_command_response},
common::types::{SongPosition, Sort, WindowRange},
filter::Filter,
request_tokenizer::RequestTokenizer,
types::{SongPosition, Sort, WindowRange},
};
pub struct FindAdd;
@@ -4,8 +4,8 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandResponse, ResponseParserError, single_item_command_request},
common::types::Uri,
response_tokenizer::{ResponseAttributes, get_and_parse_property},
types::Uri,
};
pub struct GetFingerprint;
+1 -1
View File
@@ -2,10 +2,10 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, CommandResponse, RequestParserError, ResponseParserError},
common::types::{GroupType, TagName, WindowRange},
filter::Filter,
request_tokenizer::RequestTokenizer,
response_tokenizer::{ResponseAttributes, expect_property_type},
types::{GroupType, TagName, WindowRange},
};
pub struct List;
+2 -3
View File
@@ -1,13 +1,12 @@
use serde::{Deserialize, Serialize};
use crate::{
DbSelectionPrintResponse,
commands::{
Command, CommandResponse, RequestParserError, ResponseParserError,
single_optional_item_command_request,
},
common::types::Uri,
response_tokenizer::ResponseAttributes,
types::{DbSelectionPrintResponse, Uri},
};
pub struct ListAll;
@@ -43,7 +42,7 @@ impl Command<'_, '_> for ListAll {
mod tests {
use std::path::PathBuf;
use crate::{DbDirectoryInfo, DbPlaylistInfo, DbSongInfo};
use crate::types::{DbDirectoryInfo, DbPlaylistInfo, DbSongInfo};
use super::*;
+2 -3
View File
@@ -1,13 +1,12 @@
use serde::{Deserialize, Serialize};
use crate::{
DbSelectionPrintResponse,
commands::{
Command, CommandResponse, RequestParserError, ResponseParserError,
single_optional_item_command_request,
},
common::types::Uri,
response_tokenizer::ResponseAttributes,
types::{DbSelectionPrintResponse, Uri},
};
pub struct ListAllInfo;
@@ -43,7 +42,7 @@ impl Command<'_, '_> for ListAllInfo {
mod tests {
use std::path::PathBuf;
use crate::{DbDirectoryInfo, DbPlaylistInfo, DbSongInfo, Tag};
use crate::types::{DbDirectoryInfo, DbPlaylistInfo, DbSongInfo, Tag};
use super::*;
+1 -2
View File
@@ -1,13 +1,12 @@
use serde::{Deserialize, Serialize};
use crate::{
DbDirectoryInfo, DbSelectionPrintResponse,
commands::{
Command, CommandResponse, RequestParserError, ResponseParserError,
single_optional_item_command_request,
},
common::types::Uri,
response_tokenizer::ResponseAttributes,
types::{DbDirectoryInfo, DbSelectionPrintResponse, Uri},
};
pub struct ListFiles;
+2 -3
View File
@@ -1,13 +1,12 @@
use serde::{Deserialize, Serialize};
use crate::{
DbSelectionPrintResponse,
commands::{
Command, CommandResponse, RequestParserError, ResponseParserError,
single_optional_item_command_request,
},
common::types::Uri,
response_tokenizer::ResponseAttributes,
types::{DbSelectionPrintResponse, Uri},
};
pub struct LsInfo;
@@ -42,7 +41,7 @@ impl Command<'_, '_> for LsInfo {
mod tests {
use std::path::PathBuf;
use crate::{DbDirectoryInfo, DbPlaylistInfo};
use crate::types::{DbDirectoryInfo, DbPlaylistInfo};
use super::*;
+1 -1
View File
@@ -4,8 +4,8 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandResponse, ResponseParserError, single_item_command_request},
common::types::Uri,
response_tokenizer::{GenericResponseValue, ResponseAttributes},
types::Uri,
};
pub struct ReadComments;
+1 -1
View File
@@ -4,11 +4,11 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, CommandResponse, RequestParserError, ResponseParserError},
common::types::{Offset, Uri},
request_tokenizer::RequestTokenizer,
response_tokenizer::{
ResponseAttributes, get_and_parse_property, get_optional_property, get_property,
},
types::{Offset, Uri},
};
pub struct ReadPicture;
+1 -1
View File
@@ -7,8 +7,8 @@ use crate::{
Command, CommandResponse, RequestParserError, ResponseParserError,
single_optional_item_command_request,
},
common::types::Uri,
response_tokenizer::{ResponseAttributes, get_and_parse_property},
types::Uri,
};
pub struct Rescan;
+1 -2
View File
@@ -1,12 +1,11 @@
use serde::{Deserialize, Serialize};
use crate::{
DbSelectionPrintResponse, DbSongInfo,
commands::{Command, CommandRequest, CommandResponse, RequestParserError, ResponseParserError},
common::types::{Sort, WindowRange},
filter::Filter,
request_tokenizer::RequestTokenizer,
response_tokenizer::ResponseAttributes,
types::{DbSelectionPrintResponse, DbSongInfo, Sort, WindowRange},
};
pub struct Search;
+1 -1
View File
@@ -2,9 +2,9 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, RequestParserError, empty_command_response},
common::types::{SongPosition, Sort, WindowRange},
filter::Filter,
request_tokenizer::RequestTokenizer,
types::{SongPosition, Sort, WindowRange},
};
pub struct SearchAdd;
+1 -1
View File
@@ -2,9 +2,9 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, RequestParserError, empty_command_response},
common::types::{PlaylistName, SongPosition, Sort, WindowRange},
filter::Filter,
request_tokenizer::RequestTokenizer,
types::{PlaylistName, SongPosition, Sort, WindowRange},
};
pub struct SearchAddPl;
+1 -2
View File
@@ -3,12 +3,11 @@ use std::collections::HashMap;
use serde::{Deserialize, Serialize};
use crate::{
Seconds,
commands::{Command, CommandRequest, CommandResponse, RequestParserError, ResponseParserError},
common::types::GroupType,
filter::Filter,
request_tokenizer::RequestTokenizer,
response_tokenizer::{ResponseAttributes, get_and_parse_property},
types::{GroupType, Seconds},
};
pub struct SearchCount;
+1 -1
View File
@@ -7,8 +7,8 @@ use crate::{
Command, CommandResponse, RequestParserError, ResponseParserError,
single_optional_item_command_request,
},
common::types::Uri,
response_tokenizer::{ResponseAttributes, get_and_parse_property},
types::Uri,
};
pub struct Update;
@@ -1,6 +1,6 @@
use crate::{
commands::{Command, empty_command_response, single_item_command_request},
common::types::PartitionName,
types::PartitionName,
};
pub struct DelPartition;
@@ -1,7 +1,7 @@
use crate::{
commands::{Command, ResponseParserError, empty_command_request, multi_item_command_response},
common::types::PartitionName,
response_tokenizer::expect_property_type,
types::PartitionName,
};
pub struct ListPartitions;
@@ -1,6 +1,6 @@
use crate::{
commands::{Command, empty_command_response, single_item_command_request},
common::types::PartitionName,
types::PartitionName,
};
pub struct NewPartition;
+1 -1
View File
@@ -1,6 +1,6 @@
use crate::{
commands::{Command, empty_command_response, single_item_command_request},
common::types::PartitionName,
types::PartitionName,
};
pub struct Partition;
+1 -1
View File
@@ -1,6 +1,6 @@
use crate::{
commands::{Command, empty_command_response, single_item_command_request},
common::types::BoolOrOneshot,
types::BoolOrOneshot,
};
pub struct Consume;
+1 -1
View File
@@ -1,6 +1,6 @@
use crate::{
commands::{Command, empty_command_response, single_item_command_request},
common::types::Seconds,
types::Seconds,
};
pub struct Crossfade;
+1 -1
View File
@@ -1,6 +1,6 @@
use crate::{
commands::{Command, empty_command_request, single_item_command_response},
common::types::VolumeValue,
types::VolumeValue,
};
pub struct GetVol;
@@ -1,6 +1,6 @@
use crate::{
commands::{Command, empty_command_response, single_item_command_request},
common::types::Seconds,
types::Seconds,
};
pub struct MixRampDelay;
@@ -1,6 +1,6 @@
use crate::{
commands::{Command, empty_command_response, single_item_command_request},
common::types::ReplayGainModeMode,
types::ReplayGainModeMode,
};
pub struct ReplayGainMode;
@@ -4,8 +4,8 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandResponse, ResponseParserError, empty_command_request},
common::types::ReplayGainModeMode,
response_tokenizer::{ResponseAttributes, get_property},
types::ReplayGainModeMode,
};
pub struct ReplayGainStatus;
+1 -1
View File
@@ -1,6 +1,6 @@
use crate::{
commands::{Command, empty_command_response, single_item_command_request},
common::types::VolumeValue,
types::VolumeValue,
};
pub struct SetVol;
+1 -1
View File
@@ -1,6 +1,6 @@
use crate::{
commands::{Command, empty_command_response, single_item_command_request},
common::types::BoolOrOneshot,
types::BoolOrOneshot,
};
pub struct Single;
+1 -1
View File
@@ -1,6 +1,6 @@
use crate::{
commands::{Command, empty_command_response, single_item_command_request},
common::types::VolumeValue,
types::VolumeValue,
};
pub struct Volume;
@@ -3,11 +3,11 @@ use std::collections::HashMap;
use serde::{Deserialize, Serialize};
use crate::{
DbSongInfo, Priority, SongId, SongPosition,
commands::{Command, CommandResponse, ResponseParserError, empty_command_request},
response_tokenizer::{
ResponseAttributes, get_and_parse_optional_property, get_and_parse_property,
},
types::{DbSongInfo, Priority, SongId, SongPosition},
};
/// Displays the song info of the current song (same song that is identified in status)
+1 -1
View File
@@ -2,8 +2,8 @@ use std::str::FromStr;
use crate::{
commands::{Command, CommandRequest, RequestParserError, empty_command_response},
common::types::SubSystem,
request_tokenizer::RequestTokenizer,
types::SubSystem,
};
pub struct Idle;
+1 -1
View File
@@ -5,11 +5,11 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandResponse, ResponseParserError, empty_command_request},
common::types::{Audio, BoolOrOneshot, SongId, SongPosition},
response_tokenizer::{
ResponseAttributes, get_and_parse_optional_property, get_and_parse_property,
get_optional_property, get_property,
},
types::{Audio, BoolOrOneshot, SongId, SongPosition},
};
pub struct Status;
+1 -1
View File
@@ -2,8 +2,8 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, RequestParserError, empty_command_response},
common::types::{SongPosition, Uri},
request_tokenizer::RequestTokenizer,
types::{SongPosition, Uri},
};
pub struct Add;
+1 -1
View File
@@ -2,9 +2,9 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, CommandResponse, RequestParserError, ResponseParserError},
common::types::{SongId, SongPosition, Uri},
request_tokenizer::RequestTokenizer,
response_tokenizer::{ResponseAttributes, get_next_and_parse_property},
types::{SongId, SongPosition, Uri},
};
pub struct AddId;
+1 -1
View File
@@ -2,8 +2,8 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, RequestParserError, empty_command_response},
common::types::{SongId, TagName, TagValue},
request_tokenizer::RequestTokenizer,
types::{SongId, TagName, TagValue},
};
pub struct AddTagId;
+1 -1
View File
@@ -2,8 +2,8 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, RequestParserError, empty_command_response},
common::types::{SongId, TagName},
request_tokenizer::RequestTokenizer,
types::{SongId, TagName},
};
pub struct ClearTagId;
+1 -1
View File
@@ -1,6 +1,6 @@
use crate::{
commands::{Command, empty_command_response, single_item_command_request},
common::types::OneOrRange,
types::OneOrRange,
};
pub struct Delete;
+1 -1
View File
@@ -1,6 +1,6 @@
use crate::{
commands::{Command, empty_command_response, single_item_command_request},
common::types::SongId,
types::SongId,
};
pub struct DeleteId;
+1 -1
View File
@@ -2,8 +2,8 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, RequestParserError, empty_command_response},
common::types::{AbsouluteRelativeSongPosition, OneOrRange},
request_tokenizer::RequestTokenizer,
types::{AbsouluteRelativeSongPosition, OneOrRange},
};
pub struct Move;
+1 -1
View File
@@ -2,8 +2,8 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, RequestParserError, empty_command_response},
common::types::{AbsouluteRelativeSongPosition, SongId},
request_tokenizer::RequestTokenizer,
types::{AbsouluteRelativeSongPosition, SongId},
};
pub struct MoveId;
+1 -1
View File
@@ -1,9 +1,9 @@
use serde::{Deserialize, Serialize};
use crate::{
Uri,
commands::{Command, CommandResponse, ResponseParserError, empty_command_request},
response_tokenizer::ResponseAttributes,
types::Uri,
};
pub struct Playlist;
+2 -2
View File
@@ -1,12 +1,12 @@
use serde::{Deserialize, Serialize};
use crate::{
DbSongInfo, Priority, Response, SongId, SongPosition,
Response,
commands::{Command, CommandRequest, CommandResponse, RequestParserError, ResponseParserError},
common::types::{Sort, WindowRange},
filter::Filter,
request_tokenizer::RequestTokenizer,
response_tokenizer::ResponseAttributes,
types::{DbSongInfo, Priority, SongId, SongPosition, Sort, WindowRange},
};
pub struct PlaylistFind;
+1 -2
View File
@@ -1,10 +1,9 @@
use serde::{Deserialize, Serialize};
use crate::{
DbSongInfo, Priority, SongPosition,
commands::{Command, CommandResponse, ResponseParserError, single_item_command_request},
common::types::SongId,
response_tokenizer::ResponseAttributes,
types::{DbSongInfo, Priority, SongId, SongPosition},
};
pub struct PlaylistId;
+1 -2
View File
@@ -1,13 +1,12 @@
use serde::{Deserialize, Serialize};
use crate::{
DbSongInfo, Priority, SongId, SongPosition,
commands::{
Command, CommandResponse, RequestParserError, ResponseParserError,
single_optional_item_command_request,
},
common::types::OneOrRange,
response_tokenizer::ResponseAttributes,
types::{DbSongInfo, OneOrRange, Priority, SongId, SongPosition},
};
pub struct PlaylistInfo;
+1 -2
View File
@@ -1,12 +1,11 @@
use serde::{Deserialize, Serialize};
use crate::{
DbSongInfo, Priority, SongId, SongPosition,
commands::{Command, CommandRequest, CommandResponse, RequestParserError, ResponseParserError},
common::types::{Sort, WindowRange},
filter::Filter,
request_tokenizer::RequestTokenizer,
response_tokenizer::ResponseAttributes,
types::{DbSongInfo, Priority, SongId, SongPosition, Sort, WindowRange},
};
pub struct PlaylistSearch;
+1 -2
View File
@@ -1,11 +1,10 @@
use serde::{Deserialize, Serialize};
use crate::{
DbSongInfo, Priority, SongId, SongPosition,
commands::{Command, CommandRequest, CommandResponse, RequestParserError, ResponseParserError},
common::types::{PlaylistVersion, WindowRange},
request_tokenizer::RequestTokenizer,
response_tokenizer::ResponseAttributes,
types::{DbSongInfo, PlaylistVersion, Priority, SongId, SongPosition, WindowRange},
};
pub struct PlChanges;
+1 -2
View File
@@ -1,11 +1,10 @@
use serde::{Deserialize, Serialize};
use crate::{
SongId, SongPosition,
commands::{Command, CommandRequest, CommandResponse, RequestParserError, ResponseParserError},
common::types::{PlaylistVersion, WindowRange},
request_tokenizer::RequestTokenizer,
response_tokenizer::ResponseAttributes,
types::{PlaylistVersion, SongId, SongPosition, WindowRange},
};
pub struct PlChangesPosId;
+1 -1
View File
@@ -2,8 +2,8 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, RequestParserError, empty_command_response},
common::types::{Priority, WindowRange},
request_tokenizer::RequestTokenizer,
types::{Priority, WindowRange},
};
pub struct Prio;
+1 -1
View File
@@ -2,8 +2,8 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, RequestParserError, empty_command_response},
common::types::{Priority, SongId},
request_tokenizer::RequestTokenizer,
types::{Priority, SongId},
};
pub struct PrioId;
+1 -1
View File
@@ -2,8 +2,8 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, RequestParserError, empty_command_response},
common::types::{SongId, TimeInterval},
request_tokenizer::RequestTokenizer,
types::{SongId, TimeInterval},
};
pub struct RangeId;
+1 -1
View File
@@ -2,7 +2,7 @@ use crate::{
commands::{
Command, RequestParserError, empty_command_response, single_optional_item_command_request,
},
common::types::OneOrRange,
types::OneOrRange,
};
pub struct Shuffle;
+1 -1
View File
@@ -2,8 +2,8 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, RequestParserError, empty_command_response},
common::types::SongPosition,
request_tokenizer::RequestTokenizer,
types::SongPosition,
};
pub struct Swap;
+1 -1
View File
@@ -2,8 +2,8 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, RequestParserError, empty_command_response},
common::types::SongId,
request_tokenizer::RequestTokenizer,
types::SongId,
};
pub struct SwapId;
+1 -1
View File
@@ -2,8 +2,8 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, RequestParserError, empty_command_response},
common::types::{StickerType, Uri},
request_tokenizer::RequestTokenizer,
types::{StickerType, Uri},
};
pub struct StickerDec;
+1 -1
View File
@@ -2,8 +2,8 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, RequestParserError, empty_command_response},
common::types::{StickerType, Uri},
request_tokenizer::RequestTokenizer,
types::{StickerType, Uri},
};
pub struct StickerDelete;
+1 -1
View File
@@ -2,9 +2,9 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, CommandResponse, RequestParserError, ResponseParserError},
common::types::{Sort, StickerType, Uri, WindowRange},
request_tokenizer::RequestTokenizer,
response_tokenizer::{ResponseAttributes, expect_property_type},
types::{Sort, StickerType, Uri, WindowRange},
};
pub struct StickerFind;
+1 -1
View File
@@ -2,8 +2,8 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, RequestParserError, single_item_command_response},
common::types::{StickerType, Uri},
request_tokenizer::RequestTokenizer,
types::{StickerType, Uri},
};
pub struct StickerGet;
+1 -1
View File
@@ -2,8 +2,8 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, RequestParserError, empty_command_response},
common::types::{StickerType, Uri},
request_tokenizer::RequestTokenizer,
types::{StickerType, Uri},
};
pub struct StickerInc;
+1 -1
View File
@@ -4,9 +4,9 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, CommandResponse, RequestParserError, ResponseParserError},
common::types::{StickerType, Uri},
request_tokenizer::RequestTokenizer,
response_tokenizer::{GenericResponseValue, ResponseAttributes},
types::{StickerType, Uri},
};
pub struct StickerList;
+1 -1
View File
@@ -2,8 +2,8 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, RequestParserError, empty_command_response},
common::types::{StickerType, Uri},
request_tokenizer::RequestTokenizer,
types::{StickerType, Uri},
};
pub struct StickerSet;
+1 -1
View File
@@ -4,9 +4,9 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, CommandResponse, RequestParserError, ResponseParserError},
common::types::StickerType,
request_tokenizer::RequestTokenizer,
response_tokenizer::{ResponseAttributes, expect_property_type},
types::StickerType,
};
pub struct StickerNamesTypes;
@@ -7,9 +7,9 @@ use crate::{
Command, CommandRequest, RequestParserError, ResponseParserError,
multi_item_command_response,
},
common::types::{PlaylistName, WindowRange},
request_tokenizer::RequestTokenizer,
response_tokenizer::expect_property_type,
types::{PlaylistName, WindowRange},
};
pub struct ListPlaylist;
@@ -1,11 +1,10 @@
use serde::{Deserialize, Serialize};
use crate::{
DbSongInfo,
commands::{Command, CommandRequest, CommandResponse, RequestParserError, ResponseParserError},
common::types::{PlaylistName, WindowRange},
request_tokenizer::RequestTokenizer,
response_tokenizer::ResponseAttributes,
types::{DbSongInfo, PlaylistName, WindowRange},
};
pub struct ListPlaylistInfo;
@@ -1,9 +1,9 @@
use serde::{Deserialize, Serialize};
use crate::{
PlaylistName,
commands::{Command, CommandResponse, ResponseParserError, empty_command_request},
response_tokenizer::{ResponseAttributes, get_next_and_parse_property, get_next_property},
types::PlaylistName,
};
pub struct ListPlaylists;
+1 -1
View File
@@ -2,8 +2,8 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, RequestParserError, empty_command_response},
common::types::{PlaylistName, SongPosition, WindowRange},
request_tokenizer::RequestTokenizer,
types::{PlaylistName, SongPosition, WindowRange},
};
pub struct Load;
+1 -1
View File
@@ -2,8 +2,8 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, RequestParserError, empty_command_response},
common::types::{PlaylistName, SongPosition, Uri},
request_tokenizer::RequestTokenizer,
types::{PlaylistName, SongPosition, Uri},
};
pub struct PlaylistAdd;
@@ -1,6 +1,6 @@
use crate::{
commands::{Command, empty_command_response, single_item_command_request},
common::types::PlaylistName,
types::PlaylistName,
};
pub struct PlaylistClear;
@@ -2,8 +2,8 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, RequestParserError, empty_command_response},
common::types::{OneOrRange, PlaylistName},
request_tokenizer::RequestTokenizer,
types::{OneOrRange, PlaylistName},
};
pub struct PlaylistDelete;
@@ -4,8 +4,8 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandResponse, ResponseParserError, single_item_command_request},
common::types::PlaylistName,
response_tokenizer::{ResponseAttributes, get_and_parse_property},
types::PlaylistName,
};
pub struct PlaylistLength;
@@ -2,8 +2,8 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, RequestParserError, empty_command_response},
common::types::{OneOrRange, PlaylistName, SongPosition},
request_tokenizer::RequestTokenizer,
types::{OneOrRange, PlaylistName, SongPosition},
};
pub struct PlaylistMove;
+1 -1
View File
@@ -1,6 +1,6 @@
use crate::{
commands::{Command, empty_command_response, single_item_command_request},
common::types::PlaylistName,
types::PlaylistName,
};
pub struct Rm;
+1 -1
View File
@@ -2,8 +2,8 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, RequestParserError, empty_command_response},
common::types::{PlaylistName, SaveMode},
request_tokenizer::RequestTokenizer,
types::{PlaylistName, SaveMode},
};
pub struct Save;
@@ -2,9 +2,9 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::{Command, CommandRequest, RequestParserError, empty_command_response},
common::types::{PlaylistName, WindowRange},
filter::Filter,
request_tokenizer::RequestTokenizer,
types::{PlaylistName, WindowRange},
};
pub struct SearchPlaylist;
-1
View File
@@ -1 +0,0 @@
pub(crate) mod types;
+1 -1
View File
@@ -6,7 +6,7 @@ use serde::{Deserialize, Serialize};
use crate::{
commands::RequestParserError,
common::types::{Priority, Tag},
types::{Priority, Tag},
};
#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
+1 -1
View File
@@ -1,7 +1,7 @@
use std::str::FromStr;
use chrono::{DateTime, Utc};
use crate::filter::filter::{CaseSensitivity, ComparisonOperator, Filter, unescape_string};
use crate::common::types::Tag;
use crate::types::Tag;
grammar;

Some files were not shown because too many files have changed in this diff Show More