aboutsummaryrefslogblamecommitdiff
path: root/app/src/main/java/ml/docilealligator/infinityforreddit/subreddit/SubredditSettingData.java
blob: c9d0e375c0960fed0f736d711462eb8f7c261911 (plain) (tree)
1
2
3
4
5
6
7
8
9
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643


                                                       
 




                                                  



                                                              















































































































































































































































                                                                                                                    



                                                                            

































































































































































































































































































































































































                                                                                                                                              
package ml.docilealligator.infinityforreddit.subreddit;

import androidx.annotation.Nullable;

import com.google.gson.annotations.SerializedName;

import java.util.Objects;

public class SubredditSettingData {
    public static final String WIKIMODE_ANYONE = "anyone";
    public static final String WIKIMODE_DISABLED = "disabled";
    public static final String WIKIMODE_MODONLY = "modonly";

    //  Content visibility || Posts to this profile can appear in r/all and your profile can be discovered in /users
    @SerializedName("default_set")
    private boolean defaultSet;
    @SerializedName("toxicity_threshold_chat_level")
    private int toxicityThresholdChatLevel;
    @SerializedName("crowd_control_chat_level")
    private int crowdControlChatLevel;
    @SerializedName("restrict_posting")
    private boolean restrictPosting;
    @SerializedName("public_description")
    private String publicDescription;
    @SerializedName("subreddit_id")
    private String subredditId;
    @SerializedName("allow_images")
    private boolean allowImages;
    @SerializedName("free_form_reports")
    private boolean freeFormReports;
    @SerializedName("domain")
    @Nullable
    private String domain;
    @SerializedName("show_media")
    private boolean showMedia;
    @SerializedName("wiki_edit_age")
    private int wikiEditAge;
    @SerializedName("submit_text")
    private String submitText;
    @SerializedName("allow_polls")
    private boolean allowPolls;
    @SerializedName("title")
    private String title;
    @SerializedName("collapse_deleted_comments")
    private boolean collapseDeletedComments;
    @SerializedName("wikimode")
    private String wikiMode;
    @SerializedName("should_archive_posts")
    private boolean shouldArchivePosts;
    @SerializedName("allow_videos")
    private boolean allowVideos;
    @SerializedName("allow_galleries")
    private boolean allowGalleries;
    @SerializedName("crowd_control_level")
    private int crowdControlLevel;
    @SerializedName("crowd_control_mode")
    private boolean crowdControlMode;
    @SerializedName("welcome_message_enabled")
    private boolean welcomeMessageEnabled;
    @SerializedName("welcome_message_text")
    @Nullable
    private String welcomeMessageText;
    @SerializedName("over_18")
    private boolean over18;
    @SerializedName("suggested_comment_sort")
    private String suggestedCommentSort;
    @SerializedName("disable_contributor_requests")
    private boolean disableContributorRequests;
    @SerializedName("original_content_tag_enabled")
    private boolean originalContentTagEnabled;
    @SerializedName("description")
    private String description;
    @SerializedName("submit_link_label")
    private String submitLinkLabel;
    @SerializedName("spoilers_enabled")
    private boolean spoilersEnabled;
    @SerializedName("allow_post_crossposts")
    private boolean allowPostCrossPosts;
    @SerializedName("spam_comments")
    private String spamComments;
    @SerializedName("public_traffic")
    private boolean publicTraffic;
    @SerializedName("restrict_commenting")
    private boolean restrictCommenting;
    @SerializedName("new_pinned_post_pns_enabled")
    private boolean newPinnedPostPnsEnabled;
    @SerializedName("submit_text_label")
    private String submitTextLabel;
    @SerializedName("all_original_content")
    private boolean allOriginalContent;
    @SerializedName("spam_selfposts")
    private String spamSelfPosts;
    @SerializedName("key_color")
    private String keyColor;
    @SerializedName("language")
    private String language;
    @SerializedName("wiki_edit_karma")
    private int wikiEditKarma;
    @SerializedName("hide_ads")
    private boolean hideAds;
    @SerializedName("prediction_leaderboard_entry_type")
    private int predictionLeaderboardEntryType;
    @SerializedName("header_hover_text")
    private String headerHoverText;
    @SerializedName("allow_chat_post_creation")
    private boolean allowChatPostCreation;
    @SerializedName("allow_prediction_contributors")
    private boolean allowPredictionContributors;
    @SerializedName("allow_discovery")
    private boolean allowDiscovery;
    @SerializedName("accept_followers")
    private boolean acceptFollowers;
    @SerializedName("exclude_banned_modqueue")
    private boolean excludeBannedModQueue;
    @SerializedName("allow_predictions_tournament")
    private boolean allowPredictionsTournament;
    @SerializedName("show_media_preview")
    private boolean showMediaPreview;
    @SerializedName("comment_score_hide_mins")
    private int commentScoreHideMins;
    @SerializedName("subreddit_type")
    private String subredditType;
    @SerializedName("spam_links")
    private String spamLinks;
    @SerializedName("allow_predictions")
    private boolean allowPredictions;
    @SerializedName("user_flair_pns_enabled")
    private boolean userFlairPnsEnabled;
    @SerializedName("content_options")
    private String contentOptions;

