weight enumerator (Complete):

Index the finite field GF(q) in some fixed way:
GF(q) = { ω0=0, ω1, ... , ωq-1 }.
The composition of v = (v1,..,vn) in GF(q)n is defined by
comp(v) = (s0, ... ,sq-1),
where sj=sj(v) denotes the number of components of v equal to ω0. Clearly, Σi=0q-1 si(v)=n, for each v in GF(q)n. For s = (s0, ... ,sq-1) in ZZq, let TC(s) denote the number of codewords c in C with comp(c)=s.

The complete weight enumerator polynomial AC is defined by

WC(z0, ..., zq-1) = Σ i=0 W_C(z0,\dots ,z_{q-1})
             = Σ c in C   z0s0(c) ... zq-1sq-1(c)
             = Σs in ZZq   T_C(s)z0s0 ... zq-1sq-1.

Here ZZ denotes the ring of integers. 

Fact: If x =  z0 and y = z1  = ... = zq-1  then WC(z0, ..., zq-1) = AC(x,y).


weight enumerator (Hamming):

The (Hamming) weight enumerator polynomial AC is defined by

AC(x,y) = Σ i=0 n Ai xn-iyi = xn + Ad xn-dyd+ ... +An yn,

where

Ai = |{c in C | wt(c)=i}|

denotes the number of codewords of weight i. Of course, AC(1,1) = |C|.

See also weight enumerator at Wikipedia.