Reddit.NET  1.5
Reddit.NET is a .NET Standard library that provides easy access to the Reddit API with virtually no boilerplate code required.
Reddit.Controllers.Comments Class Reference

Controller class for comment replies. More...

Inheritance diagram for Reddit.Controllers.Comments:
Reddit.Controllers.Internal.Monitors Reddit.Controllers.BaseController Reddit.Controllers.Internal.Validators

Public Member Functions

 Comments (Dispatch dispatch, string postId=null, string subreddit=null, Comment comment=null, List< Comment > confidence=null, List< Comment > top=null, List< Comment > newComments=null, List< Comment > controversial=null, List< Comment > old=null, List< Comment > random=null, List< Comment > qa=null, List< Comment > live=null)
 Create a new instance of the comments controller. More...
 
List< CommentGetComments (string sort="new", int context=3, int truncate=0, bool showEdits=false, bool showMore=true, bool threaded=true, int? depth=null, int? limit=null, bool srDetail=false, bool isInterface=false)
 Retrieve comment replies to this comment. More...
 
List< CommentGetConfidence (int context=3, int truncate=0, bool showEdits=false, bool showMore=true, bool threaded=true, int? depth=null, int? limit=null, bool srDetail=false, bool isInterface=false)
 Retrieve a list of comments using "confidence" sort. More...
 
List< CommentGetTop (int context=3, int truncate=0, bool showEdits=false, bool showMore=true, bool threaded=true, int? depth=null, int? limit=null, bool srDetail=false, bool isInterface=false)
 Retrieve a list of comments using "top" sort. More...
 
List< CommentGetNew (int context=3, int truncate=0, bool showEdits=false, bool showMore=true, bool threaded=true, int? depth=null, int? limit=null, bool srDetail=false, bool isInterface=false)
 Retrieve a list of comments using "new" sort. More...
 
List< CommentGetControversial (int context=3, int truncate=0, bool showEdits=false, bool showMore=true, bool threaded=true, int? depth=null, int? limit=null, bool srDetail=false, bool isInterface=false)
 Retrieve a list of comments using "controversial" sort. More...
 
List< CommentGetOld (int context=3, int truncate=0, bool showEdits=false, bool showMore=true, bool threaded=true, int? depth=null, int? limit=null, bool srDetail=false, bool isInterface=false)
 Retrieve a list of comments using "old" sort. More...
 
List< CommentGetRandom (int context=3, int truncate=0, bool showEdits=false, bool showMore=true, bool threaded=true, int? depth=null, int? limit=null, bool srDetail=false, bool isInterface=false)
 Retrieve a list of comments using "random" sort. More...
 
List< CommentGetQA (int context=3, int truncate=0, bool showEdits=false, bool showMore=true, bool threaded=true, int? depth=null, int? limit=null, bool srDetail=false, bool isInterface=false)
 Retrieve a list of comments using "qa" sort. More...
 
List< CommentGetLive (int context=3, int truncate=0, bool showEdits=false, bool showMore=true, bool threaded=true, int? depth=null, int? limit=null, bool srDetail=false, bool isInterface=false)
 Retrieve a list of comments using "live" sort. More...
 
bool MonitorConfidence (int? monitoringDelayMs=null, int? monitoringBaseDelayMs=null, List< MonitoringSchedule > schedule=null, bool? breakOnFailure=null, DateTime? monitoringExpiration=null, bool useCache=true)
 Monitor Reddit for new "confidence" comments on this thread. More...
 
bool MonitorTop (int? monitoringDelayMs=null, int? monitoringBaseDelayMs=null, List< MonitoringSchedule > schedule=null, bool? breakOnFailure=null, DateTime? monitoringExpiration=null, bool useCache=true)
 Monitor Reddit for new "top" comments on this thread. More...
 
bool MonitorNew (int? monitoringDelayMs=null, int? monitoringBaseDelayMs=null, List< MonitoringSchedule > schedule=null, bool? breakOnFailure=null, DateTime? monitoringExpiration=null, bool useCache=true)
 Monitor Reddit for new "new" comments on this thread. More...
 
bool MonitorControversial (int? monitoringDelayMs=null, int? monitoringBaseDelayMs=null, List< MonitoringSchedule > schedule=null, bool? breakOnFailure=null, DateTime? monitoringExpiration=null, bool useCache=true)
 Monitor Reddit for new "controversial" comments on this thread. More...
 