    public boolean isDefaultSet() {
        return defaultSet;
    }

    public void setDefaultSet(boolean defaultSet) {
        this.defaultSet = defaultSet;
    }

    public int getToxicityThresholdChatLevel() {
        return toxicityThresholdChatLevel;
    }

    public void setToxicityThresholdChatLevel(int toxicityThresholdChatLevel) {
        this.toxicityThresholdChatLevel = toxicityThresholdChatLevel;
    }

    public int getCrowdControlChatLevel() {
        return crowdControlChatLevel;
    }

    public void setCrowdControlChatLevel(int crowdControlChatLevel) {
        this.crowdControlChatLevel = crowdControlChatLevel;
    }

    public boolean isRestrictPosting() {
        return restrictPosting;
    }

    public void setRestrictPosting(boolean restrictPosting) {
        this.restrictPosting = restrictPosting;
    }

    public String getPublicDescription() {
        return publicDescription;
    }

    public void setPublicDescription(String publicDescription) {
        this.publicDescription = publicDescription;
    }

    public String getSubredditId() {
        return subredditId;
    }

    public void setSubredditId(String subredditId) {
        this.subredditId = subredditId;
    }

    public boolean isAllowImages() {
        return allowImages;
    }

    public void setAllowImages(boolean allowImages) {
        this.allowImages = allowImages;
    }

    public boolean isFreeFormReports() {
        return freeFormReports;
    }

    public void setFreeFormReports(boolean freeFormReports) {
        this.freeFormReports = freeFormReports;
    }

    @Nullable
    public String getDomain() {
        return domain;
    }

    public void setDomain(@Nullable String domain) {
        this.domain = domain;
    }

    public boolean isShowMedia() {
        return showMedia;
    }

    public void setShowMedia(boolean showMedia) {
        this.showMedia = showMedia;
    }

    public int getWikiEditAge() {
        return wikiEditAge;
    }

    public void setWikiEditAge(int wikiEditAge) {
        this.wikiEditAge = wikiEditAge;
    }

    public String getSubmitText() {
        return submitText;
    }

    public void setSubmitText(String submitText) {
        this.submitText = submitText;
    }

    public boolean isAllowPolls() {
        return allowPolls;
    }

    public void setAllowPolls(boolean allowPolls) {
        this.allowPolls = allowPolls;
    }

    public String getTitle() {
        return title;
    }

    public void setTitle(String title) {
        this.title = title;
    }

    public boolean isCollapseDeletedComments() {
        return collapseDeletedComments;
    }

    public void setCollapseDeletedComments(boolean collapseDeletedComments) {
        this.collapseDeletedComments = collapseDeletedComments;
    }

    public String getWikiMode() {
        if (wikiMode == null) {
            // Default to disabled, since occasionally the API returns null.
            return WIKIMODE_DISABLED;
        }
        return wikiMode;
    }

    public void setWikiMode(String wikiMode) {
        this.wikiMode = wikiMode;
    }

    public boolean isShouldArchivePosts() {
        return shouldArchivePosts;
    }

    public void setShouldArchivePosts(boolean shouldArchivePosts) {
        this.shouldArchivePosts = shouldArchivePosts;
    }

