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




``` Hack
public function addRequireInterface(
  string $interface,
): this;
```




## Parameters




* ` string $interface `




## Returns




- ` this `