bool MonitorOld (int? monitoringDelayMs=null, int? monitoringBaseDelayMs=null, List< MonitoringSchedule > schedule=null, bool? breakOnFailure=null, DateTime? monitoringExpiration=null, bool useCache=true)
 Monitor Reddit for new "old" comments on this thread. More...
 
bool MonitorRandom (int? monitoringDelayMs=null, int? monitoringBaseDelayMs=null, List< MonitoringSchedule > schedule=null, bool? breakOnFailure=null, DateTime? monitoringExpiration=null, bool useCache=true)
 Monitor Reddit for new "random" comments on this thread. More...
 
bool MonitorQA (int? monitoringDelayMs=null, int? monitoringBaseDelayMs=null, List< MonitoringSchedule > schedule=null, bool? breakOnFailure=null, DateTime? monitoringExpiration=null, bool useCache=true)
 Monitor Reddit for new "qa" comments on this thread. More...
 
bool MonitorLive (int? monitoringDelayMs=null, int? monitoringBaseDelayMs=null, List< MonitoringSchedule > schedule=null, bool? breakOnFailure=null, DateTime? monitoringExpiration=null, bool useCache=true)
 Monitor Reddit for new "live" comments on this thread. More...
 
bool ConfidenceCommentsIsMonitored ()
 Whether the confidence sort is being monitored. More...
 
bool TopCommentsIsMonitored ()
 Whether the top sort is being monitored. More...
 
bool NewCommentsIsMonitored ()
 Whether the new sort is being monitored. More...
 
bool ControversialCommentsIsMonitored ()
 Whether the controversial sort is being monitored. More...
 
bool OldCommentsIsMonitored ()
 Whether the old sort is being monitored. More...
 
bool RandomCommentsIsMonitored ()
 Whether the random sort is being monitored. More...
 
bool QACommentsIsMonitored ()
 Whether the qa sort is being monitored. More...
 
bool LiveCommentsIsMonitored ()
 Whether the live sort is being monitored. More...
 
- Public Member Functions inherited from Reddit.Controllers.Internal.Monitors
 Monitors ()
 
void Wait (int ms)
 
bool IsMonitored (string key, string subKey)
 
bool IsScheduled ()
 
void WaitOrDie (string key, int timeout=60)
 
void WaitOrDie (Thread thread, int timeout=60)
 
void KillAllMonitoringThreads ()
 
- Public Member Functions inherited from Reddit.Controllers.BaseController
 BaseController ()
 Create a new Controller instance. More...
 
- Public Member Functions inherited from Reddit.Controllers.Internal.Validators
Exception BuildException (Exception ex, List< List< string >> errors)
 
dynamic Validate (dynamic obj)
 
GenericContainer Validate (GenericContainer genericContainer)
 
Generic Validate (Generic generic)
 
DynamicShortListingContainer Validate (DynamicShortListingContainer dynamicShortListingContainer)
 
DynamicShortListingData Validate (DynamicShortListingData dynamicShortListingData)
 
ImageUploadResult Validate (ImageUploadResult imageUploadResult)
 
LiveUpdateEventContainer Validate (LiveUpdateEventContainer liveUpdateEventContainer)
 
LiveThreadCreateResultContainer Validate (LiveThreadCreateResultContainer liveThreadCreateResultContainer)
 
LiveUpdateContainer Validate (LiveUpdateContainer liveUpdateContainer, int? minChildren=null)
 
SubredditSettingsContainer Validate (SubredditSettingsContainer subredditSettingsContainer)
 
SubredditSettings Validate (SubredditSettings subredditSettings)
 
List< ActionResultValidate (List< ActionResult > actionResults)
 
ActionResult Validate (ActionResult actionResult)
 
FlairListResultContainer Validate (FlairListResultContainer flairListResultContainer)
 
Flair Validate (Flair flair)
 
FlairV2 Validate (FlairV2 flairV2)
 
ModActionContainer Validate (ModActionContainer modActionContainer)
 
ModActionData Validate (ModActionData modActionData)
 
WikiPageRevisionContainer Validate (WikiPageRevisionContainer wikiPageRevisionContainer)
 
WikiPageRevisionData Validate (WikiPageRevisionData wikiPageRevisionData)
 
WikiPageSettingsContainer Validate (WikiPageSettingsContainer wikiPageSettingsContainer)
 
WikiPageSettings Validate (WikiPageSettings wikiPageSettings)
 
