-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Created a class to implement the builder factory. Added this class to
instances where new builder were instantiated. Fixed one component of the SDFBuilderTest [23650083]
- Loading branch information
Showing
4 changed files
with
101 additions
and
55 deletions.
There are no files selected for viewing
20 changes: 20 additions & 0 deletions
20
src/main/java/edu/cmu/sv/arinc838/builder/BuilderFactoryImpl.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
package edu.cmu.sv.arinc838.builder; | ||
|
||
import edu.cmu.sv.arinc838.dao.SoftwareDescriptionDao; | ||
|
||
|
||
public class BuilderFactoryImpl implements BuilderFactory { | ||
|
||
@SuppressWarnings("unchecked") | ||
@Override | ||
public <DaoType, JaxbType> Builder<DaoType, JaxbType> getBuilder( | ||
Class<DaoType> Dao, Class<JaxbType> JaxB) { | ||
|
||
if (Dao == SoftwareDescriptionDao.class){ | ||
return (Builder<DaoType, JaxbType>) new SoftwareDescriptionBuilder(); | ||
} | ||
|
||
return null; | ||
} | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters