Top "Conditional" questions

In computer science, conditional statements, conditional expressions and conditional constructs are features of a programming language which perform different computations or actions depending on whether a programmer-specified boolean condition evaluates to true or false.

Is it possible to create a conditional association in model?

I have setup a role based access controll system with the following models: Role (as STI), UserRole (global roles) ProjectRole (…

ruby-on-rails conditional has-many polymorphic-associations single-table-inheritance
How can I map properties conditionally with MapStruct 1.2?

Is it possible with MapStruct 1.2 to map a source property with a specific value to a specific different value in …

mapping conditional mapstruct
C conditional operator ('?') with empty second parameter

Typically the '?' operator is used in the following form: A ? B : C However in cases where B = A …

c operators conditional ternary-operator
SSIS Conditional Split boolean result

In conditional split component, I need to know if Age equals -1 and am using following statement. However, there comes …

ssis split conditional boolean-expression
Bind Image.Source according to Boolean without a converter?

I want to have an image bound to a boolean and have the source of the image to depend on …

wpf binding conditional boolean-expression converters
Conditional "Browsable" Attribute

Is there a way to make a "Browsable" attribute conditional, so the property that applies it will sometimes appear in …

c# properties conditional browsable
scalar subquery in if statement Condition in PL/SQL

I have an If Statement block similar to the below which is failing with the error - PLS-00103: Encountered the …

oracle plsql conditional scalar-subquery
conditional statements inside php heredocs syntax?

i was wondering if you can have conditional statments inside a heredocs, this is my script but it deosnt parse …

php conditional heredoc
Python, doing conditional imports the right way

Right now I have a class called A. I have some code like this.. from my.package.location.A import …

python import conditional factory-pattern