List< UserPrefsContainerValidate (List< UserPrefsContainer > userPrefsContainers)
 
UserPrefsContainer Validate (UserPrefsContainer userPrefsContainer)
 
UserPrefsData Validate (UserPrefsData userPrefsData)
 
PostResultShortContainer Validate (PostResultShortContainer postResultShortContainer)
 
PostResultShort Validate (PostResultShort postResultShort)
 
PostResultContainer Validate (PostResultContainer postResultContainer)
 
PostResult Validate (PostResult postResult)
 
JQueryReturn Validate (JQueryReturn jQueryReturn)
 
List<(PostContainer, CommentContainer)> Validate (List<(PostContainer, CommentContainer)> ps)
 
CommentResultContainer Validate (CommentResultContainer commentResultContainer)
 
SubredditContainer Validate (SubredditContainer subredditContainer)
 

Protected Member Functions

void TriggerUpdate (CommentsUpdateEventArgs args, string type)
 Invoke the appropriate event for the given type. More...
 
override Thread CreateMonitoringThread (string key, string subKey, int startDelayMs=0, int? monitoringDelayMs=null)
 Creates a new monitoring thread. More...
 
- Protected Member Functions inherited from Reddit.Controllers.Internal.Monitors
bool Monitor (string key, Thread thread, string subKey)
 
void RebuildThreads (string subKey)
 
void LaunchThreadIfNotNull (string key, Thread thread)
 
void KillThread (Thread thread)
 
void KillThread (string key)
 
void ResetThreads (List< string > oldThreads)
 
- Protected Member Functions inherited from Reddit.Controllers.Internal.Validators
void CheckErrors (List< List< string >> errors)
 
void CheckErrors (List< string > errors)
 
void CheckNull (object res, string msg="Reddit API returned null response.")
 

Properties

List< Comment >? Confidence [get]
 A list of comments using "confidence" sort. More...
 
IList< Comment >? IConfidence [get]
 A list interface of comments using "confidence" sort. More...
 
List< Comment >? Top [get]
 A list of comments using "top" sort. More...
 
IList< Comment >? ITop [get]
 A list interface of comments using "top" sort. More...
 
List< Comment >? New [get]
 A list of comments using "new" sort. More...
 
IList< Comment >? INew [get]
 A list interface of comments using "new" sort. More...
 
List< Comment >? Controversial [get]
 A list of comments using "controversial" sort. More...
 
IList< Comment >? IControversial [get]
 A list interface of comments using "controversial" sort. More...
 
List< Comment >? Old [get]
 A list of comments using "old" sort. More...
 
IList< Comment >? IOld [get]
 A list interface of comments using "old" sort. More...
 
List< Comment >? Random [get]
 A list of comments using "random" sort. More...
 
IList< Comment >? IRandom [get]
 A list interface of comments using "random" sort. More...
 
List< Comment >? QA [get]
 A list of comments using "qa" sort. More...
 
IList< Comment >? IQA [get]
 A list interface of comments using "qa" sort. More...
 
List< Comment >? Live [get]
 A list of comments using "live" sort. More...
 
IList< Comment >? ILive [get]
 A list interface of comments using "live" sort. More...
 
Comment Comment [get]
 The parent comment (if one exists). More...
 
string SubKey [get, set]
 Monitoring SubKey. More...
 
- Properties inherited from Reddit.Controllers.Internal.Monitors
IDictionary< string, HashSet< string > > MonitoringCache [get, set]
 An optional cache for preventing the same post from appearing multiple times during monitoring. See: https://github.com/sirkris/Reddit.NET/issues/117#issuecomment-759501039 More...
 
- Properties inherited from Reddit.Controllers.BaseController
Lists Lists [get, set]
 List-handling. More...
 

Events

EventHandler< CommentsUpdateEventArgsConfidenceUpdated
 Event handler for monitoring comments (confidence sort) More...
 
EventHandler< CommentsUpdateEventArgsTopUpdated
 Event handler for monitoring comments (top sort) More...
 
EventHandler< CommentsUpdateEventArgsNewUpdated
 Event handler for monitoring comments (new sort) More...
 
EventHandler< CommentsUpdateEventArgsControversialUpdated
 Event handler for monitoring comments (controversial sort) More...
 
EventHandler< CommentsUpdateEventArgsOldUpdated
 Event handler for monitoring comments (old sort) More...
 
EventHandler< CommentsUpdateEventArgsRandomUpdated
 Event handler for monitoring comments (random sort) More...
 
