Here are the examples of the csharp api object.Equals(object) taken from open source projects. By voting up you can indicate which examples are most useful and appropriate.
4417 Examples
19
Source : Sequence.cs
with GNU Affero General Public License v3.0
from ACEmulator
with GNU Affero General Public License v3.0
from ACEmulator
public void remove_cyclic_anims()
{
var node = FirstCyclic;
while (node != null)
{
if (CurrAnim.Equals(node))
{
CurrAnim = node.Previous;
if (CurrAnim != null)
FrameNumber = CurrAnim.Value.get_ending_frame();
else
FrameNumber = 0.0f;
}
var next = node.Next; // handle linked list properly
AnimList.Remove(node.Value);
node = next;
}
FirstCyclic = AnimList.Last;
}
19
Source : Sequence.cs
with GNU Affero General Public License v3.0
from ACEmulator
with GNU Affero General Public License v3.0
from ACEmulator
public void remove_link_animations(uint amount)
{
for (var i = 0; i < amount; i++)
{
if (FirstCyclic.Previous == null)
return;
if (CurrAnim.Equals(FirstCyclic.Previous))
{
CurrAnim = FirstCyclic;
if (CurrAnim != null)
FrameNumber = CurrAnim.Value.get_starting_frame();
}
AnimList.Remove(FirstCyclic.Previous);
}
}
19
Source : Sequence.cs
with GNU Affero General Public License v3.0
from ACEmulator
with GNU Affero General Public License v3.0
from ACEmulator
public void update_internal(float timeElapsed, ref LinkedListNode<AnimSequenceNode> animNode, ref float frameNum, ref AFrame frame)
{
var currAnim = animNode.Value;
var framerate = currAnim.Framerate;
var frametime = framerate * timeElapsed;
var lastFrame = (int)Math.Floor(frameNum);
frameNum += frametime;
var frameTimeElapsed = 0.0f;
var animDone = false;
if (frametime > 0.0f)
{
if (currAnim.get_high_frame() < Math.Floor(frameNum))
{
var frameOffset = frameNum - currAnim.get_high_frame() - 1.0f;
if (frameOffset < 0.0f)
frameOffset = 0.0f;
if (Math.Abs(framerate) > PhysicsGlobals.EPSILON)
frameTimeElapsed = frameOffset / framerate;
frameNum = currAnim.get_high_frame();
animDone = true;
}
while (Math.Floor(frameNum) > lastFrame)
{
if (frame != null)
{
if (currAnim.Anim.PosFrames != null)
frame = AFrame.Combine(frame, currAnim.get_pos_frame(lastFrame));
if (Math.Abs(framerate) > PhysicsGlobals.EPSILON)
apply_physics(frame, 1.0f / framerate, timeElapsed);
}
execute_hooks(currAnim.get_part_frame(lastFrame), AnimationHookDir.Forward);
lastFrame++;
}
}
else if (frametime < 0.0f)
{
if (currAnim.get_low_frame() > Math.Floor(frameNum))
{
var frameOffset = frameNum - currAnim.get_low_frame();
if (frameOffset > 0.0f)
frameOffset = 0.0f;
if (Math.Abs(framerate) > PhysicsGlobals.EPSILON)
frameTimeElapsed = frameOffset / framerate;
frameNum = currAnim.get_low_frame();
animDone = true;
}
while (Math.Floor(frameNum) < lastFrame)
{
if (frame != null)
{
if (currAnim.Anim.PosFrames != null)
frame.Subtract(currAnim.get_pos_frame(lastFrame));
if (Math.Abs(framerate) > PhysicsGlobals.EPSILON)
apply_physics(frame, 1.0f / framerate, timeElapsed);
}
execute_hooks(currAnim.get_part_frame(lastFrame), AnimationHookDir.Backward);
lastFrame--;
}
}
else
{
if (frame != null && Math.Abs(timeElapsed) > PhysicsGlobals.EPSILON)
apply_physics(frame, timeElapsed, timeElapsed);
}
if (!animDone)
return;
if (HookObj != null)
{
var node = AnimList.First;
if (!node.Equals(FirstCyclic))
HookObj.add_anim_hook(AnimationHook.AnimDoneHook);
}
advance_to_next_animation(timeElapsed, ref animNode, ref frameNum, ref frame);
timeElapsed = frameTimeElapsed;
// loop to next anim
update_internal(timeElapsed, ref animNode, ref frameNum, ref frame);
}
19
Source : Sequence.cs
with GNU Affero General Public License v3.0
from ACEmulator
with GNU Affero General Public License v3.0
from ACEmulator
public bool is_first_cyclic()
{
return CurrAnim == null || CurrAnim.Equals(FirstCyclic);
}
19
Source : SortableBindingList.cs
with Microsoft Public License
from achimismaili
with Microsoft Public License
from achimismaili
protected override int FindCore(PropertyDescriptor property, object key)
{
int count = this.Count;
for (int i = 0; i < count; ++i)
{
T element = this[i];
if (property.GetValue(element).Equals(key))
{
return i;
}
}
return -1;
}
19
Source : Game.cs
with Microsoft Public License
from achimismaili
with Microsoft Public License
from achimismaili
public override bool Equals(object obj)
{
var game = obj as Game;
return game != null && base.Equals(game);
}
19
Source : ArgUtil.cs
with MIT License
from actions
with MIT License
from actions
public static void Equal<T>(T expected, T actual, string name)
{
if (object.ReferenceEquals(expected, actual))
{
return;
}
if (object.ReferenceEquals(expected, null) ||
!expected.Equals(actual))
{
throw new ArgumentOutOfRangeException(
paramName: name,
actualValue: actual,
message: $"{name} does not equal expected value. Expected '{expected}'. Actual '{actual}'.");
}
}
19
Source : PropertiesCollection.cs
with MIT License
from actions
with MIT License
from actions
public override Boolean Equals(Object otherObj)
{
if (Object.ReferenceEquals(this, otherObj))
{
return true;
}
PropertiesCollection otherCollection = otherObj as PropertiesCollection;
if (otherCollection == null || Count != otherCollection.Count)
{
return false;
}
else
{
Object obj;
foreach (var key in Keys)
{
if (!otherCollection.TryGetValue(key, out obj) || !obj.Equals(this[key]))
{
return false;
}
}
return true;
}
}
19
Source : RichTextBoxExtended.cs
with MIT License
from Actipro
with MIT License
from Actipro
private bool? CoerceBooleanValue(object value, object trueValue) {
if (value == null)
return null;
else if (value.Equals(trueValue))
return true;
else if (value == DependencyProperty.UnsetValue)
return null;
else
return false;
}
19
Source : ResetCriterion.cs
with GNU Affero General Public License v3.0
from active-logic
with GNU Affero General Public License v3.0
from active-logic
public ResetCriterion Check(object arg, ReCon stack){
bool equals = (arg==null) ? (hold == null)
: arg.Equals(hold);
if(!equals){
context = stack.Enter(forward: true);
hold = arg;
}
return this;
}
19
Source : DacPropertyAttributesAnalyzer.cs
with GNU General Public License v3.0
from Acumatica
with GNU General Public License v3.0
from Acumatica
private static void CheckAttributeAndPropertyTypesForCompatibility(DacPropertyInfo property, AttributeInfo fieldAttribute, ITypeSymbol fieldType,
PXContext pxContext, SymbolreplacedysisContext symbolContext)
{
if (fieldType == null) //PXDBFieldAttribute case
{
ReportIncompatibleTypesDiagnostics(property, fieldAttribute, symbolContext, pxContext, registerCodeFix: false);
return;
}
ITypeSymbol typeToCompare;
if (property.PropertyType.IsValueType)
{
typeToCompare = property.PropertyType.IsNullable(pxContext)
? property.PropertyType.GetUnderlyingTypeFromNullable(pxContext)
: property.PropertyType;
}
else
{
typeToCompare = property.PropertyType;
}
if (!fieldType.Equals(typeToCompare))
{
ReportIncompatibleTypesDiagnostics(property, fieldAttribute, symbolContext, pxContext, registerCodeFix: true);
}
}
19
Source : OverridableItemsCollection.cs
with GNU General Public License v3.0
from Acumatica
with GNU General Public License v3.0
from Acumatica
internal virtual void Add<TWriteableInfo>(TWriteableInfo info)
where TWriteableInfo : TInfo, IWriteableBaseItem<TInfo>
{
if (info?.Name == null)
{
throw new ArgumentNullException($"{nameof(info)}.{nameof(info.Name)}");
}
if (TryGetValue(info.Name, out TInfo existingValue))
{
if (!existingValue.Equals(info))
{
info.Base = existingValue;
base[info.Name] = info;
}
}
else
{
Add(info.Name, info);
}
}
19
Source : PXActionOnNonPrimaryViewAnalyzer.cs
with GNU General Public License v3.0
from Acumatica
with GNU General Public License v3.0
from Acumatica
private static bool CheckActionIsDeclaredForPrimaryDAC(INamedTypeSymbol action, ITypeSymbol primaryDAC)
{
var actionTypeArgs = action.TypeArguments;
if (actionTypeArgs.Length == 0) //Cannot infer action's DAC
return true;
ITypeSymbol pxActionDacType = actionTypeArgs[0];
return pxActionDacType.Equals(primaryDAC);
}
19
Source : PXGraphDeclarationTypeParameterAnalyzer.cs
with GNU General Public License v3.0
from Acumatica
with GNU General Public License v3.0
from Acumatica
private void replacedyzeGraphDeclarationTypeParameter(SyntaxNodereplacedysisContext context, PXContext pxContext)
{
context.CancellationToken.ThrowIfCancellationRequested();
if (!(context.Node is ClreplacedDeclarationSyntax clreplacedDeclaration))
{
return;
}
var typeSymbol = context.SemanticModel.GetDeclaredSymbol(clreplacedDeclaration);
if (typeSymbol == null || !typeSymbol.IsPXGraph(pxContext))
{
return;
}
if (clreplacedDeclaration.BaseList == null)
{
return;
}
var graphArgumentNode = GetBaseGraphTypeNode(context, pxContext, clreplacedDeclaration.BaseList.Types);
if (graphArgumentNode == null)
{
return;
}
// Get last identifier to handle cases like SO.SOSetupMaint
var graphArgumentIdentifier = graphArgumentNode
.DescendantNodesAndSelf()
.OfType<IdentifierNameSyntax>()
.Last();
var graphTypeArgument = context.SemanticModel.GetTypeInfo(graphArgumentIdentifier).Type;
if (typeSymbol.Equals(graphTypeArgument) || graphTypeArgument?.Kind == SymbolKind.TypeParameter)
{
return;
}
context.ReportDiagnosticWithSuppressionCheck(
Diagnostic.Create(Descriptors.PX1093_GraphDeclarationViolation, graphArgumentIdentifier.GetLocation()),
pxContext.CodereplacedysisSettings);
}
19
Source : PairOfViewsWithSpecialNamesGraphRule.cs
with GNU General Public License v3.0
from Acumatica
with GNU General Public License v3.0
from Acumatica
private static ITypeSymbol ChooseDacCandidate(ITypeSymbol firstDacCandidate, ITypeSymbol secondDacCandidate)
{
if (firstDacCandidate == null && secondDacCandidate == null)
return null;
else if (firstDacCandidate != null && secondDacCandidate != null)
{
return firstDacCandidate.Equals(secondDacCandidate)
? firstDacCandidate
: null;
}
else
{
return firstDacCandidate ?? secondDacCandidate;
}
}
19
Source : AttributeInformation.cs
with GNU General Public License v3.0
from Acumatica
with GNU General Public License v3.0
from Acumatica
public IEnumerable<ITypeSymbol> GetAreplacedaticaAttributesFullList(ITypeSymbol attributeType, bool includeBaseTypes = false)
{
if (attributeType == null || attributeType.Equals(_eventSubscriberAttribute))
return Enumerable.Empty<ITypeSymbol>();
var baseAreplacedaticaAttributeTypes = attributeType.GetBaseTypesAndThis().ToList();
if (!baseAreplacedaticaAttributeTypes.Contains(_eventSubscriberAttribute))
return Enumerable.Empty<ITypeSymbol>();
HashSet<ITypeSymbol> results;
if (includeBaseTypes)
{
results = baseAreplacedaticaAttributeTypes.TakeWhile(a => !a.Equals(_eventSubscriberAttribute))
.ToHashSet();
}
else
{
results = new HashSet<ITypeSymbol>() { attributeType };
}
bool isAggregateAttribute = baseAreplacedaticaAttributeTypes.Contains(_aggregateAttribute) ||
baseAreplacedaticaAttributeTypes.Contains(_dynamicAggregateAttribute);
if (isAggregateAttribute)
{
var allAreplacedaticaAttributes = attributeType.GetAllAttributesDefinedOnThisAndBaseTypes()
.Where(attribute => attribute.InheritsFrom(_eventSubscriberAttribute));
foreach (var attribute in allAreplacedaticaAttributes)
{
CollectAggregatedAttribute(attribute, DefaultRecursionDepth);
}
}
return results;
void CollectAggregatedAttribute(ITypeSymbol aggregatedAttribute, int depth)
{
results.Add(aggregatedAttribute);
if (depth < 0)
return;
if (includeBaseTypes)
{
aggregatedAttribute.GetBaseTypes()
.TakeWhile(baseType => !baseType.Equals(_eventSubscriberAttribute))
.ForEach(baseType => results.Add(baseType));
}
if (IsAggregatorAttribute(aggregatedAttribute))
{
var allAreplacedaticaAttributes = aggregatedAttribute.GetAllAttributesDefinedOnThisAndBaseTypes()
.Where(attribute => attribute.InheritsFrom(_eventSubscriberAttribute));
foreach (var attribute in allAreplacedaticaAttributes)
{
CollectAggregatedAttribute(attribute, depth - 1);
}
}
}
}
19
Source : ITypeSymbolExtensions.cs
with GNU General Public License v3.0
from Acumatica
with GNU General Public License v3.0
from Acumatica
public static bool InheritsFromOrEquals(this ITypeSymbol type, ITypeSymbol baseType, bool includeInterfaces)
{
type.ThrowOnNull(nameof(type));
baseType.ThrowOnNull(nameof(baseType));
var typeList = type.GetBaseTypesAndThis();
if (includeInterfaces)
{
typeList = typeList.ConcatStructList(type.AllInterfaces);
}
return typeList.Any(t => t.Equals(baseType));
}
19
Source : ITypeSymbolExtensions.cs
with GNU General Public License v3.0
from Acumatica
with GNU General Public License v3.0
from Acumatica
public static bool InheritsFrom(this ITypeSymbol type, ITypeSymbol baseType, bool includeInterfaces = false)
{
type.ThrowOnNull(nameof(type));
baseType.ThrowOnNull(nameof(baseType));
IEnumerable<ITypeSymbol> baseTypes = type.GetBaseTypes();
if (includeInterfaces)
{
baseTypes = baseTypes.ConcatStructList(type.AllInterfaces);
}
return baseTypes.Any(t => t.Equals(baseType));
}
19
Source : ITypeSymbolExtensions.cs
with GNU General Public License v3.0
from Acumatica
with GNU General Public License v3.0
from Acumatica
public static int? GetInheritanceDepth(this ITypeSymbol type, ITypeSymbol baseType)
{
type.ThrowOnNull(nameof(type));
baseType.ThrowOnNull(nameof(type));
ITypeSymbol current = type;
int depth = 0;
while (current != null && !current.Equals(baseType))
{
current = current.BaseType;
depth++;
}
return current != null ? depth : (int?)null;
}
19
Source : ParameterUsagesRewriter.cs
with GNU General Public License v3.0
from Acumatica
with GNU General Public License v3.0
from Acumatica
public override SyntaxNode VisitIdentifierName(IdentifierNameSyntax node)
{
var symbolInfo = _semanticModel.GetSymbolInfo(node);
if (symbolInfo.Symbol != null && symbolInfo.Symbol.Equals(_parameter))
{
var replacement = _replaceWith;
if (node.HasLeadingTrivia)
replacement = replacement.WithLeadingTrivia(node.GetLeadingTrivia());
if (node.HasTrailingTrivia)
replacement = replacement.WithTrailingTrivia(node.GetTrailingTrivia());
return replacement;
}
return base.VisitIdentifierName(node);
}
19
Source : Observable.cs
with MIT License
from Adam4lexander
with MIT License
from Adam4lexander
public bool Equals(Observable<T> other) {
if (other == null) {
return false;
}
return other.value.Equals(value);
}
19
Source : Observable.cs
with MIT License
from Adam4lexander
with MIT License
from Adam4lexander
public override bool Equals(object other) {
return other != null
&& other is Observable<T>
&& ((Observable<T>)other).value.Equals(value);
}
19
Source : ObservableList.cs
with MIT License
from Adam4lexander
with MIT License
from Adam4lexander
bool IsEqual(T v1, T v2) {
if (v1 is UnityEngine.Object || v2 is UnityEngine.Object) {
return ReferenceEquals(v1, v2);
}
return (v1 == null && v2 == null) || v1 != null && v1.Equals(v2);
}
19
Source : GrammarSymbol.cs
with MIT License
from adamant
with MIT License
from adamant
public override bool Equals(object? obj)
{
if (obj is null) return false;
if (ReferenceEquals(this, obj)) return true;
return obj is GrammarSymbol other && Equals(other);
}
19
Source : GrammarType.cs
with MIT License
from adamant
with MIT License
from adamant
public override bool Equals(object? obj)
{
if (obj is null) return false;
if (ReferenceEquals(this, obj)) return true;
return obj is GrammarType other && Equals(other);
}
19
Source : FixedList.cs
with MIT License
from adamant
with MIT License
from adamant
public override bool Equals(object? obj)
{
return Equals(obj as FixedList<T>);
}
19
Source : FixedSet.cs
with MIT License
from adamant
with MIT License
from adamant
public override bool Equals(object? obj)
{
return Equals(obj as FixedSet<T>);
}
19
Source : NamespaceName.cs
with MIT License
from adamant
with MIT License
from adamant
public override bool Equals(object? other)
{
if (other is null) return false;
if (ReferenceEquals(this, other)) return true;
return other is NamespaceName name && Equals(name);
}
19
Source : TypeName.cs
with MIT License
from adamant
with MIT License
from adamant
public override bool Equals(object? other)
{
if (other is null) return false;
if (ReferenceEquals(this, other)) return true;
return other is TypeName otherTypeName && Equals(otherTypeName);
}
19
Source : Reference.cs
with MIT License
from adamant
with MIT License
from adamant
public override bool Equals(object? obj)
{
if (obj is null) return false;
if (ReferenceEquals(this, obj)) return true;
if (obj.GetType() != GetType()) return false;
return Equals((Reference)obj);
}
19
Source : Symbol.cs
with MIT License
from adamant
with MIT License
from adamant
public sealed override bool Equals(object? obj)
{
if (obj is null) return false;
if (ReferenceEquals(this, obj)) return true;
return obj.GetType() == GetType() && Equals((Symbol)obj);
}
19
Source : DataType.cs
with MIT License
from adamant
with MIT License
from adamant
public override bool Equals(object? obj)
{
if (obj is null) return false;
if (ReferenceEquals(this, obj)) return true;
return obj.GetType() == GetType() && Equals((DataType)obj);
}
19
Source : RasterCacheKey.cs
with MIT License
from adamped
with MIT License
from adamped
public static bool functorMethod(RasterCacheKey<ID> lhs, RasterCacheKey<ID> rhs)
{
return lhs.id_.Equals(rhs.id_) && lhs.matrix_.Equals(rhs.matrix_);
}
19
Source : Helper.cs
with MIT License
from adamped
with MIT License
from adamped
public static bool identical(object first, object second) => first.Equals(second);
19
Source : EnumerableFilters.cs
with MIT License
from Adoxio
with MIT License
from Adoxio
private static bool KeyEquals(object @object, string key, object value)
{
var propertyValue = Get(@object, key);
return propertyValue == null ? value == null : propertyValue.Equals(value);
}
19
Source : Converters.cs
with MIT License
from adrianmteo
with MIT License
from adrianmteo
public object Convert(object value, Type targetType, object parameter, CultureInfo culture)
{
return value.Equals(parameter) ? Visibility.Visible : Visibility.Collapsed;
}
19
Source : CheckoutBalanceCheckResponse.cs
with MIT License
from Adyen
with MIT License
from Adyen
public bool Equals(CheckoutBalanceCheckResponse input)
{
if (input == null)
return false;
return
(
this.AdditionalData == input.AdditionalData ||
this.AdditionalData != null &&
this.AdditionalData.Equals(input.AdditionalData)
) &&
(
this.Balance == input.Balance ||
this.Balance != null &&
this.Balance.Equals(input.Balance)
) &&
(
this.FraudResult == input.FraudResult ||
this.FraudResult != null &&
this.FraudResult.Equals(input.FraudResult)
) &&
(
this.PspReference == input.PspReference ||
this.PspReference != null &&
this.PspReference.Equals(input.PspReference)
) &&
(
this.RefusalReason == input.RefusalReason ||
this.RefusalReason != null &&
this.RefusalReason.Equals(input.RefusalReason)
) &&
(
this.ResultCode == input.ResultCode ||
this.ResultCode != null &&
this.ResultCode.Equals(input.ResultCode)
) &&
(
this.TransactionLimit == input.TransactionLimit ||
this.TransactionLimit != null &&
this.TransactionLimit.Equals(input.TransactionLimit)
);
}
19
Source : CheckoutCreateOrderResponse.cs
with MIT License
from Adyen
with MIT License
from Adyen
public bool Equals(CheckoutCreateOrderResponse input)
{
if (input == null)
return false;
return
(
this.AdditionalData == input.AdditionalData ||
this.AdditionalData != null &&
this.AdditionalData.Equals(input.AdditionalData)
) &&
(
this.Amount == input.Amount ||
this.Amount != null &&
this.Amount.Equals(input.Amount)
) &&
(
this.ExpiresAt == input.ExpiresAt ||
this.ExpiresAt != null &&
this.ExpiresAt.Equals(input.ExpiresAt)
) &&
(
this.FraudResult == input.FraudResult ||
this.FraudResult != null &&
this.FraudResult.Equals(input.FraudResult)
) &&
(
this.OrderData == input.OrderData ||
this.OrderData != null &&
this.OrderData.Equals(input.OrderData)
) &&
(
this.PspReference == input.PspReference ||
this.PspReference != null &&
this.PspReference.Equals(input.PspReference)
) &&
(
this.RefusalReason == input.RefusalReason ||
this.RefusalReason != null &&
this.RefusalReason.Equals(input.RefusalReason)
) &&
(
this.RemainingAmount == input.RemainingAmount ||
this.RemainingAmount != null &&
this.RemainingAmount.Equals(input.RemainingAmount)
) &&
(
this.ResultCode == input.ResultCode ||
this.ResultCode != null &&
this.ResultCode.Equals(input.ResultCode)
);
}
19
Source : PaymentMethodsRequest.cs
with MIT License
from Adyen
with MIT License
from Adyen
public bool Equals(PaymentMethodsRequest input)
{
if (input == null)
return false;
return
(
this.AdditionalData == input.AdditionalData ||
this.AdditionalData != null &&
this.AdditionalData.Equals(input.AdditionalData)
) &&
(
this.AllowedPaymentMethods == input.AllowedPaymentMethods ||
this.AllowedPaymentMethods != null &&
input.AllowedPaymentMethods != null &&
this.AllowedPaymentMethods.SequenceEqual(input.AllowedPaymentMethods)
) &&
(
this.Amount == input.Amount ||
this.Amount != null &&
this.Amount.Equals(input.Amount)
) &&
(
this.BlockedPaymentMethods == input.BlockedPaymentMethods ||
this.BlockedPaymentMethods != null &&
input.BlockedPaymentMethods != null &&
this.BlockedPaymentMethods.SequenceEqual(input.BlockedPaymentMethods)
) &&
(
this.Channel == input.Channel ||
this.Channel != null &&
this.Channel.Equals(input.Channel)
) &&
(
this.CountryCode == input.CountryCode ||
this.CountryCode != null &&
this.CountryCode.Equals(input.CountryCode)
) &&
(
this.MerchantAccount == input.MerchantAccount ||
this.MerchantAccount != null &&
this.MerchantAccount.Equals(input.MerchantAccount)
) &&
(
this.Order == input.Order ||
this.Order != null &&
this.Order.Equals(input.Order)
) &&
(
this.ShopperLocale == input.ShopperLocale ||
this.ShopperLocale != null &&
this.ShopperLocale.Equals(input.ShopperLocale)
) &&
(
this.ShopperReference == input.ShopperReference ||
this.ShopperReference != null &&
this.ShopperReference.Equals(input.ShopperReference)
) &&
(
this.SplitCardFundingSources == input.SplitCardFundingSources ||
this.SplitCardFundingSources != null &&
this.SplitCardFundingSources.Equals(input.SplitCardFundingSources)
) &&
(
this.Store == input.Store ||
this.Store != null &&
this.Store.Equals(input.Store)
);
}
19
Source : PaymentResultResponse.cs
with MIT License
from Adyen
with MIT License
from Adyen
public bool Equals(PaymentResultResponse input)
{
if (input == null)
return false;
return
(
this.AdditionalData == input.AdditionalData ||
this.AdditionalData != null &&
this.AdditionalData.Equals(input.AdditionalData)
) &&
(
this.FraudResult == input.FraudResult ||
this.FraudResult != null &&
this.FraudResult.Equals(input.FraudResult)
) &&
(
this.MerchantReference == input.MerchantReference ||
this.MerchantReference != null &&
this.MerchantReference.Equals(input.MerchantReference)
) &&
(
this.Order == input.Order ||
this.Order != null &&
this.Order.Equals(input.Order)
) &&
(
this.PaymentMethod == input.PaymentMethod ||
this.PaymentMethod != null &&
this.PaymentMethod.Equals(input.PaymentMethod)
) &&
(
this.PspReference == input.PspReference ||
this.PspReference != null &&
this.PspReference.Equals(input.PspReference)
) &&
(
this.RefusalReason == input.RefusalReason ||
this.RefusalReason != null &&
this.RefusalReason.Equals(input.RefusalReason)
) &&
(
this.RefusalReasonCode == input.RefusalReasonCode ||
this.RefusalReasonCode != null &&
this.RefusalReasonCode.Equals(input.RefusalReasonCode)
) &&
(
this.ResultCode == input.ResultCode ||
this.ResultCode != null &&
this.ResultCode.Equals(input.ResultCode)
) &&
(
this.ServiceError == input.ServiceError ||
this.ServiceError != null &&
this.ServiceError.Equals(input.ServiceError)
) &&
(
this.ShopperLocale == input.ShopperLocale ||
this.ShopperLocale != null &&
this.ShopperLocale.Equals(input.ShopperLocale)
);
}
19
Source : PaymentResponse.cs
with MIT License
from Adyen
with MIT License
from Adyen
public bool Equals(PaymentResponse input)
{
if (input == null)
return false;
return
(
this.Action == input.Action ||
this.Action != null &&
this.Action.Equals(input.Action)
) &&
(
this.AdditionalData == input.AdditionalData ||
this.AdditionalData != null &&
this.AdditionalData.Equals(input.AdditionalData)
) &&
(
this.Amount == input.Amount ||
this.Amount != null &&
this.Amount.Equals(input.Amount)
) &&
(
this.Authentication == input.Authentication ||
this.Authentication != null &&
input.Authentication != null &&
this.Authentication.SequenceEqual(input.Authentication)
) &&
(
this.Details == input.Details ||
this.Details != null &&
input.Details != null &&
this.Details.SequenceEqual(input.Details)
) &&
(
this.DonationToken == input.DonationToken ||
this.DonationToken != null &&
this.DonationToken.Equals(input.DonationToken)
) &&
(
this.FraudResult == input.FraudResult ||
this.FraudResult != null &&
this.FraudResult.Equals(input.FraudResult)
) &&
(
this.MerchantReference == input.MerchantReference ||
this.MerchantReference != null &&
this.MerchantReference.Equals(input.MerchantReference)
) &&
(
this.Order == input.Order ||
this.Order != null &&
this.Order.Equals(input.Order)
) &&
(
this.OutputDetails == input.OutputDetails ||
this.OutputDetails != null &&
input.OutputDetails != null &&
this.OutputDetails.SequenceEqual(input.OutputDetails)
) &&
(
this.PaymentData == input.PaymentData ||
this.PaymentData != null &&
this.PaymentData.Equals(input.PaymentData)
) &&
(
this.PspReference == input.PspReference ||
this.PspReference != null &&
this.PspReference.Equals(input.PspReference)
) &&
(
this.Redirect == input.Redirect ||
this.Redirect != null &&
this.Redirect.Equals(input.Redirect)
) &&
(
this.RefusalReason == input.RefusalReason ||
this.RefusalReason != null &&
this.RefusalReason.Equals(input.RefusalReason)
) &&
(
this.RefusalReasonCode == input.RefusalReasonCode ||
this.RefusalReasonCode != null &&
this.RefusalReasonCode.Equals(input.RefusalReasonCode)
) &&
(
this.ResultCode == input.ResultCode ||
this.ResultCode != null &&
this.ResultCode.Equals(input.ResultCode)
);
}
19
Source : UpdateAccountRequest.cs
with MIT License
from Adyen
with MIT License
from Adyen
public bool Equals(UpdateAccountRequest input)
{
if (input == null)
return false;
return
(
this.AccountCode == input.AccountCode ||
(this.AccountCode != null &&
this.AccountCode.Equals(input.AccountCode))
) &&
(
this.Description == input.Description ||
(this.Description != null &&
this.Description.Equals(input.Description))
) &&
(
this.Metadata == input.Metadata ||
(this.Metadata != null &&
this.Metadata.Equals(input.Metadata))
) &&
(
this.PayoutSchedule == input.PayoutSchedule ||
(this.PayoutSchedule != null &&
this.PayoutSchedule.Equals(input.PayoutSchedule))
);
}
19
Source : ThreeDSecureData.cs
with MIT License
from Adyen
with MIT License
from Adyen
public bool Equals(ThreeDSecureData input)
{
if (input == null)
return false;
return
(
this.AuthenticationResponse == input.AuthenticationResponse ||
this.AuthenticationResponse != null &&
this.AuthenticationResponse.Equals(input.AuthenticationResponse)
) &&
(
this.Cavv == input.Cavv ||
this.Cavv != null &&
this.Cavv.Equals(input.Cavv)
) &&
(
this.CavvAlgorithm == input.CavvAlgorithm ||
this.CavvAlgorithm != null &&
this.CavvAlgorithm.Equals(input.CavvAlgorithm)
) &&
(
this.DirectoryResponse == input.DirectoryResponse ||
this.DirectoryResponse != null &&
this.DirectoryResponse.Equals(input.DirectoryResponse)
) &&
(
this.DsTransID == input.DsTransID ||
this.DsTransID != null &&
this.DsTransID.Equals(input.DsTransID)
) &&
(
this.Eci == input.Eci ||
this.Eci != null &&
this.Eci.Equals(input.Eci)
) &&
(
this.ThreeDSVersion == input.ThreeDSVersion ||
this.ThreeDSVersion != null &&
this.ThreeDSVersion.Equals(input.ThreeDSVersion)
) &&
(
this.Xid == input.Xid ||
this.Xid != null &&
this.Xid.Equals(input.Xid)
) &&
(
this.ChallengeCancel == input.ChallengeCancel ||
this.ChallengeCancel != null &&
this.ChallengeCancel.Equals(input.ChallengeCancel)
) &&
(
this.RiskScore == input.RiskScore ||
this.RiskScore != null &&
this.RiskScore.Equals(input.RiskScore)
) &&
(
this.TransStatusReason == input.TransStatusReason ||
this.TransStatusReason != null &&
this.TransStatusReason.Equals(input.TransStatusReason)
);
}
19
Source : AccountHolderDetails.cs
with MIT License
from Adyen
with MIT License
from Adyen
public bool Equals(AccountHolderDetails input)
{
if (input == null)
return false;
return
(
this.Address == input.Address ||
(this.Address != null &&
this.Address.Equals(input.Address))
) &&
(
this.BankAccountDetails == input.BankAccountDetails ||
this.BankAccountDetails != null &&
input.BankAccountDetails != null &&
this.BankAccountDetails.SequenceEqual(input.BankAccountDetails)
) &&
(
this.BusinessDetails == input.BusinessDetails ||
(this.BusinessDetails != null &&
this.BusinessDetails.Equals(input.BusinessDetails))
) &&
(
this.Email == input.Email ||
(this.Email != null &&
this.Email.Equals(input.Email))
) &&
(
this.FullPhoneNumber == input.FullPhoneNumber ||
(this.FullPhoneNumber != null &&
this.FullPhoneNumber.Equals(input.FullPhoneNumber))
) &&
(
this.IndividualDetails == input.IndividualDetails ||
(this.IndividualDetails != null &&
this.IndividualDetails.Equals(input.IndividualDetails))
) &&
(
this.MerchantCategoryCode == input.MerchantCategoryCode ||
(this.MerchantCategoryCode != null &&
this.MerchantCategoryCode.Equals(input.MerchantCategoryCode))
) &&
(
this.Metadata == input.Metadata ||
(this.Metadata != null &&
this.Metadata.Equals(input.Metadata))
) &&
(
this.PayoutMethods == input.PayoutMethods ||
this.PayoutMethods != null &&
input.PayoutMethods != null &&
this.PayoutMethods.SequenceEqual(input.PayoutMethods)
) &&
(
this.WebAddress == input.WebAddress ||
(this.WebAddress != null &&
this.WebAddress.Equals(input.WebAddress))
);
}
19
Source : Account.cs
with MIT License
from Adyen
with MIT License
from Adyen
public bool Equals(Account input)
{
if (input == null)
return false;
return
(
this.AccountCode == input.AccountCode ||
(this.AccountCode != null &&
this.AccountCode.Equals(input.AccountCode))
) &&
(
this.BankAccountUUID == input.BankAccountUUID ||
(this.BankAccountUUID != null &&
this.BankAccountUUID.Equals(input.BankAccountUUID))
) &&
(
this.BeneficiaryAccount == input.BeneficiaryAccount ||
(this.BeneficiaryAccount != null &&
this.BeneficiaryAccount.Equals(input.BeneficiaryAccount))
) &&
(
this.BeneficiaryMerchantReference == input.BeneficiaryMerchantReference ||
(this.BeneficiaryMerchantReference != null &&
this.BeneficiaryMerchantReference.Equals(input.BeneficiaryMerchantReference))
) &&
(
this.Description == input.Description ||
(this.Description != null &&
this.Description.Equals(input.Description))
) &&
(
this.Metadata == input.Metadata ||
(this.Metadata != null &&
this.Metadata.Equals(input.Metadata))
) &&
(
this.PayoutMethodCode == input.PayoutMethodCode ||
(this.PayoutMethodCode != null &&
this.PayoutMethodCode.Equals(input.PayoutMethodCode))
) &&
(
this.PayoutSchedule == input.PayoutSchedule ||
(this.PayoutSchedule != null)
) &&
(
this.PayoutSpeed == input.PayoutSpeed ||
(this.PayoutSpeed != null &&
this.PayoutSpeed.Equals(input.PayoutSpeed))
) &&
(
this.Status == input.Status ||
(this.Status != null &&
this.Status.Equals(input.Status))
);
}
19
Source : CreateAccountRequest.cs
with MIT License
from Adyen
with MIT License
from Adyen
public bool Equals(CreateAccountRequest input)
{
if (input == null)
return false;
return
(
this.AccountHolderCode == input.AccountHolderCode ||
(this.AccountHolderCode != null &&
this.AccountHolderCode.Equals(input.AccountHolderCode))
) &&
(
this.Description == input.Description ||
(this.Description != null &&
this.Description.Equals(input.Description))
) &&
(
this.Metadata == input.Metadata ||
(this.Metadata != null &&
this.Metadata.Equals(input.Metadata))
) &&
(
this.PayoutSchedule == input.PayoutSchedule ||
(this.PayoutSchedule != null &&
this.PayoutSchedule.Equals(input.PayoutSchedule))
) &&
(
this.PayoutScheduleReason == input.PayoutScheduleReason ||
(this.PayoutScheduleReason != null &&
this.PayoutScheduleReason.Equals(input.PayoutScheduleReason))
);
}
19
Source : UploadDocumentRequest.cs
with MIT License
from Adyen
with MIT License
from Adyen
public bool Equals(UploadDoreplacedentRequest input)
{
if (input == null)
return false;
return
(
this.DoreplacedentContent == input.DoreplacedentContent ||
(this.DoreplacedentContent != null &&
this.DoreplacedentContent.Equals(input.DoreplacedentContent))
) &&
(
this.DoreplacedentDetail == input.DoreplacedentDetail ||
(this.DoreplacedentDetail != null &&
this.DoreplacedentDetail.Equals(input.DoreplacedentDetail))
);
}
19
Source : RecurringDetailsResult.cs
with MIT License
from Adyen
with MIT License
from Adyen
public bool Equals(RecurringDetailsResult other)
{
// credit: http://stackoverflow.com/a/10454552/677735
if (other == null)
return false;
return
(
this.LastKnownShopperEmail == other.LastKnownShopperEmail ||
this.LastKnownShopperEmail != null &&
this.LastKnownShopperEmail.Equals(other.LastKnownShopperEmail)
) &&
(
this.CreationDate == other.CreationDate ||
this.CreationDate != null &&
this.CreationDate.Equals(other.CreationDate)
) &&
(
this.Details == other.Details ||
this.Details != null &&
other.Details != null &&
this.Details.Equals(other.Details)
) &&
(
this.ShopperReference == other.ShopperReference ||
this.ShopperReference != null &&
this.ShopperReference.Equals(other.ShopperReference)
);
}
19
Source : AuthoriseMpiData.cs
with MIT License
from Adyen
with MIT License
from Adyen
public bool Equals(AuthoriseMpiData other)
{
// credit: http://stackoverflow.com/a/10454552/677735
if (other == null)
return false;
return
(
this.Cavv == other.Cavv ||
this.Cavv != null &&
this.Cavv.Equals(other.Cavv)
) &&
(
this.AuthenticationResponse == other.AuthenticationResponse ||
this.AuthenticationResponse != null &&
this.AuthenticationResponse.Equals(other.AuthenticationResponse)
) &&
(
this.Xid == other.Xid ||
this.Xid != null &&
this.Xid.Equals(other.Xid)
) &&
(
this.CavvAlgorithm == other.CavvAlgorithm ||
this.CavvAlgorithm != null &&
this.CavvAlgorithm.Equals(other.CavvAlgorithm)
) &&
(
this.DirectoryResponse == other.DirectoryResponse ||
this.DirectoryResponse != null &&
this.DirectoryResponse.Equals(other.DirectoryResponse)
) &&
(
this.Eci == other.Eci ||
this.Eci != null &&
this.Eci.Equals(other.Eci)
);
}
19
Source : ThreeDSecureData.cs
with MIT License
from Adyen
with MIT License
from Adyen
public bool Equals(ThreeDSecureData other)
{
// credit: http://stackoverflow.com/a/10454552/677735
if (other == null)
return false;
return
(
this.Cavv == other.Cavv ||
this.Cavv != null &&
this.Cavv.Equals(other.Cavv)
) &&
(
this.AuthenticationResponse == other.AuthenticationResponse ||
this.AuthenticationResponse != null &&
this.AuthenticationResponse.Equals(other.AuthenticationResponse)
) &&
(
this.Xid == other.Xid ||
this.Xid != null &&
this.Xid.Equals(other.Xid)
) &&
(
this.CavvAlgorithm == other.CavvAlgorithm ||
this.CavvAlgorithm != null &&
this.CavvAlgorithm.Equals(other.CavvAlgorithm)
) &&
(
this.DirectoryResponse == other.DirectoryResponse ||
this.DirectoryResponse != null &&
this.DirectoryResponse.Equals(other.DirectoryResponse)
) &&
(
this.Eci == other.Eci ||
this.Eci != null &&
this.Eci.Equals(other.Eci)
);
}
See More Examples