    public boolean isAllowVideos() {
        return allowVideos;
    }

    public void setAllowVideos(boolean allowVideos) {
        this.allowVideos = allowVideos;
    }

    public boolean isAllowGalleries() {
        return allowGalleries;
    }

    public void setAllowGalleries(boolean allowGalleries) {
        this.allowGalleries = allowGalleries;
    }

    public int getCrowdControlLevel() {
        return crowdControlLevel;
    }

    public void setCrowdControlLevel(int crowdControlLevel) {
        this.crowdControlLevel = crowdControlLevel;
    }

    public boolean isCrowdControlMode() {
        return crowdControlMode;
    }

    public void setCrowdControlMode(boolean crowdControlMode) {
        this.crowdControlMode = crowdControlMode;
    }

    public boolean isWelcomeMessageEnabled() {
        return welcomeMessageEnabled;
    }

    public void setWelcomeMessageEnabled(boolean welcomeMessageEnabled) {
        this.welcomeMessageEnabled = welcomeMessageEnabled;
    }

    @Nullable
    public String getWelcomeMessageText() {
        return welcomeMessageText;
    }

    public void setWelcomeMessageText(@Nullable String welcomeMessageText) {
        this.welcomeMessageText = welcomeMessageText;
    }

    public boolean isOver18() {
        return over18;
    }

    public void setOver18(boolean over18) {
        this.over18 = over18;
    }

    public String getSuggestedCommentSort() {
        return suggestedCommentSort;
    }

    public void setSuggestedCommentSort(String suggestedCommentSort) {
        this.suggestedCommentSort = suggestedCommentSort;
    }

    public boolean isDisableContributorRequests() {
        return disableContributorRequests;
    }

    public void setDisableContributorRequests(boolean disableContributorRequests) {
        this.disableContributorRequests = disableContributorRequests;
    }

    public boolean isOriginalContentTagEnabled() {
        return originalContentTagEnabled;
    }

    public void setOriginalContentTagEnabled(boolean originalContentTagEnabled) {
        this.originalContentTagEnabled = originalContentTagEnabled;
    }

    public String getDescription() {
        return description;
    }

    public void setDescription(String description) {
        this.description = description;
    }

    public String getSubmitLinkLabel() {
        return submitLinkLabel;
    }

    public void setSubmitLinkLabel(String submitLinkLabel) {
        this.submitLinkLabel = submitLinkLabel;
    }

    public boolean isSpoilersEnabled() {
        return spoilersEnabled;
    }

    public void setSpoilersEnabled(boolean spoilersEnabled) {
        this.spoilersEnabled = spoilersEnabled;
    }

    public boolean isAllowPostCrossPosts() {
        return allowPostCrossPosts;
    }

    public void setAllowPostCrossPosts(boolean allowPostCrossPosts) {
        this.allowPostCrossPosts = allowPostCrossPosts;
    }

    public String getSpamComments() {
        return spamComments;
    }

    public void setSpamComments(String spamComments) {
        this.spamComments = spamComments;
    }

    public boolean isPublicTraffic() {
        return publicTraffic;
    }

    public void setPublicTraffic(boolean publicTraffic) {
        this.publicTraffic = publicTraffic;
    }

    public boolean isRestrictCommenting() {
        return restrictCommenting;
    }

    public void setRestrictCommenting(boolean restrictCommenting) {
        this.restrictCommenting = restrictCommenting;
    }

    public boolean isNewPinnedPostPnsEnabled() {
        return newPinnedPostPnsEnabled;
    }

    public void setNewPinnedPostPnsEnabled(boolean newPinnedPostPnsEnabled) {
        this.newPinnedPostPnsEnabled = newPinnedPostPnsEnabled;
    }

    public String getSubmitTextLabel() {
        return submitTextLabel;
    }

    public void setSubmitTextLabel(String submitTextLabel) {
        this.submitTextLabel = submitTextLabel;
    }

    public boolean isAllOriginalContent() {
        return allOriginalContent;
    }

    public void setAllOriginalContent(boolean allOriginalContent) {
        this.allOriginalContent = allOriginalContent;
    }