EventHandler< CommentsUpdateEventArgsQAUpdated
 Event handler for monitoring comments (qa sort) More...
 
EventHandler< CommentsUpdateEventArgsLiveUpdated
 Event handler for monitoring comments (live sort) More...
 

Additional Inherited Members

- Public Attributes inherited from Reddit.Controllers.Internal.Monitors
int MonitoringWaitDelayMS = 1500
 
- Protected Attributes inherited from Reddit.Controllers.Internal.Monitors
volatile bool Terminate = false
 

Detailed Description

Controller class for comment replies.

Constructor & Destructor Documentation

◆ Comments()

Reddit.Controllers.Comments.Comments ( Dispatch  dispatch,
string  postId = null,
string  subreddit = null,
Comment  comment = null,
List< Comment confidence = null,
List< Comment top = null,
List< Comment newComments = null,
List< Comment controversial = null,
List< Comment old = null,
List< Comment random = null,
List< Comment qa = null,
List< Comment live = null 
)

Create a new instance of the comments controller.

Parameters
dispatch
postIdThe ID36 of the parent post
subredditThe name of the parent subreddit
commentThe parent comment instance
confidence
top
newComments
controversial
old
random
qa
live

Member Function Documentation

◆ ConfidenceCommentsIsMonitored()

bool Reddit.Controllers.Comments.ConfidenceCommentsIsMonitored ( )

Whether the confidence sort is being monitored.

Returns
Whether the confidence sort is being monitored.

◆ ControversialCommentsIsMonitored()

bool Reddit.Controllers.Comments.ControversialCommentsIsMonitored ( )

Whether the controversial sort is being monitored.

Returns
Whether the controversial sort is being monitored.

◆ CreateMonitoringThread()

override Thread Reddit.Controllers.Comments.CreateMonitoringThread ( string  key,
string  subKey,
int  startDelayMs = 0,
int?  monitoringDelayMs = null 
)
protectedvirtual

Creates a new monitoring thread.

Parameters
keyMonitoring key
subKeyMonitoring subKey
startDelayMsHow long to wait before starting the thread in milliseconds (default: 0)
monitoringDelayMsHow long to wait between monitoring queries; pass null to leave it auto-managed (default: null)
Returns
The newly-created monitoring thread.

Implements Reddit.Controllers.Internal.Monitors.

◆ GetComments()

List<Comment> Reddit.Controllers.Comments.GetComments ( string  sort = "new",
int  context = 3,
int  truncate = 0,
bool  showEdits = false,
bool  showMore = true,
bool  threaded = true,
int?  depth = null,
int?  limit = null,
bool  srDetail = false,
bool  isInterface = false 
)

Retrieve comment replies to this comment.

Parameters
sortone of (confidence, top, new, controversial, old, random, qa, live)
contextan integer between 0 and 8
truncatean integer between 0 and 50
showEditsboolean value
showMoreboolean value
threadedboolean value
depth(optional) an integer
limit(optional) an integer
srDetail(optional) expand subreddits
isInterface(optional) whether to store the result cache in the interface
Returns
A list of comments.

◆ GetConfidence()

List<Comment> Reddit.Controllers.Comments.GetConfidence ( int  context = 3,
int  truncate = 0,
bool  showEdits = false,
bool  showMore = true,
bool  threaded = true,
int?  depth = null,
int?  limit = null,
bool  srDetail = false,
bool  isInterface = false 
)

Retrieve a list of comments using "confidence" sort.

Parameters
contextan integer between 0 and 8
truncatean integer between 0 and 50
showEditsboolean value
showMoreboolean value
threadedboolean value
depth(optional) an integer
limit(optional) an integer
srDetail(optional) expand subreddits
isInterface(optional) whether to store the result cache in the interface
Returns
A list of comments.

◆ GetControversial()

List<Comment> Reddit.Controllers.Comments.GetControversial ( int  context = 3,
int  truncate = 0,
bool  showEdits = false,
bool  showMore = true,
bool  threaded = true,
int?  depth = null,
int?  limit = null,
bool  srDetail = false,
bool  isInterface = false 
)

Retrieve a list of comments using "controversial" sort.

Parameters
contextan integer between 0 and 8
truncatean integer between 0 and 50
showEditsboolean value
showMoreboolean value
threadedboolean value
depth(optional) an integer
limit(optional) an integer
srDetail(optional) expand subreddits
isInterface(optional) whether to store the result cache in the interface
Returns
A list of comments.

