ユーザープロフィール¶
ユーザープロフィールは、性別、年齢、地域、言語、会員種別など、アプリで収集可能なユーザーの付帯情報です。
このプロフィール情報を基にして、対象となるユーザーを絞り込んでプッシュ通知やメッセージを送信することができるようになります。
それぞれのプロフィール情報は固有のユーザーIDにひもづけられます。プロフィール情報をセットする前に、 ユーザーIDをセットする ことをおすすめします。ユーザーIDがセットされていない場合は、匿名ユーザーの情報として扱われ、Reproが任意に設定したIDにひもづけられますが、匿名のユーザーIDはアプリのアップデートやアンインストールによって変更されます。
警告
一度登録したユーザープロフィールキーやデータ型は、後から変更や削除をすることができません。
ユーザープロフィール設定数に上限はありません。 但し、アナリティクスでの フィルター や、キャンペーン機能で ユーザープロフィールでフィルタリング する際には利用に上限があります。 現在の設定数は 設定 > ユーザープロフィール設定 で確認することができます。
ユーザープロフィール設定 では、プッシュ通知やメッセージなど、キャンペーン機能の対象者を絞り込むために利用できるユーザープロフィールの設定を変更することができます。ここで無効にしたユーザープロフィールは、キャンペーン作成画面やアナリティクス画面のユーザー情報による絞り込みの候補として表示されません。
キャンペーン機能の対象者の絞り込みに利用できる上限を超えてユーザープロフィールを設定した場合は、ユーザープロフィールとして設定はされますがキャンペーン機能の絞り込みの候補としては表示されません。
ユーザープロフィール設定 でキャンペーン対象者の絞り込みに利用されているユーザープロフィールを無効にすると、該当するキャンペーンは配信されなくなります。
警告
HTMLアプリ内メッセージでのユーザープロフィールの設定を行うには、iOS SDK 5.19.0 以上 および Android SDK 5.18.0 以上を利用する必要があります。
WebViewにてユーザープロフィールの設定を行うには、iOS SDK 5.19.0 以上 および Android SDK 5.18.0 以上を導入し、かつ バージョン6以上のrepro.js を利用する必要があります。
条件付きセット、増減、削除の操作を行うには、iOS SDK 5.21.0、Android SDK 5.20.0、および バージョン8以上のrepro.js 以上を利用する必要があります。
標準ユーザープロフィール¶
Reproではユーザーを絞り込む上で典型的なプロフィールを 標準ユーザープロフィール として定義しています。 標準ユーザープロフィール をセットする際は、情報の種類に応じたAPIを呼び出してください。また、アプリ独自のユーザープロフィールをセットする際は カスタムユーザープロフィール をご利用ください。
警告
以下のバージョンでは、標準ユーザープロフィールとして性別およびEメールアドレスを登録することはできません。
Unity SDK 6.15.0 以下
Cordova Plugin 6.16.0 以下
標準ユーザープロフィールとして都道府県、生年月日および年齢の登録を行うためには以下のいずれかの SDK を利用する必要があります。
Android SDK 5.14.0 以上
iOS SDK 5.15.0 以上
Unity SDK 5.16.0 以上
React Native SDK 3.17.0 以上
Cordova Plugin 6.17.0 以上
Cocos2d-x SDK 5.16.0 以上
Flutter Package 3.8.0 以上
性別¶
ユーザーの性別をセットします。指定できる性別はReproの定数として定義されています。
// set the gender as "male"
[Repro setUserGender:RPRUserProfileGenderMale];
// set the gender as "female"
[Repro setUserGender:RPRUserProfileGenderFemale];
// set the gender as "other"
[Repro setUserGender:RPRUserProfileGenderOther];
// set the gender as "male"
Repro.setUserProfile(gender: .male)
// set the gender as "female"
Repro.setUserProfile(gender: .female)
// set the gender as "other"
Repro.setUserProfile(gender: .other)
// set the gender as "male"
Repro.setUserGender(UserProfileGender.MALE);
// set the gender as "female"
Repro.setUserGender(UserProfileGender.FEMALE);
// set the gender as "other"
Repro.setUserGender(UserProfileGender.OTHER);
// set the gender as "male"
Repro.setUserGender(UserProfileGender.MALE)
// set the gender as "female"
Repro.setUserGender(UserProfileGender.FEMALE)
// set the gender as "other"
Repro.setUserGender(UserProfileGender.OTHER)
// set the gender as "male"
ReproCpp::setUserGender(ReproCpp::UserProfileGenderMale);
// set the gender as "female"
ReproCpp::setUserGender(ReproCpp::UserProfileGenderFemale);
// set the gender as "other"
ReproCpp::setUserGender(ReproCpp::UserProfileGenderOther);
// set the gender as "male"
Repro.SetUserGender(UserProfileGender.Male);
// set the gender as "female"
Repro.SetUserGender(UserProfileGender.Female);
// set the gender as "other"
Repro.SetUserGender(UserProfileGender.Other);
// set the gender as "male"
Repro.setUserGender(Repro.UserProfileGender.Male);
// set the gender as "female"
Repro.setUserGender(Repro.UserProfileGender.Female);
// set the gender as "other"
Repro.setUserGender(Repro.UserProfileGender.Other);
// set the gender as "male"
Repro.setUserGender(Repro.GENDER_MALE);
// set the gender as "female"
Repro.setUserGender(Repro.GENDER_FEMALE);
// set the gender as "other"
Repro.setUserGender(Repro.GENDER_OTHER);
// set the gender as "male"
repro.setUserGender(repro.userProfileGender.Male);
// set the gender as "female"
repro.setUserGender(repro.userProfileGender.Female);
// set the gender as "other"
repro.setUserGender(repro.userProfileGender.Other);
// set the gender as "male"
Repro.setUserGender(Repro.UserProfileGender.Male);
// set the gender as "female"
Repro.setUserGender(Repro.UserProfileGender.Female);
// set the gender as "other"
Repro.setUserGender(Repro.UserProfileGender.Other);
// set the gender as "male"
await Repro.setUserGender(UserGender.male);
// set the gender as "female"
await Repro.setUserGender(UserGender.female);
// set the gender as "other"
await Repro.setUserGender(UserGender.other);
プッシュ通知やアプリ内メッセージのフィルターを設定する際は、以下の表を参照し、文字列で指定してください。
性別 |
フィルターに指定する値 |
|---|---|
男性 |
male |
女性 |
female |
その他 |
other |
Eメールアドレス¶
ユーザーのEメールアドレスをセットします。
[Repro setUserEmailAddress:@"user@example.com"];
Repro.setUserProfile(emailAddress: "user@example.com")
Repro.setUserEmailAddress("user@example.com");
Repro.setUserEmailAddress("user@example.com")
ReproCpp::setUserEmailAddress("user@example.com");
Repro.SetUserEmailAddress("user@example.com");
Repro.setUserEmailAddress("user@example.com");
Repro.setUserEmailAddress("user@example.com");
repro.setUserEmailAddress("user@example.com");
Repro.setUserEmailAddress("user@example.com");
await Repro.setUserEmailAddress("user@example.com");
都道府県¶
ユーザーが居住している都道府県名をセットします。
// set the prefecture as "Tokyo"
[Repro setUserResidencePrefecture:RPRUserProfilePrefectureTokyo];
// Possible values are as follows:
// RPRUserProfilePrefectureHokkaido, -Aomori, -Iwate, -Miyagi, -Akita, -Yamagata,
// -Fukushima, -Ibaraki, -Tochigi, -Gunma, -Saitama, -Chiba, -Tokyo, -Kanagawa,
// -Niigata, -Toyama, -Ishikawa, -Fukui, -Yamanashi, -Nagano, -Gifu, -Shizuoka,
// -Aichi, -Mie, -Shiga, -Kyoto, -Osaka, -Hyogo, -Nara, -Wakayama, -Tottori,
// -Shimane, -Okayama, -Hiroshima, -Yamaguchi, -Tokushima, -Kagawa, -Ehime, -Kochi,
// -Fukuoka, -Saga, -Nagasaki, -Kumamoto, -Oita, -Miyazaki, -Kagoshima, -Okinawa
// set the prefecture as "Tokyo"
Repro.setUserProfile(residencePrefecture: .tokyo)
// Possible values are as follows:
// .hokkaido, .aomori, .iwate, .miyagi, .akita, .yamagata,
// .fukushima, .ibaraki, .tochigi, .gunma, .saitama, .chiba, .tokyo, .kanagawa,
// .niigata, .toyama, .ishikawa, .fukui, .yamanashi, .nagano, .gifu, .shizuoka,
// .aichi, .mie, .shiga, .kyoto, .osaka, .hyogo, .nara, .wakayama, .tottori,
// .shimane, .okayama, .hiroshima, .yamaguchi, .tokushima, .kagawa, .ehime, .kochi,
// .fukuoka, .saga, .nagasaki, .kumamoto, .oita, .miyazaki, .kagoshima, .okinawa
// set the prefecture as "Tokyo"
Repro.setUserResidencePrefecture(UserProfilePrefecture.TOKYO);
// Possible values are as follows:
// HOKKAIDO, AOMORI, IWATE, MIYAGI, AKITA, YAMAGATA,
// FUKUSHIMA, IBARAKI, TOCHIGI, GUNMA, SAITAMA, CHIBA, TOKYO, KANAGAWA,
// NIIGATA, TOYAMA, ISHIKAWA, FUKUI, YAMANASHI, NAGANO, GIFU, SHIZUOKA,
// AICHI, MIE, SHIGA, KYOTO, OSAKA, HYOGO, NARA, WAKAYAMA, TOTTORI,
// SHIMANE, OKAYAMA, HIROSHIMA, YAMAGUCHI, TOKUSHIMA, KAGAWA, EHIME, KOCHI,
// FUKUOKA, SAGA, NAGASAKI, KUMAMOTO, OITA, MIYAZAKI, KAGOSHIMA, OKINAWA
// set the prefecture as "Tokyo"
Repro.setUserResidencePrefecture(UserProfilePrefecture.TOKYO)
// Possible values are as follows:
// HOKKAIDO, AOMORI, IWATE, MIYAGI, AKITA, YAMAGATA,
// FUKUSHIMA, IBARAKI, TOCHIGI, GUNMA, SAITAMA, CHIBA, TOKYO, KANAGAWA,
// NIIGATA, TOYAMA, ISHIKAWA, FUKUI, YAMANASHI, NAGANO, GIFU, SHIZUOKA,
// AICHI, MIE, SHIGA, KYOTO, OSAKA, HYOGO, NARA, WAKAYAMA, TOTTORI,
// SHIMANE, OKAYAMA, HIROSHIMA, YAMAGUCHI, TOKUSHIMA, KAGAWA, EHIME, KOCHI,
// FUKUOKA, SAGA, NAGASAKI, KUMAMOTO, OITA, MIYAZAKI, KAGOSHIMA, OKINAWA
// set the prefecture as "Tokyo"
ReproCpp::setUserResidencePrefecture(ReproCpp::UserProfilePrefectureTokyo);
// Possible values are as follows:
// UserProfilePrefectureHokkaido, -Aomori, -Iwate, -Miyagi, -Akita, -Yamagata,
// -Fukushima, -Ibaraki, -Tochigi, -Gunma, -Saitama, -Chiba, -Tokyo, -Kanagawa,
// -Niigata, -Toyama, -Ishikawa, -Fukui, -Yamanashi, -Nagano, -Gifu, -Shizuoka,
// -Aichi, -Mie, -Shiga, -Kyoto, -Osaka, -Hyogo, -Nara, -Wakayama, -Tottori,
// -Shimane, -Okayama, -Hiroshima, -Yamaguchi, -Tokushima, -Kagawa, -Ehime, -Kochi,
// -Fukuoka, -Saga, -Nagasaki, -Kumamoto, -Oita, -Miyazaki, -Kagoshima, -Okinawa
// set the prefecture as "Tokyo"
Repro.SetUserResidencePrefecture(UserProfilePrefecture.Tokyo);
// Possible values are as follows:
// Hokkaido, Aomori, Iwate, Miyagi, Akita, Yamagata,
// Fukushima, Ibaraki, Tochigi, Gunma, Saitama, Chiba, Tokyo, Kanagawa,
// Niigata, Toyama, Ishikawa, Fukui, Yamanashi, Nagano, Gifu, Shizuoka,
// Aichi, Mie, Shiga, Kyoto, Osaka, Hyogo, Nara, Wakayama, Tottori,
// Shimane, Okayama, Hiroshima, Yamaguchi, Tokushima, Kagawa, Ehime, Kochi,
// Fukuoka, Saga, Nagasaki, Kumamoto, Oita, Miyazaki, Kagoshima, Okinawa
// set the prefecture as "Tokyo"
Repro.setUserResidencePrefecture(Repro.UserProfilePrefecture.Tokyo);
// Possible values are as follows:
// Hokkaido, Aomori, Iwate, Miyagi, Akita, Yamagata,
// Fukushima, Ibaraki, Tochigi, Gunma, Saitama, Chiba, Tokyo, Kanagawa,
// Niigata, Toyama, Ishikawa, Fukui, Yamanashi, Nagano, Gifu, Shizuoka,
// Aichi, Mie, Shiga, Kyoto, Osaka, Hyogo, Nara, Wakayama, Tottori,
// Shimane, Okayama, Hiroshima, Yamaguchi, Tokushima, Kagawa, Ehime, Kochi,
// Fukuoka, Saga, Nagasaki, Kumamoto, Oita, Miyazaki, Kagoshima, Okinawa
// set the prefecture as "Tokyo"
Repro.setUserResidencePrefecture(Repro.PREFECTURE_TOKYO);
// Possible values are as follows:
// PREFECTURE_HOKKAIDO, -AOMORI, -IWATE, -MIYAGI, -AKITA, -YAMAGATA,
// -FUKUSHIMA, -IBARAKI, -TOCHIGI, -GUNMA, -SAITAMA, -CHIBA, -TOKYO, -KANAGAWA,
// -NIIGATA, -TOYAMA, -ISHIKAWA, -FUKUI, -YAMANASHI, -NAGANO, -GIFU, -SHIZUOKA,
// -AICHI, -MIE, -SHIGA, -KYOTO, -OSAKA, -HYOGO, -NARA, -WAKAYAMA, -TOTTORI,
// -SHIMANE, -OKAYAMA, -HIROSHIMA, -YAMAGUCHI, -TOKUSHIMA, -KAGAWA, -EHIME, -KOCHI,
// -FUKUOKA, -SAGA, -NAGASAKI, -KUMAMOTO, -OITA, -MIYAZAKI, -KAGOSHIMA, -OKINAWA
// set the prefecture as "Tokyo"
repro.setUserResidencePrefecture(repro.userProfilePrefecture.TOKYO);
// Possible values are as follows:
// HOKKAIDO, AOMORI, IWATE, MIYAGI, AKITA, YAMAGATA,
// FUKUSHIMA, IBARAKI, TOCHIGI, GUNMA, SAITAMA, CHIBA, TOKYO, KANAGAWA,
// NIIGATA, TOYAMA, ISHIKAWA, FUKUI, YAMANASHI, NAGANO, GIFU, SHIZUOKA,
// AICHI, MIE, SHIGA, KYOTO, OSAKA, HYOGO, NARA, WAKAYAMA, TOTTORI,
// SHIMANE, OKAYAMA, HIROSHIMA, YAMAGUCHI, TOKUSHIMA, KAGAWA, EHIME, KOCHI,
// FUKUOKA, SAGA, NAGASAKI, KUMAMOTO, OITA, MIYAZAKI, KAGOSHIMA, OKINAWA
// set the prefecture as "Tokyo"
Repro.setUserResidencePrefecture(Repro.UserProfilePrefecture.TOKYO);
// Possible values are as follows:
// HOKKAIDO, AOMORI, IWATE, MIYAGI, AKITA, YAMAGATA,
// FUKUSHIMA, IBARAKI, TOCHIGI, GUNMA, SAITAMA, CHIBA, TOKYO, KANAGAWA,
// NIIGATA, TOYAMA, ISHIKAWA, FUKUI, YAMANASHI, NAGANO, GIFU, SHIZUOKA,
// AICHI, MIE, SHIGA, KYOTO, OSAKA, HYOGO, NARA, WAKAYAMA, TOTTORI,
// SHIMANE, OKAYAMA, HIROSHIMA, YAMAGUCHI, TOKUSHIMA, KAGAWA, EHIME, KOCHI,
// FUKUOKA, SAGA, NAGASAKI, KUMAMOTO, OITA, MIYAZAKI, KAGOSHIMA, OKINAWA
// set the prefecture as "Tokyo"
await Repro.setUserResidencePrefecture(UserProfilePrefecture.tokyo);
// Possible values are as follows:
// hokkaido, aomori, iwate, miyagi, akita, yamagata,
// fukushima, ibaraki, tochigi, gunma, saitama, chiba, tokyo, kanagawa,
// niigata, toyama, ishikawa, fukui, yamanashi, nagano, gifu, shizuoka,
// aichi, mie, shiga, kyoto, osaka, hyogo, nara, wakayama, tottori,
// shimane, okayama, hiroshima, yamaguchi, tokushima, kagawa, ehime, kochi,
// fukuoka, saga, nagasaki, kumamoto, oita, miyazaki, kagoshima, okinawa
プッシュ通知やアプリ内メッセージのフィルターを設定する際は、 東京都 や 大阪府 などのように都道府県名を文字列で指定してください。
生年月日¶
ユーザーの生年月日をセットします。
NSDate *date = ... // Create an NSDate object for the user's birthday date
[Repro setUserDateOfBirth:date];
let date = ... // Create an NSDate object for the user's birthday date
Repro.setUserProfile(dateOfBirth: date)
Date date = ... // Create a Date object for the user's birthday date
Repro.setUserDateOfBirth(date);
val date = ... // Create a Date object for the user's birthday date
Repro.setUserDateOfBirth(date)
ReproCpp::setUserDateOfBirth(2000, 12, 31);
DateTime date = ... // Create a DateTime object for the user's birthday date
Repro.SetUserDateOfBirth(date);
let date = ... // Create a Date object for the user's birthday date
Repro.setUserDateOfBirth(date);
let date = ... // Create a Date object for the user's birthday date
Repro.setUserDateOfBirth(date);
let date = ... // Create a Date object for the user's birthday date
repro.setUserDateOfBirth(date.getTime());
let date = ... // Create a Date object for the user's birthday date
Repro.setUserDateOfBirth(date.getTime());
DateTime date = ... // Create a DateTime object for the user's birthday date
await Repro.SetUserDateOfBirth(date);
年齢¶
ユーザーの年齢をセットします。
[Repro setUserAge:20];
Repro.setUserProfile(age: 20)
Repro.setUserAge(20);
Repro.setUserAge(20)
ReproCpp::setUserAge(20);
Repro.SetUserAge(20);
Repro.setUserAge(20);
Repro.setUserAge(20);
repro.setUserAge(20);
Repro.setUserAge(20);
await Repro.setUserAge(20);
自動でセットされる標準ユーザープロフィール¶
以下の標準ユーザープロフィールは、セッションが発生するたびに自動でセットされるため、APIを呼び出す必要はありません。
最後に使った日¶
ユーザーが最後にアプリを利用した日付がセットされます。
ロケール¶
ユーザーの端末に設定されているロケールが文字列としてセットされます。IETF言語タグの書式に則り、 language-script-region のフォーマットで値がセットされます。IETF言語タグについては こちらの記事 を参考にしてください。
注釈
端末ロケールの値は機種に依存するため、同じロケールでも値は複数の可能性があります。例えば、同じ日本語ロケールでも値が
jaとja-JPのパターンがあります。そのため、配信フィルターで設定する際は、
含む条件を利用してください。例えば、前述のように日本語ロケールを指定する場合は、「jaを含む」で配信フィルターを設定してください。
カスタムユーザープロフィール¶
標準ユーザープロフィールとして定義されているもの以外の、サービス独自のプロフィールをセットします。プロフィールのキーには文字列のみが指定できます。 ___repro___ から始まるキーは指定できません。nilや空文字列は不可、上限は255文字です。
またプロフィールの値には、文字列、整数、小数、日付を指定できます。
文字列¶
セットできる文字数の上限は255文字です。
[Repro setStringUserProfile:@"Developer" forKey:@"Job"];
Repro.setUserProfile(stringValue: "Developer", forKey: "Job")
Repro.setStringUserProfile("Job", "Developer");
Repro.setStringUserProfile("Job", "Developer")
ReproCpp::setStringUserProfile("Job", "Developer");
Repro.SetStringUserProfile ("Job", "Developer");
Repro.setStringUserProfile("Job", "Developer");
Repro.setStringUserProfile("Job", "Developer");
repro.setStringUserProfile("Job", "Developer");
Repro.setStringUserProfile("Job", "Developer");
await Repro.setStringUserProfile("Job", "Developer");
整数¶
[Repro setIntUserProfile:25 forKey:@"Age"];
Repro.setUserProfile(integerValue: 25, forKey: "age")
Repro.setIntUserProfile("Age", 25);
Repro.setIntUserProfile("Age", 25)
ReproCpp::setIntUserProfile("Age", 25);
Repro.SetIntUserProfile ("Age", 25);
Repro.setIntUserProfile("Age", 25);
Repro.setIntUserProfile("Age", 25);
repro.setIntUserProfile("Age", 25);
Repro.setIntUserProfile("Age", 25);
await Repro.setIntUserProfile("Age", 25);
小数¶
[Repro setDoubleUserProfile:176.5 forKey:@"Height"];
Repro.setUserProfile(doubleValue: 176.5, forKey: "Height")
Repro.setDoubleUserProfile("Height", 176.5);
Repro.setDoubleUserProfile("Height", 176.5)
ReproCpp::setDoubleUserProfile("Height", 176.5);
Repro.SetDoubleUserProfile ("Height", 176.5);
Repro.setDoubleUserProfile("Height", 176.5);
Repro.setDoubleUserProfile("Height", 176.5);
repro.setDoubleUserProfile("Height", 176.5);
Repro.setDoubleUserProfile("Height", 176.5);
await Repro.setDoubleUserProfile("Height", 176.5);
日付¶
NSDate* now = [[NSDate alloc] init];
[Repro setDateUserProfile:now forKey:@"LastLogin"];
let now = Date()
Repro.setUserProfile(dateValue: now, forKey: "LastLogin")
Date now = new Date();
Repro.setDateUserProfile("LastLogin", now);
val now = Date()
Repro.setDateUserProfile("LastLogin", now)
std::time_t now = std::time(0);
ReproCpp::setDateUserProfile("LastLogin", now);
DateTime now = DateTime.Now;
Repro.SetDateUserProfile ("LastLogin", now);
let now = new Date();
Repro.setDateUserProfile("LastLogin", now);
let now = new Date();
Repro.setDateUserProfile("LastLogin", now.toISOString());
let now = new Date();
repro.setDateUserProfile("LastLogin", now.getTime());
let now = new Date();
Repro.setDateUserProfile("LastLogin", now.getTime());
final now = DateTime.now();
await Repro.setDateUserProfile("LastLogin", now);
条件付きセット操作¶
既にプロフィールが設定されている場合は更新せず、未設定の場合のみ値をセットします。
文字列(条件付き)¶
指定したキーにプロフィールが未設定の場合のみ、文字列をセットします。
[Repro onlySetIfAbsentStringUserProfile:@"Developer" forKey:@"Job"];
Repro.onlySetIfAbsentUserProfile(stringValue: "Developer", forKey: "Job")
Repro.onlySetIfAbsentStringUserProfile("Job", "Developer");
Repro.onlySetIfAbsentStringUserProfile("Job", "Developer")
ReproCpp::onlySetIfAbsentStringUserProfile("Job", "Developer");
Repro.OnlySetIfAbsentStringUserProfile ("Job", "Developer");
Repro.onlySetIfAbsentStringUserProfile("Job", "Developer");
Repro.onlySetIfAbsentStringUserProfile("Job", "Developer");
repro.onlySetIfAbsentStringUserProfile("Job", "Developer");
Repro.onlySetIfAbsentStringUserProfile("Job", "Developer");
await Repro.onlySetIfAbsentStringUserProfile("Job", "Developer");
整数(条件付き)¶
指定したキーにプロフィールが未設定の場合のみ、整数をセットします。
[Repro onlySetIfAbsentIntUserProfile:1 forKey: @"LoginCount"];
Repro.onlySetIfAbsentUserProfile(integerValue: 1, forKey: "LoginCount")
Repro.onlySetIfAbsentIntUserProfile("LoginCount", 1);
Repro.onlySetIfAbsentIntUserProfile("LoginCount", 1)
ReproCpp::onlySetIfAbsentIntUserProfile("LoginCount", 1);
Repro.OnlySetIfAbsentIntUserProfile("LoginCount", 1);
Repro.onlySetIfAbsentIntUserProfile("LoginCount", 1);
Repro.onlySetIfAbsentIntUserProfile("LoginCount", 1);
repro.onlySetIfAbsentIntUserProfile("LoginCount", 1);
Repro.onlySetIfAbsentIntUserProfile("LoginCount", 1);
await Repro.onlySetIfAbsentIntUserProfile("LoginCount", 1);
小数(条件付き)¶
指定したキーにプロフィールが未設定の場合のみ、小数をセットします。
[Repro onlySetIfAbsentDoubleUserProfile:85.5 forKey: @"Score"];
Repro.onlySetIfAbsentUserProfile(doubleValue: 85.5, forKey: "Score")
Repro.onlySetIfAbsentDoubleUserProfile("Score", 85.5);
Repro.onlySetIfAbsentDoubleUserProfile("Score", 85.5)
ReproCpp::onlySetIfAbsentDoubleUserProfile("Score", 85.5);
Repro.OnlySetIfAbsentDoubleUserProfile("Score", 85.5);
Repro.onlySetIfAbsentDoubleUserProfile("Score", 85.5);
Repro.onlySetIfAbsentDoubleUserProfile("Score", 85.5);
repro.onlySetIfAbsentDoubleUserProfile("Score", 85.5);
Repro.onlySetIfAbsentDoubleUserProfile("Score", 85.5);
await Repro.onlySetIfAbsentDoubleUserProfile("Score", 85.5);
日付(条件付き)¶
指定したキーにプロフィールが未設定の場合のみ、日付をセットします。
NSDate* now = [[NSDate alloc] init];
[Repro onlySetIfAbsentDateUserProfile:now forKey:@"FirstLogin"];
let now = Date()
Repro.onlySetIfAbsentUserProfile(dateValue: now, forKey: "FirstLogin")
Date now = new Date();
Repro.onlySetIfAbsentDateUserProfile("FirstLogin", now);
val now = Date()
Repro.onlySetIfAbsentDateUserProfile("FirstLogin", now)
std::time_t now = std::time(0);
ReproCpp::onlySetIfAbsentDateUserProfile("FirstLogin", now);
DateTime now = DateTime.Now;
Repro.OnlySetIfAbsentDateUserProfile("FirstLogin", now);
let now = new Date();
Repro.onlySetIfAbsentDateUserProfile("FirstLogin", now);
let now = new Date();
Repro.onlySetIfAbsentDateUserProfile("FirstLogin", now.toISOString());
let now = new Date();
repro.onlySetIfAbsentDateUserProfile("FirstLogin", now.getTime());
let now = new Date();
Repro.onlySetIfAbsentDateUserProfile("FirstLogin", now.getTime());
final now = DateTime.now();
await Repro.onlySetIfAbsentDateUserProfile("FirstLogin", now);
増減操作¶
既存の数値プロフィールに対して加算・減算を行います。プロフィールが未設定の場合は初期値を0として計算されます。
整数の増加¶
指定したキーの整数プロフィールに値を加算します。
[Repro incrementIntUserProfileBy:1 forKey: @"LoginCount"];
Repro.incrementIntegerUserProfile(by: 1, forKey: "LoginCount")
Repro.incrementIntUserProfileBy("LoginCount", 1);
Repro.incrementIntUserProfileBy("LoginCount", 1)
ReproCpp::incrementIntUserProfileBy("LoginCount", 1);
Repro.IncrementIntUserProfileBy("LoginCount", 1);
Repro.incrementIntUserProfileBy("LoginCount", 1);
Repro.incrementIntUserProfileBy("LoginCount", 1);
repro.incrementIntUserProfileBy("LoginCount", 1);
Repro.incrementIntUserProfileBy("LoginCount", 1);
await Repro.incrementIntUserProfileBy("LoginCount", 1);
整数の減少¶
指定したキーの整数プロフィールから値を減算します。
[Repro decrementIntUserProfileBy:10 forKey: @"Credits"];
Repro.decrementIntegerUserProfile(by: 10, forKey: "Credits")
Repro.decrementIntUserProfileBy("Credits", 10);
Repro.decrementIntUserProfileBy("Credits", 10)
ReproCpp::decrementIntUserProfileBy("Credits", 10);
Repro.DecrementIntUserProfileBy("Credits", 10);
Repro.decrementIntUserProfileBy("Credits", 10);
Repro.decrementIntUserProfileBy("Credits", 10);
repro.decrementIntUserProfileBy("Credits", 10);
Repro.decrementIntUserProfileBy("Credits", 10);
await Repro.decrementIntUserProfileBy("Credits", 10);
小数の増加¶
指定したキーの小数プロフィールに値を加算します。
[Repro incrementDoubleUserProfileBy:5.5 forKey: @"Score"];
Repro.incrementDoubleUserProfile(by: 5.5, forKey: "Score")
Repro.incrementDoubleUserProfileBy("Score", 5.5);
Repro.incrementDoubleUserProfileBy("Score", 5.5)
ReproCpp::incrementDoubleUserProfileBy("Score", 5.5);
Repro.IncrementDoubleUserProfileBy("Score", 5.5);
Repro.incrementDoubleUserProfileBy("Score", 5.5);
Repro.incrementDoubleUserProfileBy("Score", 5.5);
repro.incrementDoubleUserProfileBy("Score", 5.5);
Repro.incrementDoubleUserProfileBy("Score", 5.5);
await Repro.incrementDoubleUserProfileBy("Score", 5.5);
小数の減少¶
指定したキーの小数プロフィールから値を減算します。
[Repro decrementDoubleUserProfileBy:25.0 forKey: @"Balance"];
Repro.decrementDoubleUserProfile(by: 25.0, forKey: "Balance")
Repro.decrementDoubleUserProfileBy("Balance", 25.0);
Repro.decrementDoubleUserProfileBy("Balance", 25.0)
ReproCpp::decrementDoubleUserProfileBy("Balance", 25.0);
Repro.DecrementDoubleUserProfileBy("Balance", 25.0);
Repro.decrementDoubleUserProfileBy("Balance", 25.0);
Repro.decrementDoubleUserProfileBy("Balance", 25.0);
repro.decrementDoubleUserProfileBy("Balance", 25.0);
Repro.decrementDoubleUserProfileBy("Balance", 25.0);
await Repro.decrementDoubleUserProfileBy("Balance", 25.0);
標準ユーザープロフィールの条件付きセット・増減操作¶
標準ユーザープロフィールに対しても条件付きセットや増減操作が利用できます。
年齢(条件付き)¶
年齢が未設定の場合のみ値をセットします。
[Repro onlySetIfAbsentUserAge:25];
Repro.onlySetIfAbsentUserProfile(age: 25)
Repro.onlySetIfAbsentUserAge(25);
Repro.onlySetIfAbsentUserAge(25)
ReproCpp::onlySetIfAbsentUserAge(25);
Repro.OnlySetIfAbsentUserAge(25);
Repro.onlySetIfAbsentUserAge(25);
Repro.onlySetIfAbsentUserAge(25);
repro.onlySetIfAbsentUserAge(25);
Repro.onlySetIfAbsentUserAge(25);
await Repro.onlySetIfAbsentUserAge(25);
性別(条件付き)¶
性別が未設定の場合のみ値をセットします。
[Repro onlySetIfAbsentUserGender:RPRUserProfileGenderMale];
Repro.onlySetIfAbsentUserProfile(gender: .male)
Repro.onlySetIfAbsentUserGender(UserProfileGender.MALE);
Repro.onlySetIfAbsentUserGender(UserProfileGender.MALE)
ReproCpp::onlySetIfAbsentUserGender(ReproCpp::UserProfileGenderMale);
Repro.OnlySetIfAbsentUserGender(UserProfileGender.Male);
Repro.onlySetIfAbsentUserGender(Repro.UserProfileGender.Male);
Repro.onlySetIfAbsentUserGender(Repro.GENDER_MALE);
repro.onlySetIfAbsentUserGender(repro.userProfileGender.Male);
Repro.onlySetIfAbsentUserGender(Repro.UserProfileGender.Male);
await Repro.onlySetIfAbsentUserGender(UserGender.male);
Eメールアドレス(条件付き)¶
Eメールアドレスが未設定の場合のみ値をセットします。
[Repro onlySetIfAbsentUserEmailAddress:@"user@example.com"];
Repro.onlySetIfAbsentUserProfile(emailAddress: "user@example.com")
Repro.onlySetIfAbsentUserEmailAddress("user@example.com");
Repro.onlySetIfAbsentUserEmailAddress("user@example.com")
ReproCpp::onlySetIfAbsentUserEmailAddress("user@example.com");
Repro.OnlySetIfAbsentUserEmailAddress("user@example.com");
Repro.onlySetIfAbsentUserEmailAddress("user@example.com");
Repro.onlySetIfAbsentUserEmailAddress("user@example.com");
repro.onlySetIfAbsentUserEmailAddress("user@example.com");
Repro.onlySetIfAbsentUserEmailAddress("user@example.com");
await Repro.onlySetIfAbsentUserEmailAddress("user@example.com");
居住都道府県(条件付き)¶
居住都道府県が未設定の場合のみ値をセットします。
// set the prefecture as "Tokyo"
[Repro onlySetIfAbsentUserResidencePrefecture:RPRUserProfilePrefectureTokyo];
// set the prefecture as "Tokyo"
Repro.onlySetIfAbsentUserProfile(residencePrefecture: .tokyo)
// set the prefecture as "Tokyo"
Repro.onlySetIfAbsentUserResidencePrefecture(UserProfilePrefecture.TOKYO);
// set the prefecture as "Tokyo"
Repro.onlySetIfAbsentUserResidencePrefecture(UserProfilePrefecture.TOKYO)
// set the prefecture as "Tokyo"
ReproCpp::onlySetIfAbsentUserResidencePrefecture(ReproCpp::UserProfilePrefectureTokyo);
// set the prefecture as "Tokyo"
Repro.OnlySetIfAbsentUserResidencePrefecture(UserProfilePrefecture.Tokyo);
// set the prefecture as "Tokyo"
Repro.onlySetIfAbsentUserResidencePrefecture(Repro.UserProfilePrefecture.Tokyo);
// set the prefecture as "Tokyo"
Repro.onlySetIfAbsentUserResidencePrefecture(Repro.PREFECTURE_TOKYO);
// set the prefecture as "Tokyo"
repro.onlySetIfAbsentUserResidencePrefecture(repro.userProfilePrefecture.TOKYO);
// set the prefecture as "Tokyo"
Repro.onlySetIfAbsentUserResidencePrefecture(Repro.UserProfilePrefecture.TOKYO);
// set the prefecture as "Tokyo"
await Repro.onlySetIfAbsentUserResidencePrefecture(UserProfilePrefecture.tokyo);
生年月日(条件付き)¶
生年月日が未設定の場合のみ値をセットします。
NSDate *date = ... // Create an NSDate object for the user's birthday date
[Repro onlySetIfAbsentUserDateOfBirth:date];
let date = ... // Create an NSDate object for the user's birthday date
Repro.onlySetIfAbsentUserProfile(dateOfBirth: date)
Date date = ... // Create a Date object for the user's birthday date
Repro.onlySetIfAbsentUserDateOfBirth(date);
val date = ... // Create a Date object for the user's birthday date
Repro.onlySetIfAbsentUserDateOfBirth(date)
ReproCpp::onlySetIfAbsentUserDateOfBirth(2000, 12, 31);
DateTime date = ... // Create a DateTime object for the user's birthday date
Repro.OnlySetIfAbsentUserDateOfBirth(date);
let date = ... // Create a Date object for the user's birthday date
Repro.onlySetIfAbsentUserDateOfBirth(date);
let date = ... // Create a Date object for the user's birthday date
Repro.onlySetIfAbsentUserDateOfBirth(date);
let date = ... // Create a Date object for the user's birthday date
repro.onlySetIfAbsentUserDateOfBirth(date.getTime());
let date = ... // Create a Date object for the user's birthday date
Repro.onlySetIfAbsentUserDateOfBirth(date.getTime());
DateTime date = ... // Create a DateTime object for the user's birthday date
await Repro.onlySetIfAbsentUserDateOfBirth(date);
年齢の増加¶
現在の年齢に指定した値を加算します。
[Repro incrementUserAgeBy:1];
Repro.incrementUserProfileAge(by: 1)
Repro.incrementUserAgeBy(1);
Repro.incrementUserAgeBy(1)
ReproCpp::incrementUserAgeBy(1);
Repro.IncrementUserAgeBy(1);
Repro.incrementUserAgeBy(1);
Repro.incrementUserAgeBy(1);
repro.incrementUserAgeBy(1);
Repro.incrementUserAgeBy(1);
await Repro.incrementUserAgeBy(1);
年齢の減少¶
現在の年齢から指定した値を減算します。
[Repro decrementUserAgeBy:1];
Repro.decrementUserProfileAge(by: 1)
Repro.decrementUserAgeBy(1);
Repro.decrementUserAgeBy(1)
ReproCpp::decrementUserAgeBy(1);
Repro.DecrementUserAgeBy(1);
Repro.decrementUserAgeBy(1);
Repro.decrementUserAgeBy(1);
repro.decrementUserAgeBy(1);
Repro.decrementUserAgeBy(1);
await Repro.decrementUserAgeBy(1);
ユーザープロフィールの削除¶
設定済みのユーザープロフィールを削除します。
カスタムプロフィールの削除¶
指定したキーのカスタムユーザープロフィールを削除します。
[Repro deleteUserProfile:@"Job"];
Repro.deleteUserProfile(forKey: "Job")
Repro.deleteUserProfile("Job");
Repro.deleteUserProfile("Job")
ReproCpp::deleteUserProfile("Job");
Repro.DeleteUserProfile("Job");
Repro.deleteUserProfile("Job");
Repro.deleteUserProfile("Job");
repro.deleteUserProfile("Job");
Repro.deleteUserProfile("Job");
await Repro.deleteUserProfile("Job");
標準プロフィールの削除¶
標準ユーザープロフィールを削除します。
性別の削除:
[Repro deleteUserGender];
Repro.deleteUserProfileGender()
Repro.deleteUserGender();
Repro.deleteUserGender()
ReproCpp::deleteUserGender();
Repro.DeleteUserGender();
Repro.deleteUserGender();
Repro.deleteUserGender();
repro.deleteUserGender();
Repro.deleteUserGender();
await Repro.deleteUserGender();
年齢の削除:
[Repro deleteUserAge];
Repro.deleteUserProfileAge()
Repro.deleteUserAge();
Repro.deleteUserAge()
ReproCpp::deleteUserAge();
Repro.DeleteUserAge();
Repro.deleteUserAge();
Repro.deleteUserAge();
repro.deleteUserAge();
Repro.deleteUserAge();
await Repro.deleteUserAge();
Eメールアドレスの削除:
[Repro deleteUserEmailAddress];
Repro.deleteUserProfileEmailAddress()
Repro.deleteUserEmailAddress();
Repro.deleteUserEmailAddress()
ReproCpp::deleteUserEmailAddress();
Repro.DeleteUserEmailAddress();
Repro.deleteUserEmailAddress();
Repro.deleteUserEmailAddress();
repro.deleteUserEmailAddress();
Repro.deleteUserEmailAddress();
await Repro.deleteUserEmailAddress();
居住都道府県の削除:
[Repro deleteUserResidencePrefecture];
Repro.deleteUserProfileResidencePrefecture()
Repro.deleteUserResidencePrefecture();
Repro.deleteUserResidencePrefecture()
ReproCpp::deleteUserResidencePrefecture();
Repro.DeleteUserResidencePrefecture();
Repro.deleteUserResidencePrefecture();
Repro.deleteUserResidencePrefecture();
repro.deleteUserResidencePrefecture();
Repro.deleteUserResidencePrefecture();
await Repro.deleteUserResidencePrefecture();
生年月日の削除:
[Repro deleteUserDateOfBirth];
Repro.deleteUserProfileDateOfBirth()
Repro.deleteUserDateOfBirth();
Repro.deleteUserDateOfBirth()
ReproCpp::deleteUserDateOfBirth();
Repro.DeleteUserDateOfBirth();
Repro.deleteUserDateOfBirth();
Repro.deleteUserDateOfBirth();
repro.deleteUserDateOfBirth();
Repro.deleteUserDateOfBirth();
await Repro.deleteUserDateOfBirth();