How would I write an interface that would enforces the classes that implements it to use func_get_args?
Example:
interface SomeInterface{
function somefunc(); // ???????
}
class SomeClass implements SomeInterface{
function somefunc(){
$args = func_get_args();
}
}
You cannot in PHP. Document the function carefully in the interface.
Most interfaces should contain more lines of comments – explaining what the functions should do when implemented – than actual interface declarations.