1 /* 2 * Copyright 2020 Google LLC 3 * 4 * Licensed under the Apache License, Version 2.0 (the "License"); 5 * you may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at 7 * 8 * https://www.apache.org/licenses/LICENSE-2.0 9 * 10 * Unless required by applicable law or agreed to in writing, software 11 * distributed under the License is distributed on an "AS IS" BASIS, 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 * See the License for the specific language governing permissions and 14 * limitations under the License. 15 */ 16 // Generated by the protocol buffer compiler. DO NOT EDIT! 17 // source: google/cloud/discoveryengine/v1beta/user_event.proto 18 19 package com.google.cloud.discoveryengine.v1beta; 20 21 public interface TransactionInfoOrBuilder 22 extends 23 // @@protoc_insertion_point(interface_extends:google.cloud.discoveryengine.v1beta.TransactionInfo) 24 com.google.protobuf.MessageOrBuilder { 25 26 /** 27 * 28 * 29 * <pre> 30 * Required. Total non-zero value associated with the transaction. This value 31 * may include shipping, tax, or other adjustments to the total value that you 32 * want to include. 33 * </pre> 34 * 35 * <code>optional float value = 1 [(.google.api.field_behavior) = REQUIRED];</code> 36 * 37 * @return Whether the value field is set. 38 */ hasValue()39 boolean hasValue(); 40 /** 41 * 42 * 43 * <pre> 44 * Required. Total non-zero value associated with the transaction. This value 45 * may include shipping, tax, or other adjustments to the total value that you 46 * want to include. 47 * </pre> 48 * 49 * <code>optional float value = 1 [(.google.api.field_behavior) = REQUIRED];</code> 50 * 51 * @return The value. 52 */ getValue()53 float getValue(); 54 55 /** 56 * 57 * 58 * <pre> 59 * Required. Currency code. Use three-character ISO-4217 code. 60 * </pre> 61 * 62 * <code>string currency = 2 [(.google.api.field_behavior) = REQUIRED];</code> 63 * 64 * @return The currency. 65 */ getCurrency()66 java.lang.String getCurrency(); 67 /** 68 * 69 * 70 * <pre> 71 * Required. Currency code. Use three-character ISO-4217 code. 72 * </pre> 73 * 74 * <code>string currency = 2 [(.google.api.field_behavior) = REQUIRED];</code> 75 * 76 * @return The bytes for currency. 77 */ getCurrencyBytes()78 com.google.protobuf.ByteString getCurrencyBytes(); 79 80 /** 81 * 82 * 83 * <pre> 84 * The transaction ID with a length limit of 128 characters. 85 * </pre> 86 * 87 * <code>string transaction_id = 3;</code> 88 * 89 * @return The transactionId. 90 */ getTransactionId()91 java.lang.String getTransactionId(); 92 /** 93 * 94 * 95 * <pre> 96 * The transaction ID with a length limit of 128 characters. 97 * </pre> 98 * 99 * <code>string transaction_id = 3;</code> 100 * 101 * @return The bytes for transactionId. 102 */ getTransactionIdBytes()103 com.google.protobuf.ByteString getTransactionIdBytes(); 104 105 /** 106 * 107 * 108 * <pre> 109 * All the taxes associated with the transaction. 110 * </pre> 111 * 112 * <code>optional float tax = 4;</code> 113 * 114 * @return Whether the tax field is set. 115 */ hasTax()116 boolean hasTax(); 117 /** 118 * 119 * 120 * <pre> 121 * All the taxes associated with the transaction. 122 * </pre> 123 * 124 * <code>optional float tax = 4;</code> 125 * 126 * @return The tax. 127 */ getTax()128 float getTax(); 129 130 /** 131 * 132 * 133 * <pre> 134 * All the costs associated with the products. These can be manufacturing 135 * costs, shipping expenses not borne by the end user, or any other costs, 136 * such that: 137 * * Profit = 138 * [value][google.cloud.discoveryengine.v1beta.TransactionInfo.value] - 139 * [tax][google.cloud.discoveryengine.v1beta.TransactionInfo.tax] - 140 * [cost][google.cloud.discoveryengine.v1beta.TransactionInfo.cost] 141 * </pre> 142 * 143 * <code>optional float cost = 5;</code> 144 * 145 * @return Whether the cost field is set. 146 */ hasCost()147 boolean hasCost(); 148 /** 149 * 150 * 151 * <pre> 152 * All the costs associated with the products. These can be manufacturing 153 * costs, shipping expenses not borne by the end user, or any other costs, 154 * such that: 155 * * Profit = 156 * [value][google.cloud.discoveryengine.v1beta.TransactionInfo.value] - 157 * [tax][google.cloud.discoveryengine.v1beta.TransactionInfo.tax] - 158 * [cost][google.cloud.discoveryengine.v1beta.TransactionInfo.cost] 159 * </pre> 160 * 161 * <code>optional float cost = 5;</code> 162 * 163 * @return The cost. 164 */ getCost()165 float getCost(); 166 167 /** 168 * 169 * 170 * <pre> 171 * The total discount(s) value applied to this transaction. 172 * This figure should be excluded from 173 * [TransactionInfo.value][google.cloud.discoveryengine.v1beta.TransactionInfo.value] 174 * For example, if a user paid 175 * [TransactionInfo.value][google.cloud.discoveryengine.v1beta.TransactionInfo.value] 176 * amount, then nominal (pre-discount) value of the transaction is the sum of 177 * [TransactionInfo.value][google.cloud.discoveryengine.v1beta.TransactionInfo.value] 178 * and 179 * [TransactionInfo.discount_value][google.cloud.discoveryengine.v1beta.TransactionInfo.discount_value] 180 * This means that profit is calculated the same way, regardless of the 181 * discount value, and that 182 * [TransactionInfo.discount_value][google.cloud.discoveryengine.v1beta.TransactionInfo.discount_value] 183 * can be larger than 184 * [TransactionInfo.value][google.cloud.discoveryengine.v1beta.TransactionInfo.value]: 185 * * Profit = 186 * [value][google.cloud.discoveryengine.v1beta.TransactionInfo.value] - 187 * [tax][google.cloud.discoveryengine.v1beta.TransactionInfo.tax] - 188 * [cost][google.cloud.discoveryengine.v1beta.TransactionInfo.cost] 189 * </pre> 190 * 191 * <code>optional float discount_value = 6;</code> 192 * 193 * @return Whether the discountValue field is set. 194 */ hasDiscountValue()195 boolean hasDiscountValue(); 196 /** 197 * 198 * 199 * <pre> 200 * The total discount(s) value applied to this transaction. 201 * This figure should be excluded from 202 * [TransactionInfo.value][google.cloud.discoveryengine.v1beta.TransactionInfo.value] 203 * For example, if a user paid 204 * [TransactionInfo.value][google.cloud.discoveryengine.v1beta.TransactionInfo.value] 205 * amount, then nominal (pre-discount) value of the transaction is the sum of 206 * [TransactionInfo.value][google.cloud.discoveryengine.v1beta.TransactionInfo.value] 207 * and 208 * [TransactionInfo.discount_value][google.cloud.discoveryengine.v1beta.TransactionInfo.discount_value] 209 * This means that profit is calculated the same way, regardless of the 210 * discount value, and that 211 * [TransactionInfo.discount_value][google.cloud.discoveryengine.v1beta.TransactionInfo.discount_value] 212 * can be larger than 213 * [TransactionInfo.value][google.cloud.discoveryengine.v1beta.TransactionInfo.value]: 214 * * Profit = 215 * [value][google.cloud.discoveryengine.v1beta.TransactionInfo.value] - 216 * [tax][google.cloud.discoveryengine.v1beta.TransactionInfo.tax] - 217 * [cost][google.cloud.discoveryengine.v1beta.TransactionInfo.cost] 218 * </pre> 219 * 220 * <code>optional float discount_value = 6;</code> 221 * 222 * @return The discountValue. 223 */ getDiscountValue()224 float getDiscountValue(); 225 } 226