    public String getSpamSelfPosts() {
        return spamSelfPosts;
    }

    public void setSpamSelfPosts(String spamSelfPosts) {
        this.spamSelfPosts = spamSelfPosts;
    }

    public String getKeyColor() {
        return keyColor;
    }

    public void setKeyColor(String keyColor) {
        this.keyColor = keyColor;
    }

    public String getLanguage() {
        return language;
    }

    public void setLanguage(String language) {
        this.language = language;
    }

    public int getWikiEditKarma() {
        return wikiEditKarma;
    }

    public void setWikiEditKarma(int wikiEditKarma) {
        this.wikiEditKarma = wikiEditKarma;
    }

    public boolean isHideAds() {
        return hideAds;
    }

    public void setHideAds(boolean hideAds) {
        this.hideAds = hideAds;
    }

    public int getPredictionLeaderboardEntryType() {
        return predictionLeaderboardEntryType;
    }

    public void setPredictionLeaderboardEntryType(int predictionLeaderboardEntryType) {
        this.predictionLeaderboardEntryType = predictionLeaderboardEntryType;
    }

    public String getHeaderHoverText() {
        return headerHoverText;
    }

    public void setHeaderHoverText(String headerHoverText) {
        this.headerHoverText = headerHoverText;
    }

    public boolean isAllowChatPostCreation() {
        return allowChatPostCreation;
    }

    public void setAllowChatPostCreation(boolean allowChatPostCreation) {
        this.allowChatPostCreation = allowChatPostCreation;
    }

    public boolean isAllowPredictionContributors() {
        return allowPredictionContributors;
    }

    public void setAllowPredictionContributors(boolean allowPredictionContributors) {
        this.allowPredictionContributors = allowPredictionContributors;
    }

    public boolean isAllowDiscovery() {
        return allowDiscovery;
    }

    public void setAllowDiscovery(boolean allowDiscovery) {
        this.allowDiscovery = allowDiscovery;
    }

    public boolean isAcceptFollowers() {
        return acceptFollowers;
    }

    public void setAcceptFollowers(boolean acceptFollowers) {
        this.acceptFollowers = acceptFollowers;
    }

    public boolean isExcludeBannedModQueue() {
        return excludeBannedModQueue;
    }

    public void setExcludeBannedModQueue(boolean excludeBannedModQueue) {
        this.excludeBannedModQueue = excludeBannedModQueue;
    }

    public boolean isAllowPredictionsTournament() {
        return allowPredictionsTournament;
    }

    public void setAllowPredictionsTournament(boolean allowPredictionsTournament) {
        this.allowPredictionsTournament = allowPredictionsTournament;
    }

    public boolean isShowMediaPreview() {
        return showMediaPreview;
    }

    public void setShowMediaPreview(boolean showMediaPreview) {
        this.showMediaPreview = showMediaPreview;
    }

    public int getCommentScoreHideMins() {
        return commentScoreHideMins;
    }

    public void setCommentScoreHideMins(int commentScoreHideMins) {
        this.commentScoreHideMins = commentScoreHideMins;
    }

    public String getSubredditType() {
        return subredditType;
    }

    public void setSubredditType(String subredditType) {
        this.subredditType = subredditType;
    }

    public String getSpamLinks() {
        return spamLinks;
    }

    public void setSpamLinks(String spamLinks) {
        this.spamLinks = spamLinks;
    }

    public boolean isAllowPredictions() {
        return allowPredictions;
    }

    public void setAllowPredictions(boolean allowPredictions) {
        this.allowPredictions = allowPredictions;
    }

    public boolean isUserFlairPnsEnabled() {
        return userFlairPnsEnabled;
    }

    public void setUserFlairPnsEnabled(boolean userFlairPnsEnabled) {
        this.userFlairPnsEnabled = userFlairPnsEnabled;
    }

    public String getContentOptions() {
        return contentOptions;
    }