◆ GetLive()

List<Comment> Reddit.Controllers.Comments.GetLive ( int  context = 3,
int  truncate = 0,
bool  showEdits = false,
bool  showMore = true,
bool  threaded = true,
int?  depth = null,
int?  limit = null,
bool  srDetail = false,
bool  isInterface = false 
)

Retrieve a list of comments using "live" sort.

Parameters
contextan integer between 0 and 8
truncatean integer between 0 and 50
showEditsboolean value
showMoreboolean value
threadedboolean value
depth(optional) an integer
limit(optional) an integer
srDetail(optional) expand subreddits
isInterface(optional) whether to store the result cache in the interface
Returns
A list of comments.

◆ GetNew()

List<Comment> Reddit.Controllers.Comments.GetNew ( int  context = 3,
int  truncate = 0,
bool  showEdits = false,
bool  showMore = true,
bool  threaded = true,
int?  depth = null,
int?  limit = null,
bool  srDetail = false,
bool  isInterface = false 
)

Retrieve a list of comments using "new" sort.

Parameters
contextan integer between 0 and 8
truncatean integer between 0 and 50
showEditsboolean value
showMoreboolean value
threadedboolean value
depth(optional) an integer
limit(optional) an integer
srDetail(optional) expand subreddits
isInterface(optional) whether to store the result cache in the interface
Returns
A list of comments.

◆ GetOld()

List<Comment> Reddit.Controllers.Comments.GetOld ( int  context = 3,
int  truncate = 0,
bool  showEdits = false,
bool  showMore = true,
bool  threaded = true,
int?  depth = null,
int?  limit = null,
bool  srDetail = false,
bool  isInterface = false 
)

Retrieve a list of comments using "old" sort.

Parameters
contextan integer between 0 and 8
truncatean integer between 0 and 50
showEditsboolean value
showMoreboolean value
threadedboolean value
depth(optional) an integer
limit(optional) an integer
srDetail(optional) expand subreddits
isInterface(optional) whether to store the result cache in the interface
Returns
A list of comments.

◆ GetQA()

List<Comment> Reddit.Controllers.Comments.GetQA ( int  context = 3,
int  truncate = 0,
bool  showEdits = false,
bool  showMore = true,
bool  threaded = true,
int?  depth = null,
int?  limit = null,
bool  srDetail = false,
bool  isInterface = false 
)

Retrieve a list of comments using "qa" sort.

Parameters
contextan integer between 0 and 8
truncatean integer between 0 and 50
showEditsboolean value
showMoreboolean value
threadedboolean value
depth(optional) an integer
limit(optional) an integer
srDetail(optional) expand subreddits
isInterface(optional) whether to store the result cache in the interface
Returns
A list of comments.

◆ GetRandom()

List<Comment> Reddit.Controllers.Comments.GetRandom ( int  context = 3,
int  truncate = 0,
bool  showEdits = false,
bool  showMore = true,
bool  threaded = true,
int?  depth = null,
int?  limit = null,
bool  srDetail = false,
bool  isInterface = false 
)

Retrieve a list of comments using "random" sort.

Parameters
contextan integer between 0 and 8
truncatean integer between 0 and 50
showEditsboolean value
showMoreboolean value
threadedboolean value
depth(optional) an integer
limit(optional) an integer
srDetail(optional) expand subreddits
isInterface(optional) whether to store the result cache in the interface
Returns
A list of comments.

◆ GetTop()

List<Comment> Reddit.Controllers.Comments.GetTop ( int  context = 3,
int  truncate = 0,
bool  showEdits = false,
bool  showMore = true,
bool  threaded = true,
int?  depth = null,
int?  limit = null,
bool  srDetail = false,
bool  isInterface = false 
)

Retrieve a list of comments using "top" sort.

Parameters
contextan integer between 0 and 8
truncatean integer between 0 and 50
showEditsboolean value
showMoreboolean value
threadedboolean value
depth(optional) an integer
limit(optional) an integer
srDetail(optional) expand subreddits
isInterface(optional) whether to store the result cache in the interface
Returns
A list of comments.

◆ LiveCommentsIsMonitored()

bool Reddit.Controllers.Comments.LiveCommentsIsMonitored ( )

Whether the live sort is being monitored.

Returns
Whether the live sort is being monitored.

◆ MonitorConfidence()

