added getting available size functionality