001// Generated by delombok at Thu Aug 13 13:56:43 UTC 2026 002/* 003 * Copyright (c) 2010-2026 Mark Allen, Norbert Bartels. 004 * 005 * Permission is hereby granted, free of charge, to any person obtaining a copy 006 * of this software and associated documentation files (the "Software"), to deal 007 * in the Software without restriction, including without limitation the rights 008 * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 009 * copies of the Software, and to permit persons to whom the Software is 010 * furnished to do so, subject to the following conditions: 011 * 012 * The above copyright notice and this permission notice shall be included in 013 * all copies or substantial portions of the Software. 014 * 015 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 016 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 017 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 018 * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 019 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 020 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN 021 * THE SOFTWARE. 022 */ 023package com.restfb.types.ads; 024 025import java.util.ArrayList; 026import java.util.Collections; 027import java.util.List; 028import com.restfb.Facebook; 029 030/** 031 * Represents the <a href="https://developers.facebook.com/docs/marketing-api/adaccountgroup/">AdGroup Account Group 032 * Type</a> . 033 */ 034public class AdAccountGroup extends NamedAdsObject { 035 private static final long serialVersionUID = 1L; 036 @Facebook 037 private Integer status; 038 @Facebook("account_group_id") 039 private String accountGroupId; 040 /** 041 * The users who own the ad account group. 042 */ 043 @Facebook 044 private final List<AdAccountGroupUser> users = new ArrayList<>(); 045 /** 046 * The AdGroup Accounts in the ad account group. 047 */ 048 @Facebook 049 private final List<AdAccountGroupAccount> accounts = new ArrayList<>(); 050 051 public boolean addUser(AdAccountGroupUser user) { 052 return users.add(user); 053 } 054 055 public boolean removeUser(AdAccountGroupUser user) { 056 return users.remove(user); 057 } 058 059 public List<AdAccountGroupUser> getUsers() { 060 return Collections.unmodifiableList(users); 061 } 062 063 public boolean addAccount(AdAccountGroupAccount account) { 064 return accounts.add(account); 065 } 066 067 public boolean removeAccount(AdAccountGroupAccount account) { 068 return accounts.remove(account); 069 } 070 071 public List<AdAccountGroupAccount> getAccounts() { 072 return Collections.unmodifiableList(accounts); 073 } 074 075 @java.lang.SuppressWarnings("all") 076 @lombok.Generated 077 public Integer getStatus() { 078 return this.status; 079 } 080 081 @java.lang.SuppressWarnings("all") 082 @lombok.Generated 083 public void setStatus(final Integer status) { 084 this.status = status; 085 } 086 087 @java.lang.SuppressWarnings("all") 088 @lombok.Generated 089 public String getAccountGroupId() { 090 return this.accountGroupId; 091 } 092 093 @java.lang.SuppressWarnings("all") 094 @lombok.Generated 095 public void setAccountGroupId(final String accountGroupId) { 096 this.accountGroupId = accountGroupId; 097 } 098}