    public void setContentOptions(String contentOptions) {
        this.contentOptions = contentOptions;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;
        SubredditSettingData that = (SubredditSettingData) o;
        return defaultSet == that.defaultSet && toxicityThresholdChatLevel == that.toxicityThresholdChatLevel
                && crowdControlChatLevel == that.crowdControlChatLevel && restrictPosting == that.restrictPosting
                && allowImages == that.allowImages && freeFormReports == that.freeFormReports && showMedia == that.showMedia
                && wikiEditAge == that.wikiEditAge && allowPolls == that.allowPolls && collapseDeletedComments == that.collapseDeletedComments
                && shouldArchivePosts == that.shouldArchivePosts && allowVideos == that.allowVideos
                && allowGalleries == that.allowGalleries && crowdControlLevel == that.crowdControlLevel
                && crowdControlMode == that.crowdControlMode && welcomeMessageEnabled == that.welcomeMessageEnabled
                && over18 == that.over18 && disableContributorRequests == that.disableContributorRequests
                && originalContentTagEnabled == that.originalContentTagEnabled && spoilersEnabled == that.spoilersEnabled
                && allowPostCrossPosts == that.allowPostCrossPosts && publicTraffic == that.publicTraffic
                && restrictCommenting == that.restrictCommenting && newPinnedPostPnsEnabled == that.newPinnedPostPnsEnabled
                && allOriginalContent == that.allOriginalContent && wikiEditKarma == that.wikiEditKarma
                && hideAds == that.hideAds && predictionLeaderboardEntryType == that.predictionLeaderboardEntryType
                && allowChatPostCreation == that.allowChatPostCreation && allowPredictionContributors == that.allowPredictionContributors
                && allowDiscovery == that.allowDiscovery && acceptFollowers == that.acceptFollowers
                && excludeBannedModQueue == that.excludeBannedModQueue && allowPredictionsTournament == that.allowPredictionsTournament
                && showMediaPreview == that.showMediaPreview && commentScoreHideMins == that.commentScoreHideMins
                && allowPredictions == that.allowPredictions && userFlairPnsEnabled == that.userFlairPnsEnabled
                && Objects.equals(publicDescription, that.publicDescription) && Objects.equals(subredditId, that.subredditId)
                && Objects.equals(domain, that.domain) && Objects.equals(submitText, that.submitText)
                && Objects.equals(title, that.title) && Objects.equals(wikiMode, that.wikiMode) &&
                Objects.equals(welcomeMessageText, that.welcomeMessageText) && Objects.equals(suggestedCommentSort, that.suggestedCommentSort)
                && Objects.equals(description, that.description) && Objects.equals(submitLinkLabel, that.submitLinkLabel)
                && Objects.equals(spamComments, that.spamComments) && Objects.equals(submitTextLabel, that.submitTextLabel)
                && Objects.equals(spamSelfPosts, that.spamSelfPosts) && Objects.equals(keyColor, that.keyColor)
                && Objects.equals(language, that.language) && Objects.equals(headerHoverText, that.headerHoverText)
                && Objects.equals(subredditType, that.subredditType) && Objects.equals(spamLinks, that.spamLinks)
                && Objects.equals(contentOptions, that.contentOptions);
    }

    @Override
    public int hashCode() {
        return Objects.hash(defaultSet, toxicityThresholdChatLevel, crowdControlChatLevel, restrictPosting,
                publicDescription, subredditId, allowImages, freeFormReports, domain, showMedia, wikiEditAge,
                submitText, allowPolls, title, collapseDeletedComments, wikiMode, shouldArchivePosts,
                allowVideos, allowGalleries, crowdControlLevel, crowdControlMode, welcomeMessageEnabled,
                welcomeMessageText, over18, suggestedCommentSort, disableContributorRequests, originalContentTagEnabled,
                description, submitLinkLabel, spoilersEnabled, allowPostCrossPosts, spamComments, publicTraffic,
                restrictCommenting, newPinnedPostPnsEnabled, submitTextLabel, allOriginalContent, spamSelfPosts,
                keyColor, language, wikiEditKarma, hideAds, predictionLeaderboardEntryType, headerHoverText,
                allowChatPostCreation, allowPredictionContributors, allowDiscovery, acceptFollowers,
                excludeBannedModQueue, allowPredictionsTournament, showMediaPreview, commentScoreHideMins,
                subredditType, spamLinks, allowPredictions, userFlairPnsEnabled, contentOptions);
    }
}