seperate portal class

try to make intuitive code.