moderation library
Classes
- InterpretedLabelValueDefinition
- ModerationBehaviors
- A configuration object that determines how moderation causes are interpreted and translated into UI behaviors.
- ModerationCause
- ModerationCauseBlockedBy
- ModerationCauseBlocking
- ModerationCauseBlockOther
- ModerationCauseHidden
- ModerationCauseLabel
- ModerationCauseMuted
- ModerationCauseMuteWord
- ModerationCauseSource
- ModerationCauseSourceLabeler
- ModerationCauseSourceList
- ModerationCauseSourceUser
- ModerationDecision
- ModerationOpts
- ModerationPrefs
- ModerationPrefsLabeler
- ModerationSubjectFeedGenerator
- ModerationSubjectNotification
- ModerationSubjectPost
- ModerationSubjectProfile
- ModerationSubjectUserList
- ModerationUI
- MuteWordMatch
- A match found by matchMuteWords.
Enums
Extensions
- InterpretedLabelValueDefinitionPatterns on InterpretedLabelValueDefinition
- Adds pattern-matching-related methods to InterpretedLabelValueDefinition.
- LabelerServiceExtension on LabelerService
- ModerationCauseBlockedByPatterns on ModerationCauseBlockedBy
- Adds pattern-matching-related methods to ModerationCauseBlockedBy.
- ModerationCauseBlockingPatterns on ModerationCauseBlocking
- Adds pattern-matching-related methods to ModerationCauseBlocking.
- ModerationCauseBlockOtherPatterns on ModerationCauseBlockOther
- Adds pattern-matching-related methods to ModerationCauseBlockOther.
- ModerationCauseHiddenPatterns on ModerationCauseHidden
- Adds pattern-matching-related methods to ModerationCauseHidden.
- ModerationCauseLabelPatterns on ModerationCauseLabel
- Adds pattern-matching-related methods to ModerationCauseLabel.
- ModerationCauseMutedPatterns on ModerationCauseMuted
- Adds pattern-matching-related methods to ModerationCauseMuted.
- ModerationCauseMuteWordPatterns on ModerationCauseMuteWord
- Adds pattern-matching-related methods to ModerationCauseMuteWord.
- ModerationCausePatterns on ModerationCause
- Adds pattern-matching-related methods to ModerationCause.
- ModerationCauseSourceLabelerPatterns on ModerationCauseSourceLabeler
- Adds pattern-matching-related methods to ModerationCauseSourceLabeler.
- ModerationCauseSourceListPatterns on ModerationCauseSourceList
- Adds pattern-matching-related methods to ModerationCauseSourceList.
- ModerationCauseSourcePatterns on ModerationCauseSource
- Adds pattern-matching-related methods to ModerationCauseSource.
- ModerationCauseSourceUserPatterns on ModerationCauseSourceUser
- Adds pattern-matching-related methods to ModerationCauseSourceUser.
- ModerationOptsPatterns on ModerationOpts
- Adds pattern-matching-related methods to ModerationOpts.
- ModerationPrefsLabelerPatterns on ModerationPrefsLabeler
- Adds pattern-matching-related methods to ModerationPrefsLabeler.
- ModerationPrefsPatterns on ModerationPrefs
- Adds pattern-matching-related methods to ModerationPrefs.
- ModerationSubjectFeedGeneratorPatterns on ModerationSubjectFeedGenerator
- Adds pattern-matching-related methods to ModerationSubjectFeedGenerator.
- ModerationSubjectNotificationPatterns on ModerationSubjectNotification
- Adds pattern-matching-related methods to ModerationSubjectNotification.
- ModerationSubjectPostPatterns on ModerationSubjectPost
- Adds pattern-matching-related methods to ModerationSubjectPost.
- ModerationSubjectProfilePatterns on ModerationSubjectProfile
- Adds pattern-matching-related methods to ModerationSubjectProfile.
- ModerationSubjectUserListPatterns on ModerationSubjectUserList
- Adds pattern-matching-related methods to ModerationSubjectUserList.
- ModerationUIExtension on ModerationUI
- ModerationUIPatterns on ModerationUI
- Adds pattern-matching-related methods to ModerationUI.
- PreferencesExtension on ActorGetPreferencesOutput
Constants
-
kBlockBehavior
→ const Map<
String, ModerationBehavior> -
kDefaultBlockBehaviors
→ const Map<
ModerationBehaviorContext, ModerationBehavior> - The default behaviors applied when the subject is blocked.
-
kDefaultHideBehaviors
→ const Map<
ModerationBehaviorContext, ModerationBehavior> - The default behaviors applied when the subject is hidden by the user.
-
kDefaultLabelSettings
→ const Map<
KnownLabelValue, LabelPreference> -
kDefaultMuteBehaviors
→ const Map<
ModerationBehaviorContext, ModerationBehavior> - The default behaviors applied when the subject is muted.
-
kDefaultMuteWordBehaviors
→ const Map<
ModerationBehaviorContext, ModerationBehavior> - The default behaviors applied when the subject matches a muted word.
- kGoreInterpretedLabelValueDefinition → const InterpretedLabelValueDefinition
- Deprecated alias for kGraphicMediaInterpretedLabelValueDefinition.
- kGraphicMediaInterpretedLabelValueDefinition → const InterpretedLabelValueDefinition
-
kHideBehavior
→ const Map<
String, ModerationBehavior> - kHideInterpretedLabelValueDefinition → const InterpretedLabelValueDefinition
-
kLabelDefinitions
→ const Map<
String, InterpretedLabelValueDefinition> - The known label definitions keyed by label identifier.
-
kLabels
→ const Map<
KnownLabelValue, InterpretedLabelValueDefinition> -
kMuteBehavior
→ const Map<
String, ModerationBehavior> -
kMuteWordBehavior
→ const Map<
String, ModerationBehavior> - kNoopBehavior → const Map
- kNoUnauthenticatedInterpretedLabelValueDefinition → const InterpretedLabelValueDefinition
- kNudityInterpretedLabelValueDefinition → const InterpretedLabelValueDefinition
- kPornInterpretedLabelValueDefinition → const InterpretedLabelValueDefinition
- kSexualInterpretedLabelValueDefinition → const InterpretedLabelValueDefinition
- kWarnInterpretedLabelValueDefinition → const InterpretedLabelValueDefinition
Functions
-
getInterpretedLabelValueDefinition(
{required String identifier, LabelPreference defaultSetting = LabelPreference.warn, required String severity, required String blurs, String? definedBy, bool adultOnly = false}) → InterpretedLabelValueDefinition -
getInterpretedLabelValueDefinitions(
LabelerViewDetailed labelerView) → List< InterpretedLabelValueDefinition> -
getLabelerHeaders(
ModerationPrefs? prefs, {List< String> appLabelers = const [_kBskyLabelerDid]}) → Map<String, String> -
hasMutedWord(
{required List< MutedWord> mutedWords, required String text, List<RichtextFacet> ? facets, List<String> ? outlineTags, List<String> ? languages, ProfileViewBasic? actor}) → bool - Checks if the given text matches any of the muted words, returning a boolean if any matches are found.
-
matchMuteWords(
{required List< MutedWord> mutedWords, required String text, List<RichtextFacet> ? facets, List<String> ? outlineTags, List<String> ? languages, ProfileViewBasic? actor}) → List<MuteWordMatch> - Checks if the given text matches any of the muted words, returning the list of matches. An empty list means no matches were found.
-
moderateFeedGenerator(
ModerationSubjectFeedGenerator subject, ModerationOpts opts) → ModerationDecision -
moderateNotification(
ModerationSubjectNotification subject, ModerationOpts opts) → ModerationDecision -
moderatePost(
ModerationSubjectPost subject, ModerationOpts opts) → ModerationDecision -
moderateProfile(
ModerationSubjectProfile subject, ModerationOpts opts) → ModerationDecision -
moderateStatus(
ModerationSubjectProfile subject, ModerationOpts opts) → ModerationDecision -
moderateUserList(
ModerationSubjectUserList subject, ModerationOpts opts) → ModerationDecision