All class and their methods will be documentated here
protected void onCreate(Bundle savedInstanceState)
public void onStart()
void photoTaken(ImageProxy ip)
public void saveBitmap(Bitmap output)
void redoPhoto(boolean another)
void bindPreview(@NonNull ProcessCameraProvider cameraProvider, androidx.camera.view.PreviewView previewView)
private Bitmap getBitmap(ImageProxy image)
protected void onCreate(Bundle savedInstanceState)
public void onStart()
private void rmBackground(String fileName)
private Color extractColor (String filename)
private Clothes getClothes(String type)
public void saveBitmap(Bitmap output, String fileName)
public static Bitmap TrimImage(Bitmap bmp)
private void compress(Bitmap image, FileOutputStream output_stream)
public String getDisplayName(Clothes.Type t)
public String getType(String display)
protected void onCreate(Bundle savedInstanceState)
public void onStart()
private void resetFields()
private void edit_account(String username)
private boolean verifyPassword()
protected void onCreate(Bundle savedInstanceState)
public void onStart()
public void getWeather(String lat, String lon)
public void getLocation()
public void populateWeatherLayout(Weather weather)
public Outfit random_outfit()
public void displayOutfit(Outfit outfit)
public Outfit generateOutfitMonochrome ()
public ArrayList<Clothes.Type>validItemsForLayer (int layer)
public int determineOutfitLayers(int oneLyrTmp, int threeLyrTmp)
public boolean colorMatch (@NonNull Color baseCol, @NonNull Color c2)
public boolean checkIfBlackWhite (Color c2)
public double colorDistance(Color e1, Color e2)
protected void onCreate(Bundle savedInstanceState)
public void onStart()
public LoginCustomAdapter(Context aContext, ArrayList users)
public int getCount()
public Object getItem(int position)
public long getItemId(int position)
public View getView(int position, View convertView, ViewGroup parent)
protected void onCreate(Bundle savedInstanceState)
public void onStart()
protected void onCreate(Bundle savedInstanceState)
private void resetFields()
private void make_account(String username)
private boolean verifyPassword()
protected void onCreate(Bundle savedInstanceState)
private void resetEmail(String email)
protected void onCreate(Bundle savedInstanceState)
protected void onCreate(Bundle savedInstanceState)
private void sign_in(String email, String password)
public void onStart()
private void resetFields()
protected void onCreate(Bundle savedInstanceState)
private void signup(String email, String password, String password_verify)
private void resetFields()
private void addAccount(FirebaseUser user)
protected void onCreate(Bundle savedInstanceState)
public void onStart()
public ViewOutfitAdapter(Context aContext, ArrayList outfits, int height, int width, Wardrobe wardrobeNeeded, FireBaseManager fb_manager)
public int getCount()
public Object getItem(int position)
public long getItemId(int position)
public View getView(int position, View convertView, ViewGroup parent)
protected void onCreate(Bundle savedInstanceState)
public void onStart()
public ArrayList getClothes(Integer type)
public MyCustomAdapter(Context aContext, ArrayList clothes, String deletionMsg, String confirm, String confirmMsg )
public int getCount()
public Object getItem(int position)
public long getItemId(int position)
public View getView(int position, View convertView, ViewGroup parent)
public void onDeleteActions(String uID, int position)
public String getDisplayName(Clothes.Type t)
Type:
- T_SHIRT
- LONG_SLEEVE
- SHORTS
- PANTS
- SHOES
- SWEATER
- LIGHT_JACKET
- HEAVY_JACKET
Type type
Color color
boolean waterResistant
private String uniqueId, imageURL
Integer layer
public Clothes(Type type, Color color, String imageURL, boolean waterResistant, Integer layer)
public Type getType()
public boolean isWaterResistant()
public Color getColor()
public String getUniqueId()
public String getImageURL()
public Integer getLayer()
public void setType(Type type)
public void setWaterResistant(Boolean isResistant)
public void setColor(Color color)
public void setUniqueId(String id)
public void setImageURL(String image)
public void setLayer(Integer layer)
public String toString()
public static String[] getTypes(Class<? extends Type> e)
public T_shirt get_tshirt()
public Shirt get_long_sleeve()
publec Shoes get_shoes()
public Pants get_pants()
public Shorts get_shorts()
public LightJacket get_light_jacket()
public HeavyJacket get_heavyjacket()
public Sweater get_sweater()
float red
float green
float blue
float red2
float green2
float blue2
String hex1
String hex2
ArrayList hsl1
ArrayList hsl2
public Color(float r, float g, float b, float r2, float g2, float b2, String hex1, String hex2)
public float getRed()
public float getGreen()
public float getBlue()
public float getRed2()
public float getGreen2()
public float getBlue2()
public String getHex1()
public String getHex2()
public ArrayList getHsl1()
public ArrayList getHsl2()
public ArrayList rgb2hsl(float r, float g, float b)
public String toString()
private static FireBaseManager manager_instance
private final static String TAG = "FireBaseManager"
private FirebaseAuth mAuth
private Profile user
private int user_idx
private FirebaseDatabase database
private DatabaseReference myRef
private FirebaseUser currentUser
private String image_path
private FireBaseManager()
public static FireBaseManager getInstance()
public void setImagePath(String path)
public void setEnableCache(int value)
public void saveCache()
public void saveBitmap(Bitmap output, String fileName)
public void deleteCache()
public String getImagePath()
public Profile getProfile()
public void setProfile(Profile user)
public void addClothes(Clothes new_clothes)
public void updateEditedClothes()
public void deleteItem(String uid)
public void deleteOutFit(String uid)
public User getUser()
public ArrayList getClothes()
public void updateOneLayerTemp(int temp)
public void updateThreeLayerTemp(int temp)
public void updateFlashMode(String temp)
public void updateTheme(int temp)
public void updateLanguage(String temp)
public int getUserIdx()
public void setUserIdx(int userIdx)
public void update()
public void addUser(User user)
public void deleteUser(int user_idx)
public boolean addOutfit(Outfit new_outfit)
public Wardrobe getWardrobe()
public static String sha256(String s)
public HeavyJacket()
public void setLayer(Integer layer)
public LightJacket()
public void setLayer(Integer layer)
private ArrayList clothes_uniqueIds
private String outfitUniqueId
private String name
public Outfit()
public String getName()
public void setName(String name)
public String getOutfitUniqueId()
public void setOutfitUniqueId(String id)
public ArrayList getOutfit()
public void setOutfit(ArrayList outfit)
public void addClothesToOutfit(String clothingId)
public int getSize()
public int compareTo(Outfit outfit)
public Pants()
public void setLayer(Integer layer)
private ArrayList users
private String accountEmail
private String userId
private final static String TAG = "Profile"
public Profile(String accountEmail, String userId)
public ArrayList getUsers()
public String getAccountEmail()
public String getUserId()
public void setUsers(ArrayList users)
public void setAccountEmail(String email)
public void setUserId(String id)
public void addUser(User user)
public void deleteUser(int user_idx)
public String toString()
public static String getAlphaNumericString(int n)
public static void main(String[] args)
public Shirt()
public void setLayer(Integer layer)
public Shoes()
public Shorts()
public void setLayer(Integer layer)
public Sweater()
public void setLayer(Integer layer)
public T_shirt()
public void setLayer(Integer layer)
private String userId, username, password
private Wardrobe wardrobe
private boolean passwordProtected
private User_settings user_settings
public User(String userId, String username)
public User(String userId, String username, Wardrobe wardrobe, boolean password_protected)
public User(String userId, String username, Wardrobe wardrobe, boolean password_protected, String password)
public String getUserId()
public String getUsername()
public Wardrobe getWardrobe()
public boolean getPasswordProtected()
public String getPassword()
public void setPassword(String password)
public User_settings getUserSettings()
public void setUserSettings(User_settings settings)
public boolean setUserId(String userId)
public boolean setUsername(String username)
public boolean setWardrobe(Wardrobe wardrobe)
public boolean setPasswordProtected(boolean password_protected)
public String toString()
int oneLayerTemp, threeLayerTemp, theme, enableCache
String flashMode, language
public void setOneLayerTemp(int temp)
public void setThreeLayerTemp(int temp)
public void setFlashMode(String temp)
public void setTheme(int temp)
public void setLanguage(String lang)
public void setEnableCache(int enable)
public int getOneLayerTemp()
public int getThreeLayerTemp()
public String getFlashMode()
public int getTheme()
public String getLanguage()
public int getEnableCache()
ArrayList clothes
ArrayList outfits
private final static String TAG = "Wardrobe"
public ArrayList getOutfits()
public void addOutfits(ArrayList outfits)
public Outfit getOutfitByUid(String uid)
public boolean deleteOutfitByUid(String uid)
public boolean insertClothes(Clothes clothing)
public boolean deleteItem(String uid)
public Clothes getClothesByUid(String uid)
public boolean addOutfitToWardRobe(Outfit outfit)
public ArrayList getClothes()
public ArrayList getTShirts()
public ArrayList getLongSleeve()
public ArrayList getShoes()
public ArrayList getPants()
public ArrayList getShorts()
public ArrayList getLightJackets()
public ArrayList getHeavyJackets()
public ArrayList getSweater()
private ArrayList getType(Clothes.Type type)
private double currentTemp
private String weatherType
private String weatherDes
private double windSpeed
private double windGust
private double clouds
private double humidity
public Weather(double currentTemp, String weatherType, String weatherDes, double windSpeed, double windGust, double clouds, double humidity)
public double getCurrentTemp()
public String getWeatherType()
public String getWeatherDes()
public double getWindSpeed()
public double getWindGust()
public double getClouds()
public double getHumidity()