Added different function types support