From: Roland Häder Date: Tue, 16 Aug 2016 14:26:52 +0000 (+0200) Subject: Continued a bit: X-Git-Url: https://git.mxchange.org/?a=commitdiff_plain;h=622ee2e032eff0c7e047145540400f0182bbfe50;p=jphone-core.git Continued a bit: - renamed named queries: SearchFaxId -> SearchFaxNumberId and SearchLandLineId -> SearchLandLineNumberId - renamed entity phone_numbers -> landline_numbers - renamed also all suffixes phone_ -> landline_ --- diff --git a/src/org/mxchange/jphone/phonenumbers/fax/FaxNumber.java b/src/org/mxchange/jphone/phonenumbers/fax/FaxNumber.java index 92dd5d9..9d7bcda 100644 --- a/src/org/mxchange/jphone/phonenumbers/fax/FaxNumber.java +++ b/src/org/mxchange/jphone/phonenumbers/fax/FaxNumber.java @@ -46,7 +46,7 @@ import org.mxchange.jcountry.data.CountryData; @NamedQueries ( { @NamedQuery (name = "AllFaxNumbers", query = "SELECT f FROM fax_numbers AS f ORDER BY f.phoneId ASC"), - @NamedQuery (name = "SearchFaxId", query = "SELECT f FROM fax_numbers AS f WHERE f.phoneId = :faxId") + @NamedQuery (name = "SearchFaxNumberId", query = "SELECT f FROM fax_numbers AS f WHERE f.phoneId = :faxNumberId") } ) @SuppressWarnings ("PersistenceUnitPresent") diff --git a/src/org/mxchange/jphone/phonenumbers/landline/LandLineNumber.java b/src/org/mxchange/jphone/phonenumbers/landline/LandLineNumber.java index c567c4c..df18350 100644 --- a/src/org/mxchange/jphone/phonenumbers/landline/LandLineNumber.java +++ b/src/org/mxchange/jphone/phonenumbers/landline/LandLineNumber.java @@ -41,12 +41,12 @@ import org.mxchange.jcountry.data.CountryData; *

* @author Roland Haeder */ -@Entity (name = "phone_numbers") -@Table (name = "phone_numbers") +@Entity (name = "landline_numbers") +@Table (name = "landline_numbers") @NamedQueries ( { - @NamedQuery (name = "AllLandLineNumbers", query = "SELECT p FROM phone_numbers AS p ORDER BY p.phoneId ASC"), - @NamedQuery (name = "SearchLandLineId", query = "SELECT p FROM phone_numbers AS p WHERE p.phoneId = :phoneId") + @NamedQuery (name = "AllLandLineNumbers", query = "SELECT p FROM landline_numbers AS p ORDER BY p.phoneId ASC"), + @NamedQuery (name = "SearchLandLineNumberId", query = "SELECT p FROM landline_numbers AS p WHERE p.phoneId = :landLineNumberId") } ) @SuppressWarnings ("PersistenceUnitPresent") @@ -62,13 +62,13 @@ public class LandLineNumber implements DialableLandLineNumber { * Area code (example: 2151 for Krefeld) */ @Basic (optional = false) - @Column (name = "phone_area_code", length = 10, nullable = false) + @Column (name = "landline_area_code", length = 10, nullable = false) private Integer phoneAreaCode; /** * Connection to table "country_data" */ - @JoinColumn (name = "phone_country_id", nullable = false, updatable = false) + @JoinColumn (name = "landline_country_id", nullable = false, updatable = false) @OneToOne (targetEntity = CountryData.class, cascade = CascadeType.REFRESH, optional = false) private Country phoneCountry; @@ -77,14 +77,14 @@ public class LandLineNumber implements DialableLandLineNumber { */ @Basic (optional = false) @Temporal (TemporalType.TIMESTAMP) - @Column (name = "phone_entry_created", nullable = false, updatable = false) + @Column (name = "landline_entry_created", nullable = false, updatable = false) private Calendar phoneEntryCreated; /** * Timestamp when this entry has been created */ @Temporal (TemporalType.TIMESTAMP) - @Column (name = "phone_entry_updated", updatable = false) + @Column (name = "landline_entry_updated", updatable = false) private Calendar phoneEntryUpdated; /** @@ -92,14 +92,14 @@ public class LandLineNumber implements DialableLandLineNumber { */ @Id @GeneratedValue (strategy = GenerationType.IDENTITY) - @Column (name = "phone_id", length = 10, nullable = false, updatable = false) + @Column (name = "landline_id", length = 10, nullable = false, updatable = false) private Long phoneId; /** * Phone number with out dial prefix */ @Basic (optional = false) - @Column (name = "phone_number", nullable = false) + @Column (name = "landline_number", nullable = false) private Long phoneNumber; /**