---
layout: docs
title: setTypef
id: class.Facebook.HackCodegen.CodegenConstant.setTypef
docid: class.Facebook.HackCodegen.CodegenConstant.setTypef
permalink: /docs/reference/class.Facebook.HackCodegen.CodegenConstant.setTypef/
---
# Facebook\\HackCodegen\\CodegenConstant::setTypef()




Set the type of the constant using a %-placeholder format string




``` Hack
public function setTypef(
  HH\Lib\Str\SprintfFormatString $format,
  mixed ...$args,
): this;
```




## Parameters




+ ` HH\Lib\Str\SprintfFormatString $format `
+ ` mixed ...$args `




## Returns




* ` this `