bool Reddit.Controllers.Comments.MonitorConfidence ( int?  monitoringDelayMs = null,
int?  monitoringBaseDelayMs = null,
List< MonitoringSchedule schedule = null,
bool?  breakOnFailure = null,
DateTime?  monitoringExpiration = null,
bool  useCache = true 
)

Monitor Reddit for new "confidence" comments on this thread.

Parameters
monitoringDelayMsThe number of milliseconds between each monitoring query; leave null to auto-manage
monitoringBaseDelayMsThe number of milliseconds between each monitoring query PER THREAD (default: 1500)
scheduleA list of one or more timeframes during which monitoring of this object will occur (default: 24/7)
breakOnFailureIf true, an exception will be thrown when a monitoring query fails; leave null to keep current setting (default: false)
monitoringExpirationIf set, monitoring will automatically stop after the specified DateTime is reached
useCacheWhether to cache the IDs of the monitoring results to prevent duplicate fires (default: true)
Returns
True if this action turned monitoring on, false if this action turned it off.

◆ MonitorControversial()

bool Reddit.Controllers.Comments.MonitorControversial ( int?  monitoringDelayMs = null,
int?  monitoringBaseDelayMs = null,
List< MonitoringSchedule schedule = null,
bool?  breakOnFailure = null,
DateTime?  monitoringExpiration = null,
bool  useCache = true 
)

Monitor Reddit for new "controversial" comments on this thread.

Parameters
monitoringDelayMsThe number of milliseconds between each monitoring query; leave null to auto-manage
monitoringBaseDelayMsThe number of milliseconds between each monitoring query PER THREAD (default: 1500)
scheduleA list of one or more timeframes during which monitoring of this object will occur (default: 24/7)
breakOnFailureIf true, an exception will be thrown when a monitoring query fails; leave null to keep current setting (default: false)
monitoringExpirationIf set, monitoring will automatically stop after the specified DateTime is reached
useCacheWhether to cache the IDs of the monitoring results to prevent duplicate fires (default: true)
Returns
True if this action turned monitoring on, false if this action turned it off.

◆ MonitorLive()

bool Reddit.Controllers.Comments.MonitorLive ( int?  monitoringDelayMs = null,
int?  monitoringBaseDelayMs = null,
List< MonitoringSchedule schedule = null,
bool?  breakOnFailure = null,
DateTime?  monitoringExpiration = null,
bool  useCache = true 
)

Monitor Reddit for new "live" comments on this thread.

Parameters
monitoringDelayMsThe number of milliseconds between each monitoring query; leave null to auto-manage
monitoringBaseDelayMsThe number of milliseconds between each monitoring query PER THREAD (default: 1500)
scheduleA list of one or more timeframes during which monitoring of this object will occur (default: 24/7)
breakOnFailureIf true, an exception will be thrown when a monitoring query fails; leave null to keep current setting (default: false)
monitoringExpirationIf set, monitoring will automatically stop after the specified DateTime is reached
useCacheWhether to cache the IDs of the monitoring results to prevent duplicate fires (default: true)
Returns
True if this action turned monitoring on, false if this action turned it off.

◆ MonitorNew()

bool Reddit.Controllers.Comments.MonitorNew ( int?  monitoringDelayMs = null,
int?  monitoringBaseDelayMs = null,
List< MonitoringSchedule schedule = null,
bool?  breakOnFailure = null,
DateTime?  monitoringExpiration = null,
bool  useCache = true 
)

Monitor Reddit for new "new" comments on this thread.

Parameters
monitoringDelayMsThe number of milliseconds between each monitoring query; leave null to auto-manage
monitoringBaseDelayMsThe number of milliseconds between each monitoring query PER THREAD (default: 1500)
scheduleA list of one or more timeframes during which monitoring of this object will occur (default: 24/7)
breakOnFailureIf true, an exception will be thrown when a monitoring query fails; leave null to keep current setting (default: false)
monitoringExpirationIf set, monitoring will automatically stop after the specified DateTime is reached
useCacheWhether to cache the IDs of the monitoring results to prevent duplicate fires (default: true)
Returns
True if this action turned monitoring on, false if this action turned it off.

◆ MonitorOld()

bool Reddit.Controllers.Comments.MonitorOld ( int?  monitoringDelayMs = null,
int?  monitoringBaseDelayMs = null,
List< MonitoringSchedule schedule = null,
bool?  breakOnFailure = null,
DateTime?  monitoringExpiration = null,
bool  useCache = true 
)

