ITP Data Rep - Class3

539 views

Published on

These are class notes for my ITP Data Representation class. Likely not very useful for people who aren't taking the class.

Published in: Sports, Technology
0 Comments
1 Like
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total views
539
On SlideShare
0
From Embeds
0
Number of Embeds
3
Actions
Shares
0
Downloads
11
Comments
0
Likes
1
Embeds 0
No embeds

No notes for slide
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • \n
  • ITP Data Rep - Class3

    1. 1. Data Representation Day 3
    2. 2. 2. Parse the data into useful Objects
    3. 3. Collections - Arrays, ArrayLists, Objects & Hashmaps
    4. 4. WFF screenshot
    5. 5. API
    6. 6. ApplicationProgrammingInterface
    7. 7. class FeelingObject { String feeling; String sentence;XML String gender; FeelingObject(); }
    8. 8. class FeelingObject { class FeelingObject { class FeelingObject { class FeelingObject {XML String feeling; String feeling; String feeling; String feeling; String sentence; String sentence; String sentence; String sentence; String gender; String gender; String gender; String gender; FeelingObject(); FeelingObject(); FeelingObject(); FeelingObject(); } } } }
    9. 9. class FeelingObject { class FeelingObject { class FeelingObject { class FeelingObject { String feeling; String feeling; String feeling; String feeling; String sentence; String sentence; String sentence; String sentence; String gender; String gender; String gender; String gender; FeelingObject(); FeelingObject(); FeelingObject(); FeelingObject(); } } } } class FeelingObject { class FeelingObject { class FeelingObject { class FeelingObject { String feeling; String feeling; String feeling; String feeling; String sentence; String sentence; String sentence; String sentence; String gender; String gender; String gender; String gender; FeelingObject(); FeelingObject(); FeelingObject(); FeelingObject(); } } } } class FeelingObject { class FeelingObject { class FeelingObject { class FeelingObject {XML String feeling; String feeling; String feeling; String feeling; String sentence; String sentence; String sentence; String sentence; String gender; String gender; String gender; String gender; FeelingObject(); FeelingObject(); FeelingObject(); FeelingObject(); } } } } class FeelingObject { class FeelingObject { class FeelingObject { class FeelingObject { String feeling; String feeling; String feeling; String feeling; String sentence; String sentence; String sentence; String sentence; String gender; String gender; String gender; String gender; FeelingObject(); FeelingObject(); FeelingObject(); FeelingObject(); } } } } class FeelingObject { class FeelingObject { class FeelingObject { class FeelingObject { String feeling; String feeling; String feeling; String feeling; String sentence; String sentence; String sentence; String sentence; String gender; String gender; String gender; String gender; FeelingObject(); FeelingObject(); FeelingObject(); FeelingObject(); } } } }
    10. 10. class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class classXML class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class
    11. 11. class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class classArrayList feelingList = class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class class
    12. 12. Arrays vs. ArrayLists
    13. 13. Arrays vs. ArrayLists
    14. 14. Arrays fast easy to usegood for known quantities
    15. 15. ArrayLists flexible full-featuredgood for changing quantities
    16. 16. Basic ArrayLists ArrayList myList = new ArrayList(); CheeseBurger cb = new CheeseBurger(); myList.add(cb);
    17. 17. Basic ArrayLists CheeseBurger cb = myList.get(0); cb.eat();
    18. 18. Basic ArrayLists CheeseBurger cb = myList.get(0);X cb.eat();
    19. 19. Basic ArrayLists CheeseBurger cb = (CheeseBurger) myList.get(0); cb.eat();
    20. 20. ArrayLists w/ Generics ArrayList<CheeseBurger> myList = new ArrayList(); CheeseBurger cb = new CheeseBurger(); myList.add(cb);
    21. 21. ArrayLists w/ Generics CheeseBurger cb = myList.get(0);√ cb.eat();
    22. 22. HashMaps
    23. 23. HashMapsStore objects by a keyHelpful for keeping counts of categoriesUseful for keeping checklists
    24. 24. HashMapsHashMap<keyType, valueType>myMap = new HashMap();CustomObject o = new CustomObject();myMap.put(key, o);CustomObject o = myMap.get(key)

    ×