Lines Matching refs:abstract
51 abstract class Animal {
52 abstract String getName();
53 abstract int getNumberOfLegs();
60 abstract static class Builder {
61 abstract Builder name(String value);
62 abstract Builder numberOfLegs(int value);
63 abstract Animal build();
95 abstract class Animal {
96 abstract String name();
97 abstract int numberOfLegs();
105 abstract static class Builder {
106 abstract Builder setName(String value);
107 abstract Builder setNumberOfLegs(int value);
108 abstract Animal build();
125 To give them this ability, just add an abstract `toBuilder` method, returning
126 your abstract builder type, to your value class. AutoValue will implement it.
129 public abstract Builder toBuilder();
142 public abstract class Animal {
143 public abstract String name();
144 public abstract int numberOfLegs();
150 abstract Builder toBuilder();
157 public abstract static class Builder {
158 public abstract Builder setName(String value);
159 public abstract Builder setNumberOfLegs(int value);
160 public abstract Animal build();
175 * the non-visible, abstract method that AutoValue implements
184 public abstract class Animal {
185 public abstract String name();
186 public abstract int numberOfLegs();
193 public abstract static class Builder {
194 public abstract Builder setName(String value);
195 public abstract Builder setNumberOfLegs(int value);
197 abstract Animal autoBuild(); // not public
216 public abstract class Animal {
217 public abstract String name();
218 public abstract int numberOfLegs();
225 public abstract static class Builder {
226 public abstract Builder setName(String value);
227 public abstract Builder setNumberOfLegs(int value);
229 abstract String name(); // must match method name in Animal
231 abstract Animal autoBuild(); // not public
241 The getter in your builder must have the same signature as the abstract property
259 public abstract class Animal {
260 public abstract String name();
261 public abstract int numberOfLegs();
268 public abstract static class Builder {
269 public abstract Builder setName(String value);
270 public abstract Builder setNumberOfLegs(int value);
272 abstract Optional<String> name();
273 abstract int numberOfLegs();
275 abstract Animal autoBuild(); // not public
320 public abstract class Animal {
321 public abstract Optional<String> name();
328 public abstract static class Builder {
330 public abstract Builder setName(Optional<String> value);
331 public abstract Builder setName(String value);
332 public abstract Animal build();
367 public abstract class Animal {
368 public abstract String name();
369 public abstract int numberOfLegs();
370 public abstract ImmutableSet<String> countries();
377 public abstract static class Builder {
378 public abstract Builder setName(String value);
379 public abstract Builder setNumberOfLegs(int value);
380 public abstract Builder setCountries(Set<String> value);
381 public abstract Builder setCountries(String... value);
382 public abstract Animal build();
398 public abstract class Animal {
399 public abstract String name();
400 public abstract int numberOfLegs();
401 public abstract ImmutableSet<String> countries();
408 public abstract static class Builder {
409 public abstract Builder setName(String value);
410 public abstract Builder setNumberOfLegs(int value);
411 public abstract ImmutableSet.Builder<String> countriesBuilder();
412 public abstract Animal build();
458 public abstract class Animal {
459 public abstract String name();
460 public abstract int numberOfLegs();
461 public abstract ImmutableSet<String> countries();
468 public abstract static class Builder {
469 public abstract Builder setName(String value);
470 public abstract Builder setNumberOfLegs(int value);
472 abstract ImmutableSet.Builder<String> countriesBuilder();
478 public abstract Animal build();
517 public abstract class Animal {
518 public abstract String name();
519 public abstract Species species();
526 public abstract static class Builder {
527 public abstract Builder setName(String name);
528 public abstract Species.Builder speciesBuilder();
529 public abstract Animal build();
534 public abstract class Species {
535 public abstract String genus();
536 public abstract String epithet();
543 public abstract static class Builder {
544 public abstract Builder setGenus(String genus);
545 public abstract Builder setEpithet(String epithet);
546 public abstract Species build();
576 In the example, if `Animal` has an abstract [`toBuilder()`](#to_builder)
578 if there is an abstract `setSpecies` method in addition to the