Monitor Reddit for new "old" comments on this thread.

Parameters
monitoringDelayMsThe number of milliseconds between each monitoring query; leave null to auto-manage
monitoringBaseDelayMsThe number of milliseconds between each monitoring query PER THREAD (default: 1500)
scheduleA list of one or more timeframes during which monitoring of this object will occur (default: 24/7)
breakOnFailureIf true, an exception will be thrown when a monitoring query fails; leave null to keep current setting (default: false)
monitoringExpirationIf set, monitoring will automatically stop after the specified DateTime is reached
useCacheWhether to cache the IDs of the monitoring results to prevent duplicate fires (default: true)
Returns
True if this action turned monitoring on, false if this action turned it off.

◆ MonitorQA()

bool Reddit.Controllers.Comments.MonitorQA ( int?  monitoringDelayMs = null,
int?  monitoringBaseDelayMs = null,
List< MonitoringSchedule schedule = null,
bool?  breakOnFailure = null,
DateTime?  monitoringExpiration = null,
bool  useCache = true 
)

Monitor Reddit for new "qa" comments on this thread.

Parameters
monitoringDelayMsThe number of milliseconds between each monitoring query; leave null to auto-manage
monitoringBaseDelayMsThe number of milliseconds between each monitoring query PER THREAD (default: 1500)
scheduleA list of one or more timeframes during which monitoring of this object will occur (default: 24/7)
breakOnFailureIf true, an exception will be thrown when a monitoring query fails; leave null to keep current setting (default: false)
monitoringExpirationIf set, monitoring will automatically stop after the specified DateTime is reached
useCacheWhether to cache the IDs of the monitoring results to prevent duplicate fires (default: true)
Returns
True if this action turned monitoring on, false if this action turned it off.

◆ MonitorRandom()

bool Reddit.Controllers.Comments.MonitorRandom ( int?  monitoringDelayMs = null,
int?  monitoringBaseDelayMs = null,
List< MonitoringSchedule schedule = null,
bool?  breakOnFailure = null,
DateTime?  monitoringExpiration = null,
bool  useCache = true 
)

Monitor Reddit for new "random" comments on this thread.

Parameters
monitoringDelayMsThe number of milliseconds between each monitoring query; leave null to auto-manage
monitoringBaseDelayMsThe number of milliseconds between each monitoring query PER THREAD (default: 1500)
scheduleA list of one or more timeframes during which monitoring of this object will occur (default: 24/7)
breakOnFailureIf true, an exception will be thrown when a monitoring query fails; leave null to keep current setting (default: false)
monitoringExpirationIf set, monitoring will automatically stop after the specified DateTime is reached
useCacheWhether to cache the IDs of the monitoring results to prevent duplicate fires (default: true)
Returns
True if this action turned monitoring on, false if this action turned it off.

◆ MonitorTop()

bool Reddit.Controllers.Comments.MonitorTop ( int?  monitoringDelayMs = null,
int?  monitoringBaseDelayMs = null,
List< MonitoringSchedule schedule = null,
bool?  breakOnFailure = null,
DateTime?  monitoringExpiration = null,
bool  useCache = true 
)

Monitor Reddit for new "top" comments on this thread.

Parameters
monitoringDelayMsThe number of milliseconds between each monitoring query; leave null to auto-manage
monitoringBaseDelayMsThe number of milliseconds between each monitoring query PER THREAD (default: 1500)
scheduleA list of one or more timeframes during which monitoring of this object will occur (default: 24/7)
breakOnFailureIf true, an exception will be thrown when a monitoring query fails; leave null to keep current setting (default: false)
monitoringExpirationIf set, monitoring will automatically stop after the specified DateTime is reached
useCacheWhether to cache the IDs of the monitoring results to prevent duplicate fires (default: true)
Returns
True if this action turned monitoring on, false if this action turned it off.

◆ NewCommentsIsMonitored()

bool Reddit.Controllers.Comments.NewCommentsIsMonitored ( )

Whether the new sort is being monitored.

Returns
Whether the new sort is being monitored.

◆ OldCommentsIsMonitored()

bool Reddit.Controllers.Comments.OldCommentsIsMonitored ( )

Whether the old sort is being monitored.

Returns
Whether the old sort is being monitored.

◆ QACommentsIsMonitored()

bool Reddit.Controllers.Comments.QACommentsIsMonitored ( )

Whether the qa sort is being monitored.

Returns
Whether the qa sort is being monitored.

