Methylates CpG residues. Preferentially methylates hemimethylated DNA. It is responsible for maintaining methylation patterns established in development. Mediates transcriptional repression by direct binding to HDAC2. Plays a role in promoter hypermethylation and transcriptional silencing of tumor suppressor genes (TSGs) or other tumor-related genes. Also required to maintain a transcriptionally repressive state of genes in undifferentiated embryonic stem cells (ESCs). Associates at promoter regions of tumor suppressor genes (TSGs) leading to their gene silencing. a 2'-deoxycytidine in DNA + S-adenosyl-L-methionine = a 5-methyl-2'-deoxycytidine in DNA + H(+) + S-adenosyl-L-homocysteine Homodimer (By similarity). Interacts with PCNA (PubMed:9302295). Testis and lung. Belongs to the class I-like SAM-binding methyltransferase superfamily. C5-methyltransferase family.