Cursos
Cursos
Compilador de Código
Compilador de Código
Discutir
Preços
Teams
Fazer login
Registrar
Menu
Q&A Discussões
Pesquisar
Pesquisar
Faça uma pergunta
Faça uma pergunta
When defining a setter how would i code the value of the setter to be dependent on user input vs a static value?
attributes
classes
0 Voto
2 Respostas
2nd Mar 2019, 6:26 AM
Nick Nelson
Write a program using getter and setter method in java
playground
0 Voto
2 Respostas
11th Aug 2017, 6:13 PM
bhavsar aman
can enyone explain to me why we are use setter & getter
java
1 Voto
4 Respostas
26th Oct 2017, 6:30 PM
Asmaa Mogahed Khalifa Osman
What happens if I omit this in the setter method?
classes
java
0 Voto
1 Resposta
6th Jul 2017, 4:19 PM
.
What is this in the following program in setter block....?
,setter,getter
java
1 Voto
1 Resposta
24th Dec 2016, 7:40 AM
Saurabh Pandey
Is getter and setter are same as Scan & print tespectively?
classes
java
1 Voto
2 Respostas
22nd Sep 2017, 4:27 PM
akash
What is Getter and Setter method in Java? How they can be used?
getter
java
setter
use
3 Votos
2 Respostas
13th Jun 2018, 2:52 PM
Pradeep Anand
What are the differences between constructor with arguments and setter in java?
constructors
java
methods
1 Voto
3 Respostas
13th Jun 2017, 8:07 AM
Hassan
where to find the concept of getter and setter in C++
and
c++
getter
in
setter
0 Voto
1 Resposta
15th Jan 2019, 2:41 PM
Sm Developer
is setter method is always void? can't we make it int type and return?
java
1 Voto
4 Respostas
20th Jul 2018, 5:05 PM
mn121
Can Anyone Explain What is getter and setter with an example ?
classes
java
1 Voto
2 Respostas
3rd Feb 2017, 7:28 AM
Abhijith R
can anyone explain getter and setter in detail..i am not able to understand plzz..??
classes
java
0 Voto
5 Respostas
3rd Jul 2016, 8:46 AM
Chaitanya Pandit
Getter and setter , how to use ? What is the need ?
classes
0 Voto
2 Respostas
25th May 2018, 5:21 PM
Anshul
Should a SETTER always have "this" keyword? Or can it even work without it?
encapsulation
java
1 Voto
4 Respostas
25th Jan 2017, 5:47 PM
james nyle
plz explain the getter and setter I am not understand these concept
classes
java
0 Voto
2 Respostas
4th Oct 2016, 2:22 PM
sandhyarani
Could someone explain what a getter and setter does in really simple words?
getter
setter
1 Voto
2 Respostas
8th May 2017, 3:21 PM
Tina
Plzz anyone tell me what is the error in this getter and setter program !!
error
getter
help
java
program
setter
4 Votos
3 Respostas
25th Aug 2017, 7:45 AM
Vaibhav Singh Sikarwar
(Python)Do you see loop in this code?
python
setter
2 Votos
4 Respostas
20th Dec 2021, 8:25 AM
Lea
How does the getter and setter will protect the data? I don't understand.
classes
java
1 Voto
1 Resposta
19th Jul 2016, 10:22 AM
Jack
Staying Alive properties
getter
property
setter
0 Voto
5 Respostas
8th Jun 2021, 11:35 AM
Lee 4 Code
Я не очень понял атрибуты getter, setter и конструкторы по Java. Кто нибудь может мне объяснить? Пожалуйста!
getter
setter
venicle
2 Votos
2 Respostas
4th Sep 2020, 11:44 AM
Jasulan Kanaibaev
"You may validate the given value in the setter before actually setting the value". Explain this?
access-modifiers
java
sololearn
1 Voto
1 Resposta
3rd Nov 2021, 10:07 AM
NIKHIL JOSHI
Can We Use Getter & Setter In C++ also,Just Like C# & Java ??
c#
c++
classes
functions
java
methods
output
sololearn
this
0 Voto
1 Resposta
11th Jul 2019, 3:07 AM
Anurag Singh
Hello everyone! Can I create getter or setter myself with other name? ex. : recColor(); plaColor();
getter
java
0 Voto
1 Resposta
18th Mar 2023, 7:23 AM
Saidazim
Whta ia the use of this in setter method. I get the same output witjout use of this keyword.
classes
java
this
0 Voto
6 Respostas
9th Sep 2017, 9:26 AM
naveen
If a constructor is used in a program in Java is getter and setter still relevant to use?
java
0 Voto
3 Respostas
5th Oct 2020, 4:32 PM
Sunday Othniel
Is there a way in which we can access private variables of a class in java without setter and getter methods?
java
oop
4 Votos
6 Respostas
25th Jan 2018, 1:07 PM
Santosh Teurwadkar
Doubt in Java constructor of using "this" keyword
constructor
setter
this
1 Voto
4 Respostas
3rd Sep 2024, 6:17 AM
Yogeshwaran P
2 way data binding [SOLVED]
defineproperty
javascript
setter
2 Votos
4 Respostas
30th Sep 2020, 6:38 PM
Ore
What is property decorator how does it work and what does it even do ? Setter ? Getter?
python
1 Voto
1 Resposta
29th Aug 2023, 11:05 AM
Intermediate Depression
possible enhancement with the following question: What would the name of the setter method for the class variable named "age" be
classes
java
0 Voto
3 Respostas
17th Jan 2017, 12:33 AM
Jahndev
Why do we set this.color = c and then ignore it in the main class?
getter
java
setter
0 Voto
3 Respostas
22nd Apr 2019, 5:08 PM
Mike Smith
Fill in the blanks to assign the value "7" to the age variable of the object using its setter method.
ruby
1 Voto
2 Respostas
1st Oct 2020, 8:44 PM
Dennis Crowley
Is there Syntax ErroR.
getter
java
setter
0 Voto
3 Respostas
9th Jun 2022, 3:31 AM
We Doru
What is the word "this" in Java?
java
setter
this
0 Voto
3 Respostas
31st Jan 2019, 12:00 PM
Evgeniy Krasnyanskiy
what i don't understand about the setter property in python based on the example is, how do we decide what the value is?
properties
python
0 Voto
5 Respostas
13th Aug 2017, 8:41 AM
Owolawi Kehinde
Why use getter and setter?
getter
java
setter
use
0 Voto
7 Respostas
6th Jun 2019, 4:46 PM
Heisenberg
So... um... GETTER and SETTER are just public methods, what contain possibility to modify and show us private variables?
classes
java
0 Voto
1 Resposta
20th Dec 2016, 7:21 AM
Nochains
Why are global variables a bad idea?
bad
class
encapsulation
getter
global
object
oriented
setter
static
variables
24 Votos
21 Respostas
29th Sep 2018, 8:33 AM
Sonic
Why doesn't this program execute?
getter
java
setter
spinoza
2 Votos
6 Respostas
13th Oct 2017, 9:31 PM
Spinoza
Java Classes (getters and setters)
class
getter
java
setter
0 Voto
4 Respostas
8th Apr 2019, 9:31 PM
Albert Yakubov
Getter-setter or Constructors ??
classes
constructors
getter
java
setter
4 Votos
6 Respostas
6th Mar 2018, 4:42 AM
Shruti Singh
How do getters and setters protect the data of a java class?
bean
classes
getter
setter
0 Voto
3 Respostas
5th Apr 2018, 5:38 PM
knave
Can I declare members in abstract class? Should I declare a virtual getter / setter method for the member in that class?
abstract-classes
c++
virtual
0 Voto
2 Respostas
23rd Nov 2016, 1:46 PM
Marcell Juhasz
question from a java newbie
getter
java
self-learning
setter
2 Votos
3 Respostas
17th Oct 2017, 4:02 AM
oyl
Do getters and setters in swift work similarly to those in Java?
getter
methods
properties
setter
swift
8 Votos
3 Respostas
5th Nov 2016, 7:09 PM
Joe
getColor
classes
getter
java
setter
2 Votos
2 Respostas
3rd Jan 2017, 10:41 PM
Jackson Simpson
Why is it giving this error??
class
getter
object
php
setter
0 Voto
3 Respostas
13th Jun 2019, 2:58 PM
Niloy19
Is "this" necessary within getter and setter?
classes
getter
java
setter
0 Voto
1 Resposta
17th Nov 2018, 8:01 PM
triny
Error: self not found
classes
init
instanciation
methods
python
setter
1 Voto
4 Respostas
20th Oct 2018, 6:42 PM
HonFu
Faça uma pergunta
Faça uma pergunta
Faça uma pergunta
Faça uma pergunta
< Anterior
1
2
3
Próximo >
Quente hoje
How to allow one instance of exe
1 Votes
Reverse observer pattern : remove dynamic_cast
2 Votes
purchase of a subscription
1 Votes
seats = 100 (blank) seats > 0: print "sell ticket" (blank) = seats - 1
0 Votes
Theater management help me
2 Votes
What has happened?
1 Votes
What should I add/improve ?
1 Votes
Flight tracker coding foundation help me
1 Votes
Should You Specialize or Diversify in Programming?
1 Votes
Tools for web design?
1 Votes