You will first be asked to try to settle your case.
You will talk to the landlord or his lawyer and try to make an agreement called a stipulation.
Be very careful what you say. Know what your defenses are and what proof you will show.
If you cannot settle the case with the landlord, you can ask for a trial. In a trial, the judge will listen to the arguments of both sides and decide if you have the right to keep living in the apartment or if the landlord can have you evicted.