T5 M1: Starting the File API - rsanchez-wsu/jfiles GitHub Wiki
Issues #11 - #15
- Overview
- T5-M1-I1: Creating the JFile Class..............................................................................(#11)
- T5-M1-I2: Creating the JFileManager Class...........................................................(#12)
- T5-M1-I3: Team Coordination.....................................................................................(#13)
- T5-M1-I4: Continue Research into Exsisting Classes/Interfaces.....................(#14)
- T5-M1-I5: Continuing Development.........................................................................(#15)
##Overview
For Team 5's first Milestone, the team shall start the File API. This will consist of the following:
- Team 5 shall create the skeleton structure of the File API's JFile class and provide documentation for the basics of that class.
- Team 5 shall create the skeleton structure for JFileManager, which will manage JFile objects.
- Team 5 shall coordinate with other teams and note which methods in the JFile class require coordination with which team(s).
- Team 5 shall finish researching the functionality of the File built-in class and the Runnable built-in interface to see if and how they will be useful.
- If all of the above objectives have been completed, team 5 shall begin work on the copy, cut, paste, and rename methods.
1) Team 5 shall create the skeleton structure of the File API's JFile class and provide documentation for the basics of that class.
This issue shall consist of creating the basic, or skeletal, structure of the class that will be at the heart of the JFiles program's File API. This class shall consist of at minimum the following fields, constructors, and methods:
cut, copy, paste, and other methods that manage files shall be the duty of the JFileManager class, which shall manage files. The goal of the JFile object itself shall be to hold and manage the contents of files, not the files themselves.
- File file
- Tag[] tags
- String type
- JFile (File file)
- JFile ( )
- deleteContents()
- rename(String name)
- hasTag (String tagName)
- hasTag (int ID)
- hasTag (Tag tag)
- getType()
2) Team 5 shall create the skeleton structure for JFileManager, which will manage JFile objects.
This class shall have methods geared towards managing JFiles, such as copy, paste, delete, etc. This class will interact most closely with the JFile class and will require the most collaboration with other teams. Hopefully, this will take security (authorization, authentication, accounting), networking, and file management and be the meeting point of the three. To this end, most of the methods in this class will consist primarily of implementations of other methods and APIs.
This is separate from a JFolder object (which we may want to make later), in that this creates methods that are needed in implementation to manage JFiles, but may not be appropriate for the JFile class itself. It may be made up entirely of static methods and not need instantiation. All interactions between implantation and JFiles should go through this. In other words, this will be the class that unifies the File API and makes it usable by the implementation team.
The documentation shall reflect this. This class must have the following fields, constructors, and methods:
- JFile [] clipboard
- JFileManager()
- cut(String location)
- copy(String location)
- paste(String location)
- delete(String location)
- move(String fromLocation, String toLocation)
- rename(String location, String name)
- open(String location)
- openWith(String location, Appliaction app)
- getDetails(String location)
- getType(String location)
Setting up appropriate return types will be the duty of the individual who is making the methods. Team 5 should discuss how these methods will be implemented before starting actual work on the methods. This is also the duty of the member who is working on the methods.
3) Team 5 shall coordinate with other teams and note which methods in the JFile class require coordination with which team(s).
Team 5 shall coordinate with other teams and make comments in the Java documentation on which teams will be important to what methods in the File API. This communication shall be critical in determining how the methods in the File API shall work.
Things that should be included are the following:
- Security Measures:
- Authentication
- Authorization
- Accounting
- Networking:
- Server-Side Implementation
- Client-Side Implementation
The nature of this issue is bound to change as the relationship between teams changes. For milestone one, T5-M1: Starting the File API, team 5 shall focus on preliminary communications and get a stronger feel which teams should be notified for what kinds of development.
4) Team 5 shall finish researching the functionality of the File built-in class and the Runnable built-in interface to see if and how they will be useful.
For this issue, team 5 shall continue researching the File class and Runnable interface in Java. This research shall influence long-term goals and directions f the File API. Since the File API hinges on how we use the File class in Java, knowledge of this class will be absolutely critical to the formation of this API. Team 5 should, in particular, answer the following questions/solve the following problems:
- Which methods in the File class should be passed down to JFile as-is?
- Which methods in the File class should be passed down to JFile after modification?
- Which methods in the File class should not be passed down to JFile?
- Are there any methods in the File class that require modification beyond what a wrapper can provide? If so, how shall these issues be addressed?
- Can the Runnable interface be used as the team needs in he openAs(Application app) method?
- If Runnable does not provide the functionality the team needs, is there a class or interface that does? What class/interface is it? Does it require modification?
This issue should take a high priority. Even though it requires no actual coding, the knowledge gained through this research is critical to the creating and implementation of the File API. Without this knowledge, team 5 cannot progress. Post any important or relevant information as comments in this issue.
5) If all of the above objectives have been completed, team 5 shall begin work on the copy, cut, paste, and rename methods.
This issue is put in for the sole purpose of giving team 5 more work to do, should they finish everything else. When the deadline for the milestone is met, this issue is to be closed, regardless of whether it was ever reached. It is likely that team 5 will not reach this issue, but is added to cover all possible bases.
The methods chosen for this issue were chosen because they were deemed easiest to build. The cut method, should simply call the copy method to the clipboard and the delete method on the file after. The delete method is expected to be difficult, but calling the method isn't.