Modifier and Type | Field and Description |
---|---|
static String |
FIND_ALL
|
static String |
FIND_BY_NAME
Specifies the
String that represents the NamedQuery to create a TypedQuery to get all
cemeteries by name. |
static String |
FIND_BY_NAME_AND_REGION
Specifies the
String that represents the NamedQuery to create a TypedQuery to get all
cemeteries by name and region. |
Constructor and Description |
---|
Cemetery()
No-argument constructor for JPA.
|
Cemetery(String name)
Creates a new cemetery with the specified name.
|
Modifier and Type | Method and Description |
---|---|
City |
getCity()
Returns the city that the cemetery is in.
|
Country |
getCountry()
Returns the country that the cemetery is in.
|
County |
getCounty()
Returns the county that the cemetery is in.
|
String |
getLink()
Returns a URL String, typically either a Google query or Google map link.
|
State |
getState()
Returns the state that the cemetery is in.
|
equals, getId, getName, getPlaces, getRegion, hashCode, iterator, setId, setName, setRegion, toString
forEach, spliterator
public static final String FIND_ALL
String
that represents the NamedQuery
to create a TypedQuery
to get all
cemeteries.
For example:
TypedQuery<Cemetery> query = em.createNamedQuery(Cemetery.FIND_ALL, Cemetery.class);
public static final String FIND_BY_NAME
String
that represents the NamedQuery
to create a TypedQuery
to get all
cemeteries by name.
For example:
TypedQuery<Cemetery> query = em.createNamedQuery(Cemetery.FIND_BY_NAME, Cemetery.class); query.setParameter("name", name);
public static final String FIND_BY_NAME_AND_REGION
String
that represents the NamedQuery
to create a TypedQuery
to get all
cemeteries by name and region.
For example:
TypedQuery<Cemetery> query = em.createNamedQuery(Cemetery.FIND_BY_NAME_AND_REGION, Cemetery.class); query.setParameter("name", name); query.setParameter("region", region);
public Cemetery()
public Cemetery(String name)
name
- the name of the cemeterypublic City getCity()
public County getCounty()
public Country getCountry()
public State getState()
public String getLink()
"https://www.google.com/search?q="
while a Google map link follows the format "https://www.google.com/maps/place/"
.Copyright © 2015 Joseph Hendrix