◆ RandomCommentsIsMonitored()

bool Reddit.Controllers.Comments.RandomCommentsIsMonitored ( )

Whether the random sort is being monitored.

Returns
Whether the random sort is being monitored.

◆ TopCommentsIsMonitored()

bool Reddit.Controllers.Comments.TopCommentsIsMonitored ( )

Whether the top sort is being monitored.

Returns
Whether the top sort is being monitored.

◆ TriggerUpdate()

void Reddit.Controllers.Comments.TriggerUpdate ( CommentsUpdateEventArgs  args,
string  type 
)
protected

Invoke the appropriate event for the given type.

Parameters
argsA valid CommentsUpdateEventArgs instance
typeOne of: (confidence, top, new, controversial, old, random, qa, live)

Property Documentation

◆ Comment

Comment Reddit.Controllers.Comments.Comment
get

The parent comment (if one exists).

◆ Confidence

List<Comment>? Reddit.Controllers.Comments.Confidence
get

A list of comments using "confidence" sort.

◆ Controversial

List<Comment>? Reddit.Controllers.Comments.Controversial
get

A list of comments using "controversial" sort.

◆ IConfidence

IList<Comment>? Reddit.Controllers.Comments.IConfidence
get

A list interface of comments using "confidence" sort.

◆ IControversial

IList<Comment>? Reddit.Controllers.Comments.IControversial
get

A list interface of comments using "controversial" sort.

◆ ILive

IList<Comment>? Reddit.Controllers.Comments.ILive
get

A list interface of comments using "live" sort.

◆ INew

IList<Comment>? Reddit.Controllers.Comments.INew
get

A list interface of comments using "new" sort.

◆ IOld

IList<Comment>? Reddit.Controllers.Comments.IOld
get

A list interface of comments using "old" sort.

◆ IQA

IList<Comment>? Reddit.Controllers.Comments.IQA
get

A list interface of comments using "qa" sort.

◆ IRandom

IList<Comment>? Reddit.Controllers.Comments.IRandom
get

A list interface of comments using "random" sort.

◆ ITop

IList<Comment>? Reddit.Controllers.Comments.ITop
get

A list interface of comments using "top" sort.

◆ Live

List<Comment>? Reddit.Controllers.Comments.Live
get

A list of comments using "live" sort.

◆ New

List<Comment>? Reddit.Controllers.Comments.New
get

A list of comments using "new" sort.

◆ Old

List<Comment>? Reddit.Controllers.Comments.Old
get

A list of comments using "old" sort.

◆ QA

List<Comment>? Reddit.Controllers.Comments.QA
get

A list of comments using "qa" sort.

◆ Random

List<Comment>? Reddit.Controllers.Comments.Random
get

A list of comments using "random" sort.

◆ SubKey

string Reddit.Controllers.Comments.SubKey
getset

Monitoring SubKey.

◆ Top

List<Comment>? Reddit.Controllers.Comments.Top
get

A list of comments using "top" sort.

Event Documentation

◆ ConfidenceUpdated

EventHandler<CommentsUpdateEventArgs> Reddit.Controllers.Comments.ConfidenceUpdated

Event handler for monitoring comments (confidence sort)

◆ ControversialUpdated

EventHandler<CommentsUpdateEventArgs> Reddit.Controllers.Comments.ControversialUpdated

Event handler for monitoring comments (controversial sort)

◆ LiveUpdated

EventHandler<CommentsUpdateEventArgs> Reddit.Controllers.Comments.LiveUpdated

Event handler for monitoring comments (live sort)

◆ NewUpdated

EventHandler<CommentsUpdateEventArgs> Reddit.Controllers.Comments.NewUpdated

Event handler for monitoring comments (new sort)

◆ OldUpdated

EventHandler<CommentsUpdateEventArgs> Reddit.Controllers.Comments.OldUpdated

Event handler for monitoring comments (old sort)

◆ QAUpdated

EventHandler<CommentsUpdateEventArgs> Reddit.Controllers.Comments.QAUpdated

Event handler for monitoring comments (qa sort)

◆ RandomUpdated

EventHandler<CommentsUpdateEventArgs> Reddit.Controllers.Comments.RandomUpdated

Event handler for monitoring comments (random sort)

◆ TopUpdated

EventHandler<CommentsUpdateEventArgs> Reddit.Controllers.Comments.TopUpdated

Event handler for monitoring comments (top sort)


The documentation for this class